Repository navigation
chore(deps): happy-dom 20.14.5 with an OffscreenCanvas shim for the real-xterm test (#1365) - #1446
Merged
Merged
Conversation
…1365) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
happy-dom 20.10 added a global OffscreenCanvas. xterm's WidthCache prefers it over <canvas>, so the real-xterm wheel test's 2D-context shim is bypassed and term.open() throws 'value must not be falsy'. The shim fix follows. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…eel test (#1365) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Owner
Author
Review disposition (round 1)Two independent reviewers (Codex a and b), reports in
No code changes from review. CI is green at |
…block (#1446 review c) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Owner
Author
Review disposition: reviewer c (Pi), comment accuracy and shim hygieneVerdict: MERGE-READY. Every behavioral claim in the WHY block was checked against the installed xterm sourcemap and happy-dom 20.14.5, and the shim restore and isolation are leak-free.
|
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.
Fixes #1365.
Root cause
Only one of #1322's three failing groups was caused by happy-dom, and the cause was not event dispatch.
OffscreenCanvas. 20.9.0 has nolib/canvasat all.WidthCacheprefersnew OffscreenCanvas(1, 1)whenever that global exists.HTMLCanvasElement.prototype.getContext, so the shim was bypassed.OffscreenCanvas.getContext('2d')returnsnullwithout a canvas adapter, soterm.open()threwvalue must not be falsy.Unable to find … name "Add"/"everywhere", while the DOM in the same log shows"Add a shortcut to New Tab".e092232cupdated the tests at 17:52Z. The chore(deps): Bump the minor-and-patch group across 1 directory with 21 updates #1322 run started at 17:37Z.Change
docs/plans/2026-09-27-happy-dom-20-14-offscreen-canvas.md).^20.14.5. The lockfile diff is minimal: happy-dom plus its newbuffer-image-sizedependency. npm's unrelated pruning of five wasm optionals was left out. With this commit alone, the existing wheel test fails 5/5 on the realopen()path.OffscreenCanvas.prototype.getContext, restored inafterEach.OffscreenCanvas, so production xterm takes the same branch.fontBoundingBox*, so xterm's own try/catch falls back.Verification
Local runs used Node 24 and happy-dom 20.14.5, confirmed via the
navigator.userAgentstring. A symlinked vitest silently loads 20.9.0, so the version has to be checked.AgentCodeCustomSkillsRow > refreshes its shared revision after a Conventions mutation(afindByRoleon "New Skill…").The overlap with #1439 (node-pty) is in
package.json/package-lock.json, in different hunks:git merge-treemerges it cleanly.🤖 Generated with Claude Code