Attempt to read from field 'int com.android.server.wm.Task.mTaskId' on a null object reference
Asked Answered
D

1

6

I am getting below exception in my firebase crashlytics console.

Fatal Exception: java.lang.NullPointerException: Attempt to read from field 'int com.android.server.wm.Task.mTaskId' on a null object reference
       at android.os.Parcel.createExceptionOrNull(Parcel.java:2391)
       at android.os.Parcel.createException(Parcel.java:2369)
       at android.os.Parcel.readException(Parcel.java:2352)
       at android.os.Parcel.readException(Parcel.java:2294)
       at android.app.IActivityTaskManager$Stub$Proxy.reportAssistContextExtras(IActivityTaskManager.java:5748)
       at android.app.ActivityThread.handleRequestAssistContextExtras(ActivityThread.java:4115)
       at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2262)
       at android.os.Handler.dispatchMessage(Handler.java:106)
       at android.os.Looper.loop(Looper.java:246)
       at android.app.ActivityThread.main(ActivityThread.java:8512)
       at java.lang.reflect.Method.invoke(Method.java)
       at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:602)
       at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1130)

Caused by android.os.RemoteException: Remote stack trace:
    at com.android.server.wm.ActivityTaskManagerService.reportAssistContextExtras(ActivityTaskManagerService.java:4079)
    at android.app.IActivityTaskManager$Stub.onTransact(IActivityTaskManager.java:2645)
    at android.os.Binder.execTransactInternal(Binder.java:1195)
    at android.os.Binder.execTransact(Binder.java:1159)
Darlinedarling answered 2/7, 2021 at 13:5 Comment(4)
Any updates on this issue, I'm facing the same crash !Oswald
any updates on this?Dominy
any updates on this ? please replySolidus
Facing the same prblem. Wonder if there should be a bug report for Android.Garrott
D
0

I have a similar problem

java.lang.NullPointerException: Attempt to read from field 'int 
com.android.server.wm.Task.mTaskId' on a null object reference
at android.os.Parcel.createExceptionOrNull(Parcel.java:2391)
at android.os.Parcel.createException(Parcel.java:2369)
at android.os.Parcel.readException(Parcel.java:2352)
at android.os.Parcel.readException(Parcel.java:2294)
at android.app.IActivityTaskManager$Stub$Proxy.reportAssistContextExtras(IActivityTaskManager.java:5765)
at android.app.ActivityThread.handleRequestAssistContextExtras(ActivityThread.java:4169)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2291)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:246)
at android.app.ActivityThread.main(ActivityThread.java:8653)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:602)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1130)
Caused by: android.os.RemoteException: Remote stack trace:
at com.android.server.wm.ActivityTaskManagerService.reportAssistContextExtras(ActivityTaskManagerService.java:4114)
at android.app.IActivityTaskManager$Stub.onTransact(IActivityTaskManager.java:2653)
at android.os.Binder.execTransactInternal(Binder.java:1190)
at android.os.Binder.execTransact(Binder.java:1159)

Then we found out that the reason is Someone is doing overtime processing in Activity-lifecyle,and guess timeout lead the IActivityTaskManager broken.

it also lead to high ANR

at java.lang.Object.wait (Native method)
at java.lang.Object.wait (Object.java:442)
at java.lang.Object.wait (Object.java:568)
at *****(Manual shielding of business privacy)****
at android.app.Application.dispatchActivityStarted (Application.java:425)
at android.app.Activity.dispatchActivityStarted (Activity.java:1382)
at android.app.Activity.onStart (Activity.java:1873)
at androidx.fragment.app.FragmentActivity.onStart (FragmentActivity.java:536)
at androidx.appcompat.app.AppCompatActivity.onStart (AppCompatActivity.java:210)
at android.app.Instrumentation.callActivityOnStart (Instrumentation.java:1435)
at android.app.Activity.performStart (Activity.java:8231)
at android.app.ActivityThread.handleStartActivity (ActivityThread.java:3864)
at android.app.servertransaction.TransactionExecutor.performLifecycleSequence (TransactionExecutor.java:221)
at android.app.servertransaction.TransactionExecutor.cycleToPath (TransactionExecutor.java:201)
at android.app.servertransaction.TransactionExecutor.executeLifecycleState (TransactionExecutor.java:173)
at android.app.servertransaction.TransactionExecutor.execute (TransactionExecutor.java:97)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:2328)
at android.os.Handler.dispatchMessage (Handler.java:106)
at android.os.Looper.loop (Looper.java:246)
at android.app.ActivityThread.main (ActivityThread.java:8633)
at java.lang.reflect.Method.invoke (Native method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:602)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:1130)

In case of similar problems, it is recommended to check whether the Activity lifecycle timeout

Deathlike answered 26/5, 2022 at 9:2 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.