Allow 'write' permission to dispatch the VS Code extension release workflow#17734
Allow 'write' permission to dispatch the VS Code extension release workflow#17734adamint wants to merge 1 commit into
Conversation
The authorization gate required 'admin' or 'maintain', but on microsoft/aspire nobody holds those levels — 'write' is the highest permission granted to contributors. As written, the gate made extension-release.yml undispatchable by anyone (a real dispatch by a write-level maintainer fails at step 1). Accept 'write' and above, matching the repo's other contributor-gated workflows (apply-test-attributes.yml and backport.yml both allow ['admin', 'write']). The separate AzDO release pipeline (release-github-tasks.yml) intentionally keeps the admin/maintain gate because it is dispatched by the aspire-repo-bot GitHub App (which bypasses the human check); extension-release.yml is human-dispatched, so it must accept 'write'. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
🚀 Dogfood this PR with:
curl -fsSL https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 17734Or
iex "& { $(irm https://raw.githubusercontent.com/microsoft/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 17734" |
There was a problem hiding this comment.
Pull request overview
This PR updates the VS Code extension release workflow authorization gate so repository contributors with write permission can manually dispatch the release-preparation workflow.
Changes:
- Allows
writepermission in addition tomaintainandadmin. - Updates the authorization error message and inline comment to match the new permission policy.
|
Follow-up to #15766, surfaced while trying to run the first real release end-to-end. @davidfowl noted that nobody on this repo holds This PR relaxes the gate to |
Problem
The
extension-release.ymlauthorization gate (added in #15766) requiredadminormaintainpermission:But on
microsoft/aspirenobody holdsmaintain/admin—writeis the highest level granted to contributors. As written, the workflow is undispatchable by anyone. A real dispatch fails at step 1:(Observed live: run 26692032713 — failed at the authorization step, no branch/PR created.)
Fix
Accept
writeand above, matching the repo's other human-dispatched contributor-gated workflows —apply-test-attributes.ymlandbackport.ymlboth allow['admin', 'write'].Why not match
release-github-tasks.yml(admin/maintain)?That workflow keeps the stricter gate because it is dispatched by the
aspire-repo-botGitHub App (AzDO chained dispatch), which bypasses the human permission check entirely.extension-release.ymlis human-dispatched (a contributor decides to prepare an extension release PR), so it must acceptwrite.Testing
write/maintain/adminauthorized;read/none/triagerejected.extension-changelogrun) actually be dispatched.