Skip to content

[Bug]: Android Simulator Token issue #4129

@MariuzM

Description

@MariuzM

Mapbox Implementation

Mapbox

Mapbox Version

default

React Native Version

0.81.5

React Native Architecture

New Architecture (Fabric/TurboModules)

Platform

Android

@rnmapbox/maps version

10.2.10

Standalone component to reproduce

When i load Android Simulator i get this error, but i don’t have this problem with iOS Simulator and Real Android Device

Only way for me to solve this was to add RNMapboxMapsDownloadToken in app.config.ts

Image
import React from 'react'
import { StyleSheet } from 'react-native'
import { Camera, LocationPuck, MapView, setAccessToken, StyleURL } from '@rnmapbox/maps'

setAccessToken(process.env.EXPO_PUBLIC_MAPBOX)

const Map = () => {
  return (
    <MapView
      attributionEnabled={false}
      compassEnabled={false}
      logoEnabled={false}
      pitchEnabled={false}
      rotateEnabled={false}
      scaleBarEnabled={false}
      style={CSS.map}
      styleURL={StyleURL.Street}
    >
      <Camera followUserLocation followZoomLevel={15} />
      <LocationPuck puckBearingEnabled />
    </MapView>
  )
}

export default Map

const CSS = StyleSheet.create({
  map: {
    flex: 1,
  },
})

Observed behavior and steps to reproduce

No response

Expected behavior

No response

Notes / preliminary analysis

No response

Additional links and references

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug 🪲Something isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions