Skip to content

Fix retained challenge completion panels - #11

Merged
veillette merged 1 commit into
mainfrom
wip/vegas-levelcompleted-workaround
Nov 24, 2026
Merged

veillette merged 1 commit into
mainfrom
wip/vegas-levelcompleted-workaround

Conversation

@veillette

Copy link
Copy Markdown
Contributor

Reuse a single completion panel across challenge rounds and cover its listener cleanup with a regression test.

vegas LevelCompletedNode (SceneryStack 3.0.0) never disposes its "Level N"
DerivedProperty, which stays linked to VegasStrings.label.level; the shared
closure context then keeps the whole disposed panel alive. The Challenge view
built one per completed round, so the headless soak's retained heap climbed
~0.6 MiB a round (heap-snapshot retainers: StarNode <- ScoreDisplayStars <-
vBoxChildren <- derivation closure <- LocalizedStringProperty level).

Replace it with a sim-owned RoundCompletedPanel built once and shown or hidden,
with the same look and vegas strings, its text derived from the model's level
and score. Add a disposal-leak case for the panel and a regression test that
toggling roundCompleteProperty adds no listeners to the vegas strings.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RTDmW5KsKz1edFyaGexxua
@github-actions

Copy link
Copy Markdown
Contributor

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

@veillette
veillette merged commit eaefbe1 into main Nov 24, 2026
9 checks passed
@veillette
veillette deleted the wip/vegas-levelcompleted-workaround branch November 26, 2026 00:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant