warpdotdev/warp · error · anyhow::Error

A runner UID or --name is required

Error message

A runner UID or --name is required

What it means

Runner resolution requires exactly one selector — a UID (positional/--id) or a --name. Neither was provided, so there is nothing to match against the fetched runner list and the command fails before any server mutation.

Source

Thrown at app/src/ai/agent_sdk/runner.rs:237

        .with_default(false)
        .prompt()
        .unwrap_or_default())
}

/// Resolve a runner by UID or (unambiguous) name from a fetched list.
fn resolve_runner<'a>(
    runners: &'a [Runner],
    id: Option<&str>,
    name: Option<&str>,
) -> Result<&'a Runner> {
    if let Some(id) = id {
        return runners
            .iter()
            .find(|runner| runner.uid.inner() == id)
            .ok_or_else(|| anyhow!("Runner '{id}' not found"));
    }

    let name = name.ok_or_else(|| anyhow!("A runner UID or --name is required"))?;
    let matches: Vec<&Runner> = runners
        .iter()
        .filter(|runner| runner.config.name == name)
        .collect();
    match matches.as_slice() {
        [] => Err(anyhow!("Runner '{name}' not found")),
        [runner] => Ok(runner),
        _ => Err(anyhow!(
            "Multiple runners match '{name}'; specify the runner by UID"
        )),
    }
}

/// Build the [`RunnerInput`] for a create operation.
fn build_create_input(args: CreateRunnerArgs, owner: GqlOwner) -> UpsertRunnerInput {
    let os = os_to_gql(args.os);
    let (linux, mac) = match args.os {
        RunnerOsArg::Linux => (

View on GitHub (pinned to e72fd7aacb)

Solutions

  1. Pass a runner UID: `warp runner delete <uid>`
  2. Or pass --name <name> when the name is unique (ambiguous names error with 'Multiple runners match')
  3. In scripts, fail early when the UID variable is empty rather than letting the CLI reject it

Example fix

# before
warp runner delete "$RUNNER_ID"   # RUNNER_ID unset -> expands to nothing

# after
: "${RUNNER_ID:?RUNNER_ID must be set}"
warp runner delete "$RUNNER_ID"
Defensive patterns

Strategy: validation

Validate before calling

# Require a selector before invoking the CLI
: "${RUNNER_ID:?set RUNNER_ID or pass --name}"
warp runner delete "$RUNNER_ID"

Try / catch

out=$(warp runner delete 2>&1) || { case "$out" in *'UID or --name is required'*) echo 'usage: warp runner delete <uid> | --name <name>' >&2; exit 2;; *) echo "$out" >&2; exit 1;; esac; }

Prevention

When it happens

Trigger: Invoking a runner subcommand that routes through resolve_runner with both id and name None — flags omitted on the command line or empty variables expanding to nothing.

Common situations: Assuming the command defaults to a 'current' runner; shell scripts where the UID variable is unset (`warp runner delete $RUNNER_ID` with RUNNER_ID empty); wrappers dropping the flag.

Related errors


AI-assisted analysis of warpdotdev/warp@e72fd7aacb (2026-08-16). Data as JSON: /api/errors/22006814a1ec19dc. Report an issue: GitHub.