You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, im using react-native 0.74.3
and everything works ok in debug mode but app crashes in release build and here is the log cat :
error: MAJOR_VERSION not found in .env, js engine: hermes
2024-07-06 21:20:13.008 21766-21825 ReactNativeJS app.myapp Invariant Violation: "myApp" has not been registered. This can happen if:
* Metro (the local dev server) is run from the wrong folder. Check if Metro is running, stop it and restart it in the current project.
* A module failed to load due to an error and `AppRegistry.registerComponent` wasn't called., js engine: hermes
2024-07-06 21:20:13.023 21766-21826 AndroidRuntime app.myapp
E FATAL EXCEPTION: mqt_native_modules
Process: app.myapp , PID: 21766
com.facebook.react.common.JavascriptException: Error: MAJOR_VERSION not found in .env, js engine: hermes, stack:
accessEnv@1:2958807
getAppVersionName@1:2958848
anonymous@1:2963752
loadModuleImplementation@1:169385
guardedLoadModule@1:168619
metroRequire@1:167902
anonymous@1:2959392
loadModuleImplementation@1:169385
guardedLoadModule@1:168619
metroRequire@1:167902
anonymous@1:2473344
loadModuleImplementation@1:169385
guardedLoadModule@1:168619
metroRequire@1:167902
anonymous@1:2467551
loadModuleImplementation@1:169385
guardedLoadModule@1:168619
metroRequire@1:167902
anonymous@1:2464542
loadModuleImplementation@1:169385
guardedLoadModule@1:168619
metroRequire@1:167902
anonymous@1:2280849
loadModuleImplementation@1:169385
guardedLoadModule@1:168619
metroRequire@1:167902
anonymous@1:1680042
loadModuleImplementation@1:169385
guardedLoadModule@1:168619
metroRequire@1:167902
anonymous@1:178899
loadModuleImplementation@1:169385
guardedLoadModule@1:168576
metroRequire@1:167902
global@1:166966
at com.facebook.react.modules.core.ExceptionsManagerModule.reportException(SourceFile:76)
at java.lang.reflect.Method.invoke(Native Method)
at com.facebook.react.bridge.JavaMethodWrapper.invoke(SourceFile:155)
at com.facebook.react.bridge.JavaModuleWrapper.invoke(SourceFile:20)
at com.facebook.jni.NativeRunnable.run(Native Method)
at android.os.Handler.handleCallback(Handler.java:938)
at android.os.Handler.dispatchMessage(Handler.java:99)
at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(SourceFile:1)
at android.os.Looper.loop(Looper.java:223)
at com.facebook.react.bridge.queue.MessageQueueThreadImpl$4.run(SourceFile:38)
at java.lang.Thread.run(Thread.java:923)
2024-07-06 21:20:13.070 21766-21766 OrientationModule app.myapp D onActivityPaused
MAJOR_VERSION is my first variable inside env and since it cant read that it will crash !
The text was updated successfully, but these errors were encountered:
Problems with Proguard
When Proguard is enabled (which it is by default for Android release builds), it can rename the BuildConfig Java class in the minification process and prevent React Native Config from referencing it. To avoid this, add an exception to android/app/proguard-rules.pro:
-keep class com.yourpackage.BuildConfig { *; }
com.yourpackage should match the package value in your app/src/main/AndroidManifest.xml file.
Hello, im using react-native 0.74.3
and everything works ok in debug mode but app crashes in release build and here is the log cat :
MAJOR_VERSION is my first variable inside env and since it cant read that it will crash !
The text was updated successfully, but these errors were encountered: