When I download my app from google play the Google Map is no loaded. When I download the app with the .apk file directly (transfer it to my phone and downloading) it did load! I searched all over and it still doesn't work. This is what I did:
- In Android studio, Build->Generate Sign APK I created a new Keystore 'keystore' and a new Key 'app'
- run: keytool -list -v -keystore keystore.jks -alias app.
- In the output from step 2, under 'Certificate fingerprints:' I took the 'SHA1' value and my package name 'com.gilshelef.feedme' (from AndroidManifest.xml file) and generated a new API key in the Google api console. I restricted the key to 'android apps' and added my SHA1 and package name.
I placed the generated key (step 3) in my Manifest file:
<meta-data android:name="com.google.android.geo.API_KEY" android:value="@string/google_maps_key" />
In android studio, Build->generate sign APK I used the same keystore that I created in step 1 and the same key.
I uploaded the generated apk to Google play.
After I downloaded my app from google play the map is still blank!
NOTES:
- I also tried to changed the extension of the keystore from .jks to .keystore since android studio uses the .jks extension.
- I verified that the key from google api console and the one Im using in my AndroidManifest.xml file is the same.
- I verified the package name in google api console and Manifest file.
- I followed this: this tutorial 'Displaying the release certificate fingerprint'. The output looks the same except for the 'Signature algorithm name: SHA1withRSA'. the signature algorithm name in my release keystore is 'SHA256withRSA' maybe this is the problem?
What am I doing wrong??