Skip to content

Run shared APM restore in pre-agent-steps to preserve skills in PR context#28002

Merged
pelikhan merged 3 commits intomainfrom
copilot/fix-skill-invocation-syntax
Apr 23, 2026
Merged

Run shared APM restore in pre-agent-steps to preserve skills in PR context#28002
pelikhan merged 3 commits intomainfrom
copilot/fix-skill-invocation-syntax

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Apr 23, 2026

PR-context workflows were restoring trusted base-branch .github after imported APM restore steps, which could overwrite APM-restored .github/skills before agent startup. This change moves shared APM restore to pre-agent execution so restored skills survive the PR hardening restore.

  • APM import ordering

    • Updated /.github/workflows/shared/apm.md to emit bundle restore under pre-agent-steps (instead of steps), so restore runs immediately before agent execution.
    • Updated inline docs in the same shared workflow to reflect the new execution phase.
  • Compiled workflow impact

    • Regenerated affected lock output where this import is used (smoke-claude.lock.yml) so APM restore now appears after PR base restore and before engine execution.
  • Regression coverage

    • Added a focused compiler test in pkg/workflow/compiler_pre_agent_steps_test.go asserting:
      1. Restore agent config folders from base branch
      2. imported Restore APM packages
      3. AI execution step
# shared/apm.md
pre-agent-steps:
  - name: Download APM bundle artifact
    uses: actions/download-artifact@v8.0.1
  - name: Restore APM packages
    uses: microsoft/apm-action@v1.4.1

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 gh repo view --json owner,name --jq .owner.login + "/" + .name 64/pkg/tool/linux_amd64/vet GOINSECURE boring/bbig ache/go/1.25.8/xuser.name 64/pkg/tool/linuTest User (http block)
    • Triggering command: /usr/bin/gh gh repo view owner/repo env 3893455376 .cfg 64/pkg/tool/linux_amd64/link GOINSECURE l GOMODCACHE 64/pkg/tool/linux_amd64/link -c ger.test FnMM/DTE1YZYN5-LgmGb0FnMM ortcfg.link -n1 b/gh-aw/pkg/acti-1 --end-of-optionsxterm-color 9Ym34G_sfJyM6o-Ioz/mT-tLcfK0hMgkrev-parse (http block)
    • Triggering command: /usr/bin/gh gh repo view owner/repo env 3893455376 wDwi/8TvZlM4P0nfuVfRvwDwi .cfg GOINSECURE g/x/net/idna GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linux_amd64/compile -c 1505289/b395/_pkg_.a zLU2/r48K25Cv2sXeJpt1zLU2 .cfg -n1 --format=format:remote --end-of-options-v ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet (http block)
  • https://api.github.com/orgs/test-owner/actions/secrets
    • Triggering command: /usr/bin/gh gh api /orgs/test-owner/actions/secrets --jq .secrets[].name -json GO111MODULE x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile env -json gset/set.go x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh api /orgs/test-owner/actions/secrets --jq .secrets[].name '**/*.ts' '**/*.GOINSECURE GO111MODULE ache/go/1.25.8/xGOMODCACHE GOINSECURE GOMOD GOMODCACHE go env .js' --ignore-paGOINSECURE GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go (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, .object.type] | @tsv -v 64/pkg/tool/linu-buildtags /usr/bin/git 3822436030/.githgit .cfg 64/pkg/tool/linu--show-toplevel git -C /tmp/gh-aw-test-runs/20260423-065809-35015/test-2675785085 rev-parse /usr/bin/git 105839607/.githunode .cfg ache/go/1.25.8/xinstall git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/ai-inference/git/ref/tags/v1 --jq [.object.sha, .object.type] | @tsv -v 606399/b440/importcfg /usr/bin/git che/go-build/4c/git GOPROXY 64/bin/go git rev-�� --show-toplevel /opt/hostedtoolcache/go/1.25.8/xremote /usr/bin/git ut2362721795/001node -trimpath 64/pkg/tool/linuinstall git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/ai-inference/git/ref/tags/v1 --jq [.object.sha, .object.type] | @tsv --get-regexp ^remote\..*\.gh-resolved$ /usr/bin/git y.md GOPROXY 64/bin/go git rev-�� --show-toplevel go /usr/bin/git mpiledOutput6570node GO111MODULE 64/pkg/tool/linuinstall 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, .object.type] | @tsv GOMODCACHE x_amd64/compile /opt/hostedtoolcache/go/1.25.8/x64/pkg/tool/linux_amd64/link -json GO111MODULE x_amd64/vet /opt/hostedtoolcache/go/1.25.8/x64/pkg/tool/linux_amd64/link -o /tmp/go-build2201505289/b447/stringutil.test -importcfg /usr/bin/git -s -w -buildmode=exe git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v3 --jq [.object.sha, .object.type] | @tsv GOMODCACHE go om/org2/repo.git -json GO111MODULE 64/bin/go gh api /repos/github/gh-aw/git/ref/tags/v2.0.0 --jq (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v3 --jq [.object.sha, .object.type] | @tsv /tmp/compile-all-instructions-test-2439003169/.github/workflows l /usr/bin/git remote.origin.urgit GO111MODULE 64/bin/go git rev-�� --show-toplevel 979e5b95 /usr/bin/git -json GO111MODULE 64/bin/go 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, .object.type] | @tsv 1219833/b202/importcfg -trimpath ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet -p strings -lang=go1.25 ache/go/1.25.8/x--name-only -o st-1733891716/.github/workflows -trimpath 1/x64/bin/node -p compress/gzip -lang=go1.25 /opt/hostedtoolcache/go/1.25.8/x64/pkg/tool/linux_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v5 --jq [.object.sha, .object.type] | @tsv --show-toplevel ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet /usr/bin/git se 1505289/b060/vet\n x_amd64/link git rev-�� --show-toplevel x_amd64/link /usr/bin/git 5809-35015/test-git k/gh-aw/gh-aw/pkrev-parse ache/go/1.25.8/x--show-toplevel git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v5 --jq [.object.sha, .object.type] | @tsv --show-toplevel git /usr/bin/git --bare l 1505289/b452/tes--show-toplevel git 1/x6�� --show-toplevel 1505289/b452/testutil.test /usr/bin/git t0 remote (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, .object.type] | @tsv ithub/workflows/archie.md config /usr/bin/git l ii/equal_fold.gorev-parse x_amd64/compile git remo�� GOMODCACHE (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v6 --jq [.object.sha, .object.type] | @tsv uts.version git-receive-pack '/tmp/TestParseDefaultBranchFromLsRemoteWithRealGitbranch_with_hyphen1403132286rev-parse /usr/bin/git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/checkout/git/ref/tags/v6 --jq [.object.sha, .object.type] | @tsv ErrorFormatting3296442922/001 --format=%(objectname) /usr/bin/git '**/*.ts' '**/*.git GO111MODULE ache/go/1.25.8/x--show-toplevel git -C /tmp/TestGuardPolicyBlockedUsersCommaSeparatedCompiledOutput695549847/001 rev-parse /opt/hostedtoolcache/node/24.14.1/x64/bin/node .js' --ignore-pagit GO111MODULE 64/bin/go node (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, .object.type] | @tsv --show-toplevel ache/go/1.25.8/x64/pkg/tool/linuremote1 /usr/bin/git RequiresMinInteggit 1505289/b254/vetcommit ache/go/1.25.8/x-m git rev-�� --show-toplevel ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet /usr/bin/git /v1.2.3 /tmp/go-build220rev-parse sv git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v8 --jq [.object.sha, .object.type] | @tsv --show-toplevel go /usr/bin/git 0309-57875/test-git GO111MODULE ache/go/1.25.8/x-m git rev-�� --show-toplevel go /usr/bin/git 0309-57875/test-git GO111MODULE /opt/hostedtoolc--show-toplevel git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v8 --jq [.object.sha, .object.type] | @tsv --show-toplevel go /usr/bin/git 0954-78249/test-git GO111MODULE ache/go/1.25.8/x-m git rev-�� --show-toplevel go /usr/bin/git -json GO111MODULE /opt/hostedtoolc--show-toplevel git (http block)
  • https://api.github.com/repos/actions/github-script/git/ref/tags/v9
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v9 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE x_amd64/asm GOINSECURE GOMOD GOMODCACHE x_amd64/asm env -json GO111MODULE x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v9 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/github-script/git/ref/tags/v9 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile env -json GO111MODULE x_amd64/vet GOINSECURE dules/flatted/go-C GOMODCACHE x_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, .object.type] | @tsv GOMODCACHE x_amd64/vet /usr/bin/git ortcfg .cfg 64/pkg/tool/linu--show-toplevel /usr/bin/git conf�� --get-regexp ^remote\..*\.gh-resolved$ /usr/bin/git ortcfg GO111MODULE 64/pkg/tool/linu--show-toplevel git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-go/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv --show-toplevel go /usr/bin/git -json GO111MODULE 64/bin/go git rev-�� --show-toplevel sh /usr/bin/git itmain_branch397git itmain_branch397rev-parse 64/bin/go git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-go/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv --git-dir go /usr/bin/git -json GO111MODULE 64/bin/go git init�� GOMODCACHE sh /usr/bin/git 78/001/test-compgit GOPROXY 64/bin/go 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, .object.type] | @tsv ithub/workflows/architecture-guardian.md (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-node/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv --show-toplevel x_amd64/compile /usr/bin/infocmp ortcfg .cfg x_amd64/compile infocmp -1 xterm-color x_amd64/compile /usr/bin/git ty-test.md .cfg 64/pkg/tool/linu--show-toplevel git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/setup-node/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv ErrorFormatting2574521288/001 -q /usr/bin/git '**/*.ts' '**/*.git GO111MODULE 64/bin/sh git rev-�� s/test.md go /usr/bin/git .js' --ignore-pagit GO111MODULE 64/bin/go 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, .object.type] | @tsv GOMODCACHE x_amd64/compile ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet -json GO111MODULE x_amd64/compile ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet api /repos/actions/github-script/git/ref/tags/v9 --jq /usr/bin/git -json GO111MODULE x_amd64/compile git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/upload-artifact/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv for-each-ref --format=%(objectname) /usr/bin/git -json GO111MODULE ache/go/1.25.8/x--show-toplevel git rev-�� --show-toplevel int is not instaGO111MODULE /usr/bin/git 37f17047004cd687git GO111MODULE 64/pkg/tool/linu--show-toplevel git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/actions/upload-artifact/git/ref/tags/v4 --jq [.object.sha, .object.type] | @tsv GOMODCACHE go /usr/bin/git -json GO111MODULE ache/go/1.25.8/x--show-toplevel git -C /tmp/gh-aw-test-runs/20260423-070954-78249/test-896874140/.github/workflows remote /usr/bin/gh */*.ts' '**/*.jsgit GO111MODULE 64/bin/go gh (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, .object.type] | @tsv --show-toplevel git $name) { hasDiscussionsEnabled } } --git-dir x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/astral-sh/setup-uv/git/ref/tags/eac588ad8def6316056a12d4907a9d4d84ff7a3b --jq [.object.sha, .object.type] | @tsv --show-toplevel git /usr/bin/git --git-dir x_amd64/vet /usr/bin/git git rev-�� --show-toplevel git /usr/bin/git GOMODCACHE x_amd64/vet /usr/bin/git git (http block)
  • https://api.github.com/repos/github/gh-aw-actions/git/ref/tags/v0.1.2
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v0.1.2 --jq [.object.sha, .object.type] | @tsv --git-dir x_amd64/vet /opt/hostedtoolcache/node/24.14.1/x64/bin/node -json .cfg 64/pkg/tool/linu--show-toplevel node /tmp�� /home/REDACTED/work/gh-aw/gh-aw/.github/workflows/artifacts-summary.md 64/pkg/tool/linuInitial commit /usr/bin/git mLsRemoteWithReagit mLsRemoteWithRearev-parse 64/pkg/tool/linu--show-toplevel /usr/bin/git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v0.1.2 --jq [.object.sha, .object.type] | @tsv --show-toplevel go /usr/bin/infocmp -json GO111MODULE 64/bin/go infocmp -1 xterm-color sh /usr/bin/git hub/workflows GOPROXY 64/bin/go /usr/bin/git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v0.1.2 --jq [.object.sha, .object.type] | @tsv --show-toplevel go /usr/bin/git -json GO111MODULE 64/bin/go git rev-�� --show-toplevel sh /usr/bin/docker 78/001/test-simpgit GOPROXY 64/bin/go docker (http block)
  • https://api.github.com/repos/github/gh-aw-actions/git/ref/tags/v1.0.0
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v1.0.0 --jq [.object.sha, .object.type] | @tsv ons-test4075197393 remote /usr/bin/git -json o x_amd64/compile git -C /tmp/gh-aw-test-runs/20260423-065809-35015/test-3893455376 url /usr/bin/git 01 1.5.0/mcp/clientrev-parse x_amd64/compile git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v1.0.0 --jq [.object.sha, .object.type] | @tsv --objects l e/git --exclude-hiddengit --all --quiet e/git -C /tmp/gh-aw-test-runs/20260423-070309-57875/test-541704180/.github/workflows config /usr/bin/git remote.origin.urgit yphen1403132286/rev-parse 64/bin/go git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v1.0.0 --jq [.object.sha, .object.type] | @tsv git-upload-pack '/tmp/TestParseDefaultBranchFromLsRemoteWithRealGitmaster_branch2691578356/001' (http block)
  • https://api.github.com/repos/github/gh-aw-actions/git/ref/tags/v1.2.3
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v1.2.3 --jq [.object.sha, .object.type] | @tsv /tmp/gh-aw-test-runs/20260423-065809-35015/test-1524678894/.gith--detach stmain.go ache/go/1.25.8/x64/pkg/tool/linux_amd64/compile -json GO111MODULE x_amd64/compile ache/go/1.25.8/x64/pkg/tool/linux_amd64/compile 3752�� --show-toplevel x_amd64/compile ipts.test 1 1.5.0/oauthex/aurev-parse x_amd64/compile ipts.test (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v1.2.3 --jq [.object.sha, .object.type] | @tsv --all-progress-implied l /opt/hostedtoolcache/node/24.14.1/x64/bin/node --thin --delta-base-offrev-parse -q node /tmp�� /tmp/TestHashConsistency_WithImports2754938381/001/main.md go kflow.test -json GO111MODULE 64/bin/go kflow.test (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw-actions/git/ref/tags/v1.2.3 --jq [.object.sha, .object.type] | @tsv run --auto /usr/bin/git --detach GO111MODULE tions/setup/js/n--show-toplevel git rev-�� --git-dir go kflow.test -json GO111MODULE 64/bin/go kflow.test (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/1/artifacts
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/1/artifacts --jq .artifacts[].name GO111MODULE 64/pkg/tool/linu-nolocalimports GOINSECURE GOMOD 1219833/b013/sym-pack 64/pkg/tool/linu/tmp/go-build2201505289/b452/_testmain.go env 1219833/b221/_pkg_.a V7o_/18xeupG6XnJInX8DV7o_ .cfg GOINSECURE g/x/net/http/httrev-parse GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linu-goversion (http block)
    • Triggering command: /usr/bin/gh gh run download 1 --dir test-logs/run-1 .cfg 64/pkg/tool/linux_amd64/vet GOINSECURE entropy GOMODCACHE 64/pkg/tool/linux_amd64/vet env 1219833/b235/_pkg_.a h5RJ/fhSiz4P0ozPJ9_2Hh5RJ ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet GOINSECURE osh-tekuri/jsonsrev-parse GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linu--jq (http block)
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/1/artifacts --jq .artifacts[].name GOPROXY 64/bin/go GOSUMDB GOWORK 64/bin/go /opt/hostedtoolcache/go/1.25.8/xremote -o y_with_repos=public_971321555/001 -trimpath ache/go/1.25.8/x64/bin/go -p main -lang=go1.25 go (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/12345/artifacts
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/12345/artifacts --jq .artifacts[].name GO111MODULE 64/pkg/tool/linux_amd64/vet GOINSECURE fips140 GOMODCACHE 64/pkg/tool/linuTest User env 1219833/b217/_pkg_.a .cfg .cfg GOINSECURE g/x/text/transforev-parse GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh run download 12345 --dir test-logs/run-12345 GO111MODULE 64/pkg/tool/linux_amd64/vet GOINSECURE fips140/hmac GOMODCACHE 64/pkg/tool/linux_amd64/vet env 1219833/b223/_pkg_.a go .cfg GOINSECURE GOMOD GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linu-buildtags (http block)
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/12345/artifacts --jq .artifacts[].name GOPROXY 64/bin/go GOSUMDB GOWORK 64/bin/go /opt/hostedtoolcache/go/1.25.8/xremote.origin.url -V=f�� 541704180/.github/workflows node ache/go/1.25.8/x64/bin/go --write ../../../**/*.jsinit 64/bin/go go (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/12346/artifacts
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/12346/artifacts --jq .artifacts[].name GO111MODULE 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linutest@example.com env 1219833/b218/_pkg_.a hxms/bWOB0OjYPOs06SIChxms .cfg GOINSECURE g/x/text/unicoderev-parse GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh run download 12346 --dir test-logs/run-12346 GO111MODULE 64/pkg/tool/linux_amd64/vet GOINSECURE /unix GOMODCACHE 64/pkg/tool/linuTest User env 3893455376 .cfg 64/pkg/tool/linux_amd64/link GOINSECURE l GOMODCACHE 64/pkg/tool/linux_amd64/link (http block)
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/12346/artifacts --jq .artifacts[].name GOPROXY 64/bin/go GOSUMDB GOWORK 64/bin/go /opt/hostedtoolcorigin -V=f�� 01/main.md node 64/pkg/tool/linux_amd64/link --write ../../../**/*.jsrev-parse 64/bin/go 64/pkg/tool/linux_amd64/link (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/2/artifacts
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/2/artifacts --jq .artifacts[].name om/modelcontextprotocol/go-sdk@v-nolocalimports 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linux_amd64/vet env 1219833/b234/_pkg_.a oYmy/n_pwg_VDfKQLamLkoYmy .cfg GOINSECURE GOMOD GOMODCACHE ache/go/1.25.8/x/tmp/go-build2201505289/b115/vet.cfg (http block)
    • Triggering command: /usr/bin/gh gh run download 2 --dir test-logs/run-2 .cfg 64/pkg/tool/linu-lang=go1.25 GOINSECURE 1219833/b012/comrev-parse ache/go/1.25.8/x--show-toplevel 64/pkg/tool/linu-goversion env 105839607/.githu-c=4 BHdz/-6z_QJDvZKL-nolocalimports ache/go/1.25.8/x-importcfg GOINSECURE t/internal/numberev-parse GOMODCACHE ache/go/1.25.8/x/home/REDACTED/work/gh-aw/gh-aw/pkg/typeutil/convert_test.go (http block)
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/2/artifacts --jq .artifacts[].name mLsRemoteWithRealGitcustom_branch2599151099/001' 64/bin/go GOSUMDB GOWORK 64/bin/go /opt/hostedtoolcache/go/1.25.8/xrev-parse -o y_with_repos=public_971321555/001 -trimpath ache/go/1.25.8/x64/bin/go -p main -lang=go1.25 go (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/3/artifacts
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/3/artifacts --jq .artifacts[].name .cfg 64/pkg/tool/linu-importcfg GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linu/home/REDACTED/work/gh-aw/gh-aw/pkg/timeutil/format_test.go env 1219833/b214/_pkg_.a k-ff/hcoMcb4nJlDk1Ubnk-ff k GOINSECURE g/x/net/http/httinit GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linu-trimpath (http block)
    • Triggering command: /usr/bin/gh gh run download 3 --dir test-logs/run-3 .cfg 64/pkg/tool/linux_amd64/vet GOINSECURE fips140/aes/gcm ache/go/1.25.8/x--show-toplevel 64/pkg/tool/linux_amd64/vet env 1647940562/custom/workflows ho52/RILG8Ja3npv64jHUho52 ache/go/1.25.8/x64/pkg/tool/linu-nolocalimports GOINSECURE th2/internal GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linu/tmp/go-build2201505289/b431/_testmain.go (http block)
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/3/artifacts --jq .artifacts[].name GOPROXY 64/bin/go GOSUMDB GOWORK 64/bin/go /opt/hostedtoolcache/go/1.25.8/xconfig -o /tmp/go-build912606399/b421/_pkgremote.origin.url -trimpath ache/go/1.25.8/x64/bin/go -p main -lang=go1.25 go (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/4/artifacts
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/4/artifacts --jq .artifacts[].name .cfg 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD 1219833/b013/symuser.name 64/pkg/tool/linuTest User env 1219833/b242/_pkg_.a 1219833/b013/importcfg ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet GOINSECURE t/internal/tag GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linu/tmp/file-tracker-test870158488/test2.lock.yml (http block)
    • Triggering command: /usr/bin/gh gh run download 4 --dir test-logs/run-4 .cfg 64/pkg/tool/linux_amd64/vet GOINSECURE sysrand GOMODCACHE 64/pkg/tool/linux_amd64/vet env 1219833/b236/_pkg_.a REzZ/UVSmm-gThuyfG0BeREzZ ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet GOINSECURE osh-tekuri/jsonsrev-parse GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linushow (http block)
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/4/artifacts --jq .artifacts[].name GOPROXY 64/bin/go GOSUMDB GOWORK 64/bin/go /opt/hostedtoolcache/go/1.25.8/x64/pkg/tool/linuGO111MODULE -o y_with_repos_array_c1129674618/001 -trimpath 64/bin/go -p main -lang=go1.25 go (http block)
  • https://api.github.com/repos/github/gh-aw/actions/runs/5/artifacts
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/5/artifacts --jq .artifacts[].name .cfg 64/pkg/tool/linux_amd64/vet GOINSECURE hlite GOMODCACHE 64/pkg/tool/linutest@example.com env 4289926047/.github/workflows _zAe/m6K4S-499xrKjIdi_zAe ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet GOINSECURE t/internal/strin/tmp/js-hash-test-803826877/test-hash.js GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linu-buildtags (http block)
    • Triggering command: /usr/bin/gh gh run download 5 --dir test-logs/run-5 .cfg 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD 1219833/b029/sym--show-toplevel 64/pkg/tool/linux_amd64/vet env 1219833/b225/_pkg_.a DUdE/2oEXO76xEThYfB4YDUdE ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet GOINSECURE ce GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api --paginate repos/{owner}/{repo}/actions/runs/5/artifacts --jq .artifacts[].name GOPROXY 64/bin/go GOSUMDB GOWORK 64/bin/go /opt/hostedtoolcache/go/1.25.8/xremote -o y_with_repos_array_c1129674618/001 -trimpath ache/go/1.25.8/x64/bin/go -p main -lang=go1.25 go (http block)
  • https://api.github.com/repos/github/gh-aw/actions/workflows
    • Triggering command: /usr/bin/gh gh workflow list --json name,state,path 835577141/001' 835577141/001' -importcfg /tmp/go-build2201505289/b419/importcfg -pack /home/REDACTED/work/gh-aw/gh-aw/pkg/fileutil/fileutil.go /home/REDACTED/work/gh-aw/gh-aw/pkg/fileutil/tar.go env -json age/common.go x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh run list --json databaseId,number,url,status,conclusion,workflowName,createdAt,startedAt,updatedAt,event,headBranch,headSha,displayTitle --workflow nonexistent-workflow-12345 --limit 100 GOMOD GOMODCACHE x_amd64/vet env json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh run list --json databaseId,number,url,status,conclusion,workflowName,createdAt,startedAt,updatedAt,event,headBranch,headSha,displayTitle --workflow nonexistent-workflow-12345 --limit 6 lite GOMODCACHE 64/pkg/tool/linux_amd64/vet env b/workflows GO111MODULE 64/pkg/tool/linux_amd64/vet GOINSECURE g/x/crypto/cryptremote 1219833/b006/symabis 64/pkg/tool/linux_amd64/vet (http block)
  • https://api.github.com/repos/github/gh-aw/contents/.github/workflows/shared/reporting.md
    • Triggering command: /tmp/go-build2201505289/b404/cli.test /tmp/go-build2201505289/b404/cli.test -test.testlogfile=/tmp/go-build2201505289/b404/testlog.txt -test.paniconexit0 -test.v=true -test.parallel=4 -test.timeout=10m0s -test.run=^Test -test.short=true GOINSECURE GOMOD GOMODCACHE x_amd64/compile env -json GO111MODULE x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile (http block)
    • Triggering command: /tmp/go-build3983126371/b404/cli.test /tmp/go-build3983126371/b404/cli.test -test.testlogfile=/tmp/go-build3983126371/b404/testlog.txt -test.paniconexit0 -test.v=true -test.parallel=4 -test.timeout=10m0s -test.run=^Test -test.short=true GOINSECURE GOMOD GOMODCACHE go env '**/*.ts' '**/*.GOINSECURE GO111MODULE n-dir/node GOINSECURE GOMOD GOMODCACHE go (http block)
    • Triggering command: /tmp/go-build2215512071/b404/cli.test /tmp/go-build2215512071/b404/cli.test -test.testlogfile=/tmp/go-build2215512071/b404/testlog.txt -test.paniconexit0 -test.v=true -test.parallel=4 -test.timeout=10m0s -test.run=^Test -test.short=true GOINSECURE GOMOD GOMODCACHE go env '**/*.ts' '**/*.GOINSECURE GO111MODULE ache/go/1.25.8/xGOMODCACHE GOINSECURE GOMOD GOMODCACHE go (http block)
  • https://api.github.com/repos/github/gh-aw/git/ref/tags/v0.47.4
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v0.47.4 --jq [.object.sha, .object.type] | @tsv xterm-color x_amd64/link /usr/bin/git se 1505289/b087/vetrev-parse ache/go/1.25.8/x--show-toplevel git rev-�� --show-toplevel hz/8-8vmLiYCmHH9yLNKNaz/ITCHFh6Rtest@example.com /usr/bin/git st-1733891716 -trimpath 1/x64/bin/node git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v0.47.4 --jq [.object.sha, .object.type] | @tsv it/ref/tags/v4 go sv -json GO111MODULE ache/go/1.25.8/x--show-toplevel git rev-�� --show-toplevel go /usr/bin/git -json GO111MODULE /opt/hostedtoolc/tmp/gh-aw/aw-feature-branch.patch git (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v0.47.4 --jq [.object.sha, .object.type] | @tsv it/ref/tags/v4 go sv -json GO111MODULE ache/go/1.25.8/x--show-toplevel git rev-�� --show-toplevel go /usr/bin/git 0954-78249/test-ls GO111MODULE /opt/hostedtoolc/tmp/gh-aw/aw-feature-branch.patch git (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, .object.type] | @tsv se 1505289/b007/vet.cfg ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.0.0 --jq [.object.sha, .object.type] | @tsv b/workflows GO111MODULE 1/x64/bin/node GOINSECURE GOMOD GOMODCACHE go t-ha�� ai-moderator.md GO111MODULE 1/x64/bin/node json; \ echo "�git GOMOD GOMODCACHE go (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.0.0 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linux_amd64/vet env -json GO111MODULE 1/x64/bin/node GOINSECURE GOMOD GOMODCACHE go (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, .object.type] | @tsv go GO111MODULE x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile env -json at.go x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.2.3 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go env heck '**/*.cjs' '**/*.ts' '**/*.GOINSECURE GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v1.2.3 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go env heck '**/*.cjs' --repo GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go (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, .object.type] | @tsv -json GO111MODULE x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile env -json dfe61cbd0b1e6ea8--all x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v2.0.0 --jq [.object.sha, .object.type] | @tsv -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)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v2.0.0 --jq [.object.sha, .object.type] | @tsv bytealg/indexbyte_wasm.s GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet _bra�� g_.a @v1.1.3/base64/base64.go x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (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, .object.type] | @tsv -json GO111MODULE x_amd64/link GOINSECURE mcpgodebug GOMODCACHE x_amd64/link env -json GO111MODULE x_amd64/vet GOINSECURE GOMOD GOMODCACHE x_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/github/gh-aw/git/ref/tags/v3.0.0 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go ache�� -json GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE erignore (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, .object.type] | @tsv se 1505289/b013/vet.cfg ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet GOINSECURE 1219833/b133/ariinit ache/go/1.25.8/x64/src/math/big/--show-toplevel ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet -p 20/001/test-frontmatter-with-nested-objects.md -trimpath .cfg -I /tmp/go-build341-1 -I ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh api /repos/nonexistent/action/git/ref/tags/v999.999.999 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE ache/go/1.25.8/x64/bin/go GOINSECURE GOMOD GOMODCACHE go env -json GO111MODULE 1/x64/bin/node GOINSECURE GOMOD GOMODCACHE go (http block)
    • Triggering command: /usr/bin/gh gh api /repos/nonexistent/action/git/ref/tags/v999.999.999 --jq [.object.sha, .object.type] | @tsv -json GO111MODULE ache/go/1.25.8/x64/bin/go GOINSECURE GOMOD GOMODCACHE go env api-consumption-report.md GO111MODULE ache/go/1.25.8/x64/bin/go GOINSECURE GOMOD GOMODCACHE go (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 GOINSECURE 1219833/b133/ GOMODCACHE 64/pkg/tool/linux_amd64/vet (http block)
    • Triggering command: /usr/bin/gh gh run view 12345 --repo nonexistent/repo --json status,conclusion --ignore-path .prettierignore 64/bin/go go env -json GO111MODULE ache/go/1.25.8/x64/bin/go GOINSECURE GOMOD GOMODCACHE go (http block)
    • Triggering command: /usr/bin/gh gh run view 12345 --repo nonexistent/repo --json status,conclusion --ignore-path .prettierignore 64/bin/go go env -json GO111MODULE 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linux_amd64/vet (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 x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile env -json GO111MODULE x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh workflow list --json name,state,path --repo owner/repo x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile env -json age/compact/comp-ifaceassert x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh workflow list --repo owner/repo --json name,path,state 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linux_amd64/vet -V=f�� 1219833/b083/importcfg -Eee/499QsILxkBjFfa_H-Eee .cfg GOSUMDB GOWORK 64/bin/go ache/go/1.25.8/x^remote\..*\.gh-resolved$ (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 35577141/001' 35577141/001' x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile env -json GO111MODULE x_amd64/compile GOINSECURE GOMOD GOMODCACHE x_amd64/compile (http block)
    • Triggering command: /usr/bin/gh gh api /repos/test-owner/test-repo/actions/secrets --jq .secrets[].name '**/*.ts' '**/*.GOINSECURE GO111MODULE ache/go/1.25.8/xGOMODCACHE GOINSECURE GOMOD GOMODCACHE go env .js' --ignore-paGOINSECURE GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go (http block)
    • Triggering command: /usr/bin/gh gh api /repos/test-owner/test-repo/actions/secrets --jq .secrets[].name d GO111MODULE ache/go/1.25.8/xGOMODCACHE GOINSECURE GOMOD GOMODCACHE go env .js' --ignore-paGOINSECURE GO111MODULE 64/bin/go GOINSECURE GOMOD GOMODCACHE go (http block)
  • https://api.github.com/repos/test/repo
    • Triggering command: /usr/bin/gh gh api /repos/test/repo --jq .default_branch 1219833/b235/_pkg_.a h5RJ/fhSiz4P0ozPJ9_2Hh5RJ ache/go/1.25.8/x64/pkg/tool/linux_amd64/vet GOINSECURE osh-tekuri/jsonsrev-parse GOMODCACHE ache/go/1.25.8/x64/pkg/tool/linu--jq (http block)
    • Triggering command: /usr/bin/gh gh api /repos/test/repo --jq .default_branch edOutput1607130974/001 GO111MODULE 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linux_amd64/vet env -json GO111MODULE ache/go/1.25.8/x64/bin/go GOINSECURE GOMOD GOMODCACHE go (http block)
    • Triggering command: /usr/bin/gh gh api /repos/test/repo --jq .default_branch mpiledOutput695549847/001 GO111MODULE 64/pkg/tool/linux_amd64/vet GOINSECURE GOMOD GOMODCACHE 64/pkg/tool/linux_amd64/vet env -json GO111MODULE ache/go/1.25.8/x64/bin/go GOINSECURE GOMOD GOMODCACHE go (http block)

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

Copilot AI changed the title [WIP] Fix skill invocation syntax for APM-restored skills Run shared APM restore in pre-agent-steps to preserve skills in PR context Apr 23, 2026
Copilot AI requested a review from pelikhan April 23, 2026 07:13
@pelikhan pelikhan marked this pull request as ready for review April 23, 2026 12:01
Copilot AI review requested due to automatic review settings April 23, 2026 12:01
Copy link
Copy Markdown
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

Moves shared APM restore steps into the pre-agent-steps execution phase so PR-context hardening (restoring trusted base-branch .github) no longer overwrites APM-restored .github/skills before the agent runs.

Changes:

  • Update shared APM import (.github/workflows/shared/apm.md) to emit restore steps under pre-agent-steps instead of steps.
  • Regenerate compiled workflow output so APM restore occurs after PR base restore and before AI execution (.github/workflows/smoke-claude.lock.yml).
  • Add a compiler regression test asserting the correct ordering in PR context (pkg/workflow/compiler_pre_agent_steps_test.go).
Show a summary per file
File Description
pkg/workflow/compiler_pre_agent_steps_test.go Adds a regression test to enforce step ordering in PR context (base restore → imported pre-agent restore → AI execution).
.github/workflows/smoke-claude.lock.yml Updates compiled workflow so APM restore happens in the intended phase/order.
.github/workflows/shared/apm.md Moves shared APM restore content to pre-agent-steps and adjusts surrounding comments/docs (one doc section still needs wording updates).

Copilot's findings

Tip

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

Comments suppressed due to low confidence (1)

.github/workflows/shared/apm.md:93

  • This documentation block still refers to the agent job downloading/unpacking the APM bundle as pre-agent-steps, but the workflow now runs those restore steps under pre-agent-steps (see the frontmatter key above). Please update the wording here (including the “Unpack” bullet) to match pre-agent-steps so the docs reflect the new execution phase.
These packages are installed via a dedicated "apm" job that packs and uploads a bundle,
which the agent job then downloads and unpacks as pre-agent-steps.

### How it works

1. **Pack** (`apm` job): `microsoft/apm-action` installs packages and creates a bundle archive,
   uploaded as a GitHub Actions artifact.
2. **Unpack** (agent job pre-agent-steps): the bundle is downloaded and unpacked via
   `microsoft/apm-action` in restore mode, making all skills and tools available to the AI agent.
  • Files reviewed: 3/3 changed files
  • Comments generated: 1

Comment on lines 5 to +7
# This shared workflow creates a dedicated "apm" job (depending on activation) that
# packs packages using microsoft/apm-action and uploads the bundle as an artifact.
# The agent job then downloads and unpacks the bundle as pre-steps.
# The agent job then downloads and unpacks the bundle as pre-agent-steps.
Copy link

Copilot AI Apr 23, 2026

Choose a reason for hiding this comment

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

The header comment says the agent job unpacks the bundle as pre-agent-steps, but this PR changes the restore to run as pre-agent-steps. Please update this comment to avoid confusion about which phase runs the APM restore steps.

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

Copilot uses AI. Check for mistakes.
@github-actions
Copy link
Copy Markdown
Contributor

🧪 Test Quality Sentinel Report

Test Quality Score: 100/100

Excellent test quality

Metric Value
New/modified tests analyzed 1
✅ Design tests (behavioral contracts) 1 (100%)
⚠️ Implementation tests (low value) 0 (0%)
Tests with error/edge cases 1 (100%)
Duplicate test clusters 0
Test inflation detected No
🚨 Coding-guideline violations 0

Test Classification Details

Test File Classification Issues Detected
TestImportedPreAgentStepsRunAfterPRBaseRestore pkg/workflow/compiler_pre_agent_steps_test.go:125 ✅ Design None

Test Analysis

TestImportedPreAgentStepsRunAfterPRBaseRestore

Classification: Design test (behavioral contract)

Design invariant enforced: Step ordering guarantee — when a shared workflow with pre-agent-steps is imported in a PR-trigger context, those imported steps must execute after the PR base restore step and before the AI execution step. This is a correctness invariant users rely on for their skill/APM setup to work.

Error/edge case coverage: The test checks that all three expected step names are present in the generated lock file (failing fast with t.Fatal if any is missing), then asserts two ordering constraints with descriptive error messages including the actual indices. Both error paths and the ordering invariant are covered.

Assertion messages: All t.Errorf calls include descriptive messages with positional context. ✅

Build tag: //go:build !integration on line 1. ✅

Mock libraries: None used. ✅

Test inflation: The 68 lines added to the test file have no corresponding Go production file (the fix is in .md workflow files compiled to .lock.yml). Not applicable as inflation — the test validates compilation output end-to-end.


Language Support

Tests analyzed:

  • 🐹 Go (*_test.go): 1 test — unit (//go:build !integration)
  • 🟨 JavaScript (*.test.cjs, *.test.js): 0 tests

Verdict

Check passed. 0% of new tests are implementation tests (threshold: 30%). The single new test enforces a meaningful ordering invariant via end-to-end compilation output verification.


📖 Understanding Test Classifications

Design Tests (High Value) verify what the system does:

  • Assert on observable outputs, return values, or state changes
  • Cover error paths and boundary conditions
  • Would catch a behavioral regression if deleted
  • Remain valid even after internal refactoring

Implementation Tests (Low Value) verify how the system does it:

  • Assert on internal function calls (mocking internals)
  • Only test the happy path with typical inputs
  • Break during legitimate refactoring even when behavior is correct
  • Give false assurance: they pass even when the system is wrong

Goal: Shift toward tests that describe the system's behavioral contract — the promises it makes to its users and collaborators.

References: §24834028697

🧪 Test quality analysis by Test Quality Sentinel · ● 320.7K ·

Copy link
Copy Markdown
Contributor

@github-actions github-actions Bot left a comment

Choose a reason for hiding this comment

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

✅ Test Quality Sentinel: 100/100. Test quality is excellent — 0% of new tests are implementation tests (threshold: 30%). The new test enforces a meaningful step-ordering behavioral contract via end-to-end compilation output verification.

@pelikhan pelikhan merged commit fa70b5e into main Apr 23, 2026
37 of 40 checks passed
@pelikhan pelikhan deleted the copilot/fix-skill-invocation-syntax branch April 23, 2026 12:13
Copilot AI added a commit that referenced this pull request Apr 24, 2026
… pre-agent-steps

APM-restored skills were being clobbered in PR context because the
'Restore agent config folders from base branch' step ran AFTER
pre-agent-steps (including APM restore). This meant any .github/skills/
content installed by APM was overwritten by the base-branch snapshot.

Fix the step ordering in generateMainJobSteps so that:
1. Download activation artifact (moved earlier - needed for base restore)
2. Prepare comment memory files (moved earlier)
3. Restore agent config folders from base branch (moved before pre-agent-steps)
4. pre-agent-steps / APM restore (now runs AFTER base restore)
5. MCP setup (unchanged - still after pre-agent-steps)

Update TestImportedPreAgentStepsRunAfterPRBaseRestore to add the missing
invariant check: base restore must precede APM restore. Add a new
TestImportedPreAgentStepsRunAfterPRBaseRestoreCopilot test covering the
exact engine/trigger combination from the issue repro.

Update golden files to reflect the new step ordering.

Closes #28002-related regression

Agent-Logs-Url: https://github.com/github/gh-aw/sessions/7c91f767-3b51-4fd2-9597-f45cca403e27

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
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.

PR-context base-branch restore overwrites APM-restored .github/skills before Copilot starts

3 participants