Skip to content

chore: add missing changesets for CommonJS builds and codemod iterations#2412

Merged
felixweinberger merged 1 commit into
mainfrom
fweinberger/beta2-changesets
Jul 2, 2026
Merged

chore: add missing changesets for CommonJS builds and codemod iterations#2412
felixweinberger merged 1 commit into
mainfrom
fweinberger/beta2-changesets

Conversation

@felixweinberger

Copy link
Copy Markdown
Contributor

The CommonJS dual-build change and codemod iterations 5 merged without changesets, so the release automation has nothing to version. This adds the two missing changesets; on merge the Version Packages PR regenerates for the next beta.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)

Checklist

  • I have read the MCP Documentation
  • My code follows the repository's style guidelines
  • New and existing tests pass locally
  • I have added appropriate error handling
  • I have added or updated documentation as needed

@felixweinberger felixweinberger requested a review from a team as a code owner July 2, 2026 11:01
@changeset-bot

changeset-bot Bot commented Jul 2, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 1138496

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 9 packages
Name Type
@modelcontextprotocol/server Minor
@modelcontextprotocol/client Minor
@modelcontextprotocol/core Minor
@modelcontextprotocol/server-legacy Minor
@modelcontextprotocol/codemod Minor
@modelcontextprotocol/express Major
@modelcontextprotocol/hono Major
@modelcontextprotocol/fastify Major
@modelcontextprotocol/node Major

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@pkg-pr-new

pkg-pr-new Bot commented Jul 2, 2026

Copy link
Copy Markdown

Open in StackBlitz

@modelcontextprotocol/client

npm i https://pkg.pr.new/@modelcontextprotocol/client@2412

@modelcontextprotocol/codemod

npm i https://pkg.pr.new/@modelcontextprotocol/codemod@2412

@modelcontextprotocol/core

npm i https://pkg.pr.new/@modelcontextprotocol/core@2412

@modelcontextprotocol/server

npm i https://pkg.pr.new/@modelcontextprotocol/server@2412

@modelcontextprotocol/server-legacy

npm i https://pkg.pr.new/@modelcontextprotocol/server-legacy@2412

@modelcontextprotocol/express

npm i https://pkg.pr.new/@modelcontextprotocol/express@2412

@modelcontextprotocol/fastify

npm i https://pkg.pr.new/@modelcontextprotocol/fastify@2412

@modelcontextprotocol/hono

npm i https://pkg.pr.new/@modelcontextprotocol/hono@2412

@modelcontextprotocol/node

npm i https://pkg.pr.new/@modelcontextprotocol/node@2412

commit: 1138496

@felixweinberger felixweinberger merged commit ef120b2 into main Jul 2, 2026
19 checks passed
@felixweinberger felixweinberger deleted the fweinberger/beta2-changesets branch July 2, 2026 11:07
Comment on lines +1 to +13
---
'@modelcontextprotocol/server': minor
'@modelcontextprotocol/client': minor
'@modelcontextprotocol/core': minor
'@modelcontextprotocol/server-legacy': minor
'@modelcontextprotocol/codemod': minor
'@modelcontextprotocol/express': minor
'@modelcontextprotocol/hono': minor
'@modelcontextprotocol/fastify': minor
'@modelcontextprotocol/node': minor
---

Ship CommonJS builds alongside ESM for all v2 packages, so `require()` consumers and CJS-only toolchains can use the SDK without a bundler shim.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔴 The .changeset/cjs-dual-builds.md file duplicates the existing, still-unconsumed .changeset/cjs-support-v2-packages.md that PR #2405 already added for the same CommonJS dual-build change across the same 9 packages, and the two disagree on bump level (existing: patch, new: minor). Drop this new file (or, if a minor bump is actually intended, edit/remove the original instead) — otherwise the next Version Packages run produces two near-identical CHANGELOG entries per package and a silently escalated bump. The codemod-iterations-5.md changeset is genuinely missing from #2398 and is fine to add.

Extended reasoning...

What the bug is. The PR description states that "The CommonJS dual-build change ... merged without changesets", but that premise is incorrect. PR #2405 (commit f172626, feat(packaging): ship CommonJS builds alongside ESM for v2 packages) already included .changeset/cjs-support-v2-packages.md, and that file is still present at HEAD on this branch. This PR adds a second changeset, .changeset/cjs-dual-builds.md, describing the exact same change ("Ship CommonJS builds alongside ESM") for the exact same 9 packages.

Why the existing state doesn't prevent it. A changeset is only removed once it is consumed by a changeset version run (or listed in .changeset/pre.json's changesets array during pre-release mode). At HEAD, pre.json's consumed list contains only "beta-release", so cjs-support-v2-packages.md has not been consumed yet. Both changesets are therefore pending and will both be picked up by the next Version Packages run.

Concrete impact — step through the next changeset version run:

  1. Changesets collects all pending files: beta-release (already consumed, skipped), cjs-support-v2-packages.md (patch × 9 packages), cjs-dual-builds.md (minor × 9 packages), codemod-iterations-5.md (patch for codemod).
  2. For each of the 9 packages (server, client, core, server-legacy, codemod, express, hono, fastify, node), the CHANGELOG gains two entries describing the same CJS dual-build change, one worded per each file — redundant and confusing release notes.
  3. The bump level for each package is the max across its changesets, so the new minor declaration silently overrides the patch level the original author chose in feat(packaging): ship CommonJS builds alongside ESM for v2 packages #2405 (visible in the changeset-bot comment on this PR: everything jumps to Minor, and the pre-1.0 middleware packages to Major). Whichever level is correct, having two conflicting declarations for one change means the escalation happens implicitly rather than as a deliberate decision.

Why this matters for this PR specifically. Half of the PR is this duplicate file, and its stated purpose ("the release automation has nothing to version" for the CJS change) is not true. The other half — .changeset/codemod-iterations-5.md — is legitimate: commit 1772473 (#2398) merged with no changeset, so that one is genuinely missing.

How to fix. Either:

  • Remove .changeset/cjs-dual-builds.md from this PR (if the original patch level is correct), or
  • If a minor bump is actually intended for the CJS change, edit or replace the original cjs-support-v2-packages.md instead of adding a second changeset alongside it, so exactly one changeset describes the change at the intended level.

@github-actions github-actions Bot mentioned this pull request Jul 2, 2026
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