react-native-purchases icon indicating copy to clipboard operation
react-native-purchases copied to clipboard

Android v4 to v5 NativeModules argument mismatch – Required Google Play upgrade

Open masiamj opened this issue 1 year ago • 9 comments

Describe the bug Hi all, first-off thanks for your awesome library. I love this package and the RevenueCat ecosystem.

Unfortunately, upon submitting a new version of my app to the Play Store this week I was met with an error that the Google Play Store billing API version has been deprecated and must be upgraded before submitting a new version. Admittedly, my team is way out of date here.

image

As such, I would like to perform an upgrade from react-native-purchases@4 to react-native-purchases@5 which should be mostly backward compatible (without changing the structure of our subscription packages).

I spent time reviewing the changelog and decided to upgrade to v5.16.0 and followed the guide here: https://github.com/RevenueCat/react-native-purchases/blob/main/v4_to_v5_migration_guide.md.

For the most part this was extremely smooth and the naming convention changes and configuration API changes make sense and are very reasonable.

I was then able to bundle the aab; however, upon testing my app, I'm receiving crashes due to a native module argument mismatch. See the error here: image

I reviewed the package code and native code being called and it appears that everything should be fine. The logcat message is correct that the native module requires 6 arguments and I can confirm that the JS layer does pass all the required arguments.

So now, I'm just a little stuck and would love any help/input/insights your team or the community may have. This is a blocker for me releasing the next version of our app.

Thanks so much!

  1. Environment
    1. Platform: Android
    2. SDK version: 33
    3. OS version:
    4. Xcode/Android Studio version: Build #AI-223.8836.35.2231.10671973, built on August 17, 2023 Runtime version: 17.0.6+0-17.0.6b829.9-10027231 aarch64
    5. React Native version: 0.70.5
    6. SDK installation (CocoaPods + version or manual):
    7. How widespread is the issue. Percentage of devices affected.
  2. Debug logs that reproduce the issue
  3. Steps to reproduce, with a description of expected vs. actual behavior
  4. Other information (e.g. stacktraces, related issues, suggestions how to fix, links for us to have context, eg. stackoverflow, etc.)

Additional context It looks like others are having this issue as well but was previously closed due to inactivity: https://github.com/RevenueCat/react-native-purchases/issues/159.

masiamj avatar Nov 23 '23 03:11 masiamj