Any way to avoid Install Failed Permission level downgrade on Android? - android

I'm getting an error - INSTALL_FAILED_PERMISSION_LEVEL_DOWNGRADE while installing app from adb after targeting sdk 22, coming down from 23.
I have to do this, temporarily because of some other issues but it would not be the best experience for the users updating the app on Google play if they just couldn't. The only solution I know as of now is to uninstall the current version (targeting SDK 23) and then install the update (targeting SDK 22).
Even though there are only a handful of people on Marshmallow right now, it would be best if they don't face this issue.
Does anyone know anything about this?
Update: AFAIK nothing can be done in the app or on the console to avoid users uninstalling and installing the app. Luckily, I did it when the users on Marshmallow were few.

Perhaps this answer does not directly address the question, but may it helps others to achieve a faster solution.
I have created some versions with the following configuration (inside build.gradle) and made them available to alpha- and beta-tester via Google Play Console:
minSdkVersion 23
targetSdkVersion 23
When I noticed that users with a deeper system-version could not install the app, I changed the configuration as follows:
minSdkVersion 19
targetSdkVersion 19
However, this resulted in the downgrade error message in Google Play Console. So I adapted the configuration that the new version for both
user with a lower system version as well as for users who have installed the current app (with a higher system version).
minSdkVersion 19
targetSdkVersion 23

Related

Does Google Play Store automatically updates apps automatically?

If my App has minSDKVersion = 16 and TargetSDKVersion = 28, then will Google somehow upgrade my App to work with devices which use sdk version greater than 28?
And if the same is true for all future versions of SDK then if I dont update my app meanwhile?
Please excuse me as my English is not good. Thanks.
Google never ever updates your apps for the latest SDK, you have to do it yourself and publish again. I know its a pain when google play console frequently changes requirements to support certain Target API Level but its the pain you have to endure. TargetSDKVersion is the last SDK / API which your app will support.
No, you will need to do an update by changing your targetSDK from your build.gradle file, then make the required changes in your code to work with that API level and you can upload an update.
The Playstore will not update it automatically, that's why it's called targetSDKVersion, it will just be available from SDK 16 until the target one, 28.

TargetSdkVersion 26 i got a main please clarify

Recently i got a mail from google to change the targetsdkversion to 26 or above
but i have a question regarding this :
In my console i have around 50 android applications of which there are only 8 apps which are under production(in Live) and the rest apps i have already unpublished it and i will not use it any more (means i will not publish those apps again) so my point is should i need to update the unpublished app to change the targetsdkversion to 26 or above as in mail i got if account has more than 20 apps which are not targetsdkverion 26 it may affect account
please help me what to do
From android docs:
Google Play will require that new apps target at least Android 8.0
(API level 26) from August 1, 2018, and that app updates target
Android 8.0 from November 1, 2018
You don't need to update your production apps until you actually wanted to release new update.
One more important fact:
Configuring your app to target a recent API level ensures that users
can benefit from these improvements, while still allowing it to run on
older Android versions.
If you will not publish those apps again then don't worry for account. Just update apps those are under production

Upload apk to store gets warning message

When I try to upload the apk to store I get these warnings
Partially upgradable APK
WARNING
Some users of this APK may not be able to upgrade to any of the new APKs added in this release.
CAUTION
Users that currently have APK with version code 53, which targets SDK 22 or lower, will be eligible to upgrade to this APK. However, once users upgrade to this APK, they will be unable to upgrade to APKs that target SDK 22 or lower.
Following datas are my current build details
compileSdkVersion 26
buildToolsVersion 26.0.2
minSdkVersion 15
targetSdkVersion 26
This is my previous update details
compileSdkVersion 25
buildToolsVersion "25.0.3"
minSdkVersion 15
targetSdkVersion 22
This warning is because yoy have upgraded your api higher than 22 that means you have to handle some runtime permisions. The warning says that this is a one way switch i.e there is no way of coming back to targeting API 22 or earlier once you make the switch to the runtime permission model.The developer console is just confirming that you have done all the thing need for runtime permissions so no need to worry.
It is normal but in your case - you need to be careful since you target several levels higher.
Warning: Users using previous build would not be able to install the
update simply because of difference in permission models and higher
compile - 26. So if you don't make sure that you handle new permission
models and other functionalities, you may tend to lose part of your
users.
Caution: Users once they update to the new build will not be
able to upgrade back to lesser build of the same App. This means once
you publish your App in higher build successfully, you can't go back
to lesser build targets in your next update. Make sure all your
functionalities work in the new build before deploying.
Thanks
Its simply ok.
Warning indicates that once you increase your target version higher than your previous target version then users get update to newer targeted version app. But then after they cant receive update for lower target version.
But make sure you have handled Runtime Permission Model Properly for all dangerous group permission.
Rather than it does not affect your user base or nor your app functionality.
Happy Coding..

Increased minSdkVersion, now older devices can't install the older app version that supported them

I increased the minSdkVersion from 16 to 21. I thought that when a user with an old device visits the play store, they will be able to download the previous APK that has it set to 16, and only the new devices will see the latest version.
However, when I visited the play store with a device running sdk 16, I just see "your device is incompatible with this version"
How do I make it so that the older devices are able to download the older version?
You need to revert minSdkVersion value to 16 again.
Below happens on minSdkVersion change
On apk upload, Google plays warns you on minSdkVersion telling how many users will be affected.
Existing users lower than minSdkVersion won't get update and cannot see app in PlayStore
Existing users lower than minSdkVersion, if they uninstall, cannot reinstall the application.
I suggest you use multiple apk option in PlayStore and continue to update your newer apk. Just keep the old one as it is.
Refer this : https://developer.android.com/training/multiple-apks/api

Getting Android app to run on more devices?

This is a beginner question, but what are the steps needed to get my app to run on more devices? I noticed that my new update (on beta) is running on fewer devices. Do I just need to update the targetminsdk version in build gradle or is there anything else I need to do? I think I should be aiming for minsdkversion 18?
My versions in gradle are here
compileSdkVersion 23
minSdkVersion 21
targetSdkVersion 22
Min sdk version : Is the earliest release of the Android SDK that your application can run on. So this is what you want to change if you want more devices supported for your app.
Target sdk version : The version your application was targeted to run on. Ideally this is because of some sort of optimal run conditions.
Android Developers forum says :
The dashboard for Platform Versions is updated regularly to show the distribution of active devices running each version of Android, based
on the number of devices that visit the Google Play Store. Generally,
it’s a good practice to support about 90% of the active devices, while
targeting your app to the latest version.
For more details, go through : Supporting Different Platform Versions
For API 18 : your app will run on approximately 76.9% of the devices that are active on Google Play Store.
For API 21 : your app will run on approximately 40.5% of the devices that are active on Google Play Store.
Now that is a huge difference, that you may not really want for your app. So you need to weigh your pros and cons of having Latest API support to getting more users. I would infact recommend you to go for API 18 instead of 21, unless you have some very important functionality that necessitates API 21 and above and can't be done without.

Categories

Resources