{"record":{"id":"a8c90f8bba85d4ae","repo":"openai/codex","slug":"invalidinput-a8c90f","errorCode":"InvalidInput","errorMessage":"`ollama-chat` is no longer supported.\nHow to fix: replace `ollama-chat` with `ollama` in `model_provider`, `oss_provider`, or `--local-provider`.\nMore info: https://github.com/openai/codex/discussions/7782","messagePattern":"`ollama-chat` is no longer supported\\.\nHow to fix: replace `ollama-chat` with `ollama` in `model_provider`, `oss_provider`, or `--local-provider`\\.\nMore info: https://github\\.com/openai/codex/discussions/7782","errorType":"validation","errorClass":"std::io::Error","httpStatus":null,"severity":"error","filePath":"codex-rs/config/src/config_toml.rs","lineNumber":956,"sourceCode":"fn deserialize_model_providers<'de, D>(\n    deserializer: D,\n) -> Result<HashMap<String, ModelProviderInfo>, D::Error>\nwhere\n    D: serde::Deserializer<'de>,\n{\n    let model_providers = HashMap::<String, ModelProviderInfo>::deserialize(deserializer)?;\n    validate_model_providers(&model_providers).map_err(serde::de::Error::custom)?;\n    Ok(model_providers)\n}\n\n#[cfg(test)]\n#[path = \"bedrock_runtime_tests.rs\"]\nmod bedrock_runtime_tests;\n\npub fn validate_oss_provider(provider: &str) -> std::io::Result<()> {\n    match provider {\n        LMSTUDIO_OSS_PROVIDER_ID | OLLAMA_OSS_PROVIDER_ID => Ok(()),\n        LEGACY_OLLAMA_CHAT_PROVIDER_ID => Err(std::io::Error::new(\n            std::io::ErrorKind::InvalidInput,\n            OLLAMA_CHAT_PROVIDER_REMOVED_ERROR,\n        )),\n        _ => Err(std::io::Error::new(\n            std::io::ErrorKind::InvalidInput,\n            format!(\n                \"Invalid OSS provider '{provider}'. Must be one of: {LMSTUDIO_OSS_PROVIDER_ID}, {OLLAMA_OSS_PROVIDER_ID}\"\n            ),\n        )),\n    }\n}\n\n#[cfg(test)]\nmod tests {\n    use super::*;\n    use pretty_assertions::assert_eq;\n\n    const WORKSPACE_ID_A: &str = \"123e4567-e89b-42d3-a456-426614174000\";","sourceCodeStart":938,"sourceCodeEnd":974,"githubUrl":"https://github.com/openai/codex/blob/339751715c64496cb86246bfb3935f40e309dd3d/codex-rs/config/src/config_toml.rs#L938-L974","documentation":"validate_oss_provider in codex-rs/config/src/config_toml.rs:956 hard-rejects the removed provider id 'ollama-chat' (LEGACY_OLLAMA_CHAT_PROVIDER_ID) with ErrorKind::InvalidInput. The ollama-chat provider was merged into 'ollama', so the old id fails fast with migration instructions and a link to the removal discussion instead of being silently remapped.","triggerScenarios":"Setting model_provider = \"ollama-chat\" or oss_provider = \"ollama-chat\" in config.toml (including profiles), or passing --local-provider ollama-chat; validate_oss_provider runs during config load and returns the InvalidInput error immediately.","commonSituations":"Upgrading codex-rs past the removal while an old config.toml, a shared dotfiles profile, or CI wrapper scripts still say ollama-chat; following tutorials written before the merge.","solutions":["Replace ollama-chat with ollama in model_provider, oss_provider, or --local-provider everywhere it appears","Search every profile and override: rg ollama-chat ~/.codex/config.toml and fix each hit","See https://github.com/openai/codex/discussions/7782 for the migration details"],"exampleFix":"# ~/.codex/config.toml (before)\noss_provider = \"ollama-chat\"\n\n# (after)\noss_provider = \"ollama\"","handlingStrategy":"validation","validationCode":"const LEGACY_OLLAMA_CHAT: &str = \"ollama-chat\";\nlet provider = if provider == LEGACY_OLLAMA_CHAT {\n    \"ollama\".to_string() // migrate on read\n} else {\n    provider\n};\nvalidate_oss_provider(&provider)?;","typeGuard":"fn is_supported_oss_provider(p: &str) -> bool {\n    matches!(p, \"ollama\" | \"lmstudio\")\n}","tryCatchPattern":"match validate_oss_provider(&provider) {\n    Err(e) if e.kind() == std::io::ErrorKind::InvalidInput\n        && e.to_string().contains(\"ollama-chat\") =>\n    {\n        // rewrite the stored config value to \"ollama\" and retry once\n    }\n    other => other?,\n}","preventionTips":["Run a config lint that greps for removed provider ids after every codex upgrade","Use only the canonical ids ollama and lmstudio in templates and docs","Treat provider-rename announcements as config migration tasks"],"tags":["config","provider","ollama","deprecation","migration","rust"],"backgroundTag":"deprecated-option-removed","analyzedSha":"339751715c64496cb86246bfb3935f40e309dd3d","analyzedAt":"2026-08-25T05:35:09.876Z","schemaVersion":2},"datasetVersion":"2026-08-25T06:17:31.827Z"}