I am developing application with Google Map.
I've tested on the emulator and saw error line In the log:
01-23 16:04:28.453: ERROR/MapActivity(733): Couldn't get connection factory client
But it worked fine on the emulator.
Then I've signed the application and created its .apk file. I've put it on the web server downloaded and installed it on the real device (it is HTC with Verizon).
But my application didn't appear google maps on the device. I've checked API key and other configuration. Everything was ok. But google maps didn't work.
Have you faced to problem same as mine ?
Please suggest.
Thanks in advance.
Sounds like the maps API key you are using is not associated with the certificate you are signing the application with.
You will typically need to register for two maps API keys - one associated with the debug certificate that automatically signs each build that you deploy to the emulator during development, and another associated with your production certificate that you sign your APK with prior to publishing on the market.
http://code.google.com/android/add-ons/google-apis/mapkey.html
Related
Okay, so here is my problem:
I made a little app for myself that uses the Maps API from Google. I followed the instructions on how to put the API key in the app and all that. I make my app, run it on my phone (via USB debugging if that's important) and it works just fine. Now, out of fun, I put the app on Google Play Store (for some of my friends and family to use it idk), and all of a sudden, the app doesn't work. What happened was, the map wouldn't load (as if i haven't put in the API key). Then I uninstalled the app, tried running it with USB debugging again, and the same thing happened. So I put in the new API key, and it works just fine. Uploaded the version 2 in the Play Store, same problem and the same situation. How do I fix this?
I will provide any additional information that you need.
Check if you've entered your API key within the google_maps_api.xml file in the release directory (/app/src/release/res/values) just like in your debug directory (/app/src/main/debug/values).
Then, if you have API key restrictions make sure that you are using right certificates for the debug and release builds. You can get your debug and release certificates by following the steps given on Google Maps SDK for Android documentation
I hope this helps! Goodluck on your project
I have implemented a SafetyNet attest check when launching the app. It works fine when I run the release version from Android studio and detects (for eg.) the emulator from the device correctly. However when I download the same version from the Play store, it fires the failure listener every time, on a lot of legit devices.
It is a restricted API and works fine when run locally on those same devices.
If you check the image, the 33.75% error rate is when I have used this from the play store.
Any idea what could be happening different with the same code when running in app downloaded from the Play store?
Found my issue!
For anyone using 'App signing by Google Play', make sure you add the SHA-1 provided by Google Play to the API restrictions in the API Console.
You should find this in 'App Signing' in the app on the Play Developer Console.
I have seen several threads around this issue but I am still struggling.
My app is failing to sign in on Android with:
Unexpected response code 403 for https://www.googleapis.com/games/v1/players/me?language=en_US
I had this all working about 4 months ago but my hard drive failed and I am trying to get things working again on a newer version of Unity. I am only having this problem with NEW builds. My old apk still works fine so everything must be fine in the Google Play Developer Console. Something is not setup right in Unity.
I have tried with and without setting the "OAuth2 Client ID" from the Developer Console in the Android settings.
I have tried setting the keystore to .android/debug.keystore using the androiddebugkey with "android" as the password for both.
What else could it be?
So to sum up my comments up in an answer, that might be useful to somebody else.
1.) An app authenticates itself towards the Google Play Services with the combination of Keystore and Package name.
You can't sign in without or with another keystore. So you should always backup the keystore file together with your project in a version control system, that is safe from a single hard drive failure.
2.) If you lose keystore file, you can not update your app anymore.
But you could create a new app and link it to the same Google Play Game.
so I'm currently developing my first app. I'm just creating a simple map app with different markers on it.
So it's all working perfectly well in the emulator. But when I run the published .apk on my phone, the map doesn't show. It has the GUI but there aren't any continents.
Does this have something to do with the API I got?
Note: I'm running the app on my Samsung Galaxy S6.
You need a new API key (generated with a release certificate) for the signed apk. Simply follow instructions on this page: https://developers.google.com/maps/documentation/android-api/signup?hl=en#release-cert
You'll find information you need under Display your app's certificate information title, RELEASE CERTIFICATE section.
I've created an app on Google Play Developer Console and generated a Client ID using the debug.keystore. On the same machine I can build to device and emulator and login without problems. However if I do the same from another computer I can't login becuase it doesn't have the same key.
I guess I can solve this by copying the debug.keystore from one computer to another but is there a better way to do this while testing the app?