mapbox / mapbox/mapbox-maps-flutter
Mapbox Requests Location Before Use (Not Compliant With Chinese App Store Requirements)
@maios is already working on this.
Since Jul 15, 2026.
- Dominant language
- Dart
- Stars
- 380
- Forks
- 204
- PR merge metrics
- No merged PRs in 30d
Description
Before Mapbox is actually used in the app, Mapbox is already requesting the user’s location. This behavior does not comply with the requirements of the Chinese app marketplaces. Version 2.8.0 did not have this issue.
Below is the stack trace provided by the app marketplace:
```
com.mapbox.common.location.AndroidDeviceLocationProvider.doStart(AndroidDeviceLocationProvider.kt:152)
com.mapbox.common.location.BaseDeviceLocationProvider.start(BaseDeviceLocationProvider.kt:63)
com.mapbox.common.location.BaseDeviceLocationProvider.addLocationObserver(BaseDeviceLocationProvider.kt:2)
```
Is there a way to prevent Mapbox from accessing the user’s location before it is actually needed or before the user grants permission? This issue causes the app to be rejected during the review process in China.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.