Repository navigation
Conversation
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.
Returning a new Set containing draft children leaves revoked proxies in the result. For example,
produce({item: {id: 1}}, draft => new Set([draft.item]))produces a Set that throws when inspected and also contains an extra finalized copy. The same occurs when the replacement Set is nested in a returned object.Rebuild plain Sets from a snapshot during replacement-value finalization. This removes the original draft entries and adds finalized values in the original insertion order, including primitive and foreign-scope entries.
Four regression cases fail on unchanged main; four empty/primitive controls pass. With the fix: 4221 source tests and 3670 production-build tests pass (8 existing skips each), all JS/DTS builds pass, Flow reports no errors, and six ESM/CJS consumers verify order, identity and absence of drafts with autoFreeze on/off.
Prepared and verified with OpenAI Codex assistance.