Closed gnprice closed 2 years ago
Well, here's one blocking issue:
https://developer.android.com/about/versions/12/behavior-changes-12#notification-trampolines
We'll need to replace our NotificationIntentService
, which we use when you tap a notification to open it, with directly opening an Activity. (We learned about this from a lint warning in Android Studio: https://github.com/zulip/zulip-mobile/pull/5121#discussion_r747107709)
MainActivity
. We'll need to play with things somewhat to try to get the correct behavior in all three cases of the app being in the foreground, in the background, and not running. (Currently NotificationIntentService
has NotifyReact.kt
do this work.)
Fragment
s for navigation instead. But in any case it's not our structure of things using RN, and we have just one activity where the app's whole UI (apart from the notifications) lives. Hence the need to play with things to find a solution.ShareToZulipActivity
. That sure won't be in the spirit of what they're going for here, though. It may also cause visible jank in the UI, like an extra transition.A few items stand out in the list of breaking changes. Blank checkboxes are things we need to fix before targeting Android 12.
I expect "Android App Links", as in "Android App Links verification changes", won't be relevant until we work on #4577. It's something you can use so that your website can also be opened by your Android app. "Verification" is a step where the device makes a request to the website and retrieves some metadata from it, for the app's sake. Until #4577, I don't think we'll have any websites that need to be verified like this. (Our zulip://
URLs, for web auth, don't point at websites.) When we work on that issue, we'll just use the updated verification protocol.
[ ] #5171
"App hibernation": @gnprice and I discussed this in the office, and I think we concluded that there's not a ton we can do about this? Users who leave the app untouched for a really long time will stop getting notifications. Hopefully when that happens, it'll coincide with the user not caring if they don't get notifications.
[ ] "Safer component exporting": We'll have to put a few lines in our Android manifest XML file. That should be easy.
[x] "Notification trampoline restrictions": That's what Greg was talking about above, in https://github.com/zulip/zulip-mobile/issues/5101#issuecomment-966039530, and it's been fixed in #5146! 🎉
"Connectivity": I think the only thing from this (and it doesn't have to happen before we target Android 12) is that @react-native-community/netinfo
should eventually stop using an Android API that's newly deprecated; I've filed https://github.com/react-native-netinfo/react-native-netinfo/issues/552 for that.
This is the successor to #4284 (and #3665 and #3563 and #3075). We should update our
targetSdkVersion
to 31, meaning Android 12.Based on the last few years' experience, Google Play will probably set a deadline for this of late 2022. It's been the first business day of November in each of the last few years.
The important steps for this upgrade are:
targetSdkVersion
.We aren't aware of any blockers to this, so we can try doing it any time. It'd be nice to do it well before the deadline -- or at least to go far enough to learn about any unknown blockers.