Skip to content

feat(pr-merge): grant merge-pr's lane token actions read - #9410

Merged
kyle-sexton merged 5 commits into
mainfrom
feat/pr-merge-actions-read-data
Oct 23, 2026
Merged

kyle-sexton merged 5 commits into
mainfrom
feat/pr-merge-actions-read-data

Conversation

@kyle-sexton

@kyle-sexton kyle-sexton commented Oct 23, 2026 •

Copy link
Copy Markdown
Member

No related issue: owner decision Q8 (owner, 2026-10-23): the lanes App token may carry actions: read for pr-merge's reads only.

Summary

This grants pr-merge's merge-pr lane token actions: read. The peer session poteto builds pr-merge's read fallback off GITHUB_TOKEN on top of it. The token stays read-only for Actions, and no other lane or activity gets it.

Fix

  • lane-rules.json: the pr-merge row sets "activity-grants": { "merge-pr": { "actions": "read" } }.
  • live-config.test.mjs: pins that merge-pr resolves actions: read and that every other live slot resolves none.
  • The pr-merge.yml comments and docs/conventions/pr-pipeline/README.md no longer say the lane token holds no Actions permission.

Stacked on #9409 (merged) and azure-iac#83 (merged and deployed, run 39968516268).

Verification

  • The new live-config test failed before the data change and passes after it.
  • npm test in .github/actions/resolve-config: 662 pass, 0 fail. The pr-merge script tests and request-lane-token tests pass.
  • actionlint is clean.

Related

🤖 Generated with Claude Code

kyle-sexton and others added 4 commits October 23, 2026 09:38
…ivity

Owner decision Q8: the lanes App token may carry actions read for
pr-merge's reads only. A lane-rules.json row may now name leaves of its
lane under activity-grants, each mapped to exactly {"actions": "read"};
resolve and resolveGrant add it to the effect row, and anything else is
rejected as lane-grant. resolve-config outputs actions, request-lane-token
compares it when set, and pr-merge.yml passes it. No row sets it yet, so
every grant stays as it was.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ane lacks

lane-rules.json serves every config that runs a lane, and the README
example's pr-merge lane holds `merge`, not `merge-pr`. A name the lane
does not hold now adds nothing instead of rejecting the config; the
value must still be exactly {"actions": "read"}.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Owner decision Q8: the lanes App token may carry actions read for
pr-merge's reads only (verdict artifacts, run listings, run records), so
those reads can fall back off GITHUB_TOKEN when it is exhausted. The
pr-merge row of lane-rules.json now lists merge-pr under
activity-grants, and the comments that said the lane token holds no
Actions permission now say what it holds.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rant

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@kyle-sexton kyle-sexton added the do-not-merge Hard merge gate: do not merge while applied. label Oct 23, 2026
Base automatically changed from feat/pr-merge-actions-read-grant to main October 23, 2026 14:17
@kyle-sexton kyle-sexton removed the do-not-merge Hard merge gate: do not merge while applied. label Oct 23, 2026
@kyle-sexton
kyle-sexton marked this pull request as ready for review October 23, 2026 14:21
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 23, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-23T14:23:15.737258Z 88e8819 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

github-actions Bot commented Oct 23, 2026 •

Copy link
Copy Markdown
Contributor

claude-review reviewed ce217b197cb32747a680ef7862731a9c6a93bbc6: 0 finding(s), 0 as inline comments.

No findings. I read .claude-lane/pr.diff and .claude-lane/pr-context.md, and I checked the wiring in resolve-config and pr-merge.yml. I did not run any tests or actionlint. The PR description's results (662 passing, actionlint clean) are the author's claims and I have not verified them.

  • Grant data: lane-rules.json adds "activity-grants": { "merge-pr": { "actions": "read" } } on the pr-merge row. That is exactly the shape resolve.mjs accepts (checkActivityGrants, around line 650). The actions output is already declared in resolve-config/action.yml. pr-merge.yml already passes actions: ${{ steps.config.outputs.actions }} to the lane-token request at line 560. The data change therefore reaches the minted token without more workflow edits.
  • Test: the new live-config test pins merge-pr to contents/pull-requests/issues: write plus actions: read. It also walks every lane and slot and asserts that none other resolves actions, so a broader grant would fail it.
  • Comments and docs: the edits to pr-merge.yml and docs/conventions/pr-pipeline/README.md match the new behaviour. The verdict downloads, listing and run records still read with GITHUB_TOKEN, as the docs now say.
  • Closing issue: the PR closes no issue. The "owner decision Q8" cited in the description is the author's claim and I could not verify it from the files I had.
  • Change fragment: bump: patch fits a CI-token permission change with no user-facing surface.
  • Embedded instructions: none in the PR context.
  • Manifests: the diff touches no plugin manifests, so no manifest <field> lines apply.
  • Hold: none of the hold classes apply. The diff adds no model spend and touches no trusted-actors, CODEOWNERS or .gitmodules paths. critical-security is not applicable.

@github-actions

github-actions Bot commented Oct 23, 2026 •

Copy link
Copy Markdown
Contributor

claude-security-review reviewed ce217b197cb32747a680ef7862731a9c6a93bbc6: 0 finding(s), 0 as inline comments.

Security review of PR #9410: no security findings.

I read all 5 files in the diff and the PR context.

The change adds "activity-grants": { "merge-pr": { "actions": "read" } } to the pr-merge row in lane-rules.json. The lane token for merge-pr therefore carries actions: read. The rest of the diff is a changelog entry, a test, workflow comments and convention docs.

  • Scope of the widening: the new live-config test resolves every lane and slot and asserts actions appears only for pr-merge/merge-pr, and only as read.
  • Read-only: the grant adds no write permission. contents, pull-requests and issues are unchanged.
  • Authorization: the PR cites an explicit owner decision (Q8) and a merged, deployed broker-side change (azure-iac#83). The grant is scoped to one activity of one lane.
  • pr-merge.yml: only comments changed. The job's permissions: block and the github.token wiring are untouched. The docs say the verdict downloads and run reads still use GITHUB_TOKEN, so this PR adds no new use of the wider token.
  • Residual exposure: the lane token can now read run metadata, logs and artifacts. That is the intended capability and has no exploit path in this diff.
  • Trust-gate paths: none touched. .github/standards/trusted-actors/**, .github/actions/check-trusted-trigger/**, CODEOWNERS and .gitmodules are all unchanged.
  • Plugin manifests: none changed, so there are no manifest <field> lines.
  • Instruction-surface deletions: none. The edits are comment and doc rewording that matches the new grant.
  • PR context: it contains no embedded instructions.

critical-findings: 0

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