mirror of
https://github.com/openai/codex.git
synced 2026-11-11 02:21:10 +00:00
Reject ask user question tool in Execute and Custom (#9560)
## Summary - Keep `request_user_input` in the tool list but reject it at runtime in Execute/Custom modes with a clear model-facing error. - Add a session accessor for current collaboration mode and enforce the gate in the request_user_input handler. - Update core/app-server tests to use Plan mode for success and add Execute/Custom rejection coverage.
This commit is contained in:
1 parent
531748a080
commit
0523a259c8
4 files changed
+161
-1
No files matched your search
@@ -1531,6 +1531,11 @@ impl Session {
|
||||
self.features.clone()
|
||||
}
|
||||
|
||||
pub(crate) async fn collaboration_mode(&self) -> CollaborationMode {
|
||||
let state = self.state.lock().await;
|
||||
state.session_configuration.collaboration_mode.clone()
|
||||
}
|
||||
|
||||
async fn send_raw_response_items(&self, turn_context: &TurnContext, items: &[ResponseItem]) {
|
||||
for item in items {
|
||||
self.send_event(
|
||||
|
||||
Reference in new issue
Block a user