-
Notifications
You must be signed in to change notification settings - Fork 2k
fix(client): scope corrupt-cache-entry deletion to the probed partition #2485
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
felixweinberger
wants to merge
1
commit into
main
Choose a base branch
from
fix/partition-scoped-corrupt-delete
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+66
−9
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,5 @@ | ||
| --- | ||
| '@modelcontextprotocol/client': patch | ||
| --- | ||
|
|
||
| A corrupt cached document now deletes only the partition it was read from. The previous cleanup deleted both partitions, so on a shared multi-principal store one principal's corrupt private entry also evicted the healthy shared entry. Store delete failures during this cleanup are reported through the error sink instead of rejecting the read. | ||
|
Check failure on line 5 in .changeset/partition-scoped-corrupt-delete.md
|
||
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
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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🔴 The PR title and description describe a completely different change — adding
@modelcontextprotocol/codemodto the changesetsfixedgroup — but the diff contains none of that: it is a client responseCache fix (partition-scoped corrupt-entry deletion) with a client-only changeset, and.changeset/config.jsonis untouched. If merged as-is, the claimed codemod-versioning fix silently does not ship (thenpm install @modelcontextprotocol/codemod@2.0.0-beta.4failure the description promises to fix remains), and the merge record misdescribes the change — either push the intended diff or replace the title/description with ones describing the actual responseCache fix. Separately (minor), the changeset's last sentence ('reported through the error sink instead of rejecting the read') implies delete failures used to reject the read; they never did — the old_deleteBothalready caught and reported them — so reword it to say the existing error-sink reporting is preserved.Extended reasoning...
The PR metadata describes a change that is not in the diff
Title/description vs. actual content. The title is
chore: version the codemod with the core SDK fixed group, and the description explains adding@modelcontextprotocol/codemodto the changesetsfixedgroup (plus a codemod changeset) so the pending beta.4 release includes it. The diff, however, contains exactly three files:.changeset/partition-scoped-corrupt-delete.md(patching only@modelcontextprotocol/client),packages/client/src/client/responseCache.ts, andpackages/client/test/client/responseCacheCodec.test.ts. There is no change to.changeset/config.json, no codemod changeset, and no mention of the codemod package anywhere in the diff.Corroborating evidence. The changeset-bot comment on this PR confirms the release contents: 5 packages bumped (
client,core,server,server-legacy,core-internal) —@modelcontextprotocol/codemodis absent. The bot's link also shows the branch name isfix/partition-scoped-corrupt-delete, which matches the diff's content, not the title. And at HEAD,.changeset/config.json'sfixedgroup still lists onlycore/client/server/server-legacy— so the described change is not present anywhere; it simply does not ship. The most likely explanation is the title/description were copy-pasted from a different PR (the branch and code are internally consistent as the responseCache fix).Step-by-step consequence if merged as-is:
fixedgroup is unchanged.2.0.0-beta.4, the codemod stays at2.0.0-beta.3(no changeset, not in the fixed group).npm install @modelcontextprotocol/codemod@2.0.0-beta.4→ no matching version — exactly the failure the description claims to fix.Why this is normal severity rather than a description nit. The in-diff code is correct and well-tested, and its changeset accurately describes it — the defect is purely at the PR-metadata level. But this is not a stale or imprecise description of the code in the diff; it is a wholesale mismatch where an intended fix silently fails to ship while the record says it shipped. The author needs to act before merge: either the wrong branch/diff was pushed (push the intended
.changeset/config.jsonchange), or the metadata was pasted from another PR (retitle/re-describe this one as the responseCache partition-scoped corrupt-delete fix and file the codemod change separately).Secondary (nit): one changeset sentence implies a behavior change that isn't one
.changeset/partition-scoped-corrupt-delete.mdends with: "Store delete failures during this cleanup are reported through the error sink instead of rejecting the read." In a changelog, "instead of" reads as a before/after contrast — implying the pre-fix path rejectedread()on a store delete failure. It did not: the old corrupt path calledthis._deleteBoth(method, params ?? ''), and_deleteBoth(still present atpackages/client/src/client/responseCache.ts:431) wraps each partition'sdeletein try/catch, routes failures tothis._reportError, and always resolves. Verified against the pre-fix code (git show 80a94c5~1): a delete failure never rejected the read before this PR. Error-sink reporting is preserved pre-existing behavior, not part of this change. Suggested reword: "Store delete failures during this cleanup continue to be reported through the error sink." Nothing breaks if this merges as-is, but changelog readers would otherwise infer a rejection bug existed.