Fixed
Status Update
Comments
da...@google.com <da...@google.com> #2
In SystemJobService, it can expect null, and able to tolerance null from WorkManagerImpl.getInstance, due to auto-backup reason.
@Override
public void onCreate() {
super.onCreate();
mWorkManagerImpl = WorkManagerImpl.getInstance(getApplicationContext());
if (mWorkManagerImpl == null) {
// This can occur if...
// 1. The app is performing an auto-backup. Prior to O, JobScheduler could erroneously
// try to send commands to JobService in this state ( b/32180780 ). Since neither
// Application#onCreate nor ContentProviders have run, WorkManager won't be
// initialized. In this case, we should ignore all JobScheduler commands and tell it
// to retry.
But, current WorkManagerImpl.getInstance(Context context) implementation is that, it will never return null but throw IllegalStateException.
Isn't there's conflict among these 2 SystemJobService.onCreate logic, and WorkManagerImpl.getInstance logic?
@Override
public void onCreate() {
super.onCreate();
mWorkManagerImpl = WorkManagerImpl.getInstance(getApplicationContext());
if (mWorkManagerImpl == null) {
// This can occur if...
// 1. The app is performing an auto-backup. Prior to O, JobScheduler could erroneously
// try to send commands to JobService in this state (
// Application#onCreate nor ContentProviders have run, WorkManager won't be
// initialized. In this case, we should ignore all JobScheduler commands and tell it
// to retry.
But, current WorkManagerImpl.getInstance(Context context) implementation is that, it will never return null but throw IllegalStateException.
Isn't there's conflict among these 2 SystemJobService.onCreate logic, and WorkManagerImpl.getInstance logic?
b....@gmail.com <b....@gmail.com> #3
Project: platform/frameworks/support
Branch: androidx-master-dev
commit e14104eb7008f82edd50b37e16bd119b307e0554
Author: Sumir Kataria <sumir@google.com>
Date: Mon Jun 24 10:50:57 2019
Fix for JobScheduler calls when backup is in progress.
The original fix (ag/Ia1604b7c4b98f6b31869e1161a0c1efce7fe46f2) relied
on a null-check, but the new version of WorkManager.getInstance(Context)
with the Context param doesn't return null; it throws an Exception. This
CL updates the three places where we explicitly check for the return value
internally:
1. SystemJobService (the main place where this would manifest)
2. RescheduleReceiver
3. WorkManagerTestInitHelper (for consistency)
Fixes: 135858602
Test: Ran existing tests
Change-Id: Ia232869712d0c78fd80e91d0a863b8c50a080400
M work/workmanager-testing/src/main/java/androidx/work/testing/WorkManagerTestInitHelper.java
M work/workmanager/src/main/java/androidx/work/impl/background/systemalarm/RescheduleReceiver.java
M work/workmanager/src/main/java/androidx/work/impl/background/systemjob/SystemJobService.java
https://android-review.googlesource.com/988026
https://goto.google.com/android-sha1/e14104eb7008f82edd50b37e16bd119b307e0554
Branch: androidx-master-dev
commit e14104eb7008f82edd50b37e16bd119b307e0554
Author: Sumir Kataria <sumir@google.com>
Date: Mon Jun 24 10:50:57 2019
Fix for JobScheduler calls when backup is in progress.
The original fix (ag/Ia1604b7c4b98f6b31869e1161a0c1efce7fe46f2) relied
on a null-check, but the new version of WorkManager.getInstance(Context)
with the Context param doesn't return null; it throws an Exception. This
CL updates the three places where we explicitly check for the return value
internally:
1. SystemJobService (the main place where this would manifest)
2. RescheduleReceiver
3. WorkManagerTestInitHelper (for consistency)
Fixes: 135858602
Test: Ran existing tests
Change-Id: Ia232869712d0c78fd80e91d0a863b8c50a080400
M work/workmanager-testing/src/main/java/androidx/work/testing/WorkManagerTestInitHelper.java
M work/workmanager/src/main/java/androidx/work/impl/background/systemalarm/RescheduleReceiver.java
M work/workmanager/src/main/java/androidx/work/impl/background/systemjob/SystemJobService.java
su...@google.com <su...@google.com>
b....@gmail.com <b....@gmail.com> #4
Thanks you so much for the speedy fixed!
May I know when will it be ready for production? As, currently, this IllegalStateException is impacting our users.
May I know when will it be ready for production? As, currently, this IllegalStateException is impacting our users.
su...@google.com <su...@google.com> #5
Hello, please look for this later in the week. If you want to work around this bug specifically and don't need on-demand initialization, you can use the old (deprecated) WorkManager.getInstance() method for now.
b....@gmail.com <b....@gmail.com> #6
Hello. Thanks for respond. I surely will keep a pair of eye on the next release :)
Yes. We don't need on-demand initialization. May I know how does using old (deprecated) WorkManager.getInstance() in our app code, able to bypass this problem? Isn't the crash is origin from library internal SystemJobService?
We once thinking to bypass this problem, by switching back to Version 2.0.1 (The version just before WorkManager.getInstance(Context) is introduced). However, we notice Room version is being changed in between. Downgrading WorkManager version, might cause additional SQLite problem.
Yes. We don't need on-demand initialization. May I know how does using old (deprecated) WorkManager.getInstance() in our app code, able to bypass this problem? Isn't the crash is origin from library internal SystemJobService?
We once thinking to bypass this problem, by switching back to Version 2.0.1 (The version just before WorkManager.getInstance(Context) is introduced). However, we notice Room version is being changed in between. Downgrading WorkManager version, might cause additional SQLite problem.
su...@google.com <su...@google.com> #7
Sorry, you are correct that moving to the deprecated method will not help you here. I would advise waiting for the release later this week. And thank you very much for finding this bug and doing the research to find the underlying issue.
I am curious: do you actually have reports of this bug on Android 9? It should've been fixed in the platform layer at that point. If possible, can you share any Android 9 specific logs/bugreports/stacktraces with device models?
I am curious: do you actually have reports of this bug on Android 9? It should've been fixed in the platform layer at that point. If possible, can you share any Android 9 specific logs/bugreports/stacktraces with device models?
b....@gmail.com <b....@gmail.com> #8
OK. Finger crossed users will not leave our app. I will follow the Green Dinosaur in Twitter, to wait for his announcement.
Based on your code comment, I thought this problem shouldn't occur in new Android but it happens some how. This is the log
Asus ZenFone 5 (ZE620KL) (ASUS_X00QD), Android 9 (Happen 2 times)
Asus ZenFone 5Z (ZS620KL/ZS621KL) (ASUS_Z01R_1), Android 9 (Happen 1 time)
3 incidents are having same log trace as below
java.lang.RuntimeException:
at android.app.ActivityThread.handleCreateService (ActivityThread.java:3570)
at android.app.ActivityThread.access$1300 (ActivityThread.java:200)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1672)
at android.os.Handler.dispatchMessage (Handler.java:106)
at android.os.Looper.loop (Looper.java:198)
at android.app.ActivityThread.main (ActivityThread.java:6732)
at java.lang.reflect.Method.invoke (Method.java)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:493)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:858)
Caused by: java.lang.IllegalStateException:
at androidx.work.impl.WorkManagerImpl.getInstance (WorkManagerImpl.java:142)
at androidx.work.impl.background.systemjob.SystemJobService.onCreate (SystemJobService.java:53)
at android.app.ActivityThread.handleCreateService (ActivityThread.java:3558)
at android.app.ActivityThread.access$1300 (ActivityThread.java:200)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1672)
at android.os.Handler.dispatchMessage (Handler.java:106)
at android.os.Looper.loop (Looper.java:198)
at android.app.ActivityThread.main (ActivityThread.java:6732)
at java.lang.reflect.Method.invoke (Method.java)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:493)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:858)
I attach the screenshot of Google Play Console as well. (I expect the stack trace should print programmer's message side-by-side with IllegalStateException. But it doesn't)
Feel free to let me know if you need any information from my side. Happy to help.
Based on your code comment, I thought this problem shouldn't occur in new Android but it happens some how. This is the log
Asus ZenFone 5 (ZE620KL) (ASUS_X00QD), Android 9 (Happen 2 times)
Asus ZenFone 5Z (ZS620KL/ZS621KL) (ASUS_Z01R_1), Android 9 (Happen 1 time)
3 incidents are having same log trace as below
java.lang.RuntimeException:
at android.app.ActivityThread.handleCreateService (ActivityThread.java:3570)
at android.app.ActivityThread.access$1300 (ActivityThread.java:200)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1672)
at android.os.Handler.dispatchMessage (Handler.java:106)
at android.os.Looper.loop (Looper.java:198)
at android.app.ActivityThread.main (ActivityThread.java:6732)
at java.lang.reflect.Method.invoke (Method.java)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:493)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:858)
Caused by: java.lang.IllegalStateException:
at androidx.work.impl.WorkManagerImpl.getInstance (WorkManagerImpl.java:142)
at androidx.work.impl.background.systemjob.SystemJobService.onCreate (SystemJobService.java:53)
at android.app.ActivityThread.handleCreateService (ActivityThread.java:3558)
at android.app.ActivityThread.access$1300 (ActivityThread.java:200)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1672)
at android.os.Handler.dispatchMessage (Handler.java:106)
at android.os.Looper.loop (Looper.java:198)
at android.app.ActivityThread.main (ActivityThread.java:6732)
at java.lang.reflect.Method.invoke (Method.java)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:493)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:858)
I attach the screenshot of Google Play Console as well. (I expect the stack trace should print programmer's message side-by-side with IllegalStateException. But it doesn't)
Feel free to let me know if you need any information from my side. Happy to help.
da...@google.com <da...@google.com> #9
Thanks, we'll investigate this internally.
b....@gmail.com <b....@gmail.com> #10
Hello, wondering whether the fix will be released in another one, or two days. As, users start to complain and leaving our app, due to increased crash rate :(
Thanks.
Thanks.
b....@gmail.com <b....@gmail.com> #11
Hi, we're still aiming to get this out this week.
b....@gmail.com <b....@gmail.com> #12
still have bug:
trace:
5 java.lang.IllegalStateException:WorkManager needs to be initialized via a ContentProvider#onCreate() or an Application#onCreate().
6 androidx.work.impl.background.systemjob.SystemJobService.onCreate(SystemJobService.java:68)
7 android.app.ActivityThread.handleCreateService(ActivityThread.java:3133)
8 android.app.ActivityThread.access$1900(ActivityThread.java:196)
9 android.app.ActivityThread$H.handleMessage(ActivityThread.java:1622)
10 com.android.tony.defenselib.hook.HookHandle$1.handleMessage(HookHandle.java:30)
11 android.os.Handler.dispatchMessage(Handler.java:107)
12 android.os.Looper.loop(Looper.java:210)
13 android.app.ActivityThread.main(ActivityThread.java:5982)
14 java.lang.reflect.Method.invoke(Native Method)
15 com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:852)
16 com.android.internal.os.ZygoteInit.main(ZygoteInit.java:742)
this code cause crash:
if (!Application.class.equals(getApplication().getClass())) {
// During auto-backup, we don't get a custom Application subclass. This code path
// indicates we are either performing auto-backup or the user never used a custom
// Application class (or both).
throw new IllegalStateException("WorkManager needs to be initialized via a "
+ "ContentProvider#onCreate() or an Application#onCreate().");
}
my analysis:
code in handleCreateService() in ActivityThread.java:
" Application app = packageInfo.makeApplication(false, mInstrumentation);
service.attach(context, this,data.info.name , data.token, app, ActivityManager.getService())
"
handleCreateService--->. Application app = packageInfo.makeApplication(false, mInstrumentation); ---> forceDefaultAppClass is always false-->if have custom Application,will make custom Application ---> service.attach(context, this,data.info.name , data.token, app, ActivityManager.getService()); ---> so getApplication() in service get custom application
--> if have customApplication, the code : "Application.class.equals(getApplication().getClass()" in Service will be false , even it's in backup mode
trace:
5 java.lang.IllegalStateException:WorkManager needs to be initialized via a ContentProvider#onCreate() or an Application#onCreate().
6 androidx.work.impl.background.systemjob.SystemJobService.onCreate(SystemJobService.java:68)
7 android.app.ActivityThread.handleCreateService(ActivityThread.java:3133)
8 android.app.ActivityThread.access$1900(ActivityThread.java:196)
9 android.app.ActivityThread$H.handleMessage(ActivityThread.java:1622)
10 com.android.tony.defenselib.hook.HookHandle$1.handleMessage(HookHandle.java:30)
11 android.os.Handler.dispatchMessage(Handler.java:107)
12 android.os.Looper.loop(Looper.java:210)
13 android.app.ActivityThread.main(ActivityThread.java:5982)
14 java.lang.reflect.Method.invoke(Native Method)
15 com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:852)
16 com.android.internal.os.ZygoteInit.main(ZygoteInit.java:742)
this code cause crash:
if (!Application.class.equals(getApplication().getClass())) {
// During auto-backup, we don't get a custom Application subclass. This code path
// indicates we are either performing auto-backup or the user never used a custom
// Application class (or both).
throw new IllegalStateException("WorkManager needs to be initialized via a "
+ "ContentProvider#onCreate() or an Application#onCreate().");
}
my analysis:
code in handleCreateService() in ActivityThread.java:
" Application app = packageInfo.makeApplication(false, mInstrumentation);
service.attach(context, this,
"
handleCreateService--->. Application app = packageInfo.makeApplication(false, mInstrumentation); ---> forceDefaultAppClass is always false-->if have custom Application,will make custom Application ---> service.attach(context, this,
--> if have customApplication, the code : "Application.class.equals(getApplication().getClass()" in Service will be false , even it's in backup mode
da...@google.com <da...@google.com> #13
i'm also having the same crash, here is the relevant stacktrace:
compileSdkVersion 30
implementation 'androidx.work:work-runtime-ktx:2.4.0'
Crash
TCT (Alcatel) 5056D
Android 6.0 (SDK 23)
48.aab
2 hours ago
java.lang.RuntimeException:
at android.app.ActivityThread.handleCreateService (ActivityThread.java:2887)
at android.app.ActivityThread.access$1900 (ActivityThread.java:150)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1427)
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 (Method.java)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:616)
Caused by: java.lang.IllegalStateException:
at androidx.work.impl.background.systemjob.SystemJobService.onCreate (SystemJobService.java:2)
at android.app.ActivityThread.handleCreateService (ActivityThread.java:2877)
at android.app.ActivityThread.access$1900 (ActivityThread.java:150)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1427)
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 (Method.java)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:616)
What could the walkaround this issue? Is there another way to initialize the WorkManager instance? I'm using
private fun getWorkManager(): WorkManager =
try {
WorkManager.getInstance(App.context)
} catch (e: Exception) {
e.printStackTrace()
sleep(100)
getWorkManager()
}
compileSdkVersion 30
implementation 'androidx.work:work-runtime-ktx:2.4.0'
Crash
TCT (Alcatel) 5056D
Android 6.0 (SDK 23)
48.aab
2 hours ago
java.lang.RuntimeException:
at android.app.ActivityThread.handleCreateService (ActivityThread.java:2887)
at android.app.ActivityThread.access$1900 (ActivityThread.java:150)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1427)
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 (Method.java)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:616)
Caused by: java.lang.IllegalStateException:
at androidx.work.impl.background.systemjob.SystemJobService.onCreate (SystemJobService.java:2)
at android.app.ActivityThread.handleCreateService (ActivityThread.java:2877)
at android.app.ActivityThread.access$1900 (ActivityThread.java:150)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1427)
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 (Method.java)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:616)
What could the walkaround this issue? Is there another way to initialize the WorkManager instance? I'm using
private fun getWorkManager(): WorkManager =
try {
WorkManager.getInstance(App.context)
} catch (e: Exception) {
e.printStackTrace()
sleep(100)
getWorkManager()
}
b....@gmail.com <b....@gmail.com> #14
Same Error on production when call WorkManager.getInstance(context):
Library version: androidx.work:work-runtime:2.4.0
Samsung Galaxy S8 (dreamlte), 3840MB RAM, Android 9
java.lang.RuntimeException:
at android.app.ActivityThread.handleBindApplication (ActivityThread.java:6227)
at android.app.ActivityThread.access$1200 (ActivityThread.java:237)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1785)
at android.os.Handler.dispatchMessage (Handler.java:106)
at android.os.Looper.loop (Looper.java:214)
at android.app.ActivityThread.main (ActivityThread.java:7050)
at java.lang.reflect.Method.invoke (Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:494)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:965)
Caused by: java.lang.IllegalStateException:
at androidx.work.impl.WorkManagerImpl.getInstance (WorkManagerImpl.java:150)
at androidx.work.WorkManager.getInstance (WorkManager.java:184)
at br.com.rcgm.dicaslotofacilfull.task.WorkRequestSincronizarConcurso.enfileirar (WorkRequestSincronizarConcurso.java:20)
at br.com.rcgm.dicaslotofacilfull.BaseApplication.onCreate (BaseApplication.java:23)
at android.app.Instrumentation.callApplicationOnCreate (Instrumentation.java:1154)
at android.app.ActivityThread.handleBindApplication (ActivityThread.java:6222)
Library version: androidx.work:work-runtime:2.4.0
Samsung Galaxy S8 (dreamlte), 3840MB RAM, Android 9
java.lang.RuntimeException:
at android.app.ActivityThread.handleBindApplication (ActivityThread.java:6227)
at android.app.ActivityThread.access$1200 (ActivityThread.java:237)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1785)
at android.os.Handler.dispatchMessage (Handler.java:106)
at android.os.Looper.loop (Looper.java:214)
at android.app.ActivityThread.main (ActivityThread.java:7050)
at java.lang.reflect.Method.invoke (Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:494)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:965)
Caused by: java.lang.IllegalStateException:
at androidx.work.impl.WorkManagerImpl.getInstance (WorkManagerImpl.java:150)
at androidx.work.WorkManager.getInstance (WorkManager.java:184)
at br.com.rcgm.dicaslotofacilfull.task.WorkRequestSincronizarConcurso.enfileirar (WorkRequestSincronizarConcurso.java:20)
at br.com.rcgm.dicaslotofacilfull.BaseApplication.onCreate (BaseApplication.java:23)
at android.app.Instrumentation.callApplicationOnCreate (Instrumentation.java:1154)
at android.app.ActivityThread.handleBindApplication (ActivityThread.java:6222)
su...@google.com <su...@google.com> #15
Hi,
I'm also facing same issue, in few devices.
Instance access : WorkManager.getInstance()
I'm not doing on-demand Initialization.
version used: 'androidx.work:work-runtime:2.3.4'
Device details
Brand: samsung
Model: Galaxy J2 Pro
Android version: 6.0.1
Fatal Exception: java.lang.RuntimeException: Unable to create service androidx.work.impl.background.systemjob.SystemJobService: java.lang.IllegalStateException: WorkManager needs to be initialized via a ContentProvider#onCreate() or an Application#onCreate().
at android.app.ActivityThread.handleCreateService(ActivityThread.java:3883)
at android.app.ActivityThread.-wrap8(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1909)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:7325)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
Caused by java.lang.IllegalStateException: WorkManager needs to be initialized via a ContentProvider#onCreate() or an Application#onCreate().
at androidx.work.impl.background.systemjob.SystemJobService.onCreate(SystemJobService.java:73)
at android.app.ActivityThread.handleCreateService(ActivityThread.java:3873)
at android.app.ActivityThread.-wrap8(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1909)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:7325)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
I'm also facing same issue, in few devices.
Instance access : WorkManager.getInstance()
I'm not doing on-demand Initialization.
version used: 'androidx.work:work-runtime:2.3.4'
Device details
Brand: samsung
Model: Galaxy J2 Pro
Android version: 6.0.1
Fatal Exception: java.lang.RuntimeException: Unable to create service androidx.work.impl.background.systemjob.SystemJobService: java.lang.IllegalStateException: WorkManager needs to be initialized via a ContentProvider#onCreate() or an Application#onCreate().
at android.app.ActivityThread.handleCreateService(ActivityThread.java:3883)
at android.app.ActivityThread.-wrap8(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1909)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:7325)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
Caused by java.lang.IllegalStateException: WorkManager needs to be initialized via a ContentProvider#onCreate() or an Application#onCreate().
at androidx.work.impl.background.systemjob.SystemJobService.onCreate(SystemJobService.java:73)
at android.app.ActivityThread.handleCreateService(ActivityThread.java:3873)
at android.app.ActivityThread.-wrap8(ActivityThread.java)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1909)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:7325)
at java.lang.reflect.Method.invoke(Method.java)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:1230)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1120)
b....@gmail.com <b....@gmail.com> #16
i have the same issue
b....@gmail.com <b....@gmail.com> #17
deleted
b....@gmail.com <b....@gmail.com> #18
Still seeing this issue in 2.5.0 using default WorkManager.getInstance() initialization. How can we prevent this situation from occurring?
if (!Application.class.equals(getApplication().getClass())) {
// During auto-backup, we don't get a custom Application subclass. This code path
// indicates we are either performing auto-backup or the user never used a custom
// Application class (or both).
throw new IllegalStateException("WorkManager needs to be initialized via a "
+ "ContentProvider#onCreate() or an Application#onCreate().");
}
if (!Application.class.equals(getApplication().getClass())) {
// During auto-backup, we don't get a custom Application subclass. This code path
// indicates we are either performing auto-backup or the user never used a custom
// Application class (or both).
throw new IllegalStateException("WorkManager needs to be initialized via a "
+ "ContentProvider#onCreate() or an Application#onCreate().");
}
su...@google.com <su...@google.com> #19
this issue on workManager 2.5.0 when initialize WorkManager in background thread, bring it back to UI thread
su...@google.com <su...@google.com> #20
I begin to see this issue after using "on demand Initialization"
Stacktrace:
Caused by java.lang.IllegalStateException
WorkManager needs to be initialized via a ContentProvider#onCreate() or an Application#onCreate().
androidx.work.impl.background.systemjob.SystemJobService.onCreate (SystemJobService.java:73)
android.app.ActivityThread.handleCreateService (ActivityThread.java:3833)
android.app.ActivityThread.access$1500 (ActivityThread.java:229)
android.app.ActivityThread$H.handleMessage (ActivityThread.java:1881)
android.os.Handler.dispatchMessage (Handler.java:106)
android.os.Looper.loop (Looper.java:226)
android.app.ActivityThread.main (ActivityThread.java:7178)
java.lang.reflect.Method.invoke (Method.java)
com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:503)
com.android.internal.os.ZygoteInit.main (ZygoteInit.java:942)
For now, the device affected is
android 9 Realme.
Work Manager version: 2.6.0
Stacktrace:
Caused by java.lang.IllegalStateException
WorkManager needs to be initialized via a ContentProvider#onCreate() or an Application#onCreate().
androidx.work.impl.background.systemjob.SystemJobService.onCreate (SystemJobService.java:73)
android.app.ActivityThread.handleCreateService (ActivityThread.java:3833)
android.app.ActivityThread.access$1500 (ActivityThread.java:229)
android.app.ActivityThread$H.handleMessage (ActivityThread.java:1881)
android.os.Handler.dispatchMessage (Handler.java:106)
android.os.Looper.loop (Looper.java:226)
android.app.ActivityThread.main (ActivityThread.java:7178)
java.lang.reflect.Method.invoke (Method.java)
com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:503)
com.android.internal.os.ZygoteInit.main (ZygoteInit.java:942)
For now, the device affected is
android 9 Realme.
Work Manager version: 2.6.0
b....@gmail.com <b....@gmail.com> #21
Still happening with WorkManager 2.7.1 Samsung Galaxy S21 Ultra 5G Android 12 (SDK 31)
java.lang.RuntimeException:
at android.app.ActivityThread.handleCreateService (ActivityThread.java:4953)
at android.app.ActivityThread.access$1900 (ActivityThread.java:310)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:2300)
at android.os.Handler.dispatchMessage (Handler.java:106)
at android.os.Looper.loopOnce (Looper.java:226)
at android.os.Looper.loop (Looper.java:313)
at android.app.ActivityThread.main (ActivityThread.java:8669)
at java.lang.reflect.Method.invoke (Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:571)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:1135)
Caused by: java.lang.IllegalStateException:
at androidx.work.impl.WorkManagerImpl.getInstance (WorkManagerImpl.java:158)
at androidx.work.impl.foreground.SystemForegroundDispatcher.<init> (SystemForegroundDispatcher.java:105)
at androidx.work.impl.foreground.SystemForegroundService.initializeDispatcher (SystemForegroundService.java:96)
at androidx.work.impl.foreground.SystemForegroundService.onCreate (SystemForegroundService.java:59)
at android.app.ActivityThread.handleCreateService (ActivityThread.java:4940)
at android.app.ActivityThread.access$1900 (ActivityThread.java:310)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:2300)
at android.os.Handler.dispatchMessage (Handler.java:106)
at android.os.Looper.loopOnce (Looper.java:226)
at android.os.Looper.loop (Looper.java:313)
at android.app.ActivityThread.main (ActivityThread.java:8669)
at java.lang.reflect.Method.invoke (Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:571)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:1135)
su...@google.com <su...@google.com> #22
We recently moved our WorkManager initialization to the default pattern and have started seeing this same issue.
java.lang.RuntimeException: Unable to create service androidx.work.impl.background.systemjob.SystemJobService: java.lang.IllegalStateException: WorkManager needs to be initialized via a ContentProvider#onCreate() or an Application#onCreate().
at android.app.ActivityThread.handleCreateService(ActivityThread.java:5073)
at android.app.ActivityThread.-$$Nest$mhandleCreateService(Unknown)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2425)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loopOnce(Looper.java:226)
at android.os.Looper.loop(Looper.java:313)
at android.app.ActivityThread.main(ActivityThread.java:8741)
at java.lang.reflect.Method.invoke(Method.java:-2)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:571)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1067)
Caused by: java.lang.IllegalStateException: WorkManager needs to be initialized via a ContentProvider#onCreate() or an Application#onCreate().
at androidx.work.impl.background.systemjob.SystemJobService.onCreate(SystemJobService:73)
at android.app.ActivityThread.handleCreateService(ActivityThread.java:5060)
at android.app.ActivityThread.-$$Nest$mhandleCreateService(Unknown)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2425)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loopOnce(Looper.java:226)
at android.os.Looper.loop(Looper.java:313)
at android.app.ActivityThread.main(ActivityThread.java:8741)
at java.lang.reflect.Method.invoke(Method.java:-2)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:571)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:1067)
b....@gmail.com <b....@gmail.com> #23
I would check to make sure that the app is not a multi-process app. If it is, you will need your Application
to additionally sub-class Configuration.Provider
or additionally define a second provider for the other process.
su...@google.com <su...@google.com> #24
Hi all, I am also facing the same crash in Work Manager 2.7.1 with on-demand initialization in Samsung X-Cover Pro(31), sdk 32. There's no concrete scenario for this crash to happen, it happens randomly at any screen. Plus the auto-backup is disabled in my app which was listed as one of the factors responsible for the crash. Can someone please assist me with a way to fix/handle this crash?
b....@gmail.com <b....@gmail.com> #25
Hi all , i use workManager 2.7.0 face some crash "IllegalStateExceptionWorkManager needs to be initialized via a ContentProvider#onCreate() or an Application#onCreate()" . i am sure app manifest allowBackUp=false and initWorkManger in every process. Can someone please assist me with a way to fix/handle this crash?
b....@gmail.com <b....@gmail.com> #26
I'm experience the same problem. I used suspend function to init WorkManager and used Dispatchers.Default as a scope to launch. I'm going to use runBlocking instead
su...@google.com <su...@google.com> #27
Hi, I'm glad you have some reproducible steps. It would help us a lot if you could actually boil this down to a minimal sample app that can reproduce it so you can share it with us and we can also examine what is going wrong.
b....@gmail.com <b....@gmail.com> #28
Done! This crashes for us on the second launch, you need a large amount queued jobs for it to happen. Testing on a Moto X 2014 victara running Android 6.0.
ra...@google.com <ra...@google.com> #29
We managed to get a test device, and I can reproduce it.
I see this:
05-21 10:18:50.804 352 352 D SFPerfTracer: layers: (6:13) (FocusedStackFrame (0xb8370eb8): 0:108)* (DimLayer (0xb83412c0): 9:12) (StatusBar (0xb83bbf38): 0:701) (NavigationBar (0xb8389d10): 0:550) (com.android.systemui.ImageWallpaper (0xb83b23f8): 0:234) (DimLayer (0xb83989f0): 0:45)- (DimLayer (0xb83907e0): 0:8)- (com.example.workmanagercrash/com.example.workmanagercrash.MainActivity (0xb836c948): 0:31)- (com.android.systemui/com.android.systemui.recents.RecentsActivity (0xb838d188): 0:58)- (thumbnail anim (0xb834e7a0): 0:23)- (com.google.android.googlequicksearchbox/com.google.android.launcher.GEL (0xb834e7a0): 0:13) (Application Error: com.example.workmanagercrash (0xb83989f0): 8:14)
05-21 10:18:50.804 463 463 F DEBUG : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
05-21 10:18:50.804 463 463 F DEBUG : Build fingerprint: 'motorola/victara_tmo/victara:6.0/MPES24.49-18-7/7:user/release-keys'
05-21 10:18:50.805 463 463 F DEBUG : Revision: 'p2bf'
05-21 10:18:50.805 463 463 F DEBUG : ABI: 'arm'
05-21 10:18:50.805 463 463 F DEBUG : pid: 9165, tid: 9180, name: WorkManager-Wor >>> com.example.workmanagercrash <<<
05-21 10:18:50.805 463 463 F DEBUG : signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0
05-21 10:18:50.819 463 463 F DEBUG : r0 b9b04660 r1 af9ece50 r2 00000000 r3 00000002
05-21 10:18:50.819 463 463 F DEBUG : r4 b9b044b8 r5 b692e118 r6 00000000 r7 b9b04f08
05-21 10:18:50.819 463 463 F DEBUG : r8 00000001 r9 b9b044b8 sl 00000000 fp 00000002
05-21 10:18:50.819 463 463 F DEBUG : ip b692ddfc sp af9ece28 lr b6881e5b pc 00000000 cpsr 200f0010
05-21 10:18:50.823 463 463 F DEBUG :
05-21 10:18:50.823 463 463 F DEBUG : backtrace:
05-21 10:18:50.824 463 463 F DEBUG : #00 pc 00000000 <unknown>
05-21 10:18:50.824 463 463 F DEBUG : #01 pc 00024e59 /system/lib/libsqlite.so
05-21 10:18:50.824 463 463 F DEBUG : #02 pc 00024173 /system/lib/libsqlite.so
05-21 10:18:50.824 463 463 F DEBUG : #03 pc 0000e759 /system/lib/libsqlite.so
05-21 10:18:50.824 463 463 F DEBUG : #04 pc 0002be41 /system/lib/libsqlite.so
05-21 10:18:50.824 463 463 F DEBUG : #05 pc 00039ad7 /system/lib/libsqlite.so
05-21 10:18:50.824 463 463 F DEBUG : #06 pc 0000ffc5 /system/lib/libsqlite.so (sqlite3_step+724)
05-21 10:18:50.824 463 463 F DEBUG : #07 pc 00075021 /system/lib/libandroid_runtime.so
05-21 10:18:50.824 463 463 F DEBUG : #08 pc 02287663 /system/framework/arm/boot.oat (offset 0x1fda000)
05-21 10:18:51.062 1769 2069 V AlarmManager: sending alarm {f6ba791 type 3 *alarm*:android.content.jobscheduler.JOB_DELAY_EXPIRED}
05-21 10:18:51.065 1769 1769 V AlarmManager: done {f6ba791, *alarm*:android.content.jobscheduler.JOB_DELAY_EXPIRED} [3ms]
05-21 10:18:51.131 463 463 F DEBUG :
05-21 10:18:51.131 463 463 F DEBUG : Tombstone written to: /data/tombstones/tombstone_01
05-21 10:18:51.131 463 463 E DEBUG : AM write failed: Broken pipe
05-21 10:18:51.133 1769 1786 I BootReceiver: Copying /data/tombstones/tombstone_01 to DropBox (SYSTEM_TOMBSTONE)
05-21 10:18:51.184 485 485 I Zygote : Process 9165 exited due to signal (11)
05-21 10:18:51.214 1769 2729 I ActivityManager: Process com.example.workmanagercrash (pid 9165) has died
05-21 10:18:51.215 1769 2729 W ActivityManager: Scheduling restart of crashed service com.example.workmanagercrash/androidx.work.impl.background.systemjob.SystemJobService in 1000ms
05-21 10:18:51.238 1769 1769 I ActivityManager: Start proc 9188:com.example.workmanagercrash/u0a106 for service com.example.workmanagercrash/androidx.work.impl.background.systemjob.SystemJobService
05-21 10:18:51.256 9188 9188 I art : Late-enabling -Xcheck:jni
05-21 10:18:51.301 9188 9188 W System : ClassLoader referenced unknown path: /data/app/com.example.workmanagercrash-1/lib/arm
05-21 10:18:51.476 9188 9202 F libc : Fatal signal 11 (SIGSEGV), code 1, fault addr 0x0 in tid 9202 (WorkManager-Wor)
05-21 10:18:51.578 463 463 F DEBUG : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
05-21 10:18:51.578 463 463 F DEBUG : Build fingerprint: 'motorola/victara_tmo/victara:6.0/MPES24.49-18-7/7:user/release-keys'
05-21 10:18:51.579 463 463 F DEBUG : Revision: 'p2bf'
05-21 10:18:51.579 463 463 F DEBUG : ABI: 'arm'
05-21 10:18:51.579 463 463 F DEBUG : pid: 9188, tid: 9202, name: WorkManager-Wor >>> com.example.workmanagercrash <<<
05-21 10:18:51.580 463 463 F DEBUG : signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0
05-21 10:18:51.609 463 463 F DEBUG : r0 b9b048c0 r1 af9ece50 r2 00000000 r3 00000002
05-21 10:18:51.609 463 463 F DEBUG : r4 b9b04718 r5 b692e118 r6 00000000 r7 b9b05170
05-21 10:18:51.609 463 463 F DEBUG : r8 00000001 r9 b9b04718 sl 00000000 fp 00000002
05-21 10:18:51.609 463 463 F DEBUG : ip b692ddfc sp af9ece28 lr b6881e5b pc 00000000 cpsr 200f0010
05-21 10:18:51.615 463 463 F DEBUG :
05-21 10:18:51.615 463 463 F DEBUG : backtrace:
05-21 10:18:51.616 463 463 F DEBUG : #00 pc 00000000 <unknown>
05-21 10:18:51.616 463 463 F DEBUG : #01 pc 00024e59 /system/lib/libsqlite.so
05-21 10:18:51.616 463 463 F DEBUG : #02 pc 00024173 /system/lib/libsqlite.so
05-21 10:18:51.616 463 463 F DEBUG : #03 pc 0000e759 /system/lib/libsqlite.so
05-21 10:18:51.616 463 463 F DEBUG : #04 pc 0002be41 /system/lib/libsqlite.so
05-21 10:18:51.616 463 463 F DEBUG : #05 pc 00039ad7 /system/lib/libsqlite.so
05-21 10:18:51.616 463 463 F DEBUG : #06 pc 0000ffc5 /system/lib/libsqlite.so (sqlite3_step+724)
05-21 10:18:51.616 463 463 F DEBUG : #07 pc 00075021 /system/lib/libandroid_runtime.so
05-21 10:18:51.616 463 463 F DEBUG : #08 pc 02287663 /system/framework/arm/boot.oat (offset 0x1fda000)
05-21 10:18:51.902 463 463 F DEBUG :
05-21 10:18:51.902 463 463 F DEBUG : Tombstone written to: /data/tombstones/tombstone_02
05-21 10:18:51.902 463 463 E DEBUG : AM write failed: Broken pipe
05-21 10:18:51.903 1769 1786 I BootReceiver: Copying /data/tombstones/tombstone_02 to DropBox (SYSTEM_TOMBSTONE)
05-21 10:18:51.952 485 485 I Zygote : Process 9188 exited due to signal (11)
05-21 10:18:51.966 1769 2757 I ActivityManager: Process com.example.workmanagercrash (pid 9188) has died
I see this:
05-21 10:18:50.804 352 352 D SFPerfTracer: layers: (6:13) (FocusedStackFrame (0xb8370eb8): 0:108)* (DimLayer (0xb83412c0): 9:12) (StatusBar (0xb83bbf38): 0:701) (NavigationBar (0xb8389d10): 0:550) (com.android.systemui.ImageWallpaper (0xb83b23f8): 0:234) (DimLayer (0xb83989f0): 0:45)- (DimLayer (0xb83907e0): 0:8)- (com.example.workmanagercrash/com.example.workmanagercrash.MainActivity (0xb836c948): 0:31)- (com.android.systemui/com.android.systemui.recents.RecentsActivity (0xb838d188): 0:58)- (thumbnail anim (0xb834e7a0): 0:23)- (com.google.android.googlequicksearchbox/com.google.android.launcher.GEL (0xb834e7a0): 0:13) (Application Error: com.example.workmanagercrash (0xb83989f0): 8:14)
05-21 10:18:50.804 463 463 F DEBUG : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
05-21 10:18:50.804 463 463 F DEBUG : Build fingerprint: 'motorola/victara_tmo/victara:6.0/MPES24.49-18-7/7:user/release-keys'
05-21 10:18:50.805 463 463 F DEBUG : Revision: 'p2bf'
05-21 10:18:50.805 463 463 F DEBUG : ABI: 'arm'
05-21 10:18:50.805 463 463 F DEBUG : pid: 9165, tid: 9180, name: WorkManager-Wor >>> com.example.workmanagercrash <<<
05-21 10:18:50.805 463 463 F DEBUG : signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0
05-21 10:18:50.819 463 463 F DEBUG : r0 b9b04660 r1 af9ece50 r2 00000000 r3 00000002
05-21 10:18:50.819 463 463 F DEBUG : r4 b9b044b8 r5 b692e118 r6 00000000 r7 b9b04f08
05-21 10:18:50.819 463 463 F DEBUG : r8 00000001 r9 b9b044b8 sl 00000000 fp 00000002
05-21 10:18:50.819 463 463 F DEBUG : ip b692ddfc sp af9ece28 lr b6881e5b pc 00000000 cpsr 200f0010
05-21 10:18:50.823 463 463 F DEBUG :
05-21 10:18:50.823 463 463 F DEBUG : backtrace:
05-21 10:18:50.824 463 463 F DEBUG : #00 pc 00000000 <unknown>
05-21 10:18:50.824 463 463 F DEBUG : #01 pc 00024e59 /system/lib/libsqlite.so
05-21 10:18:50.824 463 463 F DEBUG : #02 pc 00024173 /system/lib/libsqlite.so
05-21 10:18:50.824 463 463 F DEBUG : #03 pc 0000e759 /system/lib/libsqlite.so
05-21 10:18:50.824 463 463 F DEBUG : #04 pc 0002be41 /system/lib/libsqlite.so
05-21 10:18:50.824 463 463 F DEBUG : #05 pc 00039ad7 /system/lib/libsqlite.so
05-21 10:18:50.824 463 463 F DEBUG : #06 pc 0000ffc5 /system/lib/libsqlite.so (sqlite3_step+724)
05-21 10:18:50.824 463 463 F DEBUG : #07 pc 00075021 /system/lib/libandroid_runtime.so
05-21 10:18:50.824 463 463 F DEBUG : #08 pc 02287663 /system/framework/arm/boot.oat (offset 0x1fda000)
05-21 10:18:51.062 1769 2069 V AlarmManager: sending alarm {f6ba791 type 3 *alarm*:android.content.jobscheduler.JOB_DELAY_EXPIRED}
05-21 10:18:51.065 1769 1769 V AlarmManager: done {f6ba791, *alarm*:android.content.jobscheduler.JOB_DELAY_EXPIRED} [3ms]
05-21 10:18:51.131 463 463 F DEBUG :
05-21 10:18:51.131 463 463 F DEBUG : Tombstone written to: /data/tombstones/tombstone_01
05-21 10:18:51.131 463 463 E DEBUG : AM write failed: Broken pipe
05-21 10:18:51.133 1769 1786 I BootReceiver: Copying /data/tombstones/tombstone_01 to DropBox (SYSTEM_TOMBSTONE)
05-21 10:18:51.184 485 485 I Zygote : Process 9165 exited due to signal (11)
05-21 10:18:51.214 1769 2729 I ActivityManager: Process com.example.workmanagercrash (pid 9165) has died
05-21 10:18:51.215 1769 2729 W ActivityManager: Scheduling restart of crashed service com.example.workmanagercrash/androidx.work.impl.background.systemjob.SystemJobService in 1000ms
05-21 10:18:51.238 1769 1769 I ActivityManager: Start proc 9188:com.example.workmanagercrash/u0a106 for service com.example.workmanagercrash/androidx.work.impl.background.systemjob.SystemJobService
05-21 10:18:51.256 9188 9188 I art : Late-enabling -Xcheck:jni
05-21 10:18:51.301 9188 9188 W System : ClassLoader referenced unknown path: /data/app/com.example.workmanagercrash-1/lib/arm
05-21 10:18:51.476 9188 9202 F libc : Fatal signal 11 (SIGSEGV), code 1, fault addr 0x0 in tid 9202 (WorkManager-Wor)
05-21 10:18:51.578 463 463 F DEBUG : *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
05-21 10:18:51.578 463 463 F DEBUG : Build fingerprint: 'motorola/victara_tmo/victara:6.0/MPES24.49-18-7/7:user/release-keys'
05-21 10:18:51.579 463 463 F DEBUG : Revision: 'p2bf'
05-21 10:18:51.579 463 463 F DEBUG : ABI: 'arm'
05-21 10:18:51.579 463 463 F DEBUG : pid: 9188, tid: 9202, name: WorkManager-Wor >>> com.example.workmanagercrash <<<
05-21 10:18:51.580 463 463 F DEBUG : signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0
05-21 10:18:51.609 463 463 F DEBUG : r0 b9b048c0 r1 af9ece50 r2 00000000 r3 00000002
05-21 10:18:51.609 463 463 F DEBUG : r4 b9b04718 r5 b692e118 r6 00000000 r7 b9b05170
05-21 10:18:51.609 463 463 F DEBUG : r8 00000001 r9 b9b04718 sl 00000000 fp 00000002
05-21 10:18:51.609 463 463 F DEBUG : ip b692ddfc sp af9ece28 lr b6881e5b pc 00000000 cpsr 200f0010
05-21 10:18:51.615 463 463 F DEBUG :
05-21 10:18:51.615 463 463 F DEBUG : backtrace:
05-21 10:18:51.616 463 463 F DEBUG : #00 pc 00000000 <unknown>
05-21 10:18:51.616 463 463 F DEBUG : #01 pc 00024e59 /system/lib/libsqlite.so
05-21 10:18:51.616 463 463 F DEBUG : #02 pc 00024173 /system/lib/libsqlite.so
05-21 10:18:51.616 463 463 F DEBUG : #03 pc 0000e759 /system/lib/libsqlite.so
05-21 10:18:51.616 463 463 F DEBUG : #04 pc 0002be41 /system/lib/libsqlite.so
05-21 10:18:51.616 463 463 F DEBUG : #05 pc 00039ad7 /system/lib/libsqlite.so
05-21 10:18:51.616 463 463 F DEBUG : #06 pc 0000ffc5 /system/lib/libsqlite.so (sqlite3_step+724)
05-21 10:18:51.616 463 463 F DEBUG : #07 pc 00075021 /system/lib/libandroid_runtime.so
05-21 10:18:51.616 463 463 F DEBUG : #08 pc 02287663 /system/framework/arm/boot.oat (offset 0x1fda000)
05-21 10:18:51.902 463 463 F DEBUG :
05-21 10:18:51.902 463 463 F DEBUG : Tombstone written to: /data/tombstones/tombstone_02
05-21 10:18:51.902 463 463 E DEBUG : AM write failed: Broken pipe
05-21 10:18:51.903 1769 1786 I BootReceiver: Copying /data/tombstones/tombstone_02 to DropBox (SYSTEM_TOMBSTONE)
05-21 10:18:51.952 485 485 I Zygote : Process 9188 exited due to signal (11)
05-21 10:18:51.966 1769 2757 I ActivityManager: Process com.example.workmanagercrash (pid 9188) has died
ap...@google.com <ap...@google.com> #30
Project: platform/frameworks/support
Branch: androidx-master-dev
commit 957adb282e41c2662fff6221325e6b51cd7377f9
Author: Rahul Ravikumar <rahulrav@google.com>
Date: Tue May 21 14:37:00 2019
Fixes SQLite issues on some devices.
* Always beginTransaction() outside a try.
* Make sure SystemJobScheduler marks transactions as successful.
Test: Existing tests pass.
Fixes: b/130182503 , b/132697495
Change-Id: I55092537781fbfee97f4336eb7cf1a49e647d62a
M work/workmanager-gcm/src/main/java/androidx/work/impl/background/gcm/WorkManagerGcmDispatcher.java
M work/workmanager/src/main/java/androidx/work/impl/WorkerWrapper.java
M work/workmanager/src/main/java/androidx/work/impl/background/systemjob/SystemJobScheduler.java
M work/workmanager/src/main/java/androidx/work/impl/utils/ForceStopRunnable.java
https://android-review.googlesource.com/966057
https://goto.google.com/android-sha1/957adb282e41c2662fff6221325e6b51cd7377f9
Branch: androidx-master-dev
commit 957adb282e41c2662fff6221325e6b51cd7377f9
Author: Rahul Ravikumar <rahulrav@google.com>
Date: Tue May 21 14:37:00 2019
Fixes SQLite issues on some devices.
* Always beginTransaction() outside a try.
* Make sure SystemJobScheduler marks transactions as successful.
Test: Existing tests pass.
Fixes:
Change-Id: I55092537781fbfee97f4336eb7cf1a49e647d62a
M work/workmanager-gcm/src/main/java/androidx/work/impl/background/gcm/WorkManagerGcmDispatcher.java
M work/workmanager/src/main/java/androidx/work/impl/WorkerWrapper.java
M work/workmanager/src/main/java/androidx/work/impl/background/systemjob/SystemJobScheduler.java
M work/workmanager/src/main/java/androidx/work/impl/utils/ForceStopRunnable.java
lo...@gmail.com <lo...@gmail.com> #31
Will it be fixed in a maintainance release of 2.0, or will we have to wait for 2.1 next RC or release?
ra...@google.com <ra...@google.com> #32
This will show up in the next 2.1.0 release.
Description