-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot evaluate module react-native-maps : Configuration with name 'default' not found #288
Comments
I have the same Error |
It seems that the problem is caused by nested settings.gradle, that are not supported (http://stackoverflow.com/questions/12154031/multiple-settings-gradle-files-for-multiple-projects-building) include ':react-native-maps:lib'
project(':react-native-maps').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-maps/android/lib') |
@trinhvanhuy @symmetriccurve did the solution worked for you? |
I have the same issue. @eliantor It did not work, now I get:
|
Looks like installation introduction has changed recently.
|
Did the same and receiving the same error as @bcalik now. |
Alright, I think we managed to get it running. We removed this from new MapsPackage(this) in the MainActivity.java file and it doesn't fail anymore. |
Replacing |
We had to change |
@morrigan actually it's working well, without an issue. |
It's working now, thanks all |
hey guys still facing an issue this is what i did include ':react-native-maps:lib' and my MainActivity.java is also updated as 'new MapsPackage()' still getting error FAILURE: Build failed with an exception.
|
i have the same issue , it work nice on IOS .. but fail on android |
I am experiencing this as well. I've made the suggested changes with no success. I am unable to react-native-maps with android. I was originally using a project initialized with "infinitered-ignite", also tried initializing a blank react-native project and adding the package. Followed the installation steps for "react-native-maps" but still unable to use this package with Android? Anyone else still running into problems with this? |
Okay, I got this working with the following configuration: |
hey guys you can follow this link for any problem related to the error "cannot evaluate module react-native-maps" http://stackoverflow.com/questions/38095524/cannot-evaluate-module-react-native-maps-configuration-with-name-default-n hope you will get the answer there thanks. |
Execution failed for task ':app:dexDebug'.
I am getting this error after installing react-native-maps and running rnpm link command, i have even removed android/build and android/app/build and rebuild it |
@hnagarkoti rnpm link produces a bug in build.gradle file which you have to remove follow the link http://stackoverflow.com/questions/38095524/cannot-evaluate-module-react-native-maps-configuration-with-name-default-n |
Are you talking about addition of this line and remove the auto maticlly genrater react-native maps compile 'com.airbnb.android:react-native-maps:0.7.1' In react 0.29.0 itse creating two files MainActivity.java and MainApplication.java These things are not working |
Still facing this problem in react-native 0.29.2. |
@andfs, this is work for me (0.29 and 0.30).
also manually patch your Application class like
I think it will really help you But now we can't use the |
Non-Java folks, you may also have to add an import statement for the MapsPackage:
Put that with the other import statements at the top of your MainApplication.java. |
On an existing project, I found that the project(':react-native-maps').projectDir = new File(rootProject.projectDir,
- '../node_modules/react-native-maps/android/lib')
+ '../node_modules/react-native-maps/android') |
@yozi-developer is there a permanent workaround so that I could run |
is there any fix on this? RN(0.44) |
In your android/settings.gradle replace the react-native-maps (2 lines) with this: include ':react-native-maps' The error for 0.44 is that there is no node_modules/react-native-maps/android', so change it by adding lib like so: node_modules/react-native-maps/lib/android |
@nickkapoor , I replaced lines in android/settings.gradle, but the same error . I solved it when downgrade react-native-maps to 0.13.0: But in this case android/settings.gradle lines are: App was built, but MapView now is just white rectangle ( |
include ':react-native-maps:lib' so this is almost correct but this is what you need to change it to: include ':react-native-maps:lib' so for some reason in the node_modules/react-native-maps it should be followed by /android but if you look in the directory you will see that it's just /lib and Android and iOS is inside of it.. it's backwards sooo if you just change the order of the the directory or the folder whichever to match what you have in settings.gradle it's also stated here in the instructions... https://github.com/airbnb/react-native-maps/blob/master/docs/installation.md you will be good! Cheers! |
i get this error A problem occurred configuring project ':app'.
|
I was having this problem too: The instructions here:
are actually wrong, they are missing the ':lib' element for the settings.gradle file
after adding the bold element above, it compiled successfully for me. |
after getting the error I re-installed "npm install react-native-maps --save-exact" fixed |
Hello everyone
I have some issue when i run project in Android
`JS server already running.
Building and installing the app on the device (cd android && ./gradlew installDebug...
FAILURE: Build failed with an exception.
What went wrong:
A problem occurred configuring project ':app'.
Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 5.906 secs
Could not install the app on the device, read the error above for details.
Make sure you have an Android emulator running or a device connected and have
set up your Android development environment:
https://facebook.github.io/react-native/docs/android-setup.html`
I use React-native 0.26.2
Thanks in advance
The text was updated successfully, but these errors were encountered: