Skip to content

fix(freshness): fail the run when no App token was minted - #18

Merged
Gerrrt merged 1 commit into
mainfrom
fix/freshness-fails-without-app-token
Nov 23, 2026
Merged

Gerrrt merged 1 commit into
mainfrom
fix/freshness-fails-without-app-token

Conversation

@Gerrrt

@Gerrrt Gerrrt commented Nov 23, 2026

Copy link
Copy Markdown
Contributor

What & why

#16 sat BLOCKED behind a green freshness run. The org's FLEET_APP_PRIVATE_KEY was never shared with this repo, so the mint step skipped (HAS_APP_KEY: false) and the PR step fell back to GITHUB_TOKEN. GitHub starts no workflow for a PR opened with that token, so ci.yml's six required contexts never arrived.

The key is shared and the App is installed now. A mode=pr run today logged HAS_APP_KEY: true, and #17 was opened by dotgibson-fleet-sync.

This PR adds a final step to the freshness job. If no token was minted, the run goes red and the error says which half is missing: the org secret or variable, or the App install. It runs after the PR step, so the PR still opens. The bot can't go quietly unauthored again.

The same step is going into Core's freshness.yml, along with registering this repo as an App self-PR install in dotfiles-core's fleet-app-scope.sh and GITHUB-APP-AUTH.md. That's a separate PR in dotgibson/dotfiles-core.

Checks

  • Both workflow files parse.
  • make audit-offline doesn't run under Git Bash on Windows: its helper library fails to load. CI's lint (actionlint) and ci.yml are the check here.

🤖 Generated with Claude Code

The org never shared FLEET_APP_PRIVATE_KEY with this repo, so the mint
step skipped on HAS_APP_KEY=false and the PR step fell back to
GITHUB_TOKEN. GitHub starts no workflow for a PR that token opens, so
ci.yml's required contexts never arrived and #16 sat BLOCKED behind a
green run until it was closed and reopened by hand.

The key is shared now and the bot's PRs are App-authored (#17). A last
step reds the run if the mint ever yields no token again, after the PR
step so the PR still opens, and names whether the key/variable or the
App install is the missing half.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings November 23, 2026 20:08

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Approval recommended

No active review issues were identified for the plugin-refresh authentication safeguard.

No open issues 🎉

What changed in this PR

Makes missing fleet App authentication visible in the plugin-refresh workflow, preventing a misleading green run when fallback-token PRs cannot trigger required CI.

Changes:

  • Adds a final PR-mode check that fails when no App token was minted, while preserving the existing PR creation fallback.
  • Reports missing secret or variable visibility, or the mint outcome with an installation troubleshooting hint.
  • Documents the authentication failure and new safeguard in the changelog.
File Description
CHANGELOG.md Records the blocked-PR incident and authentication safeguard.
.github/​workflows/​freshness.yml Adds the post-PR token check, error annotation, and job summary.

Review effort: Balanced

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.

2 participants