-
-
Notifications
You must be signed in to change notification settings - Fork 691
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Memory leak on map.remove() #4811
Labels
bug
Something isn't working
good first issue
Good for newcomers
PR is more than welcomed
Extra attention is needed
Comments
Thanks for taking the time to report this issue! |
HarelM
added
bug
Something isn't working
good first issue
Good for newcomers
PR is more than welcomed
Extra attention is needed
labels
Oct 8, 2024
There's also this report, which has a root cause investigated already: |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
bug
Something isn't working
good first issue
Good for newcomers
PR is more than welcomed
Extra attention is needed
hello,
I have a website where several pages contain a maplibre map. It's a SPA so maplibre-gl.js is not unloaded/reloaded for each map. Maps are created and destroyed over the navigation.
I have issues with memory consumption which increase each time i create and then destroy a map.
My work is based on maplibre 4.1 but i have also tested with maplibre 4.7.1 and the issue is the same (may be a little better with 4.7.1)
maplibre-gl-js version: 4.7.1
browser: Chrome 128 / linux
Steps to Trigger Behavior
Link to Demonstration
I have wrote a sample code to reproduce my problem :
https://output.jsbin.com/vumugiroma
Each time you press 'space' key you create or destroy a map.
The total used memory increase at each time (Check with Chrome task manager or memory in Devtools)
Expected Behavior
Don't increase memory consumption after several creation and destruction of maps.
Actual Behavior
Some objects are not released
The text was updated successfully, but these errors were encountered: