Skip to content

chore(ci): use built-in token for catalog issue writes - #348

Merged
BrainerVirus merged 1 commit into
mainfrom
chore/catalog-issues-token
Dec 4, 2026
Merged

BrainerVirus merged 1 commit into
mainfrom
chore/catalog-issues-token

Conversation

@BrainerVirus

Copy link
Copy Markdown
Owner

Why

Manual catalog-sync run 47401342274 extracted the catalog successfully but failed while closing the duplicate [catalog-break] issues:

GraphQL: Resource not accessible by personal access token (addComment)
failed to resolve catalog-break issues

The workflow passed RELEASE_SYNC_TOKEN (the PAT) as both GH_TOKEN and GITHUB_TOKEN. That PAT is required for PR creation so GitHub starts CI on the branch, but it does not carry Issues write. The built-in GITHUB_TOKEN already has issues: write from the workflow permissions.

What

  • src/catalog-break-reporter.ts: add ghEnvironment() and an optional token to githubCli(), so issue calls can use a different credential.
  • scripts/catalog-sync-ci.ts: two runners — gh keeps the PAT for PRs, issueGh uses CATALOG_ISSUES_TOKEN for issue create/edit/comment/close.
  • .github/workflows/catalog-sync.yml: set CATALOG_ISSUES_TOKEN: ${{ github.token }}; use the built-in token for label management too.
  • Tests: token override and no-token fallback.

Verification

Workit-Session: ses_dbdda4daaffexKPxS5Z9LKhpI2
@BrainerVirus
BrainerVirus merged commit b45f1be into main Dec 4, 2026
5 checks passed
@BrainerVirus
BrainerVirus deleted the chore/catalog-issues-token branch December 4, 2026 18:50
@github-actions

github-actions Bot commented Dec 4, 2026

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 0.12.56 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[catalog-break] command-code@1.94.0 — model extraction failed

1 participant