Android: updating apk from outside Google Play with greater versionCode - android

Android documentation says it is important that versionCode parameter is greater on a new apk than the old one when uploading a new release to the Developer Console, but it says also that versionCode is not really enforced on the system, if I am not wrong.
Here: http://developer.android.com/tools/publishing/versioning.html
Does it mean I could distribute newer apk files (not beta versions), let's say, on a web-site while the one on Google Play is updated less frequently (by my choice) without any problem?

The device won't let you install an application with the same package name as an existing application unless the new version code is greater than or equal to the existing version code.
So yes, you can have version 1 on your device and the Play store, then distribute newer apks with version code 1,2,3,4. Then the next apk uploaded via the console must be 5 to allow devices with code 4 to install it.

As you say you have two apk's.
Let suppose that we have
A.apk (versionCode = 40) - downloaded from Google Play. Installed on user device.
A.apk (versionCode = 41) - located on your website.
In this case you can send to your customers link to update your application. As you know Google Play waste some time to check your app, so
if you push 41 version in GooglePlay you will have next scenario :
User have application with versionCode = 40.
You send notification/link for update
You push 41 version into Google Play
User download 41 version and install it.
After Google check your app you dosn't receive any messages for update.
So, roll-back to your answer
- Does it mean I could distribute newer apk files (not beta versions), let's
say, on a web-site while the one on Google Play is updated less frequently
without any problem?
- Yes.

Related

Android play console: internal testing version, close testing ? how does it works?

I already have a production app on play store,
now I have uploaded the next release version on internal testing track,
I have created a mailing list with team testers, but now all the tester of my team see the test version and they cannot choose between production version and test version. Is there a way to choose between the two version ?
How can the tester chooses between production app and the testing version ?
Moreover I'm wondering which is the difference between Android play console internal testing and closed testing ?
End users (or testers) cannot choose which version they want, they will always receive the APK/AAB with the highest versionCode that they are eligible for.
If users receive the APK from a testing track and want to go back to the production one, they have to opt out of the testing then reinstall the app (since Android will never downgrade an app) or wait for the next production push.

Cancel support for legacy Android SDK level for new installs

My app currently has a minSdkVersion of 15 (ICS 4.0.3).
Due to additional dependencies, I have to go up with the min SDK to 19 (Kitkat 4.4).
I already build multiple APKs for min15 and min19 productFlavors.
I'd like to provide bugfixes for my existing users of min15, but don't want new users to install min15.
How can I accomplish this?
Is it possible to unpublish the min15 for new installs, but still provide updates for existing users?
At the moment this is not possible. You can't unpublish single APKs, just the whole app.
You should publish multiple apks for your app. one with minSDK 15 and another one with minSDK 19. Play-store allows this
Multiple APK support is a feature on Google Play that allows you to
publish different APKs for your application that are each targeted to
different device configurations. Each APK is a complete and
independent version of your application, but they share the same
application listing on Google Play and must share the same package
name and be signed with the same release key. This feature is useful
for cases in which your application cannot reach all desired devices
with a single APK.
Check docs here

Android: Does Google Play check versionCodes of installed apks?

Google Play has an automatic update system for apps. When a new version is uploaded to the Developer Console the app is updated on user devices because the new versionCode is greater than the one that is already installed. But users could get a newer apk from other sources.
I would like to know some details about this automatic process, I mean:
A-Does Google Play keeps a value inside so it remembers what versionCode of an app it has officially installed?
or
B-Does Google Play inspects all installed apks so it can compare the version codes to the current versions officially provided by the developers on Google Play?
Note the difference:
-in the A case, it just remember what it officially installed but is not informed about the real versionCode the user has on the device; so it could try to update even when the user already got a newer apk from outside Google Play (fail);
-in the B case, the update system can understand what version in installed because it checks it; so the update doesn't even start if the user upgraded an app from outside the Google Play.
Which is the real case?
It is case A - Google remembers which version of the app was last installed.
It does not check the device every time for the latest installed version.
How to verify this?
If you ever factory reset your phone or flash a ROM, go to play store from your browser and open an app page which you'd installed before you flashed the ROM or did a factory reset. It will still show as installed, although you wiped your device clean and it is not installed anymore.

Cannot publish updated APK: "Version 20 is not served to any device configuration"

I'm trying to publish a new version of my application in Google Play. When I upload new APK file (app version 22) I can't see the option to publish it in production. I can save it only as a draft. There's a red message (see the screenshot below) saying:
Version 20 is not served to any device configuration: all devices that
might receive version 20 would receive version 22
Situation doesn't get any better when I deactivate APK 20 (2.0).
What am I doing wrong? I can't figure it out.
The problem was very silly. I just didn't save my changes in the dashboard using the Publish now button. So in the end I just didn't deactivate the old version which prevented me from publishing the updated one.
Just publish your changes and you're good to go.

Android APK file: Re-activate older APK file in Google Play Store

I have uploaded two APK files into the Google Play store. One is a newer version and one is an older version. The newer version is the active one since it has a higher versionName and Code. Now I found some bugs in the newer version and I want to delete it from the Play Store and activate the older version. Google Play won't let me deactivate the newer one and activate the older one again, since it has a lower versionName and code.
The problem is that I'm am not the developer and did not build the app. The developer is in another country and it is difficult to get hold of them.
What can I do to reactivate the older version again? I know one solution would be to change the versionName and Code. I only have the apk file, can I change those details in Eclipse with only the apk file and very little experience in eclipse or developing android apps?
Thank You
You can't rebuild a new version of an apk from the apk itself.
Have the app developer do the following:
Rebuild project in its previous state with higher version number (must be higher than all previously submitted versions)
Resubmit
From Google's Android "Developer Console" page:
Note that rollbacks aren’t supported due to the app versioning
requirements of the Android platform. If you need to rollback,
consider launching a previous APK with a new version number. However,
this practice should be used only as a last resort, as users will lose
access to new features and your old app may not be forward-compatible
with your server changes or data formats, so be sure to run alpha and
beta tests of your updates.
A good strategy is, when creating a build, modify the manifest to build say a version 2.0 = 39 AND again 2.05 = 45 and generate these two apks which will obviously do the same thing.
Later, when build 2.01 = 40 is in production and you find an error, you can jump back to the old version by uploading the 2.05 = 45 you created earlier.
You have 5 opportunities to back track while releasing 40, 41, 42, 43 and 44 to go back to earlier functionality!
Do this for each build and you can always go back to an earlier version which has been pre compiled and built but with a higher version number than currently in production.
You will not be able to change the APK file without having the signing certificate.
You should be able to revert to an older version, assuming you didn't change the level of API support.
Presumably, go to the Dev console, select the APK tab, hit the "Advanced Mode" option, deactivate the current version and hit "Reactivate" for the version you want.

Categories

Resources