mapbox / mapbox/mapbox-gl-draw

[Bug] Map desync when panning/zooming

Open
#1,447 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

auto-triaged bug
Dominant language
JavaScript
Stars
1.1k
Forks
612
Avg merge
8d 9h
Merged PRs (30d)
5

Description

# Issue: Mapbox 3D Globe Desyncs with Map Layer

I cannot seem to attach a label to this issue despite seeing some issues having them, so I'll assume they have been disabled on this repository.

## Description

I've frequently noticed that Mapbox's 3D globe becomes desynced with the map layer on the globe. Specifically, the globe/world becomes transparent in areas where the terrain layer is shifted off its position.

In the video provided below, you can see the globe is orange. This was done by setting an orange background _behind_ the map to better highlight the issue. However, I’ve also been able to replicate this issue on Mapbox's own demo website, across nearly every map I’ve tried.

I managed to replicate this on Mapbox's demo site yesterday but in an attempt to record it and capture the address bar as proof of it being on Mapbox's own domain, I accidentally resized my browser window which of course triggered a re-render and resolved it. I'll update this thread if I can reproduce it again on Mapbox's own examples.

---

## Steps to Reproduce
1. Open a map and zoom into a relatively close view of an area.
2. Keep the tab active (ideally in a separate window that is not minimized; note: on Chrome, inactive tabs may sometimes reload when reopened if left idle for a long time, resetting the bug).
3. Leave the map idle. Unfortunately, there’s no exact time frame I have on this, but I’ve observed this issue occurring after leaving it idle anywhere between **1 to 2 hours**.
4. Return to the map window and zoom out. You’ll notice the map layer is misaligned, and the issue becomes apparent—parts of the terrain appear shifted off their position, and the globe becomes transparent behind it.

---

## Video Evidence

https://github.com/user-attachments/assets/a8b221e4-47b6-42d2-8fe8-65b4befb5192

## Additional Information

Mapbox Version: Most Recent
Chrome Version: Version 139.0.7258.155 (Official Build) (arm64)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No source file, test, or entry point is identified. Start by reproducing the issue using the listed idle, zoom, and resize conditions, then trace the map and terrain rendering involved in mapbox-gl-draw; done means the globe and terrain remain aligned after the delayed interaction.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend, web-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.