Change theme
Help
Press space for more information.
Show links for this issue (Shortcut: i, l)
Copy issue ID
Previous Issue (Shortcut: k)
Next Issue (Shortcut: j)
Sign in to use full features.
Vote: I am impacted
Notification menu
Refresh (Shortcut: Shift+r)
Go home (Shortcut: u)
Pending code changes (auto-populated)
View issue level access limits(Press Alt + Right arrow for more information)
Unintended behavior
View staffing
Description
Version used: beta01, beta02, and beta03
Devices/Android versions reproduced on: Pixel 2 on 9, Nexus 6P on 8.1
Code used to enqueue period work:
WorkManager.getInstance()
.enqueueUniquePeriodicWork("periodic_backup", ExistingPeriodicWorkPolicy.REPLACE,
PeriodicWorkRequest.Builder(BackupWorker::class.java, quantity, timeUnit)
.addTag("contacts_backup")
.build())
When testing I've used a 15 minute interval.
I have additionally tried setting various constraints to see if applying them has any impact on the task resuming after the app is swiped away, including NetworkType.CONNECTED network constraint, and a battery-not-low constraint.
As long as the app is left unswiped the periodic work will continue to run indefinitely. The moment that it is swiped from the window selector the work never resumes, even if left for more than a day. If I check the WorkInfo by searching the "periodic_backup" tag in getWorkInfosForUniqueWork, I can see that it is there, but never leaves the ENQUEUED state.