Repository navigation
fix(action): comment-trigger example only runs for owners, members and collaborators - #1259
Merged
Merged
Conversation
…d collaborators The issue_comment example and the documented Option C workflow now require github.event.comment.author_association in OWNER/MEMBER/COLLABORATOR. A new test parses every shipped example with an issue_comment trigger, plus the yaml fence in the Option C docs section, and fails if a job is ungated. Claude-Session: https://claude.ai/code/session_01VpUo5Vzp2kJErZDRxF24iy Entire-Checkpoint: 34dba514aefd
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The comment-trigger example (
sequant-action/examples/comment-trigger.yml) and the matching Option C workflow indocs/features/github-actions-integration.mdnow run only when the comment author is the repo owner, an organization member or a collaborator:The docs section also says why the check must stay.
Acceptance criteria
issue_commenttrigger gates each job onauthor_association(OWNER/COLLABORATOR, never CONTRIBUTOR/NONE). Evidence:__tests__/action-comment-trigger-gate.test.tsUsers who copied the old example should update their workflow's
if:to the one above.Verification
__tests__/action-comment-trigger-gate.test.ts2/2. It parses the yaml rather than grepping, and scopes the docs check to the Option C section's fence.tsc --noEmitclean. Prettier's warning on the docs file is pre-existing onmain.Mutation-verified: AC-1 — removed the author_association clause from comment-trigger.yml; every shipped example with an issue_comment trigger is gated failed; restored.
Mutation-verified: AC-2 — removed the author_association clause from the Option C docs workflow; the documented Option C workflow is gated failed; restored.
🤖 Generated with Claude Code