Hmbown/CodeWhale · error

this launcher does not support harness execution

Error message

this launcher does not support harness execution

What it means

Default SandboxLauncher trait implementation for run_harness: a launcher that did not override the method reports that it cannot execute harness commands inside the sandbox. Like the other default impls, it fails loudly rather than pretending to run a command.

Solutions

  1. Dispatch against a launcher that implements run_harness (the real sandboxed harness runner).
  2. Verify the launcher selection logic: why is the default-impl launcher in use for this job?
  3. In unsupported environments, skip harness execution explicitly rather than calling through the trait default.
  4. If this is a test, inject a test double that implements run_harness with deterministic output.

Example fix

// before
let out = launcher.run_harness(&receipt, &cmd)?;
// after
match launcher.run_harness(&receipt, &cmd) {
    Ok(out) => out,
    Err(e) if e.to_string().contains("does not support harness execution") => {
        bail!("harness execution unavailable with this launcher");
    }
    Err(e) => Err(e),
}
Defensive patterns

Strategy: try-catch

Validate before calling

fn launcher_supports_harness(l: &dyn SandboxLauncher) -> bool {
    l.capabilities().contains(Capability::Harness)
}

Try / catch

match launcher.run_harness(&receipt, &cmd) {
    Err(e) if e.to_string().contains("does not support harness execution") => {
        eprintln!("harness execution unavailable with this launcher; re-dispatch on a capable backend");
    }
    other => { /* ... */ }
}

Prevention

When it happens

Trigger: Calling run_harness with a receipt from a launcher that only implements the basic lifecycle (spawn/wait/teardown) or none of the execution methods — e.g. a stub launcher used in restricted environments.

Common situations: Executing a harness run in an environment without the real sandbox backend; a test double that implements teardown but not run_harness; misconfigured dispatch that selected the fallback launcher.

Related errors


AI-assisted analysis of Hmbown/CodeWhale@73e0f67d83 (2026-09-22). Data as JSON: /api/errors/8841223a92c5ea53. Report an issue: GitHub.

Appendix: source

Thrown at crates/tui/src/cloud_dispatch.rs:1186

/// Launch seam. Tests inject a recorder; production uses [`LiveDaytonaLauncher`].
///
/// The methods after `create_sandbox` default to "unsupported" so partial
/// fixtures keep compiling; the real runner (and the recording tests) drive
/// the full protocol.
pub trait DaytonaLauncher {
    /// Create the sandbox and return its id plus the (validated) toolbox URL.
    fn create_sandbox(&self, job: &CloudJob) -> Result<SandboxReceipt>;
    /// Block until the sandbox accepts toolbox calls (bounded poll).
    fn wait_ready(&self, _receipt: &SandboxReceipt) -> Result<()> {
        Ok(())
    }
    /// Clone the target forge repository inside the sandbox.
    fn clone_repository(&self, _receipt: &SandboxReceipt, _url: &str, _path: &str) -> Result<()> {
        bail!("this launcher does not support repository clones")
    }
    /// Run one harness command inside the sandbox and return bounded stdout.
    fn run_harness(&self, _receipt: &SandboxReceipt, _command: &HarnessCommand) -> Result<String> {
        bail!("this launcher does not support harness execution")
    }
    /// Collect the agent's work product from the sandbox.
    fn collect_patch(&self, _receipt: &SandboxReceipt) -> Result<PatchReceipt> {
        bail!("this launcher does not support patch collection")
    }
    /// Tear the sandbox down. Called on cancel, failure, and completion.
    fn teardown(&self, _receipt: &SandboxReceipt) -> Result<()> {
        bail!("this launcher does not support teardown")
    }
    /// List Codewhale-dispatch sandboxes with their job labels. Used by the
    /// reconciler (startup sweep and cancel); not part of the run protocol.
    fn list_job_sandboxes(&self) -> Result<Vec<LabeledSandbox>> {
        bail!("this launcher does not support sandbox listing")
    }
}

/// One dispatch-labeled sandbox discovered by the reconciler.
#[derive(Debug, Clone, PartialEq, Eq)]

View on GitHub (pinned to 73e0f67d83)