-
-
Notifications
You must be signed in to change notification settings - Fork 642
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Run ReadingListSyncAdapter as expedited work #5063
base: main
Are you sure you want to change the base?
Run ReadingListSyncAdapter as expedited work #5063
Conversation
81e81cb
to
f150815
Compare
Thanks for the PR! Not sure but I don't see the notification when I start or login the app. Does this work for manually syncing the list? |
That might be due to how foreground notifications work on Android 12 and later: "Devices that run Android 12 (API level 31) or higher provide a streamlined experience for short-running foreground services. On these devices, the system waits 10 seconds before showing the notification associated with a foreground service." I'll update the PR to change the behavior. |
Thanks. I am still not seeing the notification. My device is Samsung S24 with Android 14. |
It might be because the syncing is usually too fast to show the notification on newer Android versions. I set a breakpoint for the update foreground info method on my Pixel 8 with Android 15 and the notification appeared. |
What does this do?
This PR updates the reading list sync worker to run as expedited work.
Why is this needed?
With this change, WorkManager configures the worker to start execution immediately. It also provides APIs to create/update the work notification.
Demo
Screen_recording_20241026_083731.webm
Android 5.0