Status Update
Comments
ra...@google.com <ra...@google.com> #2
al...@gmail.com <al...@gmail.com> #3
ra...@google.com <ra...@google.com> #5
Project: platform/frameworks/support
Branch: androidx-main
Author: Daniel Santiago Rivera <
Link:
Make androidx.room and androidx.sqlite target Kotlin 2.0
Expand for full commit details
Make androidx.room and androidx.sqlite target Kotlin 2.0
This required the following changes:
* Suppress 'ACTUAL_ANNOTATIONS_NOT_MATCH_EXPECT' in SQLiteException.android.kt and ThreadLocal.jvmAndroid.kt due to being impossible to match annotations in expect when actual is a typealias to a platform type. Meanwhile in room-common repeatable annotations in JVM use @JvmRepeatable while expect uses Kotlin's @Repeatable and while trying to match actual with expect, an error is produced due to @JvmRepeatable and @Repeatable being used together.
* Fix various annotations mismatch between actual / expect.
* Removing @JvmField from common code as expect properties have no backing field and @JvmField targets FIELD.
* Smart-cast is not possible for expect properties, therefore first store in local variable before smart-case usage. Observed in TableInfo, FtsTableInfo, ViewInfo and MigrationUtil.
* Adding load() and getRefreshKey() to expect LimitOffsetPagingSource to conform to modality of actual overriding those functions.
* Make a XProcessingEnvConfig a normal class (instead of a data class) since it has a private constructor with a public copy() usage which is now invalid.
* Set useKsp2=true on projects with KSP and Kotlin language 2.0 (Room KMP test apps).
* Workaround KSP2 issue with default value of annotations not appearing in value list. Added a get() that returns nullable XAnnotationValue.
* Workaround KSP2 issue of projecting value class constructor as member of (to support generics).
* Workaround XPoet creating JavaPoet types of invalid methods (internal) when XProcessingEnvConfig.excludeMethodsWithInvalidJvmSourceNames is set to true due to Kotlin codegen.
Bug: 315461431
Bug: 384600605
Test: Existing
Relnote: "Native APIs updated due to Kotlin 2.0"
Change-Id: I8efb015c88682921780370c8bed5931d9933a319
Files:
- M
development/build_log_simplifier/messages.ignore
- M
room/integration-tests/kotlintestapp/build.gradle
- M
room/integration-tests/multiplatformtestapp/build.gradle
- M
room/room-common/bcv/native/current.txt
- M
room/room-common/build.gradle
- M
room/room-common/src/jvmMain/kotlin/androidx/room/DeleteColumn.jvm.kt
- M
room/room-common/src/jvmMain/kotlin/androidx/room/DeleteTable.jvm.kt
- M
room/room-common/src/jvmMain/kotlin/androidx/room/RenameColumn.jvm.kt
- M
room/room-common/src/jvmMain/kotlin/androidx/room/RenameTable.jvm.kt
- M
room/room-compiler-processing/src/main/java/androidx/room/compiler/processing/InternalXAnnotation.kt
- M
room/room-compiler-processing/src/main/java/androidx/room/compiler/processing/JavaPoetExt.kt
- M
room/room-compiler-processing/src/main/java/androidx/room/compiler/processing/XAnnotation.kt
- M
room/room-compiler-processing/src/main/java/androidx/room/compiler/processing/XProcessingEnvConfig.kt
- M
room/room-compiler-processing/src/main/java/androidx/room/compiler/processing/util/NamingUtils.kt
- M
room/room-compiler-processing/src/test/java/androidx/room/compiler/processing/XAnnotationTest.kt
- M
room/room-compiler/build.gradle
- M
room/room-compiler/src/main/kotlin/androidx/room/solver/TypeAdapterStore.kt
- M
room/room-compiler/src/main/kotlin/androidx/room/solver/query/result/MultimapQueryResultAdapter.kt
- M
room/room-compiler/src/test/kotlin/androidx/room/writer/BaseDaoKotlinCodeGenTest.kt
- M
room/room-compiler/src/test/kotlin/androidx/room/writer/DaoKotlinCodeGenTest.kt
- M
room/room-compiler/src/test/kotlin/androidx/room/writer/DaoRelationshipKotlinCodeGenTest.kt
- M
room/room-compiler/src/test/kotlin/androidx/room/writer/DatabaseKotlinCodeGenTest.kt
- M
room/room-compiler/src/test/test-data/kotlinCodeGen/database_daoProperty.kt
- M
room/room-compiler/src/test/test-data/kotlinCodeGen/database_internalVisibility.kt
- M
room/room-compiler/src/test/test-data/kotlinCodeGen/database_javaSource.kt
- M
room/room-compiler/src/test/test-data/kotlinCodeGen/database_simple.kt
- M
room/room-compiler/src/test/test-data/kotlinCodeGen/database_withFtsAndView.kt
- M
room/room-compiler/src/test/test-data/kotlinCodeGen/guavaCallable_java.kt
- M
room/room-ktx/build.gradle
- M
room/room-migration/build.gradle
- M
room/room-paging-guava/build.gradle
- M
room/room-paging-rxjava2/build.gradle
- M
room/room-paging-rxjava3/build.gradle
- M
room/room-paging/build.gradle
- M
room/room-paging/src/androidMain/kotlin/androidx/room/paging/LimitOffsetPagingSource.android.kt
- M
room/room-paging/src/commonMain/kotlin/androidx/room/paging/LimitOffsetPagingSource.kt
- M
room/room-paging/src/jvmNativeMain/kotlin/androidx/room/paging/LimitOffsetPagingSource.jvmNative.kt
- M
room/room-runtime/bcv/native/current.txt
- M
room/room-runtime/build.gradle
- M
room/room-runtime/src/commonMain/kotlin/androidx/room/RoomConnectionManager.kt
- M
room/room-runtime/src/commonMain/kotlin/androidx/room/util/FtsTableInfo.kt
- M
room/room-runtime/src/commonMain/kotlin/androidx/room/util/MigrationUtil.kt
- M
room/room-runtime/src/commonMain/kotlin/androidx/room/util/TableInfo.kt
- M
room/room-runtime/src/commonMain/kotlin/androidx/room/util/ViewInfo.kt
- M
room/room-runtime/src/jvmAndroidMain/kotlin/androidx/room/concurrent/ThreadLocal.jvmAndroid.kt
- M
room/room-runtime/src/jvmNativeMain/kotlin/androidx/room/InvalidationTracker.jvmNative.kt
- M
room/room-runtime/src/jvmNativeMain/kotlin/androidx/room/util/TableInfo.jvmNative.kt
- M
room/room-runtime/src/jvmNativeMain/kotlin/androidx/room/util/ViewInfo.jvmNative.kt
- M
room/room-runtime/src/nativeMain/kotlin/androidx/room/concurrent/ThreadLocal.native.kt
- M
room/room-rxjava2/build.gradle
- M
room/room-rxjava3/build.gradle
- M
room/room-testing/build.gradle
- M
sqlite/sqlite-bundled/build.gradle
- M
sqlite/sqlite-bundled/src/commonMain/kotlin/androidx/sqlite/driver/bundled/BundledSQLiteConnection.kt
- M
sqlite/sqlite-bundled/src/commonMain/kotlin/androidx/sqlite/driver/bundled/BundledSQLiteDriver.kt
- M
sqlite/sqlite-bundled/src/commonMain/kotlin/androidx/sqlite/driver/bundled/BundledSQLiteStatement.kt
- M
sqlite/sqlite-bundled/src/jvmAndroidMain/kotlin/androidx/sqlite/driver/bundled/BundledSQLite.jvmAndroid.kt
- M
sqlite/sqlite-framework/build.gradle
- M
sqlite/sqlite-ktx/build.gradle
- M
sqlite/sqlite/build.gradle
- M
sqlite/sqlite/src/androidMain/kotlin/androidx/sqlite/SQLiteException.android.kt
- M
sqlite/sqlite/src/androidUnitTest/kotlin/androidx/sqlite/db/SimpleSQLiteQueryTest.kt
Hash: 6e1e6e154483b9346ffc27a0e57d14bd20f4359f
Date: Mon Dec 16 22:13:20 2024
al...@gmail.com <al...@gmail.com> #6
Project: platform/frameworks/support
Branch: androidx-main
Author: Daniel Santiago Rivera <
Link:
Migrate androidx.sqlite to use KMP AutoCloseable
Expand for full commit details
Migrate androidx.sqlite to use KMP AutoCloseable
AutoCloseable common was added in Kotlin 2.0
Bug: 315461431
Test: Existing
Relnote: Migrate androidx.sqlite.use to Kotlin's AutoCloseable's use in the stdlib.
Change-Id: I470f02620d43bbe641c58e3fc3637119e8c44532
Files:
- M
room/integration-tests/multiplatformtestapp/src/commonTest/kotlin/androidx/room/integration/multiplatformtestapp/test/BaseAutoMigrationTest.kt
- M
room/integration-tests/multiplatformtestapp/src/commonTest/kotlin/androidx/room/integration/multiplatformtestapp/test/BaseMigrationTest.kt
- M
room/room-paging/src/androidInstrumentedTest/kotlin/androidx/room/paging/LimitOffsetPagingSourceTest.kt
- M
room/room-paging/src/androidMain/kotlin/androidx/room/paging/LimitOffsetPagingSource.android.kt
- M
room/room-runtime/src/androidMain/kotlin/androidx/room/coroutines/AndroidSQLiteDriverConnectionPool.android.kt
- M
room/room-runtime/src/androidMain/kotlin/androidx/room/driver/SupportSQLiteConnectionPool.android.kt
- M
room/room-runtime/src/commonMain/kotlin/androidx/room/EntityDeleteOrUpdateAdapter.kt
- M
room/room-runtime/src/commonMain/kotlin/androidx/room/EntityInsertAdapter.kt
- M
room/room-runtime/src/commonMain/kotlin/androidx/room/InvalidationTracker.kt
- M
room/room-runtime/src/commonMain/kotlin/androidx/room/RoomConnectionManager.kt
- M
room/room-runtime/src/commonMain/kotlin/androidx/room/coroutines/ConnectionPoolImpl.kt
- M
room/room-runtime/src/commonMain/kotlin/androidx/room/util/ConnectionUtil.kt
- M
room/room-runtime/src/commonMain/kotlin/androidx/room/util/DBUtil.kt
- M
room/room-runtime/src/commonMain/kotlin/androidx/room/util/SchemaInfoUtil.kt
- M
room/room-runtime/src/commonTest/kotlin/androidx/room/coroutines/BaseConnectionPoolTest.kt
- M
room/room-testing/src/commonMain/kotlin/androidx/room/testing/MigrationTestHelper.kt
- M
sqlite/integration-tests/driver-conformance-test/build.gradle
- M
sqlite/integration-tests/driver-conformance-test/src/commonTest/kotlin/androidx/sqlite/driver/test/BaseBundledConformanceTest.kt
- M
sqlite/integration-tests/driver-conformance-test/src/commonTest/kotlin/androidx/sqlite/driver/test/BaseConformanceTest.kt
- M
sqlite/sqlite/api/current.txt
- M
sqlite/sqlite/api/restricted_current.txt
- M
sqlite/sqlite/bcv/native/current.txt
- M
sqlite/sqlite/src/commonMain/kotlin/androidx/sqlite/SQLite.kt
- M
sqlite/sqlite/src/commonMain/kotlin/androidx/sqlite/SQLiteConnection.kt
- M
sqlite/sqlite/src/commonMain/kotlin/androidx/sqlite/SQLiteStatement.kt
Hash: 62cf305b742fc901c10da7d435f77d2a38f9d67e
Date: Mon Dec 16 11:39:49 2024
ra...@google.com <ra...@google.com> #7
The following release(s) address this bug.It is possible this bug has only been partially addressed:
androidx.room:room-common:2.7.0-alpha13
androidx.room:room-common-iosarm64:2.7.0-alpha13
androidx.room:room-common-iossimulatorarm64:2.7.0-alpha13
androidx.room:room-common-iosx64:2.7.0-alpha13
androidx.room:room-common-jvm:2.7.0-alpha13
androidx.room:room-common-linuxarm64:2.7.0-alpha13
androidx.room:room-common-linuxx64:2.7.0-alpha13
androidx.room:room-common-macosarm64:2.7.0-alpha13
androidx.room:room-common-macosx64:2.7.0-alpha13
androidx.room:room-compiler:2.7.0-alpha13
androidx.room:room-compiler-processing:2.7.0-alpha13
androidx.room:room-ktx:2.7.0-alpha13
androidx.room:room-migration:2.7.0-alpha13
androidx.room:room-migration-iosarm64:2.7.0-alpha13
androidx.room:room-migration-iossimulatorarm64:2.7.0-alpha13
androidx.room:room-migration-iosx64:2.7.0-alpha13
androidx.room:room-migration-jvm:2.7.0-alpha13
androidx.room:room-migration-linuxarm64:2.7.0-alpha13
androidx.room:room-migration-linuxx64:2.7.0-alpha13
androidx.room:room-migration-macosarm64:2.7.0-alpha13
androidx.room:room-migration-macosx64:2.7.0-alpha13
androidx.room:room-paging:2.7.0-alpha13
androidx.room:room-paging-android:2.7.0-alpha13
androidx.room:room-paging-guava:2.7.0-alpha13
androidx.room:room-paging-iosarm64:2.7.0-alpha13
androidx.room:room-paging-iossimulatorarm64:2.7.0-alpha13
androidx.room:room-paging-iosx64:2.7.0-alpha13
androidx.room:room-paging-jvm:2.7.0-alpha13
androidx.room:room-paging-linuxarm64:2.7.0-alpha13
androidx.room:room-paging-linuxx64:2.7.0-alpha13
androidx.room:room-paging-macosarm64:2.7.0-alpha13
androidx.room:room-paging-macosx64:2.7.0-alpha13
androidx.room:room-paging-rxjava2:2.7.0-alpha13
androidx.room:room-paging-rxjava3:2.7.0-alpha13
androidx.room:room-runtime:2.7.0-alpha13
androidx.room:room-runtime-android:2.7.0-alpha13
androidx.room:room-runtime-iosarm64:2.7.0-alpha13
androidx.room:room-runtime-iossimulatorarm64:2.7.0-alpha13
androidx.room:room-runtime-iosx64:2.7.0-alpha13
androidx.room:room-runtime-jvm:2.7.0-alpha13
androidx.room:room-runtime-linuxarm64:2.7.0-alpha13
androidx.room:room-runtime-linuxx64:2.7.0-alpha13
androidx.room:room-runtime-macosarm64:2.7.0-alpha13
androidx.room:room-runtime-macosx64:2.7.0-alpha13
androidx.room:room-rxjava2:2.7.0-alpha13
androidx.room:room-rxjava3:2.7.0-alpha13
androidx.room:room-testing:2.7.0-alpha13
androidx.room:room-testing-android:2.7.0-alpha13
androidx.room:room-testing-iosarm64:2.7.0-alpha13
androidx.room:room-testing-iossimulatorarm64:2.7.0-alpha13
androidx.room:room-testing-iosx64:2.7.0-alpha13
androidx.room:room-testing-jvm:2.7.0-alpha13
androidx.room:room-testing-linuxarm64:2.7.0-alpha13
androidx.room:room-testing-linuxx64:2.7.0-alpha13
androidx.room:room-testing-macosarm64:2.7.0-alpha13
androidx.room:room-testing-macosx64:2.7.0-alpha13
androidx.sqlite:sqlite:2.5.0-alpha13
androidx.sqlite:sqlite-android:2.5.0-alpha13
androidx.sqlite:sqlite-bundled:2.5.0-alpha13
androidx.sqlite:sqlite-bundled-android:2.5.0-alpha13
androidx.sqlite:sqlite-bundled-iosarm64:2.5.0-alpha13
androidx.sqlite:sqlite-bundled-iossimulatorarm64:2.5.0-alpha13
androidx.sqlite:sqlite-bundled-iosx64:2.5.0-alpha13
androidx.sqlite:sqlite-bundled-jvm:2.5.0-alpha13
androidx.sqlite:sqlite-bundled-linuxarm64:2.5.0-alpha13
androidx.sqlite:sqlite-bundled-linuxx64:2.5.0-alpha13
androidx.sqlite:sqlite-bundled-macosarm64:2.5.0-alpha13
androidx.sqlite:sqlite-bundled-macosx64:2.5.0-alpha13
androidx.sqlite:sqlite-framework:2.5.0-alpha13
androidx.sqlite:sqlite-framework-android:2.5.0-alpha13
androidx.sqlite:sqlite-framework-iosarm64:2.5.0-alpha13
androidx.sqlite:sqlite-framework-iossimulatorarm64:2.5.0-alpha13
androidx.sqlite:sqlite-framework-iosx64:2.5.0-alpha13
androidx.sqlite:sqlite-framework-linuxarm64:2.5.0-alpha13
androidx.sqlite:sqlite-framework-linuxx64:2.5.0-alpha13
androidx.sqlite:sqlite-framework-macosarm64:2.5.0-alpha13
androidx.sqlite:sqlite-framework-macosx64:2.5.0-alpha13
androidx.sqlite:sqlite-iosarm64:2.5.0-alpha13
androidx.sqlite:sqlite-iossimulatorarm64:2.5.0-alpha13
androidx.sqlite:sqlite-iosx64:2.5.0-alpha13
androidx.sqlite:sqlite-jvm:2.5.0-alpha13
androidx.sqlite:sqlite-ktx:2.5.0-alpha13
androidx.sqlite:sqlite-linuxarm64:2.5.0-alpha13
androidx.sqlite:sqlite-linuxx64:2.5.0-alpha13
androidx.sqlite:sqlite-macosarm64:2.5.0-alpha13
androidx.sqlite:sqlite-macosx64:2.5.0-alpha13
al...@gmail.com <al...@gmail.com> #8
ra...@google.com <ra...@google.com> #9
Yeah, both logcat
and the dump for adb shell dumpsys jobscheduler
for your app are going to be very useful.
al...@gmail.com <al...@gmail.com> #10
ra...@google.com <ra...@google.com> #11
You need to look at adb logcat
.
al...@gmail.com <al...@gmail.com> #12
al...@gmail.com <al...@gmail.com> #13
ra...@google.com <ra...@google.com> #14
Can you send me all the contents of adb logcat
thats scoped beyond your app ?
Once you re-launch the app does the job get scheduled again ?
There is unfortunately not a lot of useful information in dumpsys jobscheduler
.
Also, which device are you testing this on ?
al...@gmail.com <al...@gmail.com> #15
The device I am using is a Pixel 3a on Android 10.
ra...@google.com <ra...@google.com> #16
Looking at your logs, you are getting penalized for not stopping work.
Your Worker
continues to run after it had been asked to stop. You need to stop cooperatively or you will get penalized.
That's why the OS revoked connectivity for your uid
to force you to stop.
My guess is JobScheduler
is penalizing your app, and therefore it won't run your work.
ra...@google.com <ra...@google.com> #17
Also the output from adb shell dumpsys jobscheduler
is not complete. Can you please make sure you dump all the info ?
al...@gmail.com <al...@gmail.com> #18
The `adb shell dumpsys jobscheduler` was incomplete since I didn't know how how to copy the text that was cut-off at the top in my Command Prompt. I've now exported results to a txt file directly which allows me to capture everything, however that means I can't get the rest of the previous `adb shell dumpsys jobscheduler` so I did a new one.
ra...@google.com <ra...@google.com> #19
No, that was always a requirement (since WorkManager 1.0).
This behavior is not tied to WorkManager's implementation though. Its JobSchdeduler
that drives the work. So something could have changed there.
I don't see the logs for an App launch after the app exited doze mode? Do you have additional logs from that session ?
al...@gmail.com <al...@gmail.com> #20
al...@gmail.com <al...@gmail.com> #21
ra...@google.com <ra...@google.com> #22
Thanks. I don't see anything unusual there.
Save this script and try running this using python 3
.
Pass the fully qualified package name as the argument to the script. So something like: python3 jobs.py <your_package_name>
.
I still feel like I am missing huge chunks of dumpsys jobscheduler
. Alternatively, you can also do something like: adb shell dumpsys jobscheduler > out.txt
and send me that.
import os
import sys
def jobs(name):
command = 'adb shell dumpsys jobscheduler | grep -A 24 ".*JOB.*%s"' % (name)
os.system(command)
if __name__ == "__main__":
if len(sys.argv) < 2:
print('Usage is ./job.py package_name')
else:
name = sys.argv[1]
jobs(name.strip())
al...@gmail.com <al...@gmail.com> #23
I'm trying to run the script you sent me but I don't really know how.
ra...@google.com <ra...@google.com> #24
I think you may have forgotten to attach the file.
al...@gmail.com <al...@gmail.com> #25
ra...@google.com <ra...@google.com> #26
Nothing looks out of the ordinary. It looks like you had the Worker
run a couple of times based on:
Timer{<0>com.simonits.adalerts} NOT active, 0 running bg jobs
Saved sessions:
996813165 -> 996902031 (88866), 1 bg jobs.
995442568 -> 995655179 (212611), 1 bg jobs.
995400126 -> 995442559 (42433), 1 bg jobs.
991729518 -> 991739652 (10134), 1 bg jobs.
988324231 -> 988392138 (67907), 1 bg jobs.
987839386 -> 987894917 (55531), 1 bg jobs.
973374788 -> 973542710 (167922), 1 bg jobs.
973335801 -> 973335832 (31), 1 bg jobs.
973334781 -> 973335795 (1014), 1 bg jobs.
973298163 -> 973298778 (615), 1 bg jobs.
973164612 -> 973295300 (130688), 1 bg jobs.
972009891 -> 972228958 (219067), 1 bg jobs.
970880825 -> 971109890 (229065), 1 bg jobs.
969749680 -> 969976527 (226847), 1 bg jobs.
968608690 -> 968847501 (238811), 1 bg jobs.
967034243 -> 967091488 (57245), 1 bg jobs.
965486455 -> 965562052 (75597), 1 bg jobs.
964497879 -> 964555054 (57175), 1 bg jobs.
963084431 -> 963303262 (218831), 1 bg jobs.
961964759 -> 962178948 (214189), 1 bg jobs.
961282552 -> 961468886 (186334), 1 bg jobs.
960842943 -> 960902474 (59531), 1 bg jobs.
959881647 -> 959938712 (57065), 1 bg jobs.
958821517 -> 958977069 (155552), 1 bg jobs.
957169812 -> 957383549 (213737), 1 bg jobs.
So your Worker
was running.
ra...@google.com <ra...@google.com> #27
Your Worker
should respect stoppage requests. Try adding that.
Apart from that, nothing here looks out of the ordinary. I am marking this bug as not-reproducible.
If you have more information, feel free to comment and I can take a look.
al...@gmail.com <al...@gmail.com> #28
I will look into stoppage requests. Thanks.
ra...@google.com <ra...@google.com> #29
I found an edge case, where your Worker
will not correctly be rescheduled if it got interrupted.
That's probably why JobScheduler
is not picking it up. Adding a fix.
al...@gmail.com <al...@gmail.com> #31
ra...@google.com <ra...@google.com> #32
I just wanted to keep you in the loop. This should be addressed by WM 2.3.3.
al...@gmail.com <al...@gmail.com> #33
ap...@google.com <ap...@google.com> #34
Branch: androidx-master-dev
commit 3f01efa9acd4208ad35f2537bf730562982d088b
Author: Rahul Ravikumar <rahulrav@google.com>
Date: Thu Feb 27 15:04:30 2020
Mark WorkSpecs unscheduled when they are interrupted.
* We cancel work in all schedulers when onWorkFinished() is called irrespective of the
state of the WorkSpec.
* When a WorkSpec is interrupted, if it needs rescheduling, the schedule_requested_at bit must be unset,
so it can picked up by Schedulers.
Fixes:
Test: Added unit tests.
Change-Id: I9c5fb3192710ec853b5c80ffd4da5f8936912c1c
M work/workmanager/src/androidTest/java/androidx/work/WorkDatabaseMigrationTest.java
M work/workmanager/src/androidTest/java/androidx/work/impl/WorkerWrapperTest.java
M work/workmanager/src/main/java/androidx/work/impl/WorkDatabase.java
M work/workmanager/src/main/java/androidx/work/impl/WorkDatabaseMigrations.java
M work/workmanager/src/main/java/androidx/work/impl/WorkerWrapper.java
A work/workmanager/src/schemas/androidx.work.impl.WorkDatabase/11.json
Description
Version used: 2.3.2
Devices/Android versions reproduced on: Pixel 3a, Android 10
If this is a bug in the library, we would appreciate if you could attach:
- Sample project to trigger the issue.
- A screenrecord or screenshots showing the issue (if UI related).
I have unique periodic work that runs every 15 minutes. On version 2.3.1, the work stops starting when my device enters Doze Mode when I go to sleep. Then in the morning when I pick up my phone and it exits Doze Mode, the work starts again every 15 minutes. In version 2.3.2, the works stops starting when my device enters Doze Mode, but in the morning when my device exits Doze Mode, the work does not start again and never starts thereafter.