{"record":{"id":"a79164e275963ce9","repo":"Hmbown/CodeWhale","slug":"cannot-resolve-the-current-codewhale-route-e","errorCode":null,"errorMessage":"cannot resolve the current Codewhale route: {e}","messagePattern":"cannot resolve the current Codewhale route: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/tui/src/integrations/cli.rs","lineNumber":271,"sourceCode":"    match command {\n        DshIntegrationCommand::Status { json } => {\n            let (_paths, report) = status_report(config, workspace, false)?;\n            if json {\n                println!(\"{}\", serde_json::to_string_pretty(&report)?);\n            } else {\n                print_status(&report);\n            }\n            Ok(())\n        }\n        DshIntegrationCommand::Plan {\n            json,\n            profile,\n            allow_full_access,\n            skin,\n        } => {\n            let (paths, report) = status_report(config, workspace, allow_full_access)?;\n            let identity = dsh::codewhale_route_identity(config, workspace)\n                .map_err(|e| anyhow::anyhow!(\"cannot resolve the current Codewhale route: {e}\"))?;\n            let plan = dsh::plan(\n                &paths,\n                &report.detection,\n                &identity,\n                &profile,\n                allow_full_access,\n                skin,\n                true,\n            )?;\n            if json {\n                println!(\"{}\", serde_json::to_string_pretty(&plan)?);\n            } else {\n                print_plan(&plan, \"connect\");\n                if !report.detection.installed() {\n                    println!(\n                        \"  warning: dsh is not on PATH; the plan is valid but launch will fail\"\n                    );\n                }","sourceCodeStart":253,"sourceCodeEnd":289,"githubUrl":"https://github.com/Hmbown/CodeWhale/blob/73e0f67d83c59909b571efdfc88c4bc28c309cb1/crates/tui/src/integrations/cli.rs#L253-L289","documentation":"The `dsh status` path of run_dsh could not determine the current Codewhale route identity for the given config and workspace. codewhale_route_identity returned an error, which is surfaced with its cause via {e}.","triggerScenarios":"Running the `dsh status` integration command (run_dsh -> run) when codewhale_route_identity fails: missing or malformed provider/model configuration for the workspace, or an unresolvable route in config.","commonSituations":"Running dsh outside an initialized workspace; a config file with no active provider route; renamed or migrated config keys after a Codewhale upgrade.","solutions":["Read the chained cause `{e}` — it names the specific route-resolution problem.","Verify the config has a valid current provider/model route for this workspace (`codewhale` config/status).","Reconnect DSH after fixing config: run `<CLI_COMMAND> connect`."],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":"// Pre-flight: ensure the workspace has a resolvable route before running dsh status\nif codewhale.config.active_route().is_none() {\n    eprintln!(\"no active provider/model route; run `codewhale` once to initialize config\");\n}","typeGuard":null,"tryCatchPattern":"// Rust\nmatch dsh::codewhale_route_identity(config, workspace) {\n    Ok(identity) => proceed(identity),\n    Err(e) => eprintln!(\"cannot resolve route: {e}; fix config then rerun connect\"),\n}","preventionTips":["Initialize Codewhale config before running dsh subcommands.","Run `dsh status` after any config migration to catch unresolvable routes early.","Invoke dsh commands from the workspace root so detection succeeds."],"tags":["dsh","config","cli"],"backgroundTag":"missing-config-value","analyzedSha":"73e0f67d83c59909b571efdfc88c4bc28c309cb1","analyzedAt":"2026-09-22T01:30:00.501Z","contentChangedAt":"2026-09-22T01:30:00.501Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}