-
Notifications
You must be signed in to change notification settings - Fork 8
feat app: Lower min SDK to API 26 #42
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
Conversation
app/build.gradle.kts
Outdated
| versionName = "1.0.0" | ||
|
|
||
| testInstrumentationRunner = "com.matejdro.micropebble.instrumentation.TestRunner" | ||
| minSdk = 26 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not necessary, it will reuse the nubmer from the android-module-commons.gradle.kts
apps/ui/build.gradle.kts
Outdated
| buildFeatures { | ||
| androidResources = true | ||
| } | ||
| defaultConfig { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not necessary, it will reuse the nubmer from the android-module-commons.gradle.kts
|
I think this is a good start, but I'm almost sure that it will not work as-is because app uses a lot of APIs that are not available in pre-31 |
7dafe78 to
4b31684
Compare
|
I couldn't get it to crash in the emulator, but I will test further on actual hardware in the next couple of days. I'm pretty sure I have an Android 11 phone somewhere. |
|
(I hope you don't mind me pushing a CI fix to your branch) EDIT: Sorry, I thought I could fix it, but there is some other underlying issue. Until I get to it, you will unfortunately have to check the action logs to see the failed lint issues. |
… lower-min-sdk
|
Alright. Android 11 now works, pairs to the watch and all that. Newer Android also works too still, currently running this build on my phone. |
| } | ||
| } | ||
|
|
||
| val bluetoothPermission = rememberMultiplePermissionsState( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we try moving this into a separate method? Now it's a bit long to be nested inside Composable
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To be honest, I'm not sure how I'd do that easily 😅 I'll probably take another crack at it tomorrow when I've got more sleep
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me
|
How do I re-run the CI check? It looks like npm failed, not any linting error this time. |
ecde32f to
4b41971
Compare
|
Should double-check the screenshot tests — I think they're correct now but I'm not entirely certain. Also the installed watchapps screen shows a bar about a third of the width of the column instead of the full bar like before, it's a side effect of switching to PrimaryTabRow instead of the deprecated TabRow |
Actually it looks like the screenshot changes also include things gaining an accent colour and other things losing the accent colour. I'm not sure what's up with that, obviously it's a change due to this PR. Maybe the change to Theme.kt? I don't know what Android version the screenshots are generated on, could that have changed? I'm unfamiliar with how the screenshots are actually generated |
|
Yeah screenshots look fine. My guess is that screenshots are made on a fake lower SDK version, so the colors are slightly different. What concerns me, are the two things using the ComponentFactory, that got disabled on the lower SDK versions without providing an alternative:
If you do not have pre-android-9 device to test, we should increase the min SDK back to a device that we do have and we can test it works correctly (presumably at most Android 11 device?). |
|
Hmm I think the oldest device I have is an Android 11 phone. Maybe I bump up the minSDK to 28 instead? |
|
Yes, I think that would be the best. |
Lint reportResults
Suppressed ResultsNothing here. |
|
Thanks! |

No description provided.