Skip to content

Enable Actions token-based Copilot inference and document accepted IMF secret warning in news workflows#3013

Merged
pethers merged 2 commits into
mainfrom
copilot/fix-13600698-499860999-42304a36-b873-4f42-a925-291e07404a05
Jun 22, 2026
Merged

Enable Actions token-based Copilot inference and document accepted IMF secret warning in news workflows#3013
pethers merged 2 commits into
mainfrom
copilot/fix-13600698-499860999-42304a36-b873-4f42-a925-291e07404a05

Conversation

Copilot AI commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

gh aw compile produced two classes of noise across the 14 news-*.md agentic workflows: an info tip recommending permissions.copilot-requests: write, and one advisory warning per file about ${{ secrets.IMF_SDMX_SUBSCRIPTION_KEY }} appearing in the steps: section. The first is actionable; the second is intentional design (the agent makes live authenticated IMF SDMX calls) and is accepted (Option A) rather than re-architected.

Permissions — copilot-requests: write

  • Added copilot-requests: write to the permissions: block of all 14 news-*.md workflows.
  • Recompiled with gh aw compile --purge; compiled lock files now use COPILOT_GITHUB_TOKEN: ${{ github.token }} (Actions token-based inference) instead of a PAT, and the info tip is gone.
permissions:
  contents: read
  #
  security-events: read
  copilot-requests: write   # GitHub Actions token-based Copilot inference (requires org centralized Copilot billing)

Documentation — accepted IMF warning (Option A)

  • Added an "Accepted compile warnings" section to .github/workflows/README.md covering why the IMF_SDMX_SUBSCRIPTION_KEY-in-steps: warning is expected (agent runs live imf-fetch.ts sdmx calls), why it is safe (::add-mask:: + GH_AW_SECRET_NAMES redaction), why strict: true is not viable (forbids the custom MCP egress domain / write perms / bash wildcards), and the Option-C path for a zero-secrets-in-agent posture.
  • Updated the permissions table row to include copilot-requests: write with the billing caveat.

Notes

  • The 14 IMF secret warnings persist by design; compile remains green (0 error(s)).
  • Lock files were regenerated from .md sources via --purge — none were hand-edited.

@github-actions github-actions Bot added the size-xs Extra small change (< 10 lines) label Jun 22, 2026
@github-actions

Copy link
Copy Markdown
Contributor

🏷️ Automatic Labeling Summary

This PR has been automatically labeled based on the files changed and PR metadata.

Applied Labels: size-xs

Label Categories

  • 🗳️ Content: news, dashboard, visualization, intelligence
  • 💻 Technology: html-css, javascript, workflow, security
  • 📊 Data: cia-data, riksdag-data, data-pipeline, schema
  • 🌍 I18n: i18n, translation, rtl
  • 🔒 ISMS: isms, iso-27001, nist-csf, cis-controls
  • 🏗️ Infrastructure: ci-cd, deployment, performance, monitoring
  • 🔄 Quality: testing, accessibility, documentation, refactor
  • 🤖 AI: agent, skill, agentic-workflow

For more information, see .github/labeler.yml.

@github-actions

Copy link
Copy Markdown
Contributor

🔍 Lighthouse Performance Audit

Category Score Status
Performance 85/100 🟡
Accessibility 95/100 🟢
Best Practices 90/100 🟢
SEO 95/100 🟢

📥 Download full Lighthouse report

Budget Compliance: Performance budgets enforced via budget.json

…F warning

Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
Copilot AI changed the title [WIP] Copilot Request Enable Actions token-based Copilot inference and document accepted IMF secret warning in news workflows Jun 22, 2026
@github-actions github-actions Bot added documentation Documentation updates workflow GitHub Actions workflows ci-cd CI/CD pipeline changes news News articles and content generation agentic-workflow Agentic workflow changes size-l Large change (250-1000 lines) labels Jun 22, 2026
@github-actions

Copy link
Copy Markdown
Contributor

🔍 Lighthouse Performance Audit

Category Score Status
Performance 85/100 🟡
Accessibility 95/100 🟢
Best Practices 90/100 🟢
SEO 95/100 🟢

📥 Download full Lighthouse report

Budget Compliance: Performance budgets enforced via budget.json

@pethers pethers marked this pull request as ready for review June 22, 2026 09:08
Copilot AI review requested due to automatic review settings June 22, 2026 09:08

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the 14 news-*.md agentic workflows to enable GitHub Actions token-based Copilot inference (removing the need for a PAT-based COPILOT_GITHUB_TOKEN secret in compiled workflows) and documents the intentionally accepted gh aw compile warning related to forwarding IMF_SDMX_SUBSCRIPTION_KEY into the agent job.

Changes:

  • Add permissions.copilot-requests: write across all news-*.md workflows to support Actions token-based Copilot inference.
  • Regenerate the 14 compiled news-*.lock.yml workflows so COPILOT_GITHUB_TOKEN is sourced from ${{ github.token }} and PAT secret validation/redaction wiring is removed.
  • Extend .github/workflows/README.md with an “Accepted compile warnings” section explaining and justifying the IMF secret warning.

Reviewed changes

Copilot reviewed 29 out of 29 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
.github/workflows/README.md Documents the added copilot-requests: write permission and adds rationale for the accepted IMF secret compile warning.
.github/workflows/news-committee-reports.md Adds copilot-requests: write to enable Actions token-based Copilot inference.
.github/workflows/news-election-cycle.md Adds copilot-requests: write to enable Actions token-based Copilot inference.
.github/workflows/news-evening-analysis.md Adds copilot-requests: write to enable Actions token-based Copilot inference.
.github/workflows/news-interpellations.md Adds copilot-requests: write to enable Actions token-based Copilot inference.
.github/workflows/news-month-ahead.md Adds copilot-requests: write to enable Actions token-based Copilot inference.
.github/workflows/news-monthly-review.md Adds copilot-requests: write to enable Actions token-based Copilot inference.
.github/workflows/news-motions.md Adds copilot-requests: write to enable Actions token-based Copilot inference.
.github/workflows/news-propositions.md Adds copilot-requests: write to enable Actions token-based Copilot inference.
.github/workflows/news-quarter-ahead.md Adds copilot-requests: write to enable Actions token-based Copilot inference.
.github/workflows/news-realtime-monitor.md Adds copilot-requests: write to enable Actions token-based Copilot inference.
.github/workflows/news-translate.md Adds copilot-requests: write to enable Actions token-based Copilot inference.
.github/workflows/news-week-ahead.md Adds copilot-requests: write to enable Actions token-based Copilot inference.
.github/workflows/news-weekly-review.md Adds copilot-requests: write to enable Actions token-based Copilot inference.
.github/workflows/news-year-ahead.md Adds copilot-requests: write to enable Actions token-based Copilot inference.
.github/workflows/news-committee-reports.lock.yml Regenerated output: switches Copilot auth to ${{ github.token }} and reflects new permissions/redaction wiring.
.github/workflows/news-election-cycle.lock.yml Regenerated output: switches Copilot auth to ${{ github.token }} and reflects new permissions/redaction wiring.
.github/workflows/news-evening-analysis.lock.yml Regenerated output: switches Copilot auth to ${{ github.token }} and reflects new permissions/redaction wiring.
.github/workflows/news-interpellations.lock.yml Regenerated output: switches Copilot auth to ${{ github.token }} and reflects new permissions/redaction wiring.
.github/workflows/news-month-ahead.lock.yml Regenerated output: switches Copilot auth to ${{ github.token }} and reflects new permissions/redaction wiring.
.github/workflows/news-monthly-review.lock.yml Regenerated output: switches Copilot auth to ${{ github.token }} and reflects new permissions/redaction wiring.
.github/workflows/news-motions.lock.yml Regenerated output: switches Copilot auth to ${{ github.token }} and reflects new permissions/redaction wiring.
.github/workflows/news-propositions.lock.yml Regenerated output: switches Copilot auth to ${{ github.token }} and reflects new permissions/redaction wiring.
.github/workflows/news-quarter-ahead.lock.yml Regenerated output: switches Copilot auth to ${{ github.token }} and reflects new permissions/redaction wiring.
.github/workflows/news-realtime-monitor.lock.yml Regenerated output: switches Copilot auth to ${{ github.token }} and reflects new permissions/redaction wiring.
.github/workflows/news-translate.lock.yml Regenerated output: switches Copilot auth to ${{ github.token }} and reflects new permissions/redaction wiring.
.github/workflows/news-week-ahead.lock.yml Regenerated output: switches Copilot auth to ${{ github.token }} and reflects new permissions/redaction wiring.
.github/workflows/news-weekly-review.lock.yml Regenerated output: switches Copilot auth to ${{ github.token }} and reflects new permissions/redaction wiring.
.github/workflows/news-year-ahead.lock.yml Regenerated output: switches Copilot auth to ${{ github.token }} and reflects new permissions/redaction wiring.

| `safe-outputs.create-pull-request.if-no-changes` | `warn` | Empty patches emit a warning instead of failing the run (e.g. duplicate-date dispatches) |
| `network.allowed` | `node`, `github`, `defaults` + explicit Docker Hub hosts (`docker.io`, `registry-1.docker.io`, `auth.docker.io`, `production.cloudflare.docker.com`) + IMF/SCB/Riksdag/Statskontoret/site domains | Ecosystem identifiers preferred per upstream `network.md`. The broad `containers` ecosystem (which would also permit `ghcr.io`, `quay.io`, `gcr.io`, `mcr.microsoft.com`, `pkgs.k8s.io`, …) is **deliberately omitted** to keep least-privilege egress; only the minimal Docker Hub hosts actually required to resolve `node:26-alpine` for the SCB and World Bank MCP servers are enumerated. Any future switch to `ghcr.io`, `quay.io`, or other registries must add the specific hosts and be reviewed against the egress allowlist policy before merge. |
| `permissions` | `contents: read`, `issues: read`, `pull-requests: read`, `actions: read`, `discussions: read`, `security-events: read` | Least-privilege agent token; write capabilities live exclusively in the safe-outputs runner job |
| `permissions` | `contents: read`, `issues: read`, `pull-requests: read`, `actions: read`, `discussions: read`, `security-events: read`, `copilot-requests: write` | Least-privilege agent token; write capabilities live exclusively in the safe-outputs runner job. `copilot-requests: write` enables **GitHub Actions token-based Copilot inference** (`COPILOT_GITHUB_TOKEN: ${{ github.token }}` in the compiled lock file) so the Copilot engine no longer needs a personal-access-token secret. Requires org-level centralized Copilot billing — see [gh-aw billing reference](https://github.github.com/gh-aw/reference/billing/). |
@pethers pethers merged commit 154e5c5 into main Jun 22, 2026
14 checks passed
@pethers pethers deleted the copilot/fix-13600698-499860999-42304a36-b873-4f42-a925-291e07404a05 branch June 22, 2026 09:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agentic-workflow Agentic workflow changes ci-cd CI/CD pipeline changes documentation Documentation updates news News articles and content generation size-l Large change (250-1000 lines) size-xs Extra small change (< 10 lines) workflow GitHub Actions workflows

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants