mirror of
https://github.com/openai/codex.git
synced 2026-06-01 19:02:59 +00:00
feat: include [experimental_network] in <environment_context> (#11044)
If `NetworkConstraints` is set, then include the relevant settings on `<environment_context>`. Example:
```xml
<environment_context>
<cwd>/repo</cwd>
<shell>bash</shell>
<network enabled="true">
<allowed>api.example.com</allowed>
<allowed>*.openai.com</allowed>
<denied>blocked.example.com</denied>
</network>
</environment_context>
```
This commit is contained in:
@@ -2204,9 +2204,9 @@ impl Session {
|
||||
.into(),
|
||||
);
|
||||
}
|
||||
items.push(ResponseItem::from(EnvironmentContext::new(
|
||||
Some(turn_context.cwd.clone()),
|
||||
shell.as_ref().clone(),
|
||||
items.push(ResponseItem::from(EnvironmentContext::from_turn_context(
|
||||
turn_context,
|
||||
shell.as_ref(),
|
||||
)));
|
||||
items
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user