When the app in the development stage, I get the apk from the "bin" file and install it in a real android phone to test the app, and it works great. However when I export the apk from the eclipse, the apk can successful export but the apk cannot install in the phone, and shows
An existing package by the same name with a conflicting signature is already installed
Some people said you need to uninstall the app and install it again, but this app I want to put it on the Play Store, so it is impossible to ask users to do this.
Also, I want to use the ProGuard function, so I need to export the apk to enable this function.
Your development APK is signed with a development key. Your production APK is signed with a production key.
When you try to install a production APK over a development APK, it detects that the keys were different and refuses to "upgrade" the APK.
For production in the Google Play store you won't have this problem. All your users are already using the production version of the app. The new APK you provide is also a production version and so since the keys match, the upgrade will work without the users needing to uninstall the app.
Uninstall the app on your phone then re-install it
Related
While testing my app one of the action I did is to clean install from PlayStore and then install update from my computer. When I did so I received the error INSTALL_FAILED_VERSION_DOWNGRADE, there are a-lot of information in google about this error I understood that I need to increase the versionCode in build grade file, and I did so.
But then I started to receive the following error: INSTALL_FAILED_UPDATE_INCOMPATIBLE: Package ###### signatures do not match previously installed version; ignoring!.
All suggestion that I can find is about uninstall the app from device and then clean install, and it does work. My question is why it happened? I am really concern about the customers who already have this app installed, they wan't be able to to update as well?
Thanks for your answers
This means, that the two APKs are signed with different signing keys.
If you try to install a debug version, the APK is signed with a debug key. So it is normal that the installation will fail.
In order to test the update of your app, either create a release version of your app (e.g. by selecting "release" from the "Build variants" tab. Or add the signing release configurations to your debug build variant in the app module's build.gradle file.
When you upload your app to the Play Store you sign the app with a key. Now when you develop your app further and try to deploy it on your phone the app is either not signed or signed with a development key because it's only a development version of the app.
Therefore I assume you get this signature error because the app's signature just won't match. Once you upload a new version of your app to the Play Store you'll sign the app again with your key which results in the same signature and the Play Store will recognize your app as the same with a newer version.
I'm trying to install new apk for application that I uploaded on play store .. but I got this message (the Package conflicits with an existing package by the same name )
and not able to install application berfor uninstall the past app..
what should I do ?
I won't to force Uninstall on users ..
This is what I'm guessing:
When you upload an apk to Google Play you have to sign it with a proper keystore, resulting in a package-certificate pair. That apk goes with a particular version & version code number, let's suppose 1.0 / 1
If you upload then a version 1.1 to Google Play, you also have to increment the version code. Doing this, downloading the new apk is just an updating, and there is no problem at all. For the system, the app is the same because the certificate and the package are the same.
That is the normal behavior your users will experience.
Now, I'm guessing you are launching your debug apk in your device while developing, which by default uses the machine debug certificate. If you have that debug apk installed when trying to download the deployed version from Google Play, the system needs you to uninstall the previous one, as they are not the same app (different certificate) and the conflict exists.
That's only a guessing, but give it a try.
Regards.
I've an app in Play Store.
Now, I need to update that with an updated version. Before, pushing it to Playstore, I thought I'll check the migration with APK.
I installed existing version from Playstore. Now, I'm trying to install the latest (signed) apk. But it says, App cannot be installed.
This exact case is working with Playstore. I tried with Beta distribution. It worked correctly.
Am I missing something..?
Thanks in advance
This is almost certainly because of signature keys. Android only allows an upgrade (instead of uninstall/reinstall) if the upgrade is signed with exactly the same signature as the original install.
If you sign the app yourself, then make sure the signature key matches the Play store version before trying the install - if you use your debug/development signing key signed APK it won't work.
If your App is enrolled in Google Play signing then this won't be possible. The best option for testing in this case is to use the Alpha track. Set yourself as the only Alpha user, and release the APK you want to test on the Alpha channel. Google will sign it for you, and deliver the update. You can then use this to test your DB update.
The other option you can do is install the old version of the app yourself (not from Google Play, signed with your debug key), then try the update, again, signed with your debug key. But whatever you do, updates only work if the APK update is signed with the same key as the original installed APK.
First of all uninstall the current app from device and follow the below steps :
Go to Settings
Go to Apps
Now scroll down to your app and tap on your app.
On the upper left corner tap on Overloaded menu (3 vertical dots).
Tap on Uninstall for all users.
Now install the new app.
The easiest way to do this is to use the following ADB command:
adb shell pm uninstall <package name>
I have tried it and it works. After executing this command, try installing from playstore, you will be able to install
I have faced the same problem. Easiest way to test version migration, is uninstall the play store version, install old apk, (login, update datas etc), and then finally install the newest apk.
So be sure that you keep old versions of your application somewhere.
I upgraded my Android studio to 1.4. Now when I'm deploying my app to my device I get the message that the device has an application with the same package but a different signature. How is this possible? I already did some research and I looked up my debug.keystore, but this hasn't changed since 13/03/2015. Anyone has any idea how I can fix this?
The problem is the keys that have been used to sign the APKs, by default if you are running directly from your IDE and opening your Emulator, the APK installed in the Emulator is signed with your debug-key(usually installed in ~/.android/debug.keystore), so if the previous APK was signed with a different key other than the one you are currently using you will always get the signatures conflict, in order to fix it, make sure you are using the very same key to sign both APKs, even if the previous APK was signed with a debug-key from another SDK, the keys will definitely be different.
Also if you don't know exactly what key was used before to sign the apk and yet you want to install the new version of your app, you can just uninstall the previous application and reinstall the new one.
for more info go through This
Hope this Helps...
Debug builds are signed with the SDK keystore which is generated when you install the Android SDK. On Linux / OSX it is located at ~/.android/debug.keystore.
The message you had means that you have a debug build installed and you want to install an App Store build on it (or the other way around).
This can also happen when you deploy from a different machine.
I am working on the In-App tutorial and I am getting an error saying the version is not configured for billing through Google store.
There may be some confusion as to the version being used on my device.
This is my normal process
I have a signed key that has been setup and does work properly
I use Eclipse and I build my app there I build it constantly buy clicking the build icon and if my device is connected it opens on the device I do not sign anything that I know of (which leads to some confusion)
When I want to release the App I export it with the signed key and I have to export signed Application Package in the Android Tools I see when I right click on the App. An .apk file is generated and I upload that to google and everything works.
My question is when I simply run the App on my phone and it comes directly from eclipse what mode is it in
The In-App tutorial says I must be running the signed version on my phone.
Am I doing this automatically when I start it from Eclipse or is it in debug mode.
If it is debug mode how do I make it go into signed mode from Eclipse.
The version I need to upload to google is signed but is set as UNPUBLISHED as stated by the guide in the tutorial so I can not get it from the store.
To test anything that has to interact with the Google store, you need to use the release version of the .apk file. Export it as usual from Eclipse, then use the command line tool to install the release .apk on the device or emulator:
>adb install myApp.apk
If you previously ran on the same device or emulator from within Eclipse, the app will have been signed with the debug cert and you will have to completely uninstall it first. Even the -r switch on the apk install command won't install if the signing certs are different.