Summary
Since the June 2026 change (agentic workflows no longer need a PAT), workflows using copilot-requests: write can trigger CI on PRs without a Personal Access Token.
However, gh aw compile still emits GH_AW_CI_TRIGGER_TOKEN in the compiled .lock.yml — both in the manifest header and as an env var passed to the process_safe_outputs.cjs step — even when the secret is not set on the repo and copilot-requests: write is present.
Steps to reproduce
- Have a workflow with
create-pull-request safe output and copilot-requests: write permission.
- Do not set
GH_AW_CI_TRIGGER_TOKEN on the repo.
- Run
gh aw compile.
- Observe that the compiled
.lock.yml still contains GH_AW_CI_TRIGGER_TOKEN in the manifest and in the Process Safe Outputs step env.
Expected behavior
When copilot-requests: write is present and no GH_AW_CI_TRIGGER_TOKEN is configured, the compiler should either:
- Omit
GH_AW_CI_TRIGGER_TOKEN from the manifest and compiled steps entirely, or
- Add a compile-time notice that the magic secret is no longer necessary.
Why it matters
Organizations following the security guidance to remove GH_AW_CI_TRIGGER_TOKEN (e.g. after the token-leak fix in v0.85.4) will still see the secret listed in their compiled lock file, creating confusion about whether the token is still needed and whether it should be rotated.
Workaround
Delete the secret from the repo. The reference in the lock file resolves to empty string at runtime and gh-aw falls back to the org-billed path. But the lock file still looks like it expects the token.
Environment
gh aw version: v0.88.7
- Affected repos (elastic org):
docs-actions, elastic-docs-skills, elastic-docs-skills-internal, integration-docs, terraform-provider-elasticstack
Summary
Since the June 2026 change (agentic workflows no longer need a PAT), workflows using
copilot-requests: writecan trigger CI on PRs without a Personal Access Token.However,
gh aw compilestill emitsGH_AW_CI_TRIGGER_TOKENin the compiled.lock.yml— both in the manifest header and as an env var passed to theprocess_safe_outputs.cjsstep — even when the secret is not set on the repo andcopilot-requests: writeis present.Steps to reproduce
create-pull-requestsafe output andcopilot-requests: writepermission.GH_AW_CI_TRIGGER_TOKENon the repo.gh aw compile..lock.ymlstill containsGH_AW_CI_TRIGGER_TOKENin the manifest and in theProcess Safe Outputsstep env.Expected behavior
When
copilot-requests: writeis present and noGH_AW_CI_TRIGGER_TOKENis configured, the compiler should either:GH_AW_CI_TRIGGER_TOKENfrom the manifest and compiled steps entirely, orWhy it matters
Organizations following the security guidance to remove
GH_AW_CI_TRIGGER_TOKEN(e.g. after the token-leak fix in v0.85.4) will still see the secret listed in their compiled lock file, creating confusion about whether the token is still needed and whether it should be rotated.Workaround
Delete the secret from the repo. The reference in the lock file resolves to empty string at runtime and gh-aw falls back to the org-billed path. But the lock file still looks like it expects the token.
Environment
gh awversion: v0.88.7docs-actions,elastic-docs-skills,elastic-docs-skills-internal,integration-docs,terraform-provider-elasticstack