mirror of
https://github.com/openai/codex.git
synced 2026-10-31 19:28:49 +00:00
Ignore project instructions for untrusted projects (#39837)
## What changed - Skip project-scoped `AGENTS.md` discovery when the active project is untrusted, while preserving user-level instructions. - Include the active project trust level in the instruction cache key so runtime trust changes reload the applicable instructions. - Preserve updated project trust metadata during runtime configuration refreshes. ## Testing Add coverage for initially untrusted projects and for switching between trusted and untrusted states at runtime. GitOrigin-RevId: 284bf7693943f585013fb5fe4b6aa3309bc50cf3
This commit is contained in:
@@ -1752,6 +1752,7 @@ impl Session {
|
||||
let previous_config = notify_config_contributors
|
||||
.then(|| self.build_effective_session_config(&state.session_configuration));
|
||||
let mut config = (*state.session_configuration.original_config_do_not_use).clone();
|
||||
config.active_project = next_config.active_project.clone();
|
||||
config.config_layer_stack = config
|
||||
.config_layer_stack
|
||||
.with_user_layer_from(&next_config.config_layer_stack);
|
||||
|
||||
Reference in New Issue
Block a user