React-native-mapbox-gl: [Android] Getting errors for setter classes

Created on 14 Dec 2017  路  5Comments  路  Source: nitaliano/react-native-mapbox-gl

After following the instructions for installing on Android, I launch the app and simply get a black screen with the Mapbox icon and "i" info icon. I ran logcat and found that I am getting several errors regarding setter classes for many of the Mapbox libraries. Here is the log:

12-14 12:49:21.007 3228 3347 W art : Before Android 4.1, method com.mapbox.mapboxsdk.maps.MapboxMap com.mapbox.rctmgl.components.mapview.RCTMGLMapView.getMapboxMap() would have incorrectly overridden the package-private method in com.mapbox.mapboxsdk.maps.MapView 12-14 12:49:21.107 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.mapview.RCTMGLMapViewManager 12-14 12:49:21.110 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.styles.light.RCTMGLLightManager 12-14 12:49:21.111 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.annotation.RCTMGLPointAnnotationManager 12-14 12:49:21.112 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.annotation.RCTMGLCalloutManager 12-14 12:49:21.113 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.styles.sources.RCTMGLVectorSourceManager 12-14 12:49:21.114 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.styles.sources.RCTMGLShapeSourceManager 12-14 12:49:21.116 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.styles.sources.RCTMGLRasterSourceManager 12-14 12:49:21.117 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.styles.sources.RCTMGLImageSourceManager 12-14 12:49:21.118 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.styles.layers.RCTMGLFillLayerManager 12-14 12:49:21.120 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.styles.layers.RCTMGLFillExtrusionLayerManager 12-14 12:49:21.122 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.styles.layers.RCTMGLLineLayerManager 12-14 12:49:21.123 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.styles.layers.RCTMGLCircleLayerManager 12-14 12:49:21.125 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.styles.layers.RCTMGLSymbolLayerManager 12-14 12:49:21.127 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.styles.layers.RCTMGLRasterLayerManager 12-14 12:49:21.128 3228 3347 W unknown:ViewManagerPropertyUpdater: Could not find generated setter for class com.mapbox.rctmgl.components.styles.layers.RCTMGLBackgroundLayerManager 12-14 12:49:21.817 3228 3228 I art : Thread[1,tid=3228,Native,Thread*=0xf0f05400,peer=0x758266d0,"main"] recursive attempt to load library "/data/app/com.mysprotorn-1/lib/arm/libmapbox-gl.so" 12-14 12:49:21.824 3228 3228 I art : Thread[1,tid=3228,Native,Thread*=0xf0f05400,peer=0x758266d0,"main"] recursive attempt to load library "/data/app/com.mysprotorn-1/lib/arm/libmapbox-gl.so" 12-14 12:49:21.824 3228 3228 I art : Thread[1,tid=3228,Native,Thread*=0xf0f05400,peer=0x758266d0,"main"] recursive attempt to load library "/data/app/com.mysprotorn-1/lib/arm/libmapbox-gl.so"

I went back over the install steps and I am fairly confident that I have followed all of the steps as intended.

Most helpful comment

what was your problem? i am facing the same issue, blank screen on android with just the mapview and no errors throw just the same logcats warnings.

All 5 comments

Those are warnings are they causing any issues for you? I've seen those before too and haven't noticed any problems check https://github.com/facebook/react-native/issues/6692 not sure what is causing it though

Well, I thought they were causing my issue, but maybe not. I am just getting a blank, black screen when I launch my app. I only have a mapview being drawn on the screen. It works as expected on iOS, but not on Android. So that's why I am so confused by this.

Okay I figured it out. I was confused by the fact that I was getting no errors for loading the tiles, but I figured out that was my problem. Sorry about that everyone.

what was your problem? i am facing the same issue, blank screen on android with just the mapview and no errors throw just the same logcats warnings.

@orlax late, I know, however most likely you didn't set the MapViews style to fill out the container it is inhabiting?

try something like this:

<View style={{ height: 300, width: 300, backgroundColor: "red" }}>
  <MapboxGL.MapView style={{ flex: 1 }} />
</View>

You will see a red square till mapbox has finished loading, after which you will see a world map

Hope this helps others stumbling here

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Craytor picture Craytor  路  3Comments

EwanValentine picture EwanValentine  路  3Comments

lernerbot picture lernerbot  路  3Comments

lucasbento picture lucasbento  路  3Comments

madroneropaulo picture madroneropaulo  路  4Comments