I recently created an android app. When I tried to debug my app on my phone, it worked. Then I generated the apk, and tried to execute it from the file browser, it doesn't work, and I have the following error message : "App not installed", despite having allowed the unknown source in the settings. I also tried with an official app. For that, I extracted the Apk with apk extractor, uninstalled the app, and then executed the apk: same error. I tried many solutions found on the web, but none of them worked :
I disabled play protect.
I reseted the app preferences in the settings.
I tried on my former phone and on my father's phone.
I updated the os on my phone (android 10 to android 12).
I have already installed many apps just by executing the apk on my phones (including my current one) and it's the first time i'm facing this problem.
Can you help me please ?
Debug build and Release build have different signatures so before installing "release app" you should uninstall "debug app".
Also check expiration date of your release signature and make sure it is a valid signature.
Related
I generated APK by doing following in Android Studio: Build -> Generate Signed apk
I copied this APK in Phone's memory and launched it. It installed fine, but only for the first time. I then uninstalled the existing app and launched the same APK again, now it says "App Not Installed".
If I copy the same APK from my computer to this phone again, then again it cannot be installed anymore on this device.
I don't want to do with Play protect off on the device.
Is there a solution to installable the apk all the time?
Go to link And fill out the form. After about two weeks, if the app is OK, your problem will be resolved.
The web service protocol must be HTTPS.
Access permissions must be for a reason.
Etc
I want to run my application in phone but I get following message:
Installation failed with message:
INSTALL_FAILED_UPDATE_INCOMPATIBLE: Package signatures do not match
the previously installed version; ignoring!.
It is possible that this issue is resolved by uninstalling an existing version of the apk if it is present, and then re-installing.
WARNING: Uninstalling will remove the application data!
Do you want to uninstall the existing application?
In my phone I have installed previous version of app from google play. I know that uninstalling old version of app from my phone can fix the problem but I don't want to do this because then I might lose all app specific data.
What I tried:
generating signed version of app using the same keystore.jks like previously
changing versionCode and versionName in build.grandle file and then generating new version of app
And still I have the same problem. What should I do to update my app without losing data?
There are two possibilities I can think of
You use Google Play App Signing. If you use Google Play App Signing then the signature in apps coming from Google Play will always be different to the app coming from your IDE. The only way you can get the update to work is to update the app from Google Play. The best way to do this during development is to use an "Internal test track". Google launched these at Google I/O this year and they let you update your app in seconds from Google Play. So when you have an update, don't install from your IDE, upload to Google Play internal test track, republish, and then update from Google Play. It is really quick.
You don't use Google Play App Signing, but you are trying to install your debug build instead of your release/production build. Make sure you are building the production release APK, so it is signed with the same key as the one uploaded to Google Play.
If I'm understanding correctly you want to re install the "same" apk in your phone but with some changes in the code (updates) but Android Studio can't install the new apk.
I can only think in one thing, this is the explanation:
Please remember that android has different "Build Variants" there could be many but you will always have "debug" and "production" build variants, as I can read, you have installed the one in Play Store this means that you have a "production" build variant already installed in your phone, so you need a new "production" variant version of your app with the same build data (code and name version) and the updates in the code.
Build a signed apk with the same data as the previous version (code and name version) (Just like the one you used to upload to Play Store).
Find the signed apk.
Use adb to check your connected devices, expect a list
adb devices
Use adb to install this new apk.
adb -s <device_identifier> install <apk_name_include_apk>
Following those steps should let you install what you need.
Go in your React Native > Android >app
in the app folder,
you can see a build just delete this folder and Clear React Native project by npm cache clean cmd/Terminal Command.
Now try to run I hope it will Run for some of you.
It's working for me.
So I have an app on the Play Store that I released about a week ago. I've done a ton of work to to it since and I'm basically going to rebrand it a bit.
When I first released the app, I put it up on the app store with the name "First Name of App" (obviously not the correct name). I now have an update ready to publish with a lot of changes, and one change is that the app name is now "Second Name of App". It's all under the same package yet, I just changed the name using the Manifest.
I'm having an issue though with testing. Currently on my own phone, I have the version of the app that is currently on the Play Store installed.
I generated a signed APK using Android Studio (all with the same settings and key passwords and such). I then put that signed apk on my phone for testing, and when I try to install it I get the "App not installed" message.
Things I have tried:
Uninstalling the previous APK and then installing the newer version. If I uninstall the Play Store version first, and then install the newer signed APK version, it installs fine. The problem with this though is that I lose the data that I had in the Play Store version. I can't have that.
Changing the "versionCode" and "versionName" numbers in the build.gradle. I made sure both numbers are higher than what the Play Store version is, but I still get the same "App not installed" message.
Making sure the settings while generating the signed APK are the same. All of the settings are exactly the same. The signature version checkboxes are both checked yet also, as they were with all previous versions.
Anyone have any ideas what could be going on? I really would like to release this update but I'm afraid if I just upload this signed apk to the store that everyone would have the same issue, and that they'd be forced to uninstall the current version they have (resulting in data loss).
The problem seems that you are trying to install an APK with the same package name but different key and that creates a conflict. Android only considers an App to be the same if both package name and key signature are identical.
Keys are unique, even if you use the same settings and passwords each time you create a key a new unique key is created and it will be always different to the key you used in the Play Store release.
The only way to install the APK is to uninstall the Play Store version.
And that serves to emphasize how important it is to keep the key used in the Play Store, if you lose it you will not be able to upload new updates.
UPDATE
If your have "Google Play App Signing " activated for you app, the key used when an user installs the app from Play Store is different than the one you used to upload the release to the Play Console.
https://support.google.com/googleplay/android-developer/answer/7384423?hl=en
Have you by chance changed the minimum SDK version or anything like that? I've had a similar issue. I've an app on the PlayStore which I tried upgrading with an APK with the same signature as that of the PlayStore version but a different minimum SDK version. When I tried installing I get the 'app not installed' error. I then uploaded this APK on the PlayStore. On my device, the app on the PlayStore now shows two options 'Uninstall' and 'Open'. Due to your conflict, users will have to first uninstall the app and install it again. There will be no 'Update' option due to the conflict. Hope this helps :)
Similar Issue
Android Phone: Google Pixel3, Android 9
install youtube apk, but error:
Application Not Installed = App Not Installed
Final Solution
use adb's pm to install apk
even same error, but can show/known the fail reason
then can find specific solution to fix it
Examples
here later encounter many error cases:
blueline:/storage/emulated/0/Download # pm install /data/local/tmp/com.google.android.youtube_16.29.36.apk
pm install /data/local/tmp/com.google.android.youtube_16.29.36.apk
Failure [INSTALL_FAILED_VERSION_DOWNGRADE]
or:
blueline:/data/local/tmp # pm install youtube_16.29.36_addedDebuggable.apk
pm install youtube_16.29.36_addedDebuggable.apk
Failure [INSTALL_PARSE_FAILED_NO_CERTIFICATES: Failed to collect certificates from /data/app/vmdl445467286.tmp/base.apk: Attempt to get length of null array]
then google it and find specific solution to fix it, install apk successfully.
I updated my app and tested it on my device. Everything works fine if I test the app via the run button in eclipse but if I export it into an apk and try to install the apk it fails.
There is no error code or anything else, it just says the app has not been installed.
Any idea why this happens? I only changed a few things in my app: I removed the basegameutils lib from my app and migrated to the new api without basegameutils. Thats it (except for some bugfixes but that can not be the cause).
I did already restart eclipse and cleaned all projects mutiple times.
The target sdk is 22 and I am using newest system images and so on for that api level (my divce is a stock nexus 6 with 5.1.1 running). I also updated my build tools to 23.0.1 from 22.0.1 and removed the 22 version. Is this the cause?
I also tried to upload the apk in the dev console and there were no erros.
Thank you for your help.
EDIT:
The logcat output says the signature does not match the previously installed version.
If i try to install the current live version via the play store there is also an error message saying i can not install this app because another user already installed an incompatible version on this device (but i dont have it installed and i dont have multiple users on the device).
If i got to the app menu in the settings my app is shown at the bottom of the list but there is a note saying the app is not installed for the users. If i click on it all buttons are unclickable (so i can not uninstall it).
What is happening?
For me, selecting Signature Version v1 and v2 both solved the problem
Your signature changed, so as you mentioned you must uninstall the previous version. You tried to uninstall from the device UI and that fails - so try it from the command-line:
adb uninstall your_package_name
Seen on Nexus devices, occasionally only command-line uninstalls work.
I found a solution but I still have no idea what caused the problem.
somewhere on my device my app was still installed even though it didnt show up in the app drawer and the play store told me the same. In the settings/apps menu my app was still present (as i mentioned in the edit of my original post) so i clicked on it. If you click on the menu button you can chose unisntall for all users which did the trick. now I can install my apk again.
I have no idea how this happened but there you go, i hope this helps.
EDIT:
I had the same problem as this guy had. the accepted answer over there is much nicer than my poorly foramtted text ;)
"You cannot install this app because another user has already installed an incompatible version on this device"
I was facing same problem And I solved it this way, For Current Updated Android Studio 2.3
Build > Generate Signed apk.
Create Keystore path.
Put Password, alias, key password.
Build type select accordingly(eg to release in playstore use release).
Signature Version select both V1 and V2 checkboxes.
Finsih.
Go to the apk from explorer and use it for your playstore or in devices as Signed and Certified apk file.
For me the solution was to disable Play Protect on device.
You can not run signed apk directly in your android device .
I you want to run your apk then follow below steps :
1) Go to your device settings
2) In setting you find applications
3) In application checked unknown sources
This will allow you to run your signed apk without downloading from play store.
or
try this link :
"You cannot install this app because another user has already installed an incompatible version on this device"
The problem is because you have a version of your testing app. So, you're not really upgrading the app! Those are two different apps. You must first uninstall previous version (testing) so you can install the release (signed) version of your app.
I encountered this problem today and tried a few suggestions here, and this is how I solved the issue: I cleared my phone's caches / junk files and also uninstalled the test versions of the app and their APKs, and then reinstalled the new APK. Try this first before getting worried. 🙂
I got the save Error just incase someone faces this. For me it was because i have multiple projects for the same app on the phone. you need to delete older versions of the app from your phone.
If you have two options (V1 (jar signature) and V2 (Full APK Signature)) before generation signed apk. you should use V1 jar signature now, because there is no backward compatibility and all android phones with version < 7 won't accept this signature. Backward compatibility will be added in some next N Developer Preview.
There are also explanations on this developer.android in this link :
https://developer.android.com/about/versions/nougat/android-7.0#apk_signature_v2
In my case it was the proguardFiles path in build.gradle that caused this problem
Currently PlayStore performs regular checks for apps and device for harmful behavior. Installing signed APK manually is treated like unusually behavior so is preventend.
So turn off play protect feature temporary and your install will work as charm!
step one - open play store and select play protect
step two - click play protection setting button
step three - disable
step four - close and install your APK manually
I have been developing my app for a while and runing on a real device through Eclipse using Run As -> *Android Application*.
Now I am trying to distibute it to some beta users for the first time.
I used Eclipse to create a signed app, using a new keystore that I generated through the wizard. This appeared to work fine and when I check with Jarsign I get the message "Jar Verified", although there are a couple of warnings too. These are "This Jar contains entries whose certificate chain is not validated" and "Ths Jar contains signatures that do no include a timestamp".
I then copied the resulting apk onto the device and opened it. But got a message "This app was not installed". And in log cat I can see:
"Package has no certificates at entry ; Ignoring!"
I found some people had suggested going back to JDK 6 (I did have 7 previously), but that didn't help.
A few people suggested it might be due to duplicate activities in the manifest so I checked the manifest thoroughly.
What I have found is that if I rename the apk so that it is no longer exactly the same name as the last part of the package it suddenly works.
So if the package is com.mydomain.myapp and the apk is myapp.apk I get the error, but if it's myapp_debug.apk it installs just fine.
I find this very confusing and more than a little worrying. I would like to publish this app for real eventually and I'm not sure if I've done something wrong.
Based on your renaming makes it work description, you already have an app with the same package name installed on the device, but signed with a different certificate (probably the debug certificate used for eclipse-launch installs).
You must simply remove the existing installation before you install your release version. You can do that either from the settings menu, or with an ADB command of the form
adb uninstall your.package.name
Note that this removal will wipe out the private data stored by the app - that's part of why you have to do it, to prevent an imposter (naturally having a different certificate) from easily grabbing data left behind by a real app.
Remember also when distributing apps to others in this manner that they will need to allow unknown / non-market sources in their settings menu.