tinyhumansai/openhuman · warning
missing value for --out
Error message
missing value for --out
What it means
Thrown by parse_dump_all_flags when `--out`/`-o` is the last token of `openhuman agent dump-all`, so args.get(i + 1) returns None. The flag consumes the next token as its value; there is none to consume.
Source
Thrown at src/core/agent_cli.rs:70
struct DumpAllFlags {
out: PathBuf,
workspace: Option<PathBuf>,
model: Option<String>,
verbose: bool,
}
fn parse_dump_all_flags(args: &[String]) -> Result<DumpAllFlags> {
let mut out: Option<PathBuf> = None;
let mut workspace: Option<PathBuf> = None;
let mut model: Option<String> = None;
let mut verbose = false;
let mut i = 0usize;
while i < args.len() {
match args[i].as_str() {
"--out" | "-o" => {
out = Some(PathBuf::from(
args.get(i + 1)
.ok_or_else(|| anyhow!("missing value for --out"))?,
));
i += 2;
}
"--workspace" | "-w" => {
workspace = Some(PathBuf::from(
args.get(i + 1)
.ok_or_else(|| anyhow!("missing value for --workspace"))?,
));
i += 2;
}
"--model" | "-m" => {
model = Some(
args.get(i + 1)
.ok_or_else(|| anyhow!("missing value for --model"))?
.clone(),
);
i += 2;
}View on GitHub (pinned to a221052e0d)
Solutions
- Supply the output directory: `openhuman agent dump-all --out <dir>`.
- In scripts, default the variable first: `OUT_DIR="${OUT_DIR:-./prompts}"` so the flag always gets a value.
Example fix
# before openhuman agent dump-all --out # after openhuman agent dump-all --out ./agent-prompts
Defensive patterns
Strategy: validation
Validate before calling
// shell: ensure --out always has a value
OUT_DIR="${OUT_DIR:-./agent-prompts}"
openhuman agent dump-all --out "$OUT_DIR" Try / catch
match run_agent_command(&args) {
Err(e) if e.to_string().contains("missing value for --out") => {
eprintln!("usage: openhuman agent dump-all --out <dir> [options]");
}
other => other?,
} Prevention
- Always type the value immediately after --out.
- Default output-directory variables in scripts before composing the command.
- Quote variables so empty expansions are visible as missing values, not silent drops.
When it happens
Trigger: `openhuman agent dump-all --out` with nothing after it, or ending the command line with `-o`.
Common situations: Typing the command incrementally and forgetting the directory, or a shell script that appends `--out "$OUT_DIR"` with an unset variable expanding to nothing (unquoted/empty expansion leaves the flag dangling).
Related errors
- missing value for --workspace
- missing value for --model
- missing value for --agent
- missing value for --toolkit
- missing value for {arg}
AI-assisted analysis of tinyhumansai/openhuman@a221052e0d (2026-08-16).
Data as JSON: /api/errors/350cf936619413b1.
Report an issue: GitHub.