firebase crash logs one.
Fatal Exception: java.lang.IllegalStateException: CameraDevice was already closed
at android.hardware.camera2.impl.CameraDeviceImpl.checkIfCameraClosedOrInError(CameraDeviceImpl.java:2236)
at android.hardware.camera2.impl.CameraDeviceImpl.createCaptureSessionInternal(CameraDeviceImpl.java:658)
at android.hardware.camera2.impl.CameraDeviceImpl.createCaptureSession(CameraDeviceImpl.java:644)
at io.flutter.plugins.camera.Camera$DefaultCameraDeviceWrapper.createCaptureSession(Camera.java:175)
at io.flutter.plugins.camera.Camera.createCaptureSessionWithSessionConfig(Camera.java:479)
at io.flutter.plugins.camera.Camera.createCaptureSession(Camera.java:465)
at io.flutter.plugins.camera.Camera.createCaptureSession(Camera.java:387)
at io.flutter.plugins.camera.Camera.startPreview(Camera.java:1074)
at io.flutter.plugins.camera.Camera$1.onOpened(Camera.java:322)
at android.hardware.camera2.impl.CameraDeviceImpl$1.run(CameraDeviceImpl.java:151)
at android.os.Handler.handleCallback(Handler.java:938)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:246)
at android.os.HandlerThread.run(HandlerThread.java:67)
firebase crash logs two.
Fatal Exception: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.hardware.camera2.CameraCaptureSession.close()' on a null object reference
at io.flutter.plugins.camera.Camera.closeCaptureSession(Camera.java:1192)
at io.flutter.plugins.camera.Camera.access$500(Camera.java:100)
at io.flutter.plugins.camera.Camera$1.onClosed(Camera.java:342)
at android.hardware.camera2.impl.CameraDeviceImpl$5.run(CameraDeviceImpl.java:255)
at android.os.Handler.handleCallback(Handler.java:942)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loopOnce(Looper.java:240)
at android.os.Looper.loop(Looper.java:351)
at android.os.HandlerThread.run(HandlerThread.java:67)
two crashes caught in my firebase account.
by investigations, It happened at the camera plugin used in flutter modules,
It's happening on android devices only, versions are 9 to 12 versions.
Used plugin details:
camera: ^0.10.0
https://pub.dev/packages/camera
any one can help with this, ?
Related
I have recently find that my app is getting crash on Xiaomi/Redmi device with following stack trace
Fatal Exception: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.view.View.destroyHardwareResources()' on a null object reference
at android.view.ViewGroup.destroyHardwareResources(ViewGroup.java:5263)
at android.view.ViewGroup.destroyHardwareResources(ViewGroup.java:5263)
at android.view.ViewGroup.destroyHardwareResources(ViewGroup.java:5263)
at android.view.ViewGroup.destroyHardwareResources(ViewGroup.java:5263)
at android.view.ViewGroup.destroyHardwareResources(ViewGroup.java:5263)
at android.view.ViewGroup.destroyHardwareResources(ViewGroup.java:5263)
at android.view.ThreadedRenderer.destroyResources(ThreadedRenderer.java:446)
at android.view.ThreadedRenderer.destroyHardwareResources(ThreadedRenderer.java:441)
at android.view.ViewRootImpl.destroyHardwareResources(ViewRootImpl.java:1315)
at android.view.WindowManagerGlobal.trimMemory(WindowManagerGlobal.java:598)
at android.app.ActivityThread.handleTrimMemory(ActivityThread.java:6499)
at android.app.ActivityThread.access$1500(ActivityThread.java:263)
at android.app.ActivityThread$ApplicationThread.lambda$scheduleTrimMemory$0(ActivityThread.java:1699)
at android.app.-$$Lambda$ActivityThread$ApplicationThread$tUGFX7CUhzB4Pg5wFd5yeqOnu38.accept(-.java:8)
at com.android.internal.util.function.pooled.PooledLambdaImpl.doInvoke(PooledLambdaImpl.java:278)
at com.android.internal.util.function.pooled.PooledLambdaImpl.invoke(PooledLambdaImpl.java:201)
at com.android.internal.util.function.pooled.OmniFunction.run(OmniFunction.java:97)
at android.view.Choreographer$CallbackRecord.run(Choreographer.java:1039)
at android.view.Choreographer.doCallbacks(Choreographer.java:863)
at android.view.Choreographer.doFrame(Choreographer.java:796)
at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:1024)
at android.os.Handler.handleCallback(Handler.java:938)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:236)
at android.app.ActivityThread.main(ActivityThread.java:8069)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:620)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1011)`
I am not able to reproduce it
Android os : 11
Devcies : Redmi Note 9,Redmi 9, Redmi 10 2022 and some more redmi devices
I have googled but did not find any solution or hint regarding this issue, is there anyone facing some issue ?
I am developing android app using camera2 api. I am getting following crash sometimes for some reason.
E/AndroidRuntime: FATAL EXCEPTION: LegacyCameraCallback
Process: com.vuro, PID: 5793
java.lang.NullPointerException: Attempt to invoke virtual method 'java.util.List android.hardware.camera2.params.OutputConfiguration.getSurfaces()' on a null object reference
at android.hardware.camera2.impl.CameraDeviceImpl$CameraDeviceCallbacks.onCaptureErrorLocked(CameraDeviceImpl.java:2276)
at android.hardware.camera2.impl.CameraDeviceImpl$CameraDeviceCallbacks.onDeviceError(CameraDeviceImpl.java:1914)
at android.hardware.camera2.legacy.CameraDeviceUserShim$CameraCallbackThread$CallbackHandler.handleMessage(CameraDeviceUserShim.java:308)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:193)
at android.os.HandlerThread.run(HandlerThread.java:65)
E/AWSKeyValueStore: com.amazonaws.internal.keyvaluestore.KeyNotFoundException: Error occurred while accessing AndroidKeyStore to retrieve the key for keyAlias: com.amazonaws.mobile.client.aesKeyStoreAlias
I/AWSKeyValueStore: Deleting the encryption key identified by the keyAlias: com.amazonaws.mobile.client.aesKeyStoreAlias
I/tensorflow: MultiBoxTracker: Processing 0 results from 22
I/Process: Sending signal. PID: 5793 SIG: 9
If anyone has experience in this crash, Please help me.
Thank you.
I'm trying to implement the sample code of dji developer for android but i can't start the app, i add my com.dji.sdk.API_KEY and when i launch the app i get this errors:
2020-04-03 19:44:10.734 5567-5607/com.dji.sdk.sample E/AndroidRuntime: FATAL EXCEPTION: AsyncTask #1
Process: com.dji.sdk.sample, PID: 5567
java.lang.UnsatisfiedLinkError: No implementation found for java.lang.String dji.midware.natives.SDKRelativeJNI.native_getUsbAccessoryAttachedString() (tried Java_dji_midware_natives_SDKRelativeJNI_native_1getUsbAccessoryAttachedString and Java_dji_midware_natives_SDKRelativeJNI_native_1getUsbAccessoryAttachedString__)
at dji.midware.natives.SDKRelativeJNI.native_getUsbAccessoryAttachedString(Native Method)
at dji.sdk.sdkmanager.DJISDKManager.<clinit>(Unknown Source:32)
at dji.sdk.sdkmanager.DJISDKManager.getInstance(Unknown Source:0)
at com.dji.sdk.sample.internal.controller.MainActivity$5.run(:241)
at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:289)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
at java.lang.Thread.run(Thread.java:919)
If you need code of any thing i can post it too. Thanks.
EDIT:
I can do it with an hardware Samsung, not in virtual device.
I'm using an emulator, but the MSDK doesn't support it.
It only works with a real device.
I have a strange bug reported on Crashlytics:
Fatal Exception: java.lang.NullPointerException: Attempt to read from null array
at java.util.ArrayList.get(ArrayList.java:310)
at com.google.maps.api.android.lib6.gmm6.vector.gl.drawable.g.a(g.java:56)
at com.google.maps.api.android.lib6.gmm6.vector.gl.drawable.ao.a(ao.java:91)
at com.google.maps.api.android.lib6.gmm6.store.fetch.i.a(i.java:99)
at com.google.maps.api.android.lib6.gmm6.store.fetch.f.a(f.java:3)
at com.google.maps.api.android.lib6.gmm6.store.j.a(j.java:19)
at com.google.maps.api.android.lib6.gmm6.store.k.a(k.java:96)
at com.google.maps.api.android.lib6.gmm6.store.k.d(k.java:178)
at com.google.maps.api.android.lib6.gmm6.store.k.a(k.java:31)
at com.google.maps.api.android.lib6.gmm6.store.f.handleMessage(f.java:100)
at android.os.Handler.dispatchMessage(Handler.java:111)
at android.os.Looper.loop(Looper.java:194)
at com.google.maps.api.android.lib6.gmm6.store.k.run(k.java:126)
at com.google.maps.api.android.lib6.gmm6.store.ab.run(ab.java:12)
It happens only on some devices with Android 5 (Lenovo, Gigabyte, Acer...)
Do you have an idea how to solve this?
In my project i'm using the monetization service(Vungle/AppLovin).
When I'm trying to load an ad, i get this exception
E/AndroidRuntime: FATAL EXCEPTION: GoogleApiHandler
Process: kz.ikar, PID: 3673
java.lang.NoSuchMethodError: No virtual method setChannelId(Ljava/lang/String;)Landroid/support/v4/app/NotificationCompat$Builder; in class Landroid/support/v4/app/NotificationCompat$Builder; or its super classes (declaration of 'android.support.v4.app.NotificationCompat$Builder' appears in /data/app/kz.ikar-2oCl4DY4J8w7wP-jirbYvA==/split_lib_dependencies_apk.apk)
at com.google.android.gms.common.GoogleApiAvailability.zza(Unknown Source:225)
at com.google.android.gms.common.GoogleApiAvailability.zza(Unknown Source:15)
at com.google.android.gms.common.api.internal.zzbm.zzc(Unknown Source:4)
at com.google.android.gms.common.api.internal.zzbo.onConnectionFailed(Unknown Source:104)
at com.google.android.gms.common.api.internal.zzbo.connect(Unknown Source:83)
at com.google.android.gms.common.api.internal.zzbo.zza(Unknown Source:47)
at com.google.android.gms.common.api.internal.zzbm.handleMessage(Unknown Source:283)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:164)
at android.os.HandlerThread.run(HandlerThread.java:65)
In my project I have two fragments in one activity. The user gets an ad in the second one. If I load an ad from the activity, it works well. What can be the cause of this issue?
By the way both ad networks(Vungle and AppLovin) return this exception
I had the same problem and I fixed it downgrading to firebase Google Play services 11.6.0
One reason you could be getting this error is if your buildToolsVersion in your app-level Gradle is less than 26. Either that or your v4 support is less than 26.0.0 seeing as NotificationCompat.Builder was added in API 26.