openstreetmap-website icon indicating copy to clipboard operation
openstreetmap-website copied to clipboard

Switching layers and panning can cause vector tiles to be misaligned

Open elevenchars opened this issue 5 months ago • 5 comments

URL

https://www.openstreetmap.org/#map=17/36.104570/-114.903474&layers=SD

How to reproduce the issue?

  1. Select Shortbread or OMT layer
  2. Switch to raster layer
  3. Pan the map
  4. Switch back to vector layer

The viewport will be out sync with map data. It will resync once you pan the map around again.

Screenshot(s) or anything else?

https://github.com/user-attachments/assets/f7c33cf7-44af-465e-a1a2-9f28a8b0c122

elevenchars avatar Jul 23 '25 02:07 elevenchars

I've also managed to get the vector layers out of sync in a way where neither panning nor zooming causes the layers to resync. Sadly, I was unable to reproduce it.

hlfan avatar Jul 23 '25 04:07 hlfan

I can't quite nail it down but I've seen any issue that the VT layers are not immediately rendered after switching and need a tiny pan to be displayed, which is likely related.

simonpoole avatar Jul 23 '25 07:07 simonpoole

I had a similar issue with the MapTiler layer:

https://github.com/user-attachments/assets/c8ede95a-774f-4d2e-b2e4-0df43bb9b75c

willemarcel avatar Jul 23 '25 11:07 willemarcel

I can reproduce this also - came here to report it.

As a further part of the reproduce case:

  1. If you then pan the vector layer, it jumps at the start of the drag.

mvl22 avatar Jul 28 '25 00:07 mvl22

My use-case, when I stumbled upon this, and it was a bit consuming to get at the root of it, because the behaviour seems so erratic at first, form misaligned geometry down to half or fully empty viewport: I wanted to compare how the different layers present a mapping of mine.

hungerburg avatar Aug 17 '25 22:08 hungerburg