Xavier Rubio Jansana

@xrubioj
12 Followers
75 Following
9 Posts
Mobile engineer, Android & iOS. Scuba diver.
Bloghttps://xrubio.com
Twitterhttps://twitter.com/teknik_codes
GitHubhttps://github.com/xrubioj

Hello LeakCanary friends! I have a message that could use some reposting 😅

so, eeeer, 2 years ago I messed up and referenced a WorkManager internal class (`SettableFuture`) in LeakCanary. No idea why I did that. Here's my dumb mistake in all its glory: https://github.com/square/leakcanary/pull/2275/files#diff-ae4c2fcbc6f148463cada95a97481365d635c9df97e826f9604824f4f714dfa6R40

Anyway, the WorkManager team is planning to delete this internal class, at which point LeakCanary releases from 2.8 to 2.13 will crash at runtime.

To avoid a nasty surprise, update to 2.14 ASAP! https://square.github.io/leakcanary/changelog/#version-214-2024-04-17

Fix WorkerManager crash pre API 31 by pyricau · Pull Request #2275 · square/leakcanary

setExpedited() isn't enough, we also needed to provide ForegroundInfo. The documentation doesn't make this very obvious, and there's no API enforcement. Fixes #2268

GitHub

Yay, progress!

“To strengthen the Android platform, our collaboration with Google has resulted in a unified policy that we expect will create a more consistent and reliable user experience for Galaxy users. Since One UI 6.0, foreground services of apps targeting Android 14 will be guaranteed to work as intended so long as they are developed according to Android's new foreground service API policy.” - Samsung

https://android-developers.googleblog.com/2023/05/improving-consistency-of-background-work-on-android.html

Improving Consistency of Background Work on Android

In Android 14, we are adding new functionality to the existing foreground services and JobScheduler APIs. Learn more.

Android Developers Blog