TypeError: undefined is not an object (evaluating 'l.default.manifest.android.config.googleMaps')
See original GitHub issue🐛 Bug Report
TypeError: undefined is not an object (evaluating ‘l.default.manifest.android.config.googleMaps’) at Ul([native code]) at Pl([native code]) at callImmediates([native code]) at value([native code]) at value([native code])
Summary of Issue (just a few sentences)
React native maps not working on Android standalone app. App is crashing and not rendering any maps on screen.
Environment
System: OS: WINDOWS 10 node: 10.16.0 npm: 6.14.4 yarn: 1.22.4 npmPackages: “expo”: “~37.0.3”, “react”: “~16.9.0”, “react-dom”: “~16.9.0”, “react-native”: “https://github.com/expo/react-native/archive/sdk-37.0.1.tar.gz”, “react-native-maps”: “0.26.1”,
Platform: ANDROID SDK 27
app.json:
{
"expo": {
"name": "digidirectory",
"slug": "digi-directory",
"platforms": [
"ios",
"android"
],
"version": "1.0.0",
"orientation": "portrait",
"primaryColor": "#27d8a1",
"icon": "./assets/icon.png",
"splash": {
"image": "./assets/splash.png",
"resizeMode": "contain",
"backgroundColor": "#ffffff"
},
"updates": {
"fallbackToCacheTimeout": 0
},
"assetBundlePatterns": [
"**/*"
],
"facebookAppId": "584981585556234",
"androidStatusBar": {
"hidden": false,
"translucent": false,
"backgroundColor": "#23c290",
"barStyle": "light-content"
},
"ios": {
"bundleIdentifier": "com.digipakistan.digitaldirectory",
"buildNumber": "1.0.0",
"supportsTablet": true,
"infoPlist": {
"UIBackgroundModes": [
"location",
"fetch"
]
}
},
"android": {
"package": "com.digipakistan.digitaldirectory",
"versionCode": 1,
"backgroundColor": "#ffffff",
"icon": "./assets/icon.png",
"adaptiveIcon": {
"foregroundImage": "./assets/icon.png",
"backgroundColor": "#ffffff"
},
"permissions": [
"ACCESS_COARSE_LOCATION",
"ACCESS_FINE_LOCATION",
"CAMERA",
"WRITE_CONTACTS",
"WRITE_EXTERNAL_STORAGE"
],
"googleServicesFile": "./google-services.json",
"config": {
"googleSignIn": {
"apiKey": "AIzaSyCdI*********E594nPXik-ase_H9T0",
"certificateHash": "34a41f29d***********5ad33beea00873037ba2443"
},
"googleMaps": {
"apiKey": "AIzaSyBTpXf**********Qe8Siai77JIVXQMmUc"
}
}
},
"description": "Digital Directory app, Release: 1.0.0",
"hooks": {
"postPublish": [
{
"file": "sentry-expo/upload-sourcemaps",
"config": {
"organization": "tutors-house",
"project": "digi-directory",
"authToken": "73057c6f94**********2b8aaff78f2aac6b194987863f2df94256bd6b"
}
}
]
}
}
}
Reproducible Demo
Download the standalone app from here: https://we.tl/t-rF2Z7xwTw4
Steps to Reproduce
-
Open app and login, choose customer and login with email/password: Email: abcd@gmail.com Password: 12345678
-
After signing in to the app with email/password, Maps screen is expected to be shown but app crashes.
-
Sentry shows this error: TypeError: undefined is not an object (evaluating ‘l.default.manifest.android.config.googleMaps’) at Ul([native code]) at Pl([native code]) at callImmediates([native code]) at value([native code]) at value([native code])
Issue link: https://sentry.io/share/issue/b1cd2b27557d4d1d8f35a9ef1596188d/
Expected Behavior vs Actual Behavior
After signing in to the app with email/password, Maps screen is expected to be shown but app crashes.
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (2 by maintainers)
I am very confused and need help to figue out this issue. I’m stuck and find no solution to this problem. Please help.
the
ios.config
andandroid.config
keys are not included in your production manifest because they contain api keys that some might want to keep private, such as your google maps api key. we only use those during the build process. @tommybru will update the documentation to make this more clear. we may want to reconsider this in the future for clarity, or remove the config keys in development as well for consistency