Skip to content

Fix TestNeutralToolsIntegration: add git to bash allowed commands#15777

Merged
pelikhan merged 3 commits intomainfrom
copilot/fix-github-actions-workflow-9120daff-86a9-4ee3-b277-1224753c9a53
Feb 14, 2026
Merged

Fix TestNeutralToolsIntegration: add git to bash allowed commands#15777
pelikhan merged 3 commits intomainfrom
copilot/fix-github-actions-workflow-9120daff-86a9-4ee3-b277-1224753c9a53

Conversation

Copy link
Contributor

Copilot AI commented Feb 14, 2026

TestNeutralToolsIntegration fails compilation because it uses create-pull-request with restrictive bash configuration that excludes git.

Changes

  • Add "git" to bash allowed commands in test workflow: bash: ["echo", "ls", "git"]

Context

The validation in validateGitToolForSafeOutputs() runs before applyDefaults(), so workflows using create-pull-request or push-to-pull-request-branch must explicitly allow git when bash is configured with a limited command list. The test was checking neutral tools format conversion but inadvertently triggered this validation.

tools:
  bash: ["echo", "ls", "git"]  # git required for create-pull-request
  # ...
safe-outputs:
  create-pull-request:
    title-prefix: "[test] "

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 (http block)
    • Triggering command: /usr/bin/gh gh repo view owner/repo (http block)
    • Triggering command: /usr/bin/gh gh repo view owner/host-repo (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 (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 .cfg 64/pkg/tool/linux_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 .cfg x_amd64/compile (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 .cfg x_amd64/compile (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 .cfg 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 .cfg 64/pkg/tool/linux_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 .cfg 64/pkg/tool/linux_amd64/vet (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 .cfg x_amd64/vet (http block)
  • https://api.github.com/repos/github/gh-aw/actions/workflows
    • Triggering command: /usr/bin/gh gh workflow list --json name,state,path (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 (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 (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 (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 --repo owner/repo --json name,path,state 64/pkg/tool/linux_amd64/vet (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 (http block)
  • https://api.github.com/user
    • Triggering command: /usr/bin/gh gh api user --jq .login (http block)

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

Original prompt

Fix the failing GitHub Actions workflow Integration: Workflow Misc Part 2
Analyze the workflow logs, identify the root cause of the failure, and implement a fix.
Job ID: 63637157943
Job URL: https://github.com/github/gh-aw/actions/runs/22023824060/job/63637157943


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix failing GitHub Actions workflow Integration: Misc Part 2 Fix TestNeutralToolsIntegration: add git to bash allowed commands Feb 14, 2026
Copilot AI requested a review from pelikhan February 14, 2026 20:55
@pelikhan pelikhan marked this pull request as ready for review February 14, 2026 21:01
Copilot AI review requested due to automatic review settings February 14, 2026 21:01
@pelikhan pelikhan merged commit 615147e into main Feb 14, 2026
53 of 55 checks passed
@pelikhan pelikhan deleted the copilot/fix-github-actions-workflow-9120daff-86a9-4ee3-b277-1224753c9a53 branch February 14, 2026 21:01
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

This PR fixes a test compilation failure in TestNeutralToolsIntegration by adding "git" to the bash allowed commands list. The test workflow uses create-pull-request safe output, which requires git commands to be explicitly allowed when bash is configured with a restricted command list.

Changes:

  • Added "git" to bash allowed commands array: bash: ["echo", "ls", "git"]

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

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