medic / cht-gateway

Android SMS gateway app for CHT Applications
GNU Affero General Public License v3.0
84 stars 41 forks source link

Changes in upcomming Android 12 may break the SMS capabilities #182

Open mrsarm opened 3 years ago

mrsarm commented 3 years ago

Copy & paste of the issue created in https://github.com/medic/cht-android/issues/205 , same applies here:

In the upcoming Android 12 there is an API that changes the way can be used, and we use that feature in the code that handle the SMS capabilities.

Starting Android 11 the new linter from the Android Gradle Plugin warns about it (check this) so we needed to add an annotation in the source code to ignore the issue, but later we will need to remove the annotation and makes the necessary changes.

Warning when we remove the annotation:

Screenshot from 2021-08-09 16-55-38

More info about the change: https://developer.android.com/about/versions/12/behavior-changes-12#pending-intent-mutability