{"record":{"id":"fccb6d33883fab80","repo":"Hmbown/CodeWhale","slug":"pass-all-to-stop-all-fleet-work-lib","errorCode":null,"errorMessage":"pass --all to stop all Fleet work","messagePattern":"pass --all to stop all Fleet work","errorType":"validation","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"crates/tui/src/lib.rs","lineNumber":3483,"sourceCode":"            Ok(())\n        }\n        FleetCommand::Resume {\n            run_id,\n            stale_after_seconds,\n        } => {\n            let manager = manager.with_stale_after(Duration::from_secs(stale_after_seconds.max(1)));\n            emit_fleet_receipt(&fleet_control::execute_fleet_control_with(\n                ControlSurface::Cli,\n                workspace,\n                fleet_context,\n                &manager,\n                ControlOperation::FleetResume,\n                Some(&run_id),\n            ))\n        }\n        FleetCommand::Stop { all } => {\n            if !all {\n                bail!(\"pass --all to stop all Fleet work\");\n            }\n            let stopped = manager.stop_all()?;\n            println!(\"stopped: {stopped}\");\n            Ok(())\n        }\n        FleetCommand::AlertDryRun(args) => {\n            let class = alert_event_class(args.event);\n            let adapter = alert_adapter(&args);\n            let event = FleetAlertEvent {\n                class,\n                run_id: FleetRunId::from(args.run_id.clone()),\n                worker_id: args.worker_id.clone(),\n                task_id: args.task_id.clone(),\n                status: alert_status(class, args.status.clone()),\n                reason: args.reason.clone(),\n            };\n            let dispatcher = FleetAlertDispatcher::new(\n                FleetAlertConfig::dry_run_for_adapter(adapter),","sourceCodeStart":3465,"sourceCodeEnd":3501,"githubUrl":"https://github.com/Hmbown/CodeWhale/blob/73e0f67d83c59909b571efdfc88c4bc28c309cb1/crates/tui/src/lib.rs#L3465-L3501","documentation":"The Fleet Stop subcommand intentionally stops all Fleet work; refusing an ambiguous stop without --all is by design, so calling it without the flag bails immediately. This is a guard against accidentally stopping only part of (or all of) the fleet without explicit consent.","triggerScenarios":"Running `codewhale fleet stop` (or the equivalent) without passing `--all` — the FleetCommand::Stop arm checks the `all` boolean first.","commonSituations":"Typing the stop command omitting the flag; scripted stops that predate the --all requirement; muscle memory from other CLIs where bare stop is allowed.","solutions":["Re-run the command with --all to stop all Fleet work","Update automation/scripts to include --all","If partial stopping is intended, use the targeted stop/resume variant with a run id instead"],"exampleFix":"// before\ncodewhale fleet stop\n// after\ncodewhale fleet stop --all","handlingStrategy":"validation","validationCode":"if stop_requested && !args.all {\n    eprintln!(\"refusing: pass --all to stop all Fleet work\");\n    std::process::exit(2);\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Always include --all in scripts that stop Fleet work","Confirm scope before stopping: --all is intentionally explicit","Use targeted stop with a run id for partial stops"],"tags":["cli","fleet","missing-flag"],"backgroundTag":"missing-required-flag","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"}