mirror of
https://github.com/openai/codex.git
synced 2026-11-13 14:46:14 +00:00
Handle malformed agent role definitions nonfatally (#14488)
## Summary - make malformed agent role definitions nonfatal during config loading - drop invalid agent roles and record warnings in `startup_warnings` - forward startup warnings through app-server `configWarning` notifications ## Testing - `cargo test -p codex-core agent_role_ -- --nocapture` - `just fix -p codex-core` - `just fmt` - `cargo test -p codex-app-server config_warning -- --nocapture` Co-authored-by: Codex <noreply@openai.com>
This commit is contained in:
1 parent
cfe3f6821a
commit
4fa7d6f444
4 files changed
+159
-49
No files matched your search
@@ -2085,7 +2085,8 @@ impl Config {
|
||||
.unwrap_or(WebSearchMode::Cached);
|
||||
let web_search_config = resolve_web_search_config(&cfg, &config_profile);
|
||||
|
||||
let agent_roles = agent_roles::load_agent_roles(&cfg, &config_layer_stack)?;
|
||||
let agent_roles =
|
||||
agent_roles::load_agent_roles(&cfg, &config_layer_stack, &mut startup_warnings)?;
|
||||
|
||||
let mut model_providers = built_in_model_providers();
|
||||
// Merge user-defined providers into the built-in list.
|
||||
|
||||
Reference in new issue
Block a user