Skip to content

fix(ci): allow the agent's generated MCP version file in the release-train scope check - #141

Merged
mattapperson merged 1 commit into
mainfrom
fix/release-train-mcp-version-scope
Nov 3, 2026
Merged

mattapperson merged 1 commit into
mainfrom
fix/release-train-mcp-version-scope

Conversation

@mattapperson

@mattapperson mattapperson commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

Summary

The release train has failed every scheduled run (10-27, 10-29, 11-03), so nothing has shipped since @openrouter/agent@0.11.0. Every run failed the same way:

::error::path outside allowlist: packages/agent/src/mcp/version.ts
::error::Scope check failed for Version PR #119

#102 moved the committed gen:version output from packages/mcp/src/version.ts to packages/agent/src/mcp/version.ts, but verify-version-pr-scope.sh still only allowed packages/*/src/version.ts. Any Version PR that bumps @openrouter/agent now includes the moved file, so the check rejects it.

Change

  • The src/version.ts path pattern is replaced with an exact list, GENERATED_VERSION_FILES, which contains only packages/agent/src/mcp/version.ts.
  • The path allowlist and the line-by-line content check both read that list. Before, the content check matched on endswith("src/version.ts"), so a widened path pattern alone would have let src/mcp/version.ts through without checking its contents. Now a file can't be allowed without also being checked.
  • The old packages/*/src/version.ts pattern is gone; no package commits a file there anymore.
  • The stale path in a publish.yaml comment is fixed. No workflow behavior changes.

Testing

  • Against the live Version PR chore: version packages #119 (read-only): the new script returns Diff scope OK. The script on main fails with the same error the train hit.
  • Against crafted diffs, with gh replaced by a stub:
Case Result
Legitimate version bump (package.json + src/mcp/version.ts + consumed changeset) pass
Extra statement in src/mcp/version.ts rejected (non-version change)
src/mcp/version.ts with no inline patch rejected (unvettable)
Other src/ file (src/mcp/handle.ts) rejected (outside allowlist)
Old packages/mcp/src/version.ts path rejected (outside allowlist)
postinstall added to package.json rejected (non-version change)

After merge

The next train run (Tue/Thu 09:23 UTC) will gate and merge Version PR #119, or someone can run it by hand. #119 currently releases @openrouter/agent 1.0.0, because .changeset/drop-preliminary-results.md is major. Add the release:hold label to #119 if that release isn't ready to go out with the next train.


Devin Review

…train scope check

#102 moved the committed gen:version output from packages/mcp/src/version.ts
to packages/agent/src/mcp/version.ts, but the Version PR scope allowlist
still matched packages/*/src/version.ts. Every Version PR bumping
@openrouter/agent now carries the moved file, so the train has rejected the
Version PR on every scheduled run and nothing has released since 0.11.0.

Replace the src/version.ts pattern with an exact list of generated version
files, used by both the path allowlist and the content vet, so a file can't
be allowed without having its lines checked against the gen-version.mjs
output shape. Also fix the stale path in publish.yaml's comment.

Co-Authored-By: Claude Code <noreply@anthropic.com>

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Devin Review

@mattapperson
mattapperson merged commit 3d91702 into main Nov 3, 2026
6 of 7 checks passed
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