Hi everyone,
when running expo export --public-url ...
to create bundles for self-hosting, the android.config
property including googleMaps.apiKey get stripped out and is not part of the hosted json.
Now when we run expo build:android --public-url .../android-index.json
the standalone app crashes when displaying the map.
I’ve also seen that the apk is missing the gmaps api key in the AndroidManifest.xml.
After the crash we see the following in logcat:
"exp":{"lastErrors":[{"isFatal":true,"errorMessage":"API key not found. Check that <meta-data android:name=\"com.google.android.geo.API_KEY\" android:value=\"your API key\"/> is in the <application> element of AndroidManifest.xml","exceptionId":-1002205489}
Our local app.json still has the android.config.googleMaps.apiKey
but it seems to not be evaluated.
The same happens for iOS builds/Info.plist.
I strictly followed the docs https://docs.expo.io/versions/v36.0.0/sdk/map-view/ and tried all suggestions in this post: Blank MapView on Android for Standalone After Publishing
Can anyone point me in a direction? What did I miss? Thanks in advance!
Expo CLI 3.11.3 environment info:
System:
OS: macOS 10.15.2
Shell: 5.7.1 - /bin/zsh
Binaries:
Node: 10.17.0 - /usr/local/bin/node
npm: 6.13.4 - /usr/local/bin/npm
Watchman: 4.9.0 - /usr/local/bin/watchman
IDEs:
Android Studio: 3.5 AI-191.8026.42.35.6010548
Xcode: 11.3/11C29 - /usr/bin/xcodebuild
npmPackages:
@types/react: ~16.9.0 => 16.9.17
@types/react-native: ~0.60.23 => 0.60.27
expo: ~36.0.0 => 36.0.2
react: ~16.9.0 => 16.9.0
react-native: https://github.com/expo/react-native/archive/sdk-36.0.0.tar.gz => 0.61.4
npmGlobalPackages:
expo-cli: 3.11.3