Repository navigation
Conversation
|
Thanks for your first pull request! Before it is merged:
|
4 of 14 tasks
houko
force-pushed
the
fix/discard-hosted-overlay
branch
2 times, most recently
from
November 20, 2026 15:45
dbf44ec to
99337fb
Compare
discard left a hoisted node in its host's hosted list: readers skip deleted entries, but the list kept the node, and through its parent and children the whole subtree it was in, for the life of the window. This holds for every hoisted node, an Overlay, a Modal or a Fixed view, and a Tooltip's bubble is a hoisted overlay even while hidden, so every rebuild of a view with a tooltip kept that view, its text layouts and its bindings. discard now takes the node out of its host's list, as syncPosition and rehost do when a node leaves a host. Fixes #NNN
houko
force-pushed
the
fix/discard-hosted-overlay
branch
from
November 20, 2026 16:28
99337fb to
d40ce90
Compare
The previous commit's CHANGELOG line and Fixes footer held #NNN until the issue was filed. Fixes nsgo-dev#1006
houko
force-pushed
the
fix/discard-hosted-overlay
branch
from
November 20, 2026 16:28
d40ce90 to
261f6db
Compare
This branch has not been deployed
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.
Summary
Fixes #1006.
Tree.discardleft a hoisted node in its host'shostedlist. Readers skip deleted entries, but the list kept the node, and through itsparentandchildrenthe whole subtree it was in, for the life of the window. This held for every hoisted node (anOverlay, aModal, aPosition: Fixedview), and aTooltip's bubble is a hoisted overlay even while hidden, so every rebuild of a view with a tooltip kept that view.discardnow takes the node out of its host's list, assyncPositionandrehostalready do when a node leaves a host.core/tree.go:discardremovesnfromn.hoist.host.hosted.core/tooltip_test.go:TestRebuiltTooltipFreesTheOldViewrebuilds a view with a tooltip three times, then checks that the root view hosts one overlay and that the first view is collected. It fails on main with 4 hosted overlays.CHANGELOG.md: anUnreleasedline.Targets
core,base,ui,tsx, thensgotool)Screenshots
None.
Verification
go tool nsgo test -run '^TestRebuiltTooltipFreesTheOldView$' ./corefails on main at211434ba(the root view hosts 4 overlays, want the shown tooltip's 1) and passes with this change, also with-count=3.go tool nsgo checkon Linux x86_64 (the host): passes.go tool nsgo teston Linux x86_64 under Xvfb (GDK_BACKEND=x11,GSK_RENDERER=cairo): 3,060 passed, 9 failed, 59 skipped. The same 8 fail on main in the same environment:TestAccessibilitySelectedAndExpandedReachATSPI(no AT-SPI registry),TestVideoShowsWhatIsBehindItsTransparentPixels(no GStreamer plug-in for the alpha WebM), and sixTestInstance*whose socket path passed the address limit under this run's longTMPDIR; all six pass with a short one.TestInputsDrawTheirTextAsTextDoes(internal/platform/linux) failed once under the full run's load, as it did once on the other fix's branch; it passes alone three times out of three here and on main.-targettests, as nothing here is backend-specific; Windows, web and Apple's mobile targets.Checklist
fix(linux): keep the caret after a paste; a squash merge uses it as the commit subject.CHANGELOG.md'sUnreleasedhas a line for a capability users can see.