Repository navigation
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
Playeradds a new "Open Player" / "Quit Player"ControlButtonevery time aPropertiesChangedsignal containsCanRaise/CanQuit. Firefox's MPRIS player sends these repeatedly, so the buttons pile up in_playerBox, and their tooltips pile up inMain.uiGroup. Also,props.CanRaiseis a GVariant, soif (props.CanRaise)is true even when the value isfalse.Impact
Found while investigating periodic desktop stutter on Linux Mint 22.3 / Cinnamon 6.6.9 / cjs 115.1. After 33 days of uptime the live JS heap (
imports.system.dumpMemoryInfo()→gcBytes) was 329 MB. Since cjs schedules a non-incremental "big hammer" GC on toggle-down, which on a live desktop fires every ~10 s, the compositor was blocked 200–234 ms every 10 s (a forcedimports.system.gc()took 215 ms). After restarting Cinnamon: 6 MB heap, 7 ms GC. A heap dump showed several leaks; the biggest one is #13956 (fix in #13958), this is another one.After 33 days the Firefox player's
_playerBoxhad 510 children (about 254 "Open Player" + 254 "Quit Player" buttons), andMain.uiGroupheld 509 matching tooltip actors.Fix
CanRaise/CanQuitfromPropertiesChanged.The create-once guard was verified on 6.6.9 with an equivalent runtime patch: repeated
_showCanRaise()/_showCanQuit()calls no longer add buttons. Theunpack()change is not exercised by that test.🤖 Generated with Claude Code