Skip to content

fix(runtime): keep a node first seen inside a Map or Set when it is referenced again - #693

Merged
route merged 2 commits into
mainfrom
fix/evaluate-node-shared-with-map-or-set
Nov 3, 2026
Merged

route merged 2 commits into
mainfrom
fix/evaluate-node-shared-with-map-or-set

Conversation

@route

@route route commented Nov 3, 2026

Copy link
Copy Markdown
Member

evaluate raised NoMethodError: undefined method '[]' for nil in Node#initialize when a DOM node first appeared inside a Map or Set and was referenced again elsewhere in the same result.

Chrome's deep serialization sends a shared object in full once and as a bare weakLocalObjectReference afterwards. convert returned {} for map and set without reading their entries, so the full node was never recorded and the later reference reached Node.new with no properties.

map and set entries are now read so their nodes are recorded; the container itself is still returned as {}.

Introduced in 0.20.0 (#677), present in 0.20.1.

@route
route merged commit 25629e7 into main Nov 3, 2026
7 checks passed
@route
route deleted the fix/evaluate-node-shared-with-map-or-set branch November 3, 2026 12:05
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