Hmbown/CodeWhale · error · anyhow::Error
Unsupported MCP transport '{transport}'. Supported values: s
Error message
Unsupported MCP transport '{transport}'. Supported values: sse What it means
validate_mcp_transport only accepts the value "sse" (compared case-insensitively after trimming); any other explicit transport string in an MCP server config is rejected with this message. Omitting the transport field entirely is valid - validation returns Ok(()) for None. The message deliberately lists the single supported value.
Source
Thrown at crates/tui/src/mcp.rs:1380
}
}
fn is_legacy_sse_transport(config: &McpServerConfig) -> bool {
config
.transport
.as_deref()
.map(|transport| transport.trim().eq_ignore_ascii_case("sse"))
.unwrap_or(false)
}
pub fn validate_mcp_transport(transport: Option<&str>) -> Result<()> {
let Some(transport) = transport else {
return Ok(());
};
if transport.trim().eq_ignore_ascii_case("sse") {
return Ok(());
}
anyhow::bail!("Unsupported MCP transport '{transport}'. Supported values: sse");
}
fn response_id_matches(id: Option<&serde_json::Value>, expected_id: &str) -> bool {
let Some(id) = id else {
return false;
};
if id.as_str() == Some(expected_id) {
return true;
}
id.as_u64()
.map(|id| id.to_string() == expected_id)
.unwrap_or(false)
}
// === McpConnection - Async Connection Management ===
/// Manages a single async connection to an MCP server
pub struct McpConnection {View on GitHub (pinned to 0c42157ee5)
Solutions
- Remove the transport field from the server entry; the url field alone determines the HTTP/SSE behavior
- If you keep the field, set it to exactly "sse" (case-insensitive)
- For local servers, drop url/transport and use "command" instead (stdio subprocess, no transport field needed)
Example fix
// before
{"servers": {"api": {"url": "https://example.com/mcp", "transport": "http"}}}
// after
{"servers": {"api": {"url": "https://example.com/mcp"}}} Defensive patterns
Strategy: validation
Validate before calling
fn validTransport(value: Option<&str>) -> bool {
match value {
None => true,
Some(t) => t.trim().eq_ignore_ascii_case("sse"),
}
} Prevention
- Omit the transport field unless you specifically mean SSE
- Validate config files with the same rule before shipping: only "sse" is accepted
- Rely on the url field to select remote transports; do not copy transport enums from other clients
When it happens
Trigger: An MCP server config entry with "transport": "http", "stdio", "streamable-http", or any other string besides "sse", passed through config load or validate_mcp_transport.
Common situations: Copying a config from a client that supports richer transport enums; manually setting transport when the URL scheme already implies it; believing 'streamable-http' is a selectable option here (this build only gates the SSE transport field).
Related errors
- Unsupported MCP transport '{transport}'. Supported values: s
- MCP server '{name}' config must have either 'command' or 'ur
- workspace path cannot be empty
- Provide either a command or URL for MCP server '{name}'.
- Model name cannot be empty
AI-assisted analysis of Hmbown/CodeWhale@0c42157ee5 (2026-08-20).
Data as JSON: /api/errors/a93d0af07ab52bf2.
Report an issue: GitHub.