Skip to content
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

Replace deprecated JobIntentService with WorkManager #5742

Merged

Conversation

TacoTheDank
Copy link
Contributor

@TacoTheDank TacoTheDank commented Feb 21, 2022

JobIntentService is deprecated. WorkManager is its recommended replacement. I replaced it.

Why? Because JobIntentService has an infamous crashing bug on Android O (though that was fixed with a workaround). And it's also deprecated.

Tested on APIs 29 (physical device) and 22 (virtual device).

See these for WorkManager info.

Feel free to make any suggestions.

@TacoTheDank
Copy link
Contributor Author

TacoTheDank commented Feb 23, 2022

Why did the validation wrapper fail 🤔

Okay passed now.

@ByteHamster ByteHamster merged commit b6da9ae into AntennaPod:develop Feb 23, 2022
@TacoTheDank
Copy link
Contributor Author

Thank you.

@TacoTheDank TacoTheDank deleted the widgetUpdaterWorkManager branch February 24, 2022 23:33
@ByteHamster
Copy link
Member

Looks like this broke the widget. It can now sometimes get into a loop and update forever. Reverting this commit immediately fixes the problem. Looks like PlayerWidget.onUpdate is called indefinitely.

device-2022-04-22-230436.mp4

@TacoTheDank
Copy link
Contributor Author

TacoTheDank commented Apr 22, 2022

I didn't experience that at all 🤔. I will attempt to reproduce and solve this issue.

Right now I'm at the end of my semester, so I'll have little time to test for the next week or so.

What Android version was this recording shot on?

@ByteHamster
Copy link
Member

What Android version was this recording shot on?

Android 11 (LineageOS). I cannot reproduce in an emulator, unfortunately. But I can reproduce in both Nova Launcher and Lawnchair2. Hmmm...

@ByteHamster
Copy link
Member

Re-installing the app fixed this. Maybe WorkManager somehow remembered old jobs and triggered them again and again. Not sure. Let's hope it does not come back.

@antennapod-bot
Copy link

This pull request has been mentioned on AntennaPod Forum. There might be relevant details there:

https://forum.antennapod.org/t/antennapod-2-6-release-notes/1964/1

@antennapod-bot
Copy link

This pull request has been mentioned on AntennaPod Forum. There might be relevant details there:

https://forum.antennapod.org/t/widget-problem/2162/2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants