microsoft / react-native-code-push

React Native module for CodePush
http://appcenter.ms
Other
8.87k stars 1.45k forks source link

Android app crash and rollback after codepush update #2691

Closed DongGukMon closed 1 day ago

DongGukMon commented 2 months ago

After the codepush update, the app shuts down with a 50% probability and appears as rollback. And if you check the logcat, you'll see "java.lang.NullPointerException: Parameters specified as non-null is null: method androidx.lifecycle.LifecycleRegistry.removeObserver, parameterObserver" error. What did I do wrong?

Environment

DongGukMon commented 2 months ago

I noticed that it was a collision with sentry, and I solved it by upgrading the sentry library to the latest version. However, since then, there has been a crash with errors such as "failed to read /proc/uptime: permission denied" and "ReadableNativeArray cannot be cast to java.lang.string", which also seems to be an occasional issue, so I will share it again when I find out the cause and solution.

Yamini0 commented 2 months ago

Hey @DongGukMon Im facing the same issue can you tell if you were able to resolve the error?

nppull commented 2 months ago

Environment react-native-code-push: 8.2.2 react-native: 0.73.5

Error

react-native-code-push could not be found within the project or in these directories:
import codePush from "react-native-code-push";

Solution Work good with react-native-code-push: 8.2.1

DmitriyKirakosyan commented 3 weeks ago

@nppull, this error does not seem related to the original issue. Please ensure that the react-native-code-push package is correctly added to your app. Try creating a fresh app with react-native-code-push and see if it works. If it does, check for any differences that could potentially cause the issue in your main application. If the issue reproduces on the new app, please file a separate issue with the demo app attached.

DmitriyKirakosyan commented 3 weeks ago

@Yamini0 , are you having the exact same error as in the issue description? Are you using sentry as well?

DmitriyKirakosyan commented 1 day ago

Closing due to inactivity.