Reputation: 101
I try to make my first application with the library RNMapbox/maps, everything is working fine on iOS but on android, I have this error:
Mapbox error [HTTP] Unable to parse resourceUrl mapbox://styles/magnasie/cl0ifyl63000z14o5o993xd2o {"level": "error", "message": "[HTTP] Unable to parse resourceUrl mapbox://styles/magnasie/cl0ifyl63000z14o5o993xd2o", "tag": "Mbgl-HttpRequest"}
I think it's because maplibre is by default and can't access to Mapbox style ? But I'm not sure. And when I want to set Mapbox v10 in build.gradle, I have this error:
Followed by this one on build:
Caused by: org.gradle.api.internal.artifacts.ivyservice.DefaultLenientConfiguration$ArtifactResolveException: Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
Caused by: org.gradle.internal.resolve.ModuleVersionNotFoundException: Could not find com.mapbox.maps:android:10.3.0.
When I search on google, it seems that I try to sync on offline mode, but no, my Gradle is set to online mode.
I try on emulator, but still the same issue.
Thank you a lot for your help.
Upvotes: 0
Views: 2739
Reputation: 5699
You either needs to set RNMapboxImpl to mapbox
in pod/gradlefile to use mapbox (v10) implementation.
If you want to use Mapbox styles with maplibre implementation you need to use Mapbox.setWellknownTileServer(Mapbox.TileServers.Mapbox)
Upvotes: 0
Reputation: 101
I correct this issue by doing the second part of this section: documentation
I was thinking it was only for Mapbox-gl but it seems that I need it for Mapbox, Maplibre and Mapbox-gl
Upvotes: 2