Repository navigation
fix(terminal): remove host listeners during cleanup - #214
Open
vincentkoc wants to merge 1 commit into
Open
vincentkoc wants to merge 1 commit into
vincentkoc wants to merge 1 commit into
Conversation
vincentkoc
marked this pull request as ready for review
November 4, 2026 06:09
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
Disposing a terminal, or failing partway through
open(), left two listeners on the host element.beforeinputkept cancelling editing, and a reused host could invoke disposed terminals' custom wheel callbacks.Keep a stable host-only
beforeinputhandler and remove it incleanupComponents(). Remove the wheel handler with the same capture setting used during registration. Child input behavior and unrelated host listeners are preserved.This complements the document-listener cleanup in PR #206; it only changes the two host listeners.
Validation
Validated signed commit
58fdf6ae4825269f2397f07fca33f1987757ffe6with Bun 1.4.4 and Zig 0.15.2:bun run fmt,bun run lint,bun run typecheck,bun test, andbun run buildpass: 375 tests, 4,608 assertions.Hosted CI and PR title validation await upstream maintainer approval; no hosted jobs have run. The validation above completed on an isolated Linux machine.
No version or dependency changes. Release notes use the repository's conventional-commit/release-please workflow.