Home » Android » android – Keystore file Error:Execution failed for task ':app:validateSigningRelease'

android – Keystore file Error:Execution failed for task ':app:validateSigningRelease'

Posted by: admin May 14, 2020 Leave a comment

Questions:

I updated android studio and my keystore path must had changed in the process. I have tried the “Choose Existing ” button but cannot find what I am looking for. I do not know where to find it. Would anyone please give me some instruction where to look?

I looked everywhere, I read a other posts with similar problems but debugging and it didn’t help because I am attempting a new release. I have also searched for a software program to help me retrieve the path but I have been unsuccessful with that as well.

Below is the error message I get when I attempt to generate a signed apk. I did save the apk’s from older versions that I had generated, if that helps at all.

The error is as follows after android studio attempts compiling:

Information:Gradle tasks [:app:assembleRelease] 
Error:Execution failed for task ':app:validateSigningRelease'.
> Keystore file C:\Users\aform\OneDrive\Documents\xxxxxxx\xxxx  not found for signing config 'externalOverride'.
Information:BUILD FAILED

I am also working on a new PC, but I got the same error of my previous PC as well. Thanks for any help.

How to&Answers:

Check your keystore path and also example.jks file location all are correct. find the location where the keystore path was generated for the fisrt time. check at C:\Users\.android

Answer:

If you’re using React Native, Just copy the

C:\Users\UserName\.android\debug.keystore

and past it int

ProjectPath\android\app\

This will solve your problem

Answer:

You have misplace the path to the key store.jks file. Search for the file on your computer and use the path and everything will work Great!!

Answer:

I had the same problem!
you need to invalidate the studio cache and restart in. it works for this kind of issues.

Steps
1. Go tot file at the top left corner.
2. On file, click invalidate Caches / Restart
3. A pop up box appears. Click Invalidate and Restart.

enter image description here

After this go ahead to generate you Signed App for playstore

Answer:

cd android
cd app

keytool -genkey -v -keystore my-debug-key.keystore -alias my-key-alias -keyalg RSA -keysize 2048 -validity 10000


keytool -genkey -v -keystore my-release-key.keystore -alias my-key-alias -keyalg RSA -keysize 2048 -validity 10000

Using this your keystore file Error app:validateSigningRelease’ is Solved

Answer:

You need to generate key:

cd ./android/app
sudo keytool -genkey -v -keystore my-upload-key.keystore -alias my-key-alias -keyalg RSA -keysize 2048 -validity 10000

Answer:

I had to copy paste the file “my-upload-key.keystore” into my project’s android->app folder and this solved the problem for me.

Incase you dont have the “my-upload-key.keystore” file, you can create it by using the following 3 steps (for windows):
1) open you command prompt as administrator
2) make sure you re not in any folder and you see C:> as address
3) run command keytool -genkeypair -v -keystore my-upload-key.keystore -alias my-key-alias -keyalg RSA -keysize 2048 -validity 10000 and you will see the file in your C directory

For Linux you can run the same command in terminal, even in your project and move the file to andorid->app