docs(agents): allow N-level command paths in CLI contract - #712
Merged
Conversation
AGENTS.md described the canonical shape as exactly `direct <group> <command>`, which no longer matches the repo: PR #674 made three command tree walkers recursive specifically to support nested groups, and PR #675-#677 shipped `masters adimages get|add|delete|set` as a real three-level leaf. The stale wording already produced a false P1 from Codex on PR #675, citing these exact lines as a contract violation. Reword the contract to describe a path of one or more group segments plus a leaf command, each segment validated the same way, and add `masters adimages` as a documented example of the existing pattern. Closes #680
Owner
Author
🔍 Local review (cycle 1) — round 3321ef62-f2da-48c0-b5ed-788198aad30aReviewed locally (
Totals: 0 FIX, 0 SKIP, 0 UNVERIFIED. Both reviewers approve. |
5 tasks
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.
Summary
direct <group> <command>, which is stale: PR refactor: recurse the command-tree walkers #674 made three command-tree walkers recursive specifically to support nested groups, and PR feat(masters): adddirect masters adimages get#675-feat(masters): adddirect masters adimages delete/set#677 shippedmasters adimages get|add|delete|setas a real three-level leaf.direct masters adimages get#675, citing AGENTS.md L15-19 as evidence that the new nested group broke the contract (triaged and rejected there, but the underlying wording remained misleading for future reviewers).group/commandrules (tests/test_cli_contract.py'sGROUP_NAME_RE/COMMAND_NAME_REonly ever validated segment names, never tree depth), and addeddirect masters adimages get 123as a documented example of the existing pattern.Test plan
pytest tests/test_cli_contract.py tests/test_smoke_matrix.py -q— 29 passedpython -m direct_cli.cli masters adimages get --help— confirmed the example command's real signature (positionalCAMPAIGN_ID, no--wizard-idflag)Closes #680
🤖 Generated with Claude Code