Hmbown/CodeWhale · error · anyhow::Error

{error}

Error message

{error}

What it means

StubRuntime is the placeholder backend for the not-yet-implemented Vm and Ci runtime kinds (surface-only in Phase 1). Its start formats "<kind> runtime is not implemented; use tmux or inline", appends a lane_failed event to the lane log, best-effort marks the record Failed via mark_terminal_if_active, and re-raises that message verbatim — so the error you see is the formatted text (e.g. 'vm runtime is not implemented; use tmux or inline').

Source

Thrown at crates/lane/src/runtime.rs:1110

        registry: &LaneRegistry,
        record: &mut LaneRecord,
        _spec: &LaneStartSpec,
    ) -> Result<()> {
        let error = format!(
            "{} runtime is not implemented; use tmux or inline",
            self.kind.as_str()
        );
        append_log_event(
            &record.log_path,
            serde_json::json!({
                "type": "lane_failed",
                "lane_id": record.id,
                "runtime": self.kind.as_str(),
                "error": &error,
            }),
        )?;
        let _ = registry.mark_terminal_if_active(record, LaneStatus::Failed)?;
        bail!("{error}")
    }

    fn attach_command(&self, _record: &LaneRecord) -> Option<String> {
        None
    }

    fn stop(
        &self,
        registry: &LaneRegistry,
        record: &mut LaneRecord,
        fence: Option<u64>,
    ) -> Result<TerminalTransition> {
        registry.mark_terminal_if_active_fenced(record, LaneStatus::Stopped, fence, |_| Ok(()))
    }
}

fn shell_escape(s: &str) -> String {
    format!("'{}'", s.replace('\'', "'\\''"))

View on GitHub (pinned to 0c42157ee5)

Solutions

  1. Switch the lane's runtime to "tmux" or "inline", the two implemented backends
  2. If you selected vm/ci accidentally (typo, stale example), fix the configuration value
  3. Track the feature for the backend you need instead of retrying — this failure is deterministic, not transient

Example fix

# before
# config: runtime = "vm"

# after
runtime = "tmux"
Defensive patterns

Strategy: validation

Validate before calling

fn runtime_implemented(kind: RuntimeBackendKind) -> bool {
    matches!(kind, RuntimeBackendKind::Tmux | RuntimeBackendKind::Inline)
}

anyhow::ensure!(
    runtime_implemented(selected_kind),
    "{} runtime is not implemented; use tmux or inline",
    selected_kind.as_str()
);

Type guard

fn runtime_implemented(kind: RuntimeBackendKind) -> bool {
    matches!(kind, RuntimeBackendKind::Tmux | RuntimeBackendKind::Inline)
}

Prevention

When it happens

Trigger: Starting a lane whose RuntimeBackendKind parses to "vm" or "ci" (RuntimeBackendKind::parse accepts all four). Any start attempt on those kinds deterministically fails here after recording the failure.

Common situations: Config or CLI selecting runtime "vm"/"ci" because the option is accepted; copying examples from forward-looking docs; code enumerating all backend kinds and defaulting to an unimplemented one.

Related errors


AI-assisted analysis of Hmbown/CodeWhale@0c42157ee5 (2026-08-20). Data as JSON: /api/errors/118a86bead3ec8e5. Report an issue: GitHub.