-
-
Notifications
You must be signed in to change notification settings - Fork 4.9k
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
Unable to resolve Gradle dependencies #2695
Comments
It works:
|
For me, works in android P:
` But crash when I add Polyline. |
I am facing the same issue. |
The issues are related to other packages you include in the project.
can't be done due to that different We can help, but I need a MCVE to checkout and see the problem. P.S. @rborn @christopherdro I think moving such questions to SO and keeping here only real bugs could definitely help supporting the project. |
ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-compat:25.2.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-annotations:25.2.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-core-utils:25.2.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-core-ui:25.2.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-fragment:25.2.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-annotations:28.0.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-compat:28.0.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-core-utils:28.0.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-fragment:28.0.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-core-ui:28.0.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-compat:25.2.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-core-utils:25.2.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-core-ui:25.2.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-fragment:25.2.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-annotations:26.1.0. ERROR: Unable to resolve dependency for ':react-native-maps@debug/compileClasspath': Could not resolve com.android.support:support-annotations:25.2.0. WARNING: API 'variant.getMergeAssets()' is obsolete and has been replaced with 'variant.getMergeAssetsProvider()'. |
Any above solution doesn't work at all. |
@alvelig if this can help I'm sharing my app build.gradle and global build.gradle along with the way I was able to solve the dependency resolving issue manually. build.gradle (app)
build.gradle (project)
In order to solve the issue I had to use this configuration, as suggested by @JosefBlattler
along with adding this line to the end of react-native-maps build.gradle in the dependencies declaration
Hope this can help! |
Hi @michaelsinatra thanks for providing this information. I added this line in my node_modules and it works again. So I create also small PR #2702 based on this. Maybe some of you can also verify that this PR works also for you?! Thanks |
App was crashing in Android 9. This fixed for me #2695 (comment) |
Hi guys, I am here to verify that the solution of @michaelsinatra save my life. I am using the react-native 0.59. What I need to do is simple add the magic line:
|
@truongluong1314520 this should be fixed in ##2720 can you test with master please? |
Hi @rborn , you mean I just need to |
Hi @rborn , I try this link |
@truongluong1314520 that's fine, it's a deprecation warning that has already a PR in works #2740 But it should work for now without any problem. Thank you for testing 🤗 |
This issue has been fixed for me also by adding this line into the react-native-maps 's build.gradle file important : what I didn't catch immediately is that this line should be added directly in the node_modules/react-native-maps/lib/android/build.gradle Thanks @michaelsinatra !
|
I hope you know that you are a lifesaver @michaelsinatra |
Você resolveu o meu problema! Obrigado |
I used the solution of @michaelsinatra and worked well for 32-bit devices. However, app keeps stopping when rendering MapView in 64-bit devices. I have tested it in a Google Pixel and in android emulator. |
@nfgutierrezp did you test with the last master from github? Thank you |
Sorry @rborn, it was my mistake. I tested with the master version and it worked perfect. Thanks! |
I am getting this error
When I change to @michaelsinatra solution, any thoughts? |
OK, a spend so much time for a solution, and find this:
should be something like this:
This work for me, I hope for you too |
@IgnacioGalliano King of town! |
there is no problem when I run on the debug mode however during the release mode it suddenly crash after compiling, when I check on the adb logcat it shows s is not a function. (In 's()', 's' is 3) |
add in lib/android/build.gradle for maps def supportLibVersion = safeExtGet('supportLibVersion', '28.0.0') |
Is this a bug report?
Yes
Have you read the Installation Instructions?
Yes
Environment
react-native: 0.57.4
react: 16.6.0-alpha.8af6728
react-native-maps: 0.23.0
Target Platform: Android 9 Emulator, Nexus 5 X
Steps to Reproduce
Expected Behavior
I expect the
react-native-maps
project to be included in the main projectand all its dependencies to get resolved by Gradle itself.
Actual Behavior
Reproducible Demo
My rootProject variable versions are
To reproduce the issue i have placed the above piece of code in my root build.gradle and have followed the installation guide for Android step by step.
The text was updated successfully, but these errors were encountered: