From 534a1384b1ff37ba8574eaf4b00cc7c2467f1a33 Mon Sep 17 00:00:00 2001 From: cliffhall Date: Sun, 13 Sep 2026 19:37:52 -0400 Subject: [PATCH] chore: refresh the stale ext-apps example in the sdk-watch comments #2358 bumped `@modelcontextprotocol/ext-apps` from `^1.7.4` to `^2.0.0`, leaving two comments in `scripts/sdk-watch.mjs` still describing the current install as `^1.7.4` and illustrating the "compare the installed version, not the declared range" mechanism with a 1.8.0 target. Both now describe the mechanism in terms of "a caret range" and "a patch or minor ahead within the same major" rather than any concrete version, so the example cannot go stale on the next bump. Comments only; the 1.7.4/1.7.5 fixtures in `sdk-watch.test.mjs` are test data for the comparison logic and are untouched. Closes #2359 Co-Authored-By: Claude Fable 5.1 Claude-Session: https://claude.ai/code/session_01PsmUAZ6aLUAFqenjJKSSRp Signed-off-by: cliffhall --- scripts/sdk-watch.mjs | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/scripts/sdk-watch.mjs b/scripts/sdk-watch.mjs index 5dcd0a36..9c8c3475 100644 --- a/scripts/sdk-watch.mjs +++ b/scripts/sdk-watch.mjs @@ -27,11 +27,12 @@ // 2. **Compare the INSTALLED version, not the declared range.** #1063 phrases // the check as "is the current version > than the one we have in our // package.json", which is exact today only because the four SDK packages -// are pinned exactly. `ext-apps` is a caret range (`^1.7.4`) whose lockfile -// already resolves higher, so comparing against the declared string would -// file an issue for a bump `npm install` has already taken. The declared -// range is still reported — it is what says whether the fix is a manifest -// edit or a lockfile refresh — but the comparison is against the lockfile. +// are pinned exactly. `ext-apps` is a caret range, so its lockfile can +// already resolve higher than the manifest's floor, and comparing against +// the declared string would file an issue for a bump `npm install` has +// already taken. The declared range is still reported — it is what says +// whether the fix is a manifest edit or a lockfile refresh — but the +// comparison is against the lockfile. // 3. **A new SDK package must not be watched silently by nobody.** The group // table is a hardcoded list, so a fifth `@modelcontextprotocol/*` package // added to the root manifest would never be checked and nothing would say @@ -352,10 +353,10 @@ const cell = (value) => String(value).replace(/\|/g, "\\|"); * ⚠️ Not every bump is a manifest edit, and saying so unconditionally was wrong * for the very case this script exists to handle separately (Copilot). The four * `typescript-sdk` packages are pinned **exactly**, so any new version needs the - * manifest changed. `ext-apps` is a **range** (`^1.7.4`), so a 1.8.0 target is - * already satisfied by what `package.json` says and only `npm install` is needed - * — telling a maintainer to edit the manifest there sends them to change a line - * that is already correct. + * manifest changed. `ext-apps` is a caret **range**, so a target that is only a + * patch or minor ahead within the same major is already satisfied by what + * `package.json` says and only `npm install` is needed — telling a maintainer to + * edit the manifest there sends them to change a line that is already correct. * * A row whose declared value is not a parseable range (an unparsed dependency, * or the `(undeclared)` placeholder) counts as needing the edit: that is the