Closed Koppel-Zhou closed 3 years ago
拍照结束后确定照片后应用重启了,非必现,Bugsnag捕捉报错如下:
java.lang.RuntimeException Failure delivering result ResultInfo{who=null, request=188, result=-1, data=Intent { (has extras) }} to activity {com.shuidao.partdealer/com.shuidao.partdealer.MainActivity}: java.lang.NullPointerException: Attempt to invoke interface method 'boolean com.facebook.react.bridge.ReadableMap.getBoolean(java.lang.String)' on a null object reference ActivityThread.java:5471 android.app.ActivityThread.deliverResults ActivityThread.java:5512 android.app.ActivityThread.handleSendResult ActivityResultItem.java:51 android.app.servertransaction.ActivityResultItem.execute TransactionExecutor.java:149 android.app.servertransaction.TransactionExecutor.executeCallbacks TransactionExecutor.java:103 android.app.servertransaction.TransactionExecutor.execute ActivityThread.java:2386 android.app.ActivityThread$H.handleMessage Handler.java:107 android.os.Handler.dispatchMessage Looper.java:213 android.os.Looper.loop ActivityThread.java:8178 android.app.ActivityThread.main Method.java:-2 java.lang.reflect.Method.invoke RuntimeInit.java:513 com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run ZygoteInit.java:1101 com.android.internal.os.ZygoteInit.main Caused by: java.lang.NullPointerException Attempt to invoke interface method 'boolean com.facebook.react.bridge.ReadableMap.getBoolean(java.lang.String)' on a null object reference RNSyanImagePickerModule.java:374 com.syanpicker.RNSyanImagePickerModule.onGetResult RNSyanImagePickerModule.java:42 com.syanpicker.RNSyanImagePickerModule.access$000 RNSyanImagePickerModule.java:326 com.syanpicker.RNSyanImagePickerModule$1$1.run Thread.java:929 java.lang.Thread.run RNSyanImagePickerModule.java:328 com.syanpicker.RNSyanImagePickerModule$1.onActivityResult ReactContext.java:288 com.facebook.react.bridge.ReactContext.onActivityResult ReactInstanceManager.java:738 com.facebook.react.ReactInstanceManager.onActivityResult ReactDelegate.java:90 com.facebook.react.ReactDelegate.onActivityResult ReactActivityDelegate.java:112 com.facebook.react.ReactActivityDelegate.onActivityResult ReactActivity.java:68 com.facebook.react.ReactActivity.onActivityResult Activity.java:8413 android.app.Activity.dispatchActivityResult ActivityThread.java:5464 android.app.ActivityThread.deliverResults ActivityThread.java:5512 android.app.ActivityThread.handleSendResult ActivityResultItem.java:51 android.app.servertransaction.ActivityResultItem.execute TransactionExecutor.java:149 android.app.servertransaction.TransactionExecutor.executeCallbacks TransactionExecutor.java:103 android.app.servertransaction.TransactionExecutor.execute ActivityThread.java:2386 android.app.ActivityThread$H.handleMessage Handler.java:107 android.os.Handler.dispatchMessage Looper.java:213 android.os.Looper.loop ActivityThread.java:8178 android.app.ActivityThread.main Method.java:-2 java.lang.reflect.Method.invoke RuntimeInit.java:513 com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run ZygoteInit.java:1101 com.android.internal.os.ZygoteInit.main
机型:荣耀V10
这个问题,我这里是必现🙃
找到原因了,是我写的原生库的问题,onActivityResult回调没有做好判断,直接返回了,写的随意了
拍照结束后确定照片后应用重启了,非必现,Bugsnag捕捉报错如下:
机型:荣耀V10