Skip to content
This repository has been archived by the owner on Jun 20, 2023. It is now read-only.

[Discussion] Android 5.0 (lollipop) Support #1799

Closed
felischmi2003 opened this issue Dec 3, 2020 · 28 comments
Closed

[Discussion] Android 5.0 (lollipop) Support #1799

felischmi2003 opened this issue Dec 3, 2020 · 28 comments
Assignees
Labels
enhancement Improvement of an existing feature mirrored-to-jira This item is also tracked internally in JIRA question Further information is requested

Comments

@felischmi2003
Copy link

felischmi2003 commented Dec 3, 2020

Danke, dass ihr den Source Code öffentlich zugänglich gemacht habt.

Aber trotzdem habe ich ein problem...
Ich besitze ein Gerät mit Android 5.0 und die App ist aber erst mit 6.0.x kompatieble.

Wie kann ich diesen Code umändern um die auch für ältere Geräte verfügbar machen kann?

Mit freundlichen Grüßen,
Felix Schmitt


Internal Tracking ID: EXPOSUREAPP-6360

@felischmi2003 felischmi2003 added the question Further information is requested label Dec 3, 2020
@MikeMcC399
Copy link
Contributor

MikeMcC399 commented Dec 3, 2020

@felischmi2003

es gibt leider technische Probleme mit Android 5.0 (API 21) - siehe #649 und #1446 (comment)
Manifest merger failed : uses-sdk:minSdkVersion 21 cannot be smaller than version 23 declared in library [androidx.security:security-crypto:1.0.0-rc03]

Offiziell wird die Corona-Warn-App erst ab Android 6.0 (API 23) unterstützt - siehe https://www.coronawarn.app/de/faq/#minimum_requirements.

Edit: Since CWA Android 2.2 the error message regarding androidx.security has been suppressed. This was implemented through #2955.

<uses-sdk tools:overrideLibrary="com.google.zxing.client.android,androidx.security" />

@felischmi2003
Copy link
Author

@MikeMcC399
Oh, Ok Danke für die Info

@fynngodau
Copy link
Contributor

@MikeMcC399 There is a more recent version of this androidx.security:security-crypto available that supports API version 21. Support was added in 1.1.0-alpha1.

You could use it like I did in this commit to the repo of our fork: https://codeberg.org/corona-contact-tracing-germany/cwa-android/commit/f420799562f2e203cfaa941914d815700c2e2c13

With that obstacle out of the way, it would only be a few minor issues that would need to be fixed for Android 5 support as far as the CWA client is concerned. I'm currently also planning to tackle the ones I haven't had time for yet in my fork.

@MikeMcC399
Copy link
Contributor

@fynngodau

There is a more recent version of this androidx.security:security-crypto available that supports API version 21. Support was added in 1.1.0-alpha1.

I see there is some more information on https://developer.android.com/jetpack/androidx/releases/security.

This library caused major problems in the past (see #642 (comment) from this hot topic) so I would guess that any upgrade in the CWA app by the developers would be done with extreme caution, in addition to the fact that it would mean moving from a release candidate to an alpha build of the library. I don't see any "Current Stable Release" mentioned either.

You have of course more flexibility in your own environment where you have forked the app.

@dsarkar dsarkar changed the title Android 5.0 (lollipop) Support [Discussion] Android 5.0 (lollipop) Support Dec 5, 2020
@dsarkar dsarkar added the further input needed Issue requires more input from the creator to be processed good first issue label Dec 5, 2020
@LillyWho
Copy link

LillyWho commented Dec 5, 2020

At this point you might as well unlock your device and install a more recent Android version via a custom ROM instead of forking the app if implementing a new library version is so risky.

@cschweers
Copy link

Another fact that should be taken into account: the vast majority of devices running Android 5.0 do not support the necessary Bluetooth 4.0 functions.

@treysis
Copy link

treysis commented Dec 11, 2020

Another fact that should be taken into account: the vast majority of devices running Android 5.0 do not support the necessary Bluetooth 4.0 functions.

I wouldn't be so sure about that. I even think it is the other way round: most Android 5.0 devices support BLE including acting as a beacon. BLE was introduced into Android with 4.3. Before that, some vendors used their own patches to make use of BLE.

@MikeMcC399
Copy link
Contributor

I noticed that a new release candidate security-crypto-1.0.0-rc04 was released 2 days ago on Jan 13, 2021

Bug Fixes

Upgraded Tink to 1.5.0 for increased stability.

Interestingly it does not throw an error when built with minSdkVersion 21 unlike 1.0.0-rc03 (see #1799 (comment)), so this should at least remove this road-block for supporting Android 5.0 (API21).

Perhaps security-crypto-1.0.0-rc04 could be considered for a future branch (so long as there is no stable release available)?

@fynngodau
Copy link
Contributor

@MikeMcC399 I'm not sure why you are not seeing the build failure anymore, but version 1.0.0-rc4 also requires minSdkVersion 23, as becomes evident from the source code (at the latest commit in RC 4): https://android.googlesource.com/platform/frameworks/support/+/15da9761b41f813f22ba89ee571c696ef912bb36/security/crypto/build.gradle#43

Therefore, the build must still not work (if it does build, one must expect runtime crashes on Android 5).

So far, we have been using the alpha releases for version 1.1.0 since the first of our releases that supports Lollipop over at CCTG as I described above, and we haven't encountered any issues with this library, but I'm also guessing that our userbase for Android 5 specifically is rather small.

Another development on this issue is that #2026 has been merged, increasing the codebase's compatibility with Android Lollipop.

@MikeMcC399
Copy link
Contributor

@fynngodau
Thank you for setting the record straight. I guess it must have been a "pilot error" in Android Studio on my part, coupled with "wishful thinking". 🙄

I rechecked and saw
Manifest merger failed : uses-sdk:minSdkVersion 21 cannot be smaller than version 23 declared in library [androidx.security:security-crypto:1.0.0-rc04]
which completely confirms what you wrote. Sorry for my misleading post! It's also clear if you read https://developer.android.com/jetpack/androidx/releases/security carefully enough.

It is good to hear that you are making good ground with Android Lollipop anyway!

@MikeMcC399
Copy link
Contributor

@fynngodau
How is the experience of CCTG with Android 5.0 (Lollipop) progressing?

Also I wonder how many additional users might download CWA if it was also available on Android 5.x.

Maybe it's not comparable, but the numbers of Apple iOS downloads shown on https://www.coronawarn.app/en/blog/ have changed about the same as Android numbers since CWA 1.12 was made available on Feb 10, 2021 covering iPhone 5s, 6, and 6 Plus. Android and iOS downloads have each increased about 0.2 Million during February. The last totals were Android 14.2 Mio, iOS 11.6 Mio, total 25.8 Mio downloads.

@fynngodau
Copy link
Contributor

#2955 was merged, adding compatibility to Lollipop, including many compat fixes so that it works well with Android 5, to the codebase.

The PR does not, however, reduce minSdkVersion to 21, there's still internal discussion about this.

@vaubaehn
Copy link
Contributor

vaubaehn commented May 4, 2021

The PR does not, however, reduce minSdkVersion to 21, there's still internal discussion about this.

I'm quite sure, that it's just a matter of (short) time... I hope...

@heinezen heinezen added the Fix 2.2 Fix is planned for 2.2 label May 4, 2021
@MikeMcC399
Copy link
Contributor

@heinezen

As @fynngodau said, minSdkVersion is not changed to 21 (for Android 5) and stands as before at 23 (for Android 6):

Probably the label Fix 2.2 should be removed from this issue because support for Android 5.0 (Lollipop) has not been enabled with the release of 2.2.1.

@dsarkar dsarkar removed Fix 2.2 Fix is planned for 2.2 further input needed Issue requires more input from the creator to be processed good first issue labels May 14, 2021
@MikeMcC399
Copy link
Contributor

Are there any unsolved technical issues preventing CWA being released for Android 5.0 (Lollipop)?

Probably there should be an "enhancement" (Request) label attached to this issue, since it has become more of a request than just a simple "question" over the course of time.

@heinezen heinezen added the enhancement Improvement of an existing feature label May 16, 2021
@fynngodau
Copy link
Contributor

Are there any unsolved technical issues preventing CWA being released for Android 5.0 (Lollipop)?

None to my knowledge, except for very minor visual details like missing ripple effects.

@AlexElvers
Copy link

Are there any updates? The app is still not available in the Play Store for Android 5.0. I would really like to use it, especially the new Impfnachweis feature. :)

@MikeMcC399
Copy link
Contributor

@AlexElvers

Are there any updates? The app is still not available in the Play Store for Android 5.0. I would really like to use it, especially the new Impfnachweis feature. :)

I checked in the Google Play Store for CovPass-App as an alternative for managing vaccination certificates and unfortunately this other app also requires a minimum of Android 6.0 🙁.

In any case it would be good to hear back from the developers what the plans for CWA are in respect to Android 5.0. I can't see any changes to minSdkVersion 23 in the future branches 2.4.x and 2.5.x so far though.

@fynngodau
Copy link
Contributor

fynngodau commented Jun 11, 2021

@AlexElvers An application to store your digital vaccination is not really needed, you can simply make an offline copy of the QR code. This will work just the same. (Digitaler-Impfnachweis/documentation#13)

Otherwise, you are of course much invited to use our CCTG app ;)

@G00fY2
Copy link

G00fY2 commented Jul 16, 2021

Just want to crosspost this issue from the covpass app here: Digitaler-Impfnachweis/covpass-android#15

Since people are asking for at least one app running on API 21 devices for managing their vaccination certificates. In this issue I also explained some possible reasons why using minSDK 21 is a potential risk.

@zettelmuseum
Copy link

For those who want to have a digital eu certificate on their Android 5 phone, I just found this CWA fork:
https://f-droid.org/en/packages/de.corona.tracing/
Just installed this on my very old very cheap zte phone with android 5.0.2 and successfully scanned my certificate qr code. cheers!

@mtwalli
Copy link
Contributor

mtwalli commented Mar 10, 2023

Not planned

@mtwalli mtwalli closed this as not planned Won't fix, can't repro, duplicate, stale Mar 10, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement Improvement of an existing feature mirrored-to-jira This item is also tracked internally in JIRA question Further information is requested
Projects
None yet
Development

No branches or pull requests