Skip to content

feat: add safe-outputs.failure-issue-repo to redirect failure issues to a different repo#20429

Merged
pelikhan merged 5 commits intomainfrom
copilot/support-configure-failure-repo
Mar 11, 2026
Merged

feat: add safe-outputs.failure-issue-repo to redirect failure issues to a different repo#20429
pelikhan merged 5 commits intomainfrom
copilot/support-configure-failure-repo

Conversation

Copy link
Contributor

Copilot AI commented Mar 10, 2026

Repositories with issues disabled (e.g. github/docs-internal) silently drop failure reports from the built-in failure tracking mechanism. This adds a failure-issue-repo field to safe-outputs to redirect those issues to a companion repo.

Changes

  • SafeOutputsConfig – new FailureIssueRepo string field (yaml:"failure-issue-repo")
  • safe_outputs_config.go – parses failure-issue-repo from frontmatter
  • imports.go – merges FailureIssueRepo from imported workflow configs (first-wins)
  • notify_comment.go – emits GH_AW_FAILURE_ISSUE_REPO env var to the conclusion job when set
  • handle_agent_failure.cjs – overrides owner/repo for all issue search/create/comment calls when GH_AW_FAILURE_ISSUE_REPO is present; also threads it through ensureParentIssue
  • JSON schema – added failure-issue-repo with ^[^/]+/[^/]+$ pattern validation
  • Docs – new sections in safe-outputs.md and glossary.md

Usage

safe-outputs:
  failure-issue-repo: github/docs-engineering
  create-issue:

The GITHUB_TOKEN must have issues: write permission on the target repository.

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • https://api.github.com/graphql
    • Triggering command: /usr/bin/gh /usr/bin/gh api graphql -f query=query($owner: String!, $name: String!) { repository(owner: $owner, name: $name) { hasDiscussionsEnabled } } -f owner=github -f name=gh-aw (http block)
    • Triggering command: /usr/bin/gh /usr/bin/gh api graphql -f query=query($owner: String!, $name: String!) { repository(owner: $owner, name: $name) { hasDiscussionsEnabled } } -f owner=github -f name=gh-aw main -lang=go1.25 go env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh /usr/bin/gh api graphql -f query=query($owner: String!, $name: String!) { repository(owner: $owner, name: $name) { hasDiscussionsEnabled } } -f owner=github -f name=gh-aw GOMOD GOMODCACHE go env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
  • https://api.github.com/repos/actions/ai-inference/git/ref/tags/v1
    • Triggering command: /usr/bin/gh gh api /repos/actions/ai-inference/git/ref/tags/v1 --jq .object.sha --show-toplevel /tmp/go-build4273713018/b001/workflow.test ache/node/24.14.0/x64/bin/node k/gh-aw/gh-aw/.ggit -test.timeout=10rev-parse me: String!) { --show-toplevel ache/node/24.14.0/x64/bin/node 9920�� --show-toplevel git /usr/bin/git --name-only HEAD (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/ai-inference/git/ref/tags/v1 --jq .object.sha /home/REDACTED/work/gh-aw/gh-aw/.github/workflows/ace-editor.md /tmp/go-build2064961138/b384/_testmain.go /opt/hostedtoolcache/node/24.14.0/x64/bin/node --show-toplevel git /usr/bin/git node /tmp�� /home/REDACTED/work/gh-aw/gh-aw/.github/workflows/auto-triage-issues.md l /usr/bin/git --show-toplevel 7199194/b405/matrev-parse /usr/bin/git git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/ai-inference/git/ref/tags/v1 --jq .object.sha user.email test@example.com /usr/bin/git --show-toplevel nly /usr/bin/git git add .github/workflows/test.md git /usr/bin/git --show-toplevel iptables /usr/bin/git git (http block)
  • https://api.github.com/repos/actions/checkout/git/ref/tags/v3
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v3 --jq .object.sha --show-toplevel ache/go/1.25.0/x64/pkg/tool/linu-f 7199194/b367/vet.cfg ithub/workflows GO111MODULE ache/go/1.25.0/x--show-toplevel git rev-�� --show-toplevel ache/go/1.25.0/x64/pkg/tool/linuHEAD 0/x64/bin/node ithub/workflows /tmp/go-build421rev-parse p/bin/git 0/x64/bin/node (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v3 --jq .object.sha --show-toplevel git 4961138/b200/vet.cfg --show-toplevel git /usr/bin/git git rev-�� --show-toplevel git /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/compile --show-toplevel git /usr/bin/git /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v3 --jq .object.sha runs/20260311-000652-43684/test-362104317/.github/workflows git (http block)
  • https://api.github.com/repos/actions/checkout/git/ref/tags/v5
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v5 --jq .object.sha /home/REDACTED/work/gh-aw/gh-aw/.g-c=4 rev-parse /usr/bin/git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v5 --jq .object.sha user.email test@example.com /usr/bin/git --get er@0.29.0 (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v5 --jq .object.sha --show-toplevel infocmp /usr/bin/git xterm-color go /home/REDACTED/wor--show-toplevel git rev-�� --show-toplevel bash /usr/bin/git --noprofile 64/pkg/tool/linurev-parse /usr/bin/git git (http block)
  • https://api.github.com/repos/actions/checkout/git/ref/tags/v6
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v6 --jq .object.sha ithub/workflows /tmp/go-build4216809629/b043/vet.cfg ache/go/1.25.0/x64/bin/bash GOSUMDB GOWORK 64/bin/go /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linumcp/ast-grep:latest -ato�� ithub/workflows -buildtags /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/vet -errorsas -ifaceassert -nilfunc /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linu-f (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v6 --jq .object.sha -unreachable=false /tmp/go-build4216809629/b139/vet.cfg repository(owner: $owner, name: $name) { hasDiscussionsEnabled } } GOSUMDB GOWORK 64/bin/go /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linu@sentry/mcp-server@0.29.0 -uns�� ithub/workflows /tmp/go-build4216809629/b186/vet.cfg (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v6 --jq .object.sha -unreachable=false /tmp/go-build4216809629/b049/vet.cfg tnet/tools/git p/smoke_test_225git GO111MODULE ed } } /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linurev-parse -uns�� ithub/workflows /tmp/go-build4216809629/b212/vet.cfg 694700af8cfeef02c93f918e -json GO111MODULE 64/bin/go /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linurev-parse (http block)
  • https://api.github.com/repos/actions/github-script/git/ref/tags/v8
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v8 --jq .object.sha -json .cfg r: $owner, name:-f GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linuconfig env -json .cfg kflow.test GOINSECURE GOMOD GOMODCACHE kflow.test (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v8 --jq .object.sha ithub/workflows GOPROXY rgo/bin/bash GOSUMDB GOWORK 64/bin/go /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linu@sentry/mcp-server@0.29.0 -uns�� -unreachable=false /tmp/go-build4216809629/b172/vet.cfg /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/vet -json GO111MODULE 64/bin/go /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linu-f (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v8 --jq .object.sha ithub/workflows /tmp/go-build4216809629/b085/vet.cfg ash GOSUMDB GOWORK 64/bin/go /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linu-f -ato�� -bool -buildtags me: String!) { repository(owner: $owner, name:-f -errorsas -ifaceassert -nilfunc /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/vet (http block)
  • https://api.github.com/repos/actions/setup-go/git/ref/tags/v4
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-go/git/ref/tags/v4 --jq .object.sha ithub/workflows /tmp/go-build4216809629/b065/vet.cfg cal/bin/bash GOSUMDB GOWORK 64/bin/go /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linuname -uns�� ithub/workflows /tmp/go-build4216809629/b180/vet.cfg /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/vet -json GO111MODULE 64/bin/go /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linu-f (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-go/git/ref/tags/v4 --jq .object.sha /tmp/gh-aw-test-runs/20260311-000118-32427/test-667971488/.github/workflows config ache/node/24.14.0/x64/bin/node remote.origin.urgit resolved$ /usr/local/.ghcu--show-toplevel /tmp/go-build2307199194/b409/parser.test t-33�� k/gh-aw/gh-aw/.github/workflows/ace-editor.md -test.v=true /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/compile -test.timeout=10git -test.run=^Test -test.short=true--show-toplevel /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-go/git/ref/tags/v4 --jq .object.sha --show-toplevel git /usr/bin/git --show-toplevel git /usr/bin/git git rev-�� --show-toplevel git /usr/bin/git --show-toplevel git /usr/bin/git git (http block)
  • https://api.github.com/repos/actions/setup-node/git/ref/tags/v4
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-node/git/ref/tags/v4 --jq .object.sha -unreachable=false /tmp/go-build4216809629/b010/vet.cfg me: String!) { repository(owner: $owner, name: $name) { hasDiscussionsEnabled } } GOSUMDB GOWORK 64/bin/go /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linumcp/context7 -ato�� -bool -buildtags /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/vet -errorsas -ifaceassert -nilfunc /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linurev-parse (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-node/git/ref/tags/v4 --jq .object.sha --show-toplevel (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-node/git/ref/tags/v4 --jq .object.sha /tmp/gh-aw-test-runs/20260311-000441-37008/test-704035060/.github/workflows config /usr/bin/git remote.origin.urgit git /usr/bin/git git rev-�� --show-toplevel git /usr/bin/git ays.md git /usr/bin/git git (http block)
  • https://api.github.com/repos/actions/upload-artifact/git/ref/tags/v4
    • Triggering command: /usr/bin/gh gh api /repos/actions/upload-artifact/git/ref/tags/v4 --jq .object.sha artifacts-summary.md ache/go/1.25.0/xrev-parse ache/go/1.25.0/x64/pkg/tool/linu-nilfunc se 6809629/b104/vetrev-parse c93f918e ache/go/1.25.0/x64/pkg/tool/linu-tests rev-�� 7199194/b405/_pkg_.a ache/go/1.25.0/x64/pkg/tool/linux_amd64/vet 7199194/b405=> -json GO111MODULE ache/go/1.25.0/x--show-toplevel git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/upload-artifact/git/ref/tags/v4 --jq .object.sha --show-toplevel git 694700af8cfeef02c93f918e --show-toplevel x_amd64/vet /usr/bin/git git rev-�� --show-toplevel git ache/node/24.14.0/x64/bin/node --show-toplevel infocmp /usr/bin/git git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/upload-artifact/git/ref/tags/v4 --jq .object.sha --show-toplevel git ache/go/1.25.0/x64/pkg/tool/linux_amd64/vet --show-toplevel git /usr/bin/git ache/go/1.25.0/x64/pkg/tool/linux_amd64/vet rev-�� --show-toplevel git /opt/hostedtoolcache/node/24.14.0/x64/bin/node --show-toplevel git /usr/bin/git node (http block)
  • https://api.github.com/repos/astral-sh/setup-uv/git/ref/tags/eac588ad8def6316056a12d4907a9d4d84ff7a3b
    • Triggering command: /usr/bin/gh gh api /repos/astral-sh/setup-uv/git/ref/tags/eac588ad8def6316056a12d4907a9d4d84ff7a3b --jq .object.sha -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/1/artifacts
    • Triggering command: /usr/bin/gh gh run download 1 --dir test-logs/run-1 config ache/go/1.25.0/x64/pkg/tool/linux_amd64/compile remote.origin.urnode GO111MODULE x_amd64/vet ache/go/1.25.0/x64/pkg/tool/linurev-parse estl�� graphql -f /usr/bin/infocmp -f owner=github -f infocmp (http block)
    • Triggering command: /usr/bin/gh gh run download 1 --dir test-logs/run-1 node /usr/lib/git-core/git-upload-pack k/gh-aw/gh-aw/.ggit git /usr/bin/git git-upload-pack orig�� n-dir/git git 64/pkg/tool/linux_amd64/compile --show-toplevel bash /usr/bin/git 64/pkg/tool/linux_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh run download 1 --dir test-logs/run-1 git /usr/bin/git runs/20260311-00git remote.origin.ur-C /usr/bin/git git rev-�� --show-toplevel git x_amd64/vet 0/x64/bin/node git /usr/bin/git x_amd64/vet (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/12345/artifacts
    • Triggering command: /usr/bin/gh gh run download 12345 --dir test-logs/run-12345 x_amd64/vet x_amd64/compile -json GO111MODULE DiscussionsEnabl--show-toplevel x_amd64/compile imag�� inspect mcp/memory /usr/bin/infocmp -json GO111MODULE x_amd64/vet infocmp (http block)
    • Triggering command: /usr/bin/gh gh run download 12345 --dir test-logs/run-12345 git /usr/bin/git user.email test@example.comrev-parse /usr/bin/git git comm�� -m Initial .test --show-current git /usr/bin/git .test (http block)
    • Triggering command: /usr/bin/gh gh run download 12345 --dir test-logs/run-12345 git /usr/bin/git --get remote.origin.ur-C 0/x64/bin/node git rev-�� --show-toplevel 0/x64/bin/node x_amd64/asm --show-toplevel /tmp/go-build206rev-parse /usr/bin/git x_amd64/asm (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/12346/artifacts
    • Triggering command: /usr/bin/gh gh run download 12346 --dir test-logs/run-12346 --jq x_amd64/vet -json GO111MODULE x_amd64/vet x_amd64/vet imag�� inspect mcp/ast-grep:latest /usr/bin/gh -json GO111MODULE x_amd64/vet /usr/bin/gh (http block)
    • Triggering command: /usr/bin/gh gh run download 12346 --dir test-logs/run-12346 git /usr/lib/git-core/git --get remote.origin.urrev-parse /usr/bin/git /usr/lib/git-core/git main�� agent-performance-analyzer.md --auto stants.test --detach git /usr/bin/git stants.test (http block)
    • Triggering command: /usr/bin/gh gh run download 12346 --dir test-logs/run-12346 ache/node/24.14.0/x64/bin/node /usr/bin/git ts.result rev-parse /usr/bin/git git rev-�� --show-toplevel git x_amd64/cgo --get remote.origin.urrev-parse /usr/bin/git x_amd64/cgo (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/2/artifacts
    • Triggering command: /usr/bin/gh gh run download 2 --dir test-logs/run-2 -f x_amd64/compile -f owner=github -f x_amd64/compile -1 xterm-color x_amd64/vet /usr/bin/git -json GO111MODULE x_amd64/vet git (http block)
    • Triggering command: /usr/bin/gh gh run download 2 --dir test-logs/run-2 docker /usr/bin/git rhysd/actionlintgit git /opt/hostedtoolcuser.email git show�� agent-persona-explorer.md --quiet /usr/bin/git /tmp/TestHashStagit bash /usr/bin/git git (http block)
    • Triggering command: /usr/bin/gh gh run download 2 --dir test-logs/run-2 git /usr/bin/git /tmp/gh-aw-test-git s/test.md ache/node/24.14.--git-dir git rev-�� --show-toplevel ache/node/24.14.0/x64/bin/node x_amd64/vet user.name Test User /usr/bin/git x_amd64/vet (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/3/artifacts
    • Triggering command: /usr/bin/gh gh run download 3 --dir test-logs/run-3 config x_amd64/vet remote.origin.urgit GO111MODULE DiscussionsEnabl--show-toplevel x_amd64/vet /opt�� view @sentry/mcp-server@0.29.0 /usr/bin/git -json GO111MODULE x_amd64/vet git (http block)
    • Triggering command: /usr/bin/gh gh run download 3 --dir test-logs/run-3 docker /usr/bin/git test/concurrent-git git /usr/lib/git-cor--show-toplevel git fetc�� origin main /usr/bin/git run --auto /usr/bin/git git (http block)
    • Triggering command: /usr/bin/gh gh run download 3 --dir test-logs/run-3 0/x64/bin/node /usr/bin/git s/test.md config /usr/bin/git git rev-�� --show-toplevel git x_amd64/vet user.email test@example.comrev-parse /usr/bin/git x_amd64/vet (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/4/artifacts
    • Triggering command: /usr/bin/gh gh run download 4 --dir test-logs/run-4 rev-parse x_amd64/vet -json GO111MODULE x_amd64/vet x_amd64/vet /opt�� view mport|TestCompile /usr/bin/gh -json GO111MODULE x_amd64/vet /usr/bin/gh (http block)
    • Triggering command: /usr/bin/gh gh run download 4 --dir test-logs/run-4 docker /bin/sh k/gh-aw/gh-aw/.ggit git /usr/bin/git /bin/sh -c git-upload-pack 'origin' git-upload-pack 'origin' util.test --git-dir bash /usr/bin/git util.test (http block)
    • Triggering command: /usr/bin/gh gh run download 4 --dir test-logs/run-4 git /usr/bin/git s/test.md -dwarf=false /opt/hostedtoolc/tmp/gh-aw-test-runs/20260311-000652-43684/test-1963416333 git rev-�� --show-toplevel node /usr/lib/git-core/git /home/REDACTED/worgit /tmp/go-build206rev-parse 0/x64/bin/node /usr/lib/git-core/git (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/5/artifacts
    • Triggering command: /usr/bin/gh gh run download 5 --dir test-logs/run-5 x_amd64/vet x_amd64/link -json GO111MODULE x_amd64/vet x_amd64/link -C /home/REDACTED/work/gh-aw/gh-aw/.github/workflows rev-parse /usr/bin/git -json GO111MODULE x_amd64/vet D_/yfVVsRlKznoAR7GIxUgZ/8d2moSUn--jq (http block)
    • Triggering command: /usr/bin/gh gh run download 5 --dir test-logs/run-5 /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/vet /usr/bin/git k/gh-aw/gh-aw/.ggit -buildtags /usr/bin/git git merg�� origin/main feature-branch 64/pkg/tool/linux_amd64/link /tmp/gh-aw-test-git status /usr/bin/git 64/pkg/tool/linux_amd64/link (http block)
    • Triggering command: /usr/bin/gh gh run download 5 --dir test-logs/run-5 git /usr/bin/git --show-toplevel -extld=gcc /usr/bin/git git rev-�� --show-toplevel git /usr/bin/git --get remote.origin.urrev-parse /usr/bin/git git (http block)
  • https://api.github.com/repos/github/gh-aw/actions/workflows
    • Triggering command: /usr/bin/gh gh workflow list --json name,state,path ithub/workflows /tmp/go-build4216809629/b233/vet.cfg /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/vet 523882/b399/_pkggit GO111MODULE 64/bin/go /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linurev-parse -ato�� ithub/workflows -buildtags /home/REDACTED/.cargo/bin/git -errorsas -ifaceassert -nilfunc git (http block)
    • Triggering command: /usr/bin/gh gh workflow list --json name,state,path ACCEPT git /usr/bin/git 0118-32427/test-git 64/pkg/tool/linurev-parse 64/pkg/tool/linu--show-toplevel git rev-�� --show-toplevel 64/pkg/tool/linux_amd64/compile /usr/bin/git g_.a 64/pkg/tool/linu-w 0/x64/bin/node git (http block)
    • Triggering command: /usr/bin/gh gh workflow list --json name,state,path --show-toplevel git (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/a70c5eada06553e3510ac27f2c3bda9d3705bccb
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/a70c5eada06553e3510ac27f2c3bda9d3705bccb --jq .object.sha -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/v1.0.0
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.0.0 --jq .object.sha xterm-color x_amd64/vet /usr/bin/gh Repo GO111MODULE x_amd64/vet /usr/bin/gh api graphql -f /usr/bin/git -f owner=github -f git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.0.0 --jq .object.sha --show-toplevel ache/go/1.25.0/xmain ache/node/24.14.-lang=go1.25 7199194/b408/_pkgit ache/go/1.25.0/xrev-parse 7199194/b408=> git ache�� --show-toplevel nly /usr/bin/git fa6R/SYklXEUnLW-git git 0/x64/bin/node git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.0.0 --jq .object.sha --show-toplevel git /bin/sh add origin /usr/bin/git /bin/sh -c git-upload-pack 'origin' git-upload-pack 'origin' 0/x64/bin/node --show-toplevel git /usr/bin/git git (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/v1.2.3
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.2.3 --jq .object.sha ithub/workflows -tests er: String!, $name: String!) { repository(owne-f 6bpw/kCwzrebj4eQ/opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/cgo GO111MODULE DiscussionsEnabled } } git diff�� k/gh-aw/gh-aw/.github/workflows HEAD ache/go/1.25.0/x64/bin/node l **/*.cjs ed } } git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.2.3 --jq .object.sha --show-toplevel git /usr/bin/git bot-detection.md/opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/compile /test2.lock.yml 694700af8cfeef02/tmp/go-build2064961138/b001/_pkg_.a git rev-�� --show-toplevel ch /usr/bin/git --show-toplevel resolved$ /usr/bin/git git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.2.3 --jq .object.sha --show-toplevel bqUv72e6-_n3m/F_jFMYpq1JnIQtlrs8dO/uvoaxXZ6SdsIYvttU1Rk/at81KHObqUv72e6-_n3m /usr/bin/git ithub-script/gitnode git 4961138/b381/_pkg_.a git rev-�� --show-toplevel git /usr/bin/git -aw/git/ref/tagsgit git (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/v2.0.0
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v2.0.0 --jq .object.sha k/gh-aw/gh-aw/.github/workflows -tests me: String!) { repository(owner: $owner, name: $name) { hasDiscussionsEnabled } } -json GO111MODULE ed } } git diff�� k/gh-aw/gh-aw/.github/workflows HEAD 64/pkg/tool/linux_amd64/compile l **/*.cjs 64/bin/go 64/pkg/tool/linurev-parse (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v2.0.0 --jq .object.sha --noprofile -tests me: String!) { repository(owner: $owner, name: $name) { hasDiscussionsEnabled } } -json GO111MODULE 64/bin/go git diff�� k/gh-aw/gh-aw/.g-p HEAD 64/pkg/tool/linu-lang=go1.25 prettier --check DiscussionsEnabl/tmp/gh-aw-test-runs/20260311-000118-32427/test-429487208/.github/workflows 64/pkg/tool/linuconfig (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v2.0.0 --jq .object.sha ithub/workflows -tests n-dir/git l GO111MODULE 64/bin/go git diff�� --name-only HEAD 64/pkg/tool/linu-nilfunc prettier --check 64/bin/go 64/pkg/tool/linu-tests (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/v3.0.0
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v3.0.0 --jq .object.sha ithub/workflows -tests /home/REDACTED/.config/composer/vendor/bin/git l GO111MODULE 64/bin/go git diff�� --name-only HEAD er: String!, $na-nilfunc prettier --check 64/bin/go git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v3.0.0 --jq .object.sha --show-toplevel git /usr/bin/git --show-toplevel stmain.go ache/go/1.25.0/x/tmp/go-build2064961138/b001/cli.test git rev-�� --show-toplevel ache/go/1.25.0/x-w /usr/bin/git 7199194/b413/rep/opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/vet ache/go/1.25.0/x-atomic 7199194/b413/imp-bool git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v3.0.0 --jq .object.sha --show-toplevel 4961138/b411/stringutil.test /usr/bin/git t0 m0s 0/x64/bin/node git rev-�� --show-toplevel op.prop.prop.prop.prop.prop.pro /usr/bin/git k/gh-aw/gh-aw/.ggit git /opt/hostedtoolc/tmp/gh-aw-test-runs/20260311-000652-43684/test-204164198/.github/workflows git (http block)
  • https://api.github.com/repos/githubnext/agentics/git/ref/tags/
    • Triggering command: /usr/bin/gh gh api /repos/githubnext/agentics/git/ref/tags/# --jq .object.sha -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
  • https://api.github.com/repos/nonexistent/action/git/ref/tags/v999.999.999
    • Triggering command: /usr/bin/gh gh api /repos/nonexistent/action/git/ref/tags/v999.999.999 --jq .object.sha /home/REDACTED/work/gh-aw/gh-aw/.github/workflows config /usr/bin/git remote.origin.urgit GO111MODULE $name) { has--show-toplevel git -C 1702054926/.github/workflows rev-parse /usr/bin/git -json GO111MODULE ache/go/1.25.0/x--show-toplevel git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/nonexistent/action/git/ref/tags/v999.999.999 --jq .object.sha --show-toplevel git /usr/bin/git --show-toplevel ache/go/1.25.0/x-1 /usr/bin/git git rev-�� --show-toplevel git /usr/bin/git --show-toplevel bash 0/x64/bin/node git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/nonexistent/action/git/ref/tags/v999.999.999 --jq .object.sha --show-toplevel ache/node/24.14.0/x64/bin/node /usr/bin/git --get remote.origin.urrev-parse /usr/bin/git git merg�� origin/main feature-branch 0/x64/bin/node --show-toplevel git (http block)
  • https://api.github.com/repos/nonexistent/repo/actions/runs/12345
    • Triggering command: /usr/bin/gh gh run view 12345 --repo nonexistent/repo --json status,conclusion remote.origin.urgit GO111MODULE x_amd64/vet /usr/bin/gh api graphql -f /usr/bin/gh -f owner=github -f /usr/bin/gh (http block)
    • Triggering command: /usr/bin/gh gh run view 12345 --repo nonexistent/repo --json status,conclusion --show-toplevel git /usr/bin/git git rev-�� --show-toplevel git 0/x64/bin/node user.name Test User /usr/bin/git git (http block)
    • Triggering command: /usr/bin/gh gh run view 12345 --repo nonexistent/repo --json status,conclusion --show-toplevel git ache/node/24.14.--show-toplevel git rev-�� --show-toplevel ache/node/24.14.0/x64/bin/node /usr/bin/git --get remote.origin.urrev-parse /usr/bin/git git (http block)
  • https://api.github.com/repos/owner/repo/actions/workflows
    • Triggering command: /usr/bin/gh gh workflow list --json name,state,path --repo owner/repo (http block)
    • Triggering command: /usr/bin/gh gh workflow list --json name,state,path --repo owner/repo /opt/hostedtoolcache/uv/0.10.9/x86_64/git 523882/b394/_pkggit GO111MODULE ed } } git diff�� ithub/workflows HEAD /opt/pipx_bin/bash l GO111MODULE 64/bin/go bash (http block)
    • Triggering command: /usr/bin/gh gh workflow list --json name,state,path --repo owner/repo /usr/bin/git 01/test2.md 64/pkg/tool/linurev-parse /usr/bin/git git rev-�� --show-toplevel ortcfg /usr/bin/git ternal/tools/gengit ache/go/1.25.0/xdiff ache/go/1.25.0/x--name-only git (http block)
  • https://api.github.com/repos/owner/repo/contents/file.md
    • Triggering command: /tmp/go-build2307199194/b383/cli.test /tmp/go-build2307199194/b383/cli.test -test.testlogfile=/tmp/go-build2307199194/b383/testlog.txt -test.paniconexit0 -test.v=true -test.parallel=4 -test.timeout=10m0s -test.run=^Test -test.short=true -json GO111MODULE 64/bin/go ker/docker-init -ato�� ithub/workflows -buildtags 2105137/b123/vet.cfg a/action_pins.jsgit -ifaceassert -nilfunc cmp (http block)
    • Triggering command: /tmp/go-build2064961138/b001/cli.test /tmp/go-build2064961138/b001/cli.test -test.testlogfile=/tmp/go-build2064961138/b001/testlog.txt -test.paniconexit0 -test.timeout=10m0s patc�� --show-toplevel 64/pkg/tool/linux_amd64/compile /usr/bin/git 01/main.md 64/pkg/tool/linurev-parse /usr/bin/git git rev-�� --show-toplevel git /usr/bin/git AfU4Hzctr go ingutil.test git (http block)
    • Triggering command: /tmp/go-build1977792817/b363/cli.test /tmp/go-build1977792817/b363/cli.test -test.testlogfile=/tmp/go-build1977792817/b363/testlog.txt -test.paniconexit0 -test.timeout=10m0s rev-�� --show-toplevel git /usr/bin/git 16997430/001 git 694700af8cfeef02c93f918e git rev-�� --show-toplevel git /usr/bin/git runs/20260311-00node git ache/node/24.14.0/x64/bin/node git (http block)
  • https://api.github.com/repos/test-owner/test-repo/actions/secrets
    • Triggering command: /usr/bin/gh gh api /repos/test-owner/test-repo/actions/secrets --jq .secrets[].name -unreachable=false /tmp/go-build4216809629/b240/vet.cfg me: String!) { repository(owner: $owner, name: $name) { hasDiscussionsEnabled } } 523882/b373/_pkggit GO111MODULE ed } } /opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linuconfig -ato�� ithub/workflows -buildtags /opt/hostedtoolcache/node/24.14.0/x64/bin/git l -ifaceassert -nilfunc git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/test-owner/test-repo/actions/secrets --jq .secrets[].name --show-toplevel git /usr/bin/git 0118-32427/test-git 64/pkg/tool/linurev-parse 64/pkg/tool/linu--show-toplevel git rev-�� nPathSetup_GorootOrdering2033842455/001/go/1.25.0/x64"; export PATH="$(find "/tmp/TestGetNpmBinP/opt/hostedtoolcache/go/1.25.0/x64/pkg/tool/linux_amd64/vet 64/pkg/tool/linux_amd64/compile /usr/bin/git g_.a ache/go/1.25.0/xrev-parse 64/pkg/tool/linu--show-toplevel git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/test-owner/test-repo/actions/secrets --jq .secrets[].name --show-toplevel git /usr/bin/git --show-toplevel git /usr/bin/git git rev-�� --show-toplevel git /usr/bin/git runs/20260311-00node git /usr/bin/git git (http block)

If you need me to access, download, or install something from one of these locations, you can either:


🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.

Copilot AI and others added 4 commits March 10, 2026 23:41
Copilot AI changed the title [WIP] Add option to configure different repo for failure issues feat: add safe-outputs.failure-issue-repo to redirect failure issues to a different repo Mar 11, 2026
@pelikhan pelikhan marked this pull request as ready for review March 11, 2026 00:34
Copilot AI review requested due to automatic review settings March 11, 2026 00:34
@pelikhan pelikhan merged commit 5af0fee into main Mar 11, 2026
109 checks passed
@pelikhan pelikhan deleted the copilot/support-configure-failure-repo branch March 11, 2026 00:35
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds support for redirecting agent failure-tracking issues to a separate repository via a new safe-outputs.failure-issue-repo setting, addressing workflows in repositories where GitHub Issues are disabled.

Changes:

  • Introduces FailureIssueRepo in SafeOutputsConfig and parses it from workflow frontmatter.
  • Propagates the configured repo to the conclusion job via GH_AW_FAILURE_ISSUE_REPO.
  • Updates the agent failure handler to target the configured repository for issue search/create/comment operations, plus adds schema/docs entries.

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
pkg/workflow/compiler_types.go Adds FailureIssueRepo to SafeOutputsConfig.
pkg/workflow/safe_outputs_config.go Parses failure-issue-repo from safe-outputs frontmatter.
pkg/workflow/imports.go Merges FailureIssueRepo from imported configs (first-wins).
pkg/workflow/notify_comment.go Emits GH_AW_FAILURE_ISSUE_REPO into the conclusion job env when configured.
actions/setup/js/handle_agent_failure.cjs Uses GH_AW_FAILURE_ISSUE_REPO to override issue repo targeting and threads through parent issue creation.
pkg/parser/schemas/main_workflow_schema.json Adds schema support/validation for safe-outputs.failure-issue-repo.
docs/src/content/docs/reference/safe-outputs.md Documents the new failure-issue-repo option.
docs/src/content/docs/reference/glossary.md Adds glossary entry for failure-issue-repo.
Comments suppressed due to low confidence (1)

actions/setup/js/handle_agent_failure.cjs:714

  • There are existing unit tests for this module (handle_agent_failure.test.cjs), but none cover the new GH_AW_FAILURE_ISSUE_REPO override behavior. Add tests to verify: (1) valid owner/repo overrides are used for issue search/create/comment calls, and (2) invalid values fall back to context.repo with a warning.
    // Determine the target repository for failure issues
    // If GH_AW_FAILURE_ISSUE_REPO is set, use that repo instead of the current repo
    const failureIssueRepo = process.env.GH_AW_FAILURE_ISSUE_REPO || "";
    let owner, repo;
    if (failureIssueRepo && failureIssueRepo.includes("/")) {
      const parts = failureIssueRepo.split("/");
      owner = parts[0];
      repo = parts[1];
      core.info(`Using configured failure issue repo: ${owner}/${repo}`);
    } else {
      ({ owner, repo } = context.repo);
    }

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

Comment on lines +707 to +711
if (failureIssueRepo && failureIssueRepo.includes("/")) {
const parts = failureIssueRepo.split("/");
owner = parts[0];
repo = parts[1];
core.info(`Using configured failure issue repo: ${owner}/${repo}`);
Copy link

Copilot AI Mar 11, 2026

Choose a reason for hiding this comment

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

Parsing GH_AW_FAILURE_ISSUE_REPO with split("/") and taking the first two elements can silently mis-handle invalid values (e.g. owner/, /repo, or owner/repo/extra), leading to API calls against the wrong repo or to hard-to-diagnose failures. Recommend validating that the value matches exactly owner/repo (two non-empty segments, no extra /) and logging a warning + falling back to context.repo when invalid.

This issue also appears on line 703 of the same file.

Suggested change
if (failureIssueRepo && failureIssueRepo.includes("/")) {
const parts = failureIssueRepo.split("/");
owner = parts[0];
repo = parts[1];
core.info(`Using configured failure issue repo: ${owner}/${repo}`);
if (failureIssueRepo) {
const match = failureIssueRepo.match(/^([^/]+)\/([^/]+)$/);
if (match) {
owner = match[1];
repo = match[2];
core.info(`Using configured failure issue repo: ${owner}/${repo}`);
} else {
core.warning(
`Invalid GH_AW_FAILURE_ISSUE_REPO value "${failureIssueRepo}". Expected format "owner/repo". Falling back to context.repo.`
);
({ owner, repo } = context.repo);
}

Copilot uses AI. Check for mistakes.
Comment on lines +208 to +211
// Pass failure-issue-repo configuration (optional, defaults to current repo)
if data.SafeOutputs != nil && data.SafeOutputs.FailureIssueRepo != "" {
agentFailureEnvVars = append(agentFailureEnvVars, fmt.Sprintf(" GH_AW_FAILURE_ISSUE_REPO: %q\n", data.SafeOutputs.FailureIssueRepo))
}
Copy link

Copilot AI Mar 11, 2026

Choose a reason for hiding this comment

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

buildConclusionJob now conditionally emits GH_AW_FAILURE_ISSUE_REPO, but TestConclusionJob in notify_comment_test.go doesn't assert anything about this env var (it already checks other env vars like GH_AW_AGENT_CONCLUSION). Please add a unit test case that sets SafeOutputs.FailureIssueRepo and verifies the rendered conclusion job YAML includes GH_AW_FAILURE_ISSUE_REPO with the expected value.

Copilot uses AI. Check for mistakes.
Comment on lines +474 to +476
if failureIssueRepoStr, ok := failureIssueRepo.(string); ok && failureIssueRepoStr != "" {
config.FailureIssueRepo = failureIssueRepoStr
safeOutputsConfigLog.Printf("Failure issue repo: %s", failureIssueRepoStr)
Copy link

Copilot AI Mar 11, 2026

Choose a reason for hiding this comment

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

failure-issue-repo is accepted as any non-empty string, but downstream handle_agent_failure.cjs assumes an owner/repo format and splits on /. As-is, values like owner/, /repo, or owner/repo/extra will be propagated and can break or misdirect issue creation. Consider validating against the same ^[^/]+/[^/]+$ pattern here (and either ignore invalid values with a warning or return an explicit configuration error).

Suggested change
if failureIssueRepoStr, ok := failureIssueRepo.(string); ok && failureIssueRepoStr != "" {
config.FailureIssueRepo = failureIssueRepoStr
safeOutputsConfigLog.Printf("Failure issue repo: %s", failureIssueRepoStr)
if failureIssueRepoStr, ok := failureIssueRepo.(string); ok {
trimmed := strings.TrimSpace(failureIssueRepoStr)
if trimmed != "" {
parts := strings.Split(trimmed, "/")
if len(parts) == 2 && parts[0] != "" && parts[1] != "" {
config.FailureIssueRepo = trimmed
safeOutputsConfigLog.Printf("Failure issue repo: %s", trimmed)
} else {
safeOutputsConfigLog.Printf("Ignoring invalid failure-issue-repo %q; expected format owner/repo", failureIssueRepoStr)
}
}

Copilot uses AI. Check for mistakes.
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.

Support configuring a different repository for failure issues

3 participants