Android Google Maps V2 authentication error

后端 未结 5 1090
粉色の甜心
粉色の甜心 2020-12-04 01:09

I get this message in logCat when I attempt to load a supportMapFragment:

Failed to load map. Error contacting Google servers. This is probably an authentic         


        
5条回答
  •  悲哀的现实
    2020-12-04 02:05

    In cases, described by tony earlier, where everything else is configured correctly but you still get this error, instead of uninstalling and installing you can simply clear application data.

    I found steps that reliably reproduce this problem and solution (works for me):

    • Install release build, signed by your release cert with maps API key issued for you release cert. All works fine.
    • Replace by a debug build, but ``forget'' to change the maps API key from release to debug. Yes, this is wrong and not supposed to work, but this happens when switching builds. Easily solved you thought... Hah!
    • Fix the maps api key in the debug re-build by changing it to the maps API key issued for your debug cert. Re-install debug build with now correct debug maps api key. Expect the maps to work now, but they don't. The problem seems to be on the device itself.
    • Clear app data and same install shows tiles again!

    EDIT

    This problem may have been fixed in: https://code.google.com/p/gmaps-api-issues/issues/detail?id=6099 If so, it is still unclear to me in which version of the google-play-services API this fix is included.

提交回复
热议问题