Closed
Copilot
AI
changed the title
[WIP] Add codemod for engine.codex with tools.bash allow-list
Add guided gh aw fix diagnostic for restricted tools.bash on engines that ignore allow-listing
pelikhan marked this pull request as ready for review
August 7, 2026 16:37Copilot AI balanced review requested due to automatic review settings
August 7, 2026 16:37…ive tools from imports - Use fmt.Sprintf(%q) in describeBashRestriction to prevent terminal output spoofing via ANSI control sequences or embedded newlines in YAML-sourced command strings - Add ApplyWithContext optional field to Codemod struct for codemods that need the workflow file path to resolve effective configuration from imports/includes - Update fix_command.go to call ApplyWithContext (if set) instead of Apply so the bash allowlist codemod receives the file path at runtime - Add resolveEffectiveBashTools helper: resolves imports via parser.ProcessImportsFromFrontmatterWithSource and markdown includes via parser.ExpandIncludesWithManifest, then merges with top-level tools; fast path skips resolution when the top-level tools already declares a bash key (it wins) - Update tests: fix expected error string for quoted commands; add control-character and newline spoofing test cases; add ApplyWithContext import-sourced restriction test Co-authored-by: gh-aw-bot <259018956+gh-aw-bot@users.noreply.github.com>
…e-read fix, test clarity - Add EnginesWithCapability(predicate) to EngineRegistry so callers can derive the supported-engine list from the registry rather than hardcoding it; this addresses the grill-with-docs thread that flagged 'copilot, claude, or gemini' as fragile as new engines gain BashCommandAllowlist support - Use EnginesWithCapability in the guided error message in applyBashAllowlistUnsupportedEngineCheck so the list stays registry-accurate - Extract bashVal := effectiveTools["bash"] once before HasBashExplicitRestriction so describeBashRestriction reads the same value (codebase-design thread fix) - Rename 'default engine' test case to explicitly call out that it relies on copilot being the default engine and having BashCommandAllowlist (tdd thread fix) - Update test assertion to check for individual engine names rather than the full hardcoded string to remain correct as the sorted list evolves Co-authored-by: gh-aw-bot <259018956+gh-aw-bot@users.noreply.github.com>
pelikhan deleted the copilot/aw-compat-missing-codemod-fix branch
August 7, 2026 18:02Copilot stopped work on behalf of pelikhan due to an error
August 7, 2026 18:21Closed
This was referenced
Aug 7, 2026Closed
Closed
Closed