Skip to content

chore: enforce PR-issue link via GH Actions#18

Merged
brandonrc merged 2 commits into
mainfrom
chore/issue-link-enforcement
May 21, 2026
Merged

chore: enforce PR-issue link via GH Actions#18
brandonrc merged 2 commits into
mainfrom
chore/issue-link-enforcement

Conversation

@brandonrc

Copy link
Copy Markdown
Contributor

Summary

Adds .github/workflows/require-linked-issue.yml, which fails a PR check when the PR body does not reference an issue in this repo via Closes #N, Fixes #N, or Resolves #N (any tense, case-insensitive). The workflow uses actions/github-script@v7 to parse the body, verify the referenced issue exists, and post (or remove) a friendly bot comment explaining the policy. Maintainers can bypass with the no-issue-required label.

Closes #17
Refs artifact-keeper/artifact-keeper#1309

Part of the cross-repo rollout for the new PR-must-link-issue rule.

Test Checklist

  • Spectral lint passes (no OpenAPI changes)
  • All 5 SDK builds pass (no OpenAPI changes)
  • No breaking changes
  • Manually verified affected endpoints (none touched)

SDK Impact

  • TypeScript SDK builds (unaffected)
  • Kotlin SDK builds (unaffected)
  • Swift SDK builds (unaffected)
  • Rust SDK builds (unaffected)
  • Python SDK builds (unaffected)
  • Breaking change documented
  • Version bump needed

@brandonrc brandonrc requested a review from a team as a code owner May 21, 2026 23:09
@brandonrc

Copy link
Copy Markdown
Contributor Author

Applied review fixes: switched to pull_request_target for fork support, added concurrency block, SHA-pinned actions/github-script, sanitize HTML comments and code blocks before regex, paginate listComments, surface 404 errors with specific issue number. Same canonical change pushed across all 8 enforcement PRs.

@sonarqubecloud

Copy link
Copy Markdown

@brandonrc brandonrc merged commit c1f3dc7 into main May 21, 2026
9 of 10 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.

Add PR-issue-link enforcement workflow

1 participant