I’m having issues using Google Maps on Android, it works fine on web and iOS but on Android i keep getting the same error which is:
The google maps plugin i’m using is the official one provided by Capacitor
W/DynamiteModule: Local module descriptor class for com.google.android.gms.googlecertificates not found.
I/DynamiteModule: Considering local module com.google.android.gms.googlecertificates:0 and remote module com.google.android.gms.googlecertificates:7
I/DynamiteModule: Selected remote version of com.google.android.gms.googlecertificates, version >= 7
W/ziparchive: Unable to open '/data/user_de/0/com.google.android.gms/app_chimera/m/00000014/GoogleCertificates.dm': No such file or directory
W/ziparchive: Unable to open '/data/user_de/0/com.google.android.gms/app_chimera/m/00000014/GoogleCertificates.dm': No such file or directory
I/SnapshotHandler: Unable to retrieve flag snapshot for com.google.android.libraries.consentverifier#com.x.x, using defaults.
W/MobStoreFlagStore: Unable to update local snapshot for com.google.android.libraries.consentverifier#com.x.x, may result in stale flags.
java.util.concurrent.ExecutionException: java.lang.SecurityException: GoogleCertificatesRslt: not allowed: pkg=com.x.x, sha256=[x], atk=false, ver=230514044.true (go/gsrlt)
at ajq.s(:com.google.android.gms.dynamite_mapsdynamite@230514044@23.05.14 (190400-0):3)
at ajq.get(:com.google.android.gms.dynamite_mapsdynamite@230514044@23.05.14 (190400-0):2)
at ala.g(:com.google.android.gms.dynamite_mapsdynamite@230514044@23.05.14 (190400-0):2)
at ys.d(:com.google.android.gms.dynamite_mapsdynamite@230514044@23.05.14 (190400-0):1)
at yu.run(:com.google.android.gms.dynamite_mapsdynamite@230514044@23.05.14 (190400-0):0)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:463)
at java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:307)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1137)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:637)
at java.lang.Thread.run(Thread.java:1012)
Caused by: java.lang.SecurityException: GoogleCertificatesRslt: not allowed: pkg=com.x.x, sha256=[x], atk=false, ver=230514044.true (go/gsrlt)
The map does not show at all, it even crashes my app when i attempt to open the map aswell sometimes, but i always get this error.
I have set up the API keys correctly, i think i have placed everything correctly in the manifest aswell.
This is how my Android Manifest looks like currently:
<?xml version="1.0" encoding="utf-8" ?>
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
package="com.x.x"
>
<!-- Permissions -->
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/AppTheme"
>
<meta-data
android:name="com.google.android.geo.API_KEY"
android:value="xxx"
/>
<activity
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|smallestScreenSize|screenLayout|uiMode"
android:name="com.x.x.MainActivity"
android:label="@string/title_activity_main"
android:theme="@style/AppTheme.NoActionBarLaunch"
android:launchMode="singleTask"
android:exported="true"
>
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<provider
android:name="androidx.core.content.FileProvider"
android:authorities="${applicationId}.fileprovider"
android:exported="false"
android:grantUriPermissions="true"
>
<meta-data
android:name="android.support.FILE_PROVIDER_PATHS"
android:resource="@xml/file_paths"
/>
</provider>
</application>
</manifest>
I’ve bee looking at different websites looking for solutions, like downgrading com.android.tools.build:gradle:
to a version that worked for them and so on.
But none of these suggestions have worked, i attempted to ask Google Support to see if they had anything to say but was asked to contact Ionic, and since i’m a free user i have to ask the community, so here we are.
Hope anyone has a solution for this!