You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Copilot CLI install: --cooldown-days default fails with 401 on GitHub Enterprise (ghe.com) (release-age check uses api.github.com with the ghe.com token) #77115
Since v1.2.0 the compiler emits install_copilot_cli.sh <ver> --prefer-toolcache --cooldown-days 3 by default. On GitHub Enterprise Cloud with data residency (<org>.ghe.com) the agent job fails in "Install GitHub Copilot CLI":
Exact version match found: /opt/hostedtoolcache/copilot-cli/1.0.103/x64/bin/copilot
curl: (22) The requested URL returned error: 401 (x6)
ERROR: Cannot verify Copilot release age: GitHub release metadata is unavailable
Root cause: actions/setup/sh/install_copilot_cli.sh, check_copilot_release_age (lines 737-783) hardcodes https://api.github.com/repos/${COPILOT_REPO}/releases/... and sends the job's GITHUB_TOKEN. On ghe.com that token was issued by the ghe.com instance, which github.com rejects with 401. The failure is fatal (line 767) and happens before the cached binary is activated (line 817). v1.0.1 locks had no --cooldown-days and worked.
Treat the release-age check as best-effort when its metadata request is rejected. If the request to api.github.com fails with 401/403, warn and continue with the pinned version (the toolcache binary, or the download verified against the pinned SHA256 manifest), instead of aborting the job. The pinned version and checksum already protect the install; the cooldown only adds a waiting period for new releases. Optionally, also stop emitting --cooldown-days by default for ghe.com targets, since the check can never succeed there with the job token.
Plan
In actions/setup/sh/install_copilot_cli.sh, check_copilot_release_age: when the metadata request fails with 401/403 (or the host is a ghe.com instance), don't return 1. Print a warning and continue, so the exact toolcache version or checksum-verified download is still used. Checksum verification stays independent.
In pkg/workflow/copilot_installer.go (generateCopilotInstallerSteps, lines 34-35): do not emit --cooldown-days by default when the compile target is ghe.com, or document why it is kept.
Tests: add a case to the installer script tests where the metadata request returns 401, and assert the warning and a successful install.
Docs: in docs/src/content/docs/reference/frontmatter.md, note the ghe.com behaviour of engine.cooldown.
Acceptance criterion
On GitHub Enterprise (ghe.com), a workflow with the default engine.cooldown just works: the Copilot CLI install succeeds with no extra setup (no extra secrets, no cooldown: 0, no strict: false).
Environment
gh-aw v1.2.2, engine: copilot, Copilot CLI 1.0.103, host <org>.ghe.com, ubuntu-24.04. Earlier steps run with GH_HOST=<org>.ghe.com (set by configure_gh_for_ghe.sh), but the "Install GitHub Copilot CLI" step runs with GH_HOST: github.com and GITHUB_TOKEN set to the ghe.com-issued token.
Activity
pelikhan commentedon Nov 17, 2026
@copilot remove check_copilot_release_age
pelikhan commentedon Nov 17, 2026
@copilot instead add a static built-time cooldown check
JoshGreenslade commentedon Nov 23, 2026
Affecting us too
pelikhan commentedon Nov 23, 2026
Looking