warpdotdev/warp · error

invalid value 'harness-support'

Error message

invalid value 'harness-support'

What it means

Thrown by the dispatcher arm for CliCommand::HarnessSupport (mod.rs:202) when `harness-support` parsed but FeatureFlag::AgentHarness is disabled. The clap-mimicking 'invalid value' error hides the harness-support tooling (install/setup of external agent harness CLIs) when the flag is off. Defaults to false; channel/account-dependent.

Source

Thrown at app/src/ai/agent_sdk/mod.rs:202

                return Err(anyhow::anyhow!("invalid value 'schedule'"));
            }
            schedule::run(ctx, global_options, schedule_cmd)
        }
        CliCommand::Secret(secret_cmd) => {
            if !FeatureFlag::WarpManagedSecrets.is_enabled() {
                return Err(anyhow::anyhow!("invalid value 'secret'"));
            }
            secret::run(ctx, global_options, secret_cmd)
        }
        CliCommand::Federate(federate_cmd) => {
            if !FeatureFlag::OzIdentityFederation.is_enabled() {
                return Err(anyhow::anyhow!("invalid value 'federate'"));
            }
            federate::run(ctx, global_options, federate_cmd)
        }
        CliCommand::HarnessSupport(args) => {
            if !FeatureFlag::AgentHarness.is_enabled() {
                return Err(anyhow::anyhow!("invalid value 'harness-support'"));
            }
            harness_support::run(ctx, global_options, args)
        }
        CliCommand::Artifact(artifact_cmd) => {
            if !FeatureFlag::ArtifactCommand.is_enabled() {
                return Err(anyhow::anyhow!("invalid value 'artifact'"));
            }
            artifact::run(ctx, global_options, artifact_cmd)
        }
        CliCommand::ApiKey(api_key_cmd) => {
            if !FeatureFlag::APIKeyManagement.is_enabled() {
                return Err(anyhow::anyhow!("invalid value 'api-key'"));
            }
            api_key::run(ctx, global_options, api_key_cmd)
        }
        CliCommand::Runner(runner_cmd) => {
            if !FeatureFlag::CloudAgentRunners.is_enabled() {
                return Err(anyhow::anyhow!("invalid value 'runner'"));

View on GitHub (pinned to e72fd7aacb)

Solutions

  1. Use a build/account where AgentHarness is enabled, or update the CLI to a version where harness support is generally available
  2. Install the target harness CLI (claude/codex/gemini) manually if you only need the binary present
  3. As a Warp developer, override the flag or add FeatureFlag::AgentHarness to DOGFOOD_FLAGS and rebuild

Example fix

# before
$ oz harness-support install claude
Error: invalid value 'harness-support'

# after: check the shared gate first
if FeatureFlag::AgentHarness.is_enabled() {
    harness_support::run(ctx, global_options, args)?;
}
Defensive patterns

Strategy: validation

Validate before calling

if matches!(cmd, CliCommand::HarnessSupport(_))
    && !FeatureFlag::AgentHarness.is_enabled()
{
    return Ok(());
}

Type guard

pub fn harness_feature_available() -> bool {
    FeatureFlag::AgentHarness.is_enabled()
}

Try / catch

match agent_sdk::run(ctx, opts, cmd) {
    Err(e) if e.to_string() == "invalid value 'harness-support'" => {
        // install the harness CLI manually instead
    }
    result => result?,
}

Prevention

When it happens

Trigger: Invoking `<cli> harness-support <args>` on a build where FeatureFlag::AgentHarness.is_enabled() == false. Related gates (--harness on run/run-cloud, harness_support::run) share the same flag.

Common situations: Bootstrapping a claude/codex/gemini/opencode harness via the CLI on a gated build; CI images built from release binaries where AgentHarness is off; docs referencing harness-support on versions where it had not shipped.

Related errors


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