fix: remove restrictive bash allowlist from go-logger workflow#3864
Merged
fix: remove restrictive bash allowlist from go-logger workflow#3864
Conversation
The Go Logger Enhancement workflow (#3826) failed because the agent tried to run 'go build ./...' but only 'go build -o awmg' was in the bash allowlist. The AWF sandbox already provides security, so the explicit command restrictions are unnecessary. Changes: - Remove restrictive bash command allowlist, use 'bash: true' instead - Add 'go' ecosystem identifier to network.allowed for module downloads - Recompile lock file Closes #3826 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Adjusts the Go Logger Enhancement agentic workflow to avoid AWF sandbox rejections caused by an overly strict bash command allowlist, aligning the workflow with the typical “unrestricted bash within sandbox + network allowlisting” pattern used elsewhere in this repo.
Changes:
- Expand
network.allowedto include thegoecosystem so Go module/proxy access works during builds. - Replace the explicit bash command allowlist with
bash: trueto prevent valid Go build/test invocations from being blocked. - Recompile the workflow lock file to reflect the updated tool/network configuration.
Show a summary per file
| File | Description |
|---|---|
| .github/workflows/go-logger.md | Enables go network access and removes the restrictive bash allowlist by switching to bash: true. |
| .github/workflows/go-logger.lock.yml | Updates compiled lock output (allowed domains + Copilot CLI tool allowances) to match the workflow changes. |
Copilot's findings
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Files reviewed: 2/2 changed files
- Comments generated: 0
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
The Go Logger Enhancement workflow failed (#3826) because the AWF sandbox blocked the agent's
go build ./...command. The workflow had a restrictive bash allowlist that only permittedgo build -o awmg, so the agent reported itself as incomplete, triggering failure handling.Root cause
The
go-logger.mdworkflow used an explicit bash command allowlist:The Copilot agent tried
go build ./...(a valid Go build command) which didn't match the allowlist exactly, so the AWF rejected it.Fix
bash: true— The AWF sandbox already provides security, so explicit command restrictions are unnecessary (per gh-aw best practices)goecosystem identifier tonetwork.allowed— Ensures Go module proxy access for buildsgo-logger.lock.ymlto reflect changesVerification
gh aw compile go-loggersucceedsmake agent-finishedpasses all checksCloses #3826