Hmbown/CodeWhale · error
This Codewhale account is configured for agent provider
Error message
This Codewhale account is configured for agent provider `{provider}`, which this CLI build does not know. Upgrade `codewhale`, or choose a supported provider in the Codewhale app. What it means
The CLI reads the account's configured agent provider (`agent.model_provider`) and maps it via `parse_route_kind`. If the account is set to a provider identifier this build's route parser does not know, it throws this error advising an upgrade or a provider change in the Codewhale app.
Solutions
- Upgrade `codewhale` to the latest release so the new provider id is known.
- Choose a supported provider for the agent in the Codewhale web app, or run `codewhale account keys set <provider>`.
- Check `codewhale --version` against the latest release if the provider is newly announced.
Defensive patterns
Strategy: fallback
Validate before calling
// check the installed build knows the provider before syncing account config
if parse_route_kind(account.agent.model_provider).is_none() {
eprintln!("upgrade codewhale or change the agent provider in the Codewhale app");
} Prevention
- Keep the CLI on the latest release when switching providers in the web app.
- Pick providers listed as supported by your CLI build.
- Test account sync after provider changes.
When it happens
Trigger: The Codewhale account (synced from the app) has `agent.model_provider` set to a provider id that `parse_route_kind` cannot resolve in the installed CLI build.
Common situations: Older CLI version predating a newly added provider; account switched to a beta/renamed provider in the web app; stale build distributed before the provider shipped.
Related errors
- Failed to resolve runtime thread route
- {reason}
- 127
- A pinned task provider requires an explicit model
- A provider and page loader are required.
AI-assisted analysis of Hmbown/CodeWhale@73e0f67d83 (2026-09-22).
Data as JSON: /api/errors/f59ecbce501b5132.
Report an issue: GitHub.
Appendix: source
Thrown at crates/cli/src/cloud/machine.rs:1183
/// Map the account's configured provider identifier onto a local route.
///
/// `codewhale review` hard-errors when a model resolves to several configured
/// routes. When CI authenticates with a machine key the account has already
/// answered that question, so the account's own provider is the disambiguator
/// — no new flag, and no guess.
pub(crate) fn review_provider_from_agent(agent: &AgentState) -> Result<ProviderKind> {
if !agent.configured {
return Err(anyhow::Error::new(MachineError::new(
409,
"account_agent_model_unconfigured",
"This Codewhale account has no agent model configured. Choose one in the Codewhale \
app, or run `codewhale account keys set <provider>`.",
EXIT_AGENT_UNCONFIGURED,
)));
}
let provider = agent.model_provider.trim();
parse_route_kind(provider).ok_or_else(|| {
anyhow!(
"This Codewhale account is configured for agent provider `{}`, which this CLI build \
does not know. Upgrade `codewhale`, or choose a supported provider in the Codewhale app.",
printable(provider)
)
})
}
#[cfg(test)]
mod tests;
View on GitHub (pinned to 73e0f67d83)