Repository navigation
Store: fix the unresolved review comments from #6053 - #6060
Merged
William Wong (compulim) merged 9 commits intoNov 20, 2026
Merged
William Wong (compulim) merged 9 commits into
William Wong (compulim) merged 9 commits into
Conversation
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
…ed properties in createNode Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: copilot-swe-agent[bot] <[email protected]>
William Wong (compulim)
marked this pull request as ready for review
November 20, 2026 00:57
William Wong (compulim)
requested review from
Eugene (OEvgeny),
Chris Whitten (cwhitten) and
Thomas Durnford (tdurnford)
as code owners
November 20, 2026 00:57
William Wong (compulim)
deleted the
copilot/6053-write-failing-test-cases
branch
November 20, 2026 00:57
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.
This PR fixes the unresolved review comments from #6053 (new graph store) in
packages/store. Each comment first got a failing test, then the source fix. Where there is a reference behaviour, the test shows it next to ours:JSON.parse(JSON.stringify(value))for JSON values, and nativeSetfor set operations.JSON values,
createNode,deepFreezeJSONValue.ts:unboxnow detects boxed primitives by checking for their internal slot (valueOf.callinside try/catch), not withinstanceof. Spoofed prototypes and boxes from other realms are now handled correctly.createNode.ts: properties are read from own data descriptors, so user getters are never called.toFrozenNodeSetnow takes the original value.deepFreeze.ts: objects with anullprototype are copied into plain objects instead of being reused. This matches the JSON round-trip.SetView/FrozenSet/FrozenNodeSetsizenow throwRangeError, as nativeSetdoes.FrozenNodeSetkeys by@id.union,symmetricDifferenceandintersectionde-duplicate values from the other set by that key.isSupersetOfno longer returns early based on size. That shortcut was wrong when the other set held duplicates under key equality.VersionedStorageOverlaynow iterates live throughentries/keys/values. If the overlay is committed mid-iteration, iteration continues on the committed version.FrozenMap/FrozenSetuse this instead of copying everything throughtoMap().dateCreatedprecisionDatedoes, and children in the same millisecond are sorted by@id.dateCreatedstring is stored unchanged.