{"record":{"id":"4ea5dbf7dd5b7b02","repo":"Hmbown/CodeWhale","slug":"ssh-fleet-workers-do-not-yet-support-nested-worksp","errorCode":null,"errorMessage":"SSH Fleet workers do not yet support nested workspace.root values; task cwd '{}' cannot be mapped safely beneath the remote working_directory","messagePattern":"SSH Fleet workers do not yet support nested workspace\\.root values; task cwd '(.+?)' cannot be mapped safely beneath the remote working_directory","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"crates/tui/src/fleet/manager.rs","lineNumber":2376,"sourceCode":"            .lines()\n            .all(|line| line.starts_with(\"- \") && line.len() <= 512)\n}\n\nfn validate_task_cwd_for_host(\n    workspace: &Path,\n    host: &FleetHostSpec,\n    task_cwd: &Path,\n) -> Result<()> {\n    if !matches!(host, FleetHostSpec::Ssh { .. }) {\n        return Ok(());\n    }\n    let workspace_root = crate::tools::spec::resolve_strict_authority_path(\n        &crate::tools::ToolContext::new(workspace.to_path_buf()),\n        \".\",\n    )\n    .map_err(anyhow::Error::new)?;\n    if task_cwd != workspace_root {\n        bail!(\n            \"SSH Fleet workers do not yet support nested workspace.root values; task cwd '{}' cannot be mapped safely beneath the remote working_directory\",\n            task_cwd.display()\n        );\n    }\n    Ok(())\n}\n\nfn task_receipt_outcome(\n    payload: &FleetWorkerEventPayload,\n    exit_code: Option<i32>,\n) -> (FleetTaskResult, Option<FleetTaskFailureKind>, Option<i32>) {\n    match payload {\n        FleetWorkerEventPayload::Completed {\n            exit_code: payload_exit_code,\n            ..\n        } => (\n            FleetTaskResult::Pass,\n            None,","sourceCodeStart":2358,"sourceCodeEnd":2394,"githubUrl":"https://github.com/Hmbown/CodeWhale/blob/0c42157ee52f9d55af2b506d71b46249910f77d3/crates/tui/src/fleet/manager.rs#L2358-L2394","documentation":"For SSH fleet hosts, the worker's remote cwd is mapped directly onto the configured remote working_directory; only a task cwd equal to the resolved workspace root can be mapped safely. If task_cwd differs from resolve_strict_authority_path(workspace, \".\"), the run is refused rather than guessing a remote path.","triggerScenarios":"Starting an SSH fleet run whose task spec sets cwd to a subdirectory (or any path other than the workspace root), e.g. cwd = \"crates/tui\" with an SSH host.","commonSituations":"Copying a local fleet task spec that used a nested cwd to an SSH host config; setting workspace.root to a nested value while tasks default cwd elsewhere.","solutions":["Set the task cwd to the workspace root (\".\" / omit cwd) for SSH hosts","Flatten workspace.root so the task cwd equals the root","Use a local (non-SSH) host if nested cwds are a hard requirement","Track the feature request rather than symlinking around it on the remote"],"exampleFix":"# before (task.toml, SSH host)\n[[tasks]]\nobjective = \"fix tests\"\ncwd = \"crates/tui\"\n\n# after\n[[tasks]]\nobjective = \"fix tests\"\ncwd = \".\"","handlingStrategy":"validation","validationCode":"fn task_cwd_ok_for_ssh(task_cwd: &std::path::Path, workspace_root: &std::path::Path) -> bool {\n    task_cwd == workspace_root\n}\n\n// before starting an SSH-hosted run:\nassert!(task_cwd_ok_for_ssh(&task.cwd, &workspace_root),\n    \"SSH fleet tasks must run at the workspace root\");","typeGuard":null,"tryCatchPattern":"match fleet_manager.start_run(&spec) {\n    Ok(run) => Ok(run),\n    Err(err) if err.to_string().contains(\"nested workspace.root\") => {\n        eprintln!(\"set task cwd to the workspace root or use a local host\");\n        Err(err)\n    }\n    Err(err) => Err(err),\n}","preventionTips":["Default SSH fleet task specs to cwd = \".\" at the workspace root","Validate task specs against the host type before submission, not at launch time","Track nested-root support rather than working around it with remote symlinks"],"tags":["fleet","ssh","workspace","unsupported-feature","rust","codewhale"],"backgroundTag":"unsupported-configuration","analyzedSha":"0c42157ee52f9d55af2b506d71b46249910f77d3","analyzedAt":"2026-08-20T21:50:45.477Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}