Android crashes on start - java

My app was working fine, until it crashed once and can't run again only on android. IOS is working fine.
build doesn't catch any error, but when I start it on android studio I get these error log.
enter image description here
E/unknown:ReactNative: ReactInstanceManager.createReactContext: mJSIModulePackage not null
E/AndroidRuntime: FATAL EXCEPTION: mqt_js
Process: com.gamo, PID: 17096
java.lang.AssertionError: No source URL loaded, have you initialised the instance?
at com.facebook.infer.annotation.Assertions.assertNotNull(Assertions.java:35)
at com.facebook.react.modules.debug.SourceCodeModule.getTypedExportedConstants(SourceCodeModule.java:39)
at com.facebook.fbreact.specs.NativeSourceCodeSpec.getConstants(NativeSourceCodeSpec.java:35)
at com.facebook.react.bridge.JavaModuleWrapper.getConstants(JavaModuleWrapper.java:129)
at com.facebook.react.bridge.queue.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(MessageQueueThreadHandler.java:27)
at android.os.Looper.loop(Looper.java:223)
at com.facebook.react.bridge.queue.MessageQueueThreadImpl$4.run(MessageQueueThreadImpl.java:226)
at java.lang.Thread.run(Thread.java:923)
I/Process: Sending signal. PID: 17096 SIG: 9
I already tried gradlew clean, cache clean, enable hermes = true

Related

"Unfortunately, app has stopped" error message when I try the app in the emulator [duplicate]

This question already has answers here:
Unable to get provider com.google.android.gms.ads.MobileAdsInitProvider: java.lang.IllegalStateException
(23 answers)
Closed 3 years ago.
I made an android app through android studio and it successfully compiled but when I try it on the emulator I get this error message:
"Unfortunately, app has stopped"
Can anyone please help me?
LogCat:
04-25 15:19:26.613 5309-5309/? I/art: Late-enabling -Xcheck:jni
04-25 15:19:27.446 5309-5309/com.coolclassicgamehandwarriorsepicbattleshoeshoot2playerbeatchildhoodplayfamilyfriendsagainstcomputerrpsboardrockpaperscissorss D/AndroidRuntime: Shutting down VM
04-25 15:19:27.447 5309-5309/com.coolclassicgamehandwarriorsepicbattleshoeshoot2playerbeatchildhoodplayfamilyfriendsagainstcomputerrpsboardrockpaperscissorss E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.coolclassicgamehandwarriorsepicbattleshoeshoot2playerbeatchildhoodplayfamilyfriendsagainstcomputerrpsboardrockpaperscissorss, PID: 5309
java.lang.RuntimeException: Unable to get provider com.google.android.gms.ads.MobileAdsInitProvider: java.lang.IllegalStateException:
******************************************************************************
* The Google Mobile Ads SDK was initialized incorrectly. AdMob publishers *
* should follow the instructions here: to add a valid *
* App ID inside the AndroidManifest. Google Ad Manager publishers should *
* follow instructions here: . *
******************************************************************************
at android.app.ActivityThread.installProvider(ActivityThread.java:5041)
at android.app.ActivityThread.installContentProviders(ActivityThread.java:4633)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4573)
at android.app.ActivityThread.access$1500(ActivityThread.java:153)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1366)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:135)
at android.app.ActivityThread.main(ActivityThread.java:5293)
at java.lang.reflect.Method.invoke(Native Method)
at java.lang.reflect.Method.invoke(Method.java:372)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:903)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:698)
Caused by: java.lang.IllegalStateException:
******************************************************************************
* The Google Mobile Ads SDK was initialized incorrectly. AdMob publishers *
* should follow the instructions here: to add a valid *
* App ID inside the AndroidManifest. Google Ad Manager publishers should *
* follow instructions here: . *
******************************************************************************
at com.google.android.gms.internal.ads.zzabg.attachInfo(Unknown Source)
at com.google.android.gms.ads.MobileAdsInitProvider.attachInfo(Unknown Source)
at android.app.ActivityThread.installProvider(ActivityThread.java:5038)
... 11 more
04-25 15:19:30.305 5309-5309/com.coolclassicgamehandwarriorsepicbattleshoeshoot2playerbeatchildhoodplayfamilyfriendsagainstcomputerrpsboardrockpaperscissorss I/Process: Sending signal. PID: 5309 SIG: 9
Change your theme name in AndroidMenifest.xml file
android->manifest-> then change to android:theme="#style/AppTheme"

ToastFactory crash in HUAWEI Devices

I face crash in HUAWEI Devices with android version 6.0 & 6.0.1.
it looks the crash related to toast in HUAWEI Rom, this information I got from Crashlytics.
even the crash is not in my app package, the crash comes totally from com.huawei.android.hwcontrol.ToastFactory
anyone has any idea how to resolve or overcome this issue?
crash info:
Fatal Exception: android.view.InflateException: Binary XML file line #33: Binary XML file line #33: Error inflating class TextView
at android.view.LayoutInflater.inflate(LayoutInflater.java:558)
at android.view.LayoutInflater.inflate(LayoutInflater.java:434)
at android.view.LayoutInflater.inflate(LayoutInflater.java:377)
at com.huawei.android.hwcontrol.ToastFactory.layoutInflate(ToastFactory.java:55)
at android.widget.Toast.makeText(Toast.java:271)
at android.widget.Toast.makeText(Toast.java:298)
at android.widget.TextView.onTextContextMenuItem(TextView.java:9455)
at android.widget.Editor$TextActionModeCallback.onActionItemClicked(Editor.java:3303)
at com.android.internal.policy.PhoneWindow$DecorView$ActionModeCallback2Wrapper.onActionItemClicked(PhoneWindow.java:3656)
at com.android.internal.view.FloatingActionMode$3.onMenuItemSelected(FloatingActionMode.java:88)
at com.android.internal.view.menu.MenuBuilder.dispatchMenuItemSelected(MenuBuilder.java:761)
at com.android.internal.view.menu.MenuItemImpl.invoke(MenuItemImpl.java:152)
at com.android.internal.view.menu.MenuBuilder.performItemAction(MenuBuilder.java:904)
at com.android.internal.view.menu.MenuBuilder.performItemAction(MenuBuilder.java:894)
at com.android.internal.view.FloatingActionMode$4.onMenuItemClick(FloatingActionMode.java:114)
at com.android.internal.widget.FloatingToolbar$FloatingToolbarMainPanel$1.onClick(FloatingToolbar.java:1045)
at android.view.View.performClick(View.java:5264)
at android.view.View$PerformClick.run(View.java:21297)
at android.os.Handler.handleCallback(Handler.java:743)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:150)
at android.app.ActivityThread.main(ActivityThread.java:5621)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:794)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:684)

NoClassDefFoundError - Only on marshmallow

After a recent commit, my app started crashing on marshmallow. I added a custom class, NormalMode, which is created when a service is started. The bug only occurs when this service is started.
I tried looking into the 65K limit and tried to used multidex, but it didn't make a difference. I also installed a plugin to tell me how many methods I use, it found 54996 methods.
Here is a sample of the logcat, running an emulator:
02-15 18:00:44.428 8783-8783/com.vivescere.beacon I/art: Rejecting re-init on previously-failed class java.lang.Class<com.vivescere.beacon.emitter.mode.NormalMode>
02-15 18:00:44.429 8783-8783/com.vivescere.beacon D/AndroidRuntime: Shutting down VM
02-15 18:00:44.429 8783-8783/com.vivescere.beacon E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.vivescere.beacon, PID: 8783
java.lang.NoClassDefFoundError: com.vivescere.beacon.emitter.mode.NormalMode
at com.vivescere.beacon.emitter.EmitterService.switchMode(EmitterService.java:328)
at com.vivescere.beacon.emitter.EmitterService.start(EmitterService.java:289)
at com.vivescere.beacon.emitter.EmitterService.onStartCommand(EmitterService.java:163)
at android.app.ActivityThread.handleServiceArgs(ActivityThread.java:3010)
at android.app.ActivityThread.-wrap17(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1442)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5417)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
02-15 18:00:48.441 8783-8783/com.vivescere.beacon I/Process: Sending signal. PID: 8783 SIG: 9
I tried removing the class in question, but it just slows down the error, which now happens when creating an instance of the next custom class I have.

Unable to run app on Nexus 6

My app is working perfectly on Samsung Galaxy S4, but when I try to run it on Motorola Nexus 6 , I get runtime exception.
I have recently changed build variants: presentation:devDebug, data:debug
gradleVersion '2.14.1'
12-01 20:52:37.357 1808-1808/? E/ctxmgr: [PlaceFenceHelper]NearbyBuffer is null!
12-01 20:52:37.770 846-6904/? E/ActivityManager: applyOptionsLocked: Unknown animationType=0
12-01 20:26:07.847 21100-21107/? E/art: Failed sending reply to debugger: Broken pipe
12-01 20:26:08.694 21100-21100/? E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.dev.debug, PID: 21100
java.lang.NoClassDefFoundError: Failed resolution of: Lorg/spongycastle/jce/provider/BouncyCastleProvider;
at com.q42.qlassified.Provider.QlassifiedCrypto.encrypt(QlassifiedCrypto.java:31)
at com.q42.qlassified.Provider.QlassifiedKeyStore.encrypt(QlassifiedKeyStore.java:177)
at com.q42.qlassified.Provider.QlassifiedKeyStore.encryptEntry(QlassifiedKeyStore.java:119)
at com.q42.qlassified.QlassifiedFactory.put(QlassifiedFactory.java:70)
at com.q42.qlassified.Qlassified.put(Qlassified.java:120)
at com..presenter.utils.QlassifiedHelper.generateEncryptionKey(QlassifiedHelper.java:38)
at com.presenter.BaseApplication.initMainRealmConfiguration(BaseApplication.java:32)
at com.presenter.AndroidApplication.onCreate(AndroidApplication.java:24)
I think you have to check the runtime permission if your device has marshmellow OS.

Sensortag20 Program Crashes connecting to bluetooth device

I'm trying to modify this project from android studio 2 but when I try to run the app from Android 4.4.2 and connect to a bluetooth device, it gives these error messages.
06-02 14:51:30.126 12669-12669/com.example.ti.ble.sensortag E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.example.ti.ble.sensortag, PID: 12669
java.lang.IllegalArgumentException: null is not a valid Bluetooth address
at android.bluetooth.BluetoothDevice.<init>(BluetoothDevice.java:564)
at android.bluetooth.BluetoothAdapter.getRemoteDevice(BluetoothAdapter.java:418)
at com.example.ti.ble.common.BluetoothLeService.disconnect(BluetoothLeService.java:635)
at com.example.ti.ble.sensortag.MainActivity.onConnect(MainActivity.java:320)
at com.example.ti.ble.sensortag.MainActivity.onDeviceClick(MainActivity.java:379)
at com.example.ti.ble.sensortag.ScanView$1.onItemClick(ScanView.java:205)
at android.widget.AdapterView.performItemClick(AdapterView.java:299)
at android.widget.AbsListView.performItemClick(AbsListView.java:1152)
at android.widget.AbsListView$PerformClick.run(AbsListView.java:3014)
at android.widget.AbsListView$3.run(AbsListView.java:3865)
at android.os.Handler.handleCallback(Handler.java:808)
at android.os.Handler.dispatchMessage(Handler.java:103)
at android.os.Looper.loop(Looper.java:193)
at android.app.ActivityThread.main(ActivityThread.java:5341)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:825)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:641)
at dalvik.system.NativeStart.main(Native Method)
The project can be found here SensorTag20 Project. How do I fix these problems?
Turns out, I just needed to restart the device everytime I reprogram it.

Categories

Resources