mapbox / mapbox-gl-js

Interactive, thoroughly customizable maps in the browser, powered by vector tiles and WebGL
https://docs.mapbox.com/mapbox-gl-js/
Other
11.2k stars 2.22k forks source link

Standard Style CONTEXT_LOST_WEBGL #13273

Closed shuabrannigan closed 1 month ago

shuabrannigan commented 2 months ago

mapbox-gl-js version: v3.5.2

browser: Chrome Version 128.0.6613.119 (Official Build) (arm64)

Steps to Trigger Behavior

  1. Load a map using the standard mapStyle mapbox://styles/mapbox/standard
  2. Add custom layers with filter applied
  3. Dynamically update the layer filter via map.setFilter(...)
  4. Interact with the map by zooming and panning

Link to Demonstration

jsbin

Expected Behavior

Actual Behavior

Additionally when i switch the style to mapbox://styles/mapbox/streets-v12 i do not run into this issue.

Screenshot 2024-09-06 at 12 10 15 pm

stepankuzmin commented 1 month ago

Hi @shuabrannigan,

What OS are you using? I wasn't able to reproduce it on Google Chrome 128.0.6613.138 on macOS 14.6.1.

shuabrannigan commented 1 month ago

Hey @stepankuzmin

So i am running macOS 13.0.1 , i tried my jsbin again, and it happened as i described, however it did take longer to fail than previously here is a screen grab of the console on failure, hopefully helpful.

Screenshot 2024-09-17 at 1 06 45 pm

stepankuzmin commented 1 month ago

Thanks for more details, @shuabrannigan. Could you please also try reproducing it with the latest v3.7.0-beta.1?

shuabrannigan commented 1 month ago

@stepankuzmin okay here is an update, i did not lose context using that beta in my jsbin from the brief test I did. here is the updated code jsbin

i did get the following messages in the console

Screenshot 2024-09-18 at 8 01 49 am

but nothing killed the map, so issue seems resolved?

stepankuzmin commented 1 month ago

Yeah, it appears that the root cause was fixed. The messages in the console are unrelated to the GL JS itself, so I'm considering this issue was fixed. Thanks!