Commit be3b4c5
fix: align tool allow lists with gh-aw (#279)
* fix: align tool allow lists with gh-aw
- Emit --allow-all-tools when bash wildcard (:* or *) is set, dropping all
individual --allow-tool flags (matches gh-aw computeCopilotToolArguments)
- Default to --allow-all-tools when bash is not specified (matches gh-aw's
applyDefaultTools sandbox behavior — bash: [*] is the default when sandbox
is enabled, and ado-aw agents always run in AWF sandbox)
- Emit --allow-all-paths when edit tool is enabled (matches gh-aw
GetExecutionSteps)
- Remove DEFAULT_BASH_COMMANDS constant (no longer the default)
- Update tests and AGENTS.md documentation
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: address review feedback on tool allow list comments
- Add comment noting wildcard+command mixing is unsupported (cmds.len()==1)
- Add comment explaining why restricted-bash path emits both --allow-tool
write and --allow-all-paths (tool identity vs path scope)
- Replace silent vec![] fallback with debug_assert! in unreachable None arm
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: address remaining review feedback on tool allow lists
- Update AGENTS.md copilot_params docs: --allow-all-tools now mentions
bash-omitted default, --allow-tool references configured tools instead
of deleted DEFAULT_BASH_COMMANDS list
- Replace debug_assert!(false, ...) with unreachable!() for the
bash=None invariant (idiomatic Rust for proven-unreachable paths)
- Strengthen test_copilot_params_custom_mcp_no_mcp_flag assertion to
check --allow-tool (not non-existent --mcp flag)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>1 parent 784de06 commit be3b4c5
3 files changed
Lines changed: 204 additions & 115 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
393 | 393 | | |
394 | 394 | | |
395 | 395 | | |
396 | | - | |
397 | | - | |
398 | | - | |
399 | | - | |
400 | | - | |
| 396 | + | |
401 | 397 | | |
402 | 398 | | |
403 | 399 | | |
404 | 400 | | |
405 | | - | |
| 401 | + | |
406 | 402 | | |
407 | 403 | | |
408 | 404 | | |
409 | | - | |
| 405 | + | |
410 | 406 | | |
411 | 407 | | |
412 | 408 | | |
413 | | - | |
| 409 | + | |
414 | 410 | | |
415 | 411 | | |
416 | 412 | | |
| |||
637 | 633 | | |
638 | 634 | | |
639 | 635 | | |
640 | | - | |
641 | 636 | | |
| 637 | + | |
| 638 | + | |
| 639 | + | |
642 | 640 | | |
643 | 641 | | |
644 | 642 | | |
| |||
0 commit comments