fix: direct-slash resume-safe commands route to CliAction instead of interactive_only (#831)#3205
Open
code-yeongyu wants to merge 2 commits into
Open
fix: direct-slash resume-safe commands route to CliAction instead of interactive_only (#831)#3205code-yeongyu wants to merge 2 commits into
code-yeongyu wants to merge 2 commits into
Conversation
…#830) `claw --output-format json mcp show` (no server name) previously emitted error_kind:"unknown_mcp_action" — misleading because `show` IS a known action; the problem is a missing required argument. Fix: - `render_mcp_report_json_for`: `Some("show")` arm now emits a dedicated JSON response with error_kind:"missing_argument" + usage hint - `classify_error_kind`: add classifier arm for "missing_argument:" prefix One new test: mcp_show_missing_server_name_emits_missing_argument 572+ tests pass.
…interactive_only (#831) `claw /status`, `claw /diff`, `claw /version`, `claw /doctor`, `claw /sandbox` all returned interactive_only because the direct-slash handler only had explicit arms for /help, /agents, /mcp, /skills. Other resume-safe slash commands fell through to the generic `Ok(Some(command)) => Err(interactive_only...)` arm. Fix: add explicit routing arms for SlashCommand::Status, ::Diff, ::Version, ::Doctor, ::Sandbox in `parse_direct_slash_command`. One new integration test: direct_slash_resume_safe_commands_route_correctly (covers /version, /sandbox, /diff) 572+ tests pass.
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.
Fixes ROADMAP #831.
Before:
claw /status→error_kind:"interactive_only"claw /diff→error_kind:"interactive_only"claw /version→error_kind:"interactive_only"claw /doctor→error_kind:"interactive_only"claw /sandbox→error_kind:"interactive_only"After: Same output as
claw status/claw diff/claw versionetc.Root cause:
parse_direct_slash_commandonly had explicit arms for/help,/agents,/mcp,/skills. All other SlashCommand variants fell to the genericinteractive_onlyarm.Tests: 1 new integration test, 572+ pass.