tinyhumansai/openhuman · error
unknown mcp arg: {other}
Error message
unknown mcp arg: {other} What it means
The `openhuman mcp` argument loop recognizes only -v/--verbose, --transport, --host, --port, --auth-token, and -h/--help; any other token — an unknown flag or a stray positional — aborts parsing immediately with the offending token echoed.
Source
Thrown at src/openhuman/mcp/server/stdio.rs:76
.parse()
.map_err(|_| anyhow::anyhow!("invalid --port value `{raw}`"))?;
index += 2;
}
"--auth-token" => {
let token = args
.get(index + 1)
.ok_or_else(|| anyhow::anyhow!("missing value for --auth-token"))?;
if token.trim().is_empty() {
bail!("--auth-token must not be empty");
}
auth_token = Some(token.trim().to_string());
index += 2;
}
"-h" | "--help" => {
print_help();
return Ok(());
}
other => bail!("unknown mcp arg: {other}"),
}
}
init_mcp_logging(verbose);
let rt = tokio::runtime::Builder::new_multi_thread()
.enable_all()
.build()?;
match transport {
McpTransport::Stdio => {
log::debug!("[mcp_server] starting stdio MCP server");
rt.block_on(async { run_stdio(tokio::io::stdin(), tokio::io::stdout()).await })?;
}
McpTransport::Http => {
#[cfg(feature = "http-server")]
{
let bind_addr: SocketAddr =View on GitHub (pinned to 7491200858)
Solutions
- Run `openhuman mcp --help` (print_help) to list the accepted flags for your build.
- Remove the unsupported flag; if it configured real behavior, find the equivalent in the core's config file.
- Update wrapper scripts pinned to an older CLI surface.
Example fix
# before $ openhuman mcp --transport stdio --scope user error: unknown mcp arg: --scope # after $ openhuman mcp --help # accepted: -v/--verbose, --transport, --host, --port, --auth-token, -h/--help $ openhuman mcp --transport stdio
Defensive patterns
Strategy: validation
Validate before calling
const MCP_ARGS: &[&str] = &["-v", "--verbose", "--transport", "--host", "--port", "--auth-token", "-h", "--help"]; // reject unknown tokens before spawning the subprocess
Prevention
- Version-pin wrapper scripts against the CLI they were written for.
- Smoke-test `openhuman mcp --help` output in deploy pipelines to catch surface drift.
- Keep host/port/token in the documented flag forms rather than inventing new ones.
When it happens
Trigger: Passing flags from another version or another tool's CLI (e.g. `--scope`, `--server`, `-s`) or a stray positional argument after `mcp`. The parse loop is a strict whitelist, so anything unrecognized lands here.
Common situations: Scripts written for a different MCP client; docs drift between versions; config snippets copy-pasted from Claude Desktop/Cursor examples.
Related errors
- unknown --transport value `{other}` (expected stdio or http)
- --auth-token must not be empty
- mcp feature disabled at compile time: this build was compile
- Socket not connected
- Invalid ${paramName}: ${value}. Must be a positive integer.
AI-assisted analysis of tinyhumansai/openhuman@7491200858 (2026-08-17).
Data as JSON: /api/errors/856ef188e287ea51.
Report an issue: GitHub.