mirror of
https://github.com/openai/codex.git
synced 2026-10-28 18:58:46 +00:00
codex: seed turn metadata from app-server turn start
Co-authored-by: Codex <noreply@openai.com>
This commit is contained in:
co-authored by
Codex
parent
db3ddeae35
commit
6e8ebdc5bc
@@ -20,6 +20,7 @@ use core_test_support::responses;
|
||||
use core_test_support::test_codex::test_codex;
|
||||
use futures::StreamExt;
|
||||
use pretty_assertions::assert_eq;
|
||||
use serde_json::json;
|
||||
use tempfile::TempDir;
|
||||
use wiremock::matchers::header;
|
||||
|
||||
@@ -546,3 +547,129 @@ async fn responses_stream_includes_turn_metadata_header_for_git_workspace_e2e()
|
||||
Some(false)
|
||||
);
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
async fn responses_stream_includes_parent_headers_from_turn_metadata() {
|
||||
core_test_support::skip_if_no_network!();
|
||||
|
||||
let server = responses::start_mock_server().await;
|
||||
let request_recorder = responses::mount_sse_once(
|
||||
&server,
|
||||
responses::sse(vec![
|
||||
responses::ev_response_created("resp-1"),
|
||||
responses::ev_completed("resp-1"),
|
||||
]),
|
||||
)
|
||||
.await;
|
||||
|
||||
let provider = ModelProviderInfo {
|
||||
name: "mock".into(),
|
||||
base_url: Some(format!("{}/v1", server.uri())),
|
||||
env_key: None,
|
||||
env_key_instructions: None,
|
||||
experimental_bearer_token: None,
|
||||
wire_api: WireApi::Responses,
|
||||
query_params: None,
|
||||
http_headers: None,
|
||||
env_http_headers: None,
|
||||
request_max_retries: Some(0),
|
||||
stream_max_retries: Some(0),
|
||||
stream_idle_timeout_ms: Some(5_000),
|
||||
websocket_connect_timeout_ms: None,
|
||||
requires_openai_auth: false,
|
||||
supports_websockets: false,
|
||||
};
|
||||
|
||||
let codex_home = TempDir::new().expect("failed to create TempDir");
|
||||
let mut config = load_default_config_for_test(&codex_home).await;
|
||||
config.model_provider_id = provider.name.clone();
|
||||
config.model_provider = provider.clone();
|
||||
let effort = config.model_reasoning_effort;
|
||||
let summary = config.model_reasoning_summary;
|
||||
let model = codex_core::test_support::get_model_offline(config.model.as_deref());
|
||||
config.model = Some(model.clone());
|
||||
let config = Arc::new(config);
|
||||
|
||||
let conversation_id = ThreadId::new();
|
||||
let auth_mode = TelemetryAuthMode::Chatgpt;
|
||||
let session_source = SessionSource::Exec;
|
||||
let model_info =
|
||||
codex_core::test_support::construct_model_info_offline(model.as_str(), &config);
|
||||
let session_telemetry = SessionTelemetry::new(
|
||||
conversation_id,
|
||||
model.as_str(),
|
||||
model_info.slug.as_str(),
|
||||
None,
|
||||
Some("test@test.com".to_string()),
|
||||
Some(auth_mode),
|
||||
"test_originator".to_string(),
|
||||
false,
|
||||
"test".to_string(),
|
||||
session_source.clone(),
|
||||
);
|
||||
|
||||
let client = ModelClient::new(
|
||||
None,
|
||||
conversation_id,
|
||||
provider,
|
||||
session_source,
|
||||
config.model_verbosity,
|
||||
false,
|
||||
false,
|
||||
false,
|
||||
None,
|
||||
);
|
||||
let mut client_session = client.new_session();
|
||||
|
||||
let mut prompt = Prompt::default();
|
||||
prompt.input = vec![ResponseItem::Message {
|
||||
id: None,
|
||||
role: "user".into(),
|
||||
content: vec![ContentItem::InputText {
|
||||
text: "hello".into(),
|
||||
}],
|
||||
end_turn: None,
|
||||
phase: None,
|
||||
}];
|
||||
let turn_metadata_header = serde_json::to_string(&json!({
|
||||
"turn_id": "turn-123",
|
||||
"metadata": {
|
||||
"parentConversationId": "conv-123",
|
||||
"parentMessageId": "msg-123",
|
||||
"parentTurnId": "turn-123",
|
||||
},
|
||||
}))
|
||||
.expect("turn metadata json");
|
||||
|
||||
let mut stream = client_session
|
||||
.stream(
|
||||
&prompt,
|
||||
&model_info,
|
||||
&session_telemetry,
|
||||
effort,
|
||||
summary.unwrap_or(model_info.default_reasoning_summary),
|
||||
None,
|
||||
Some(turn_metadata_header.as_str()),
|
||||
)
|
||||
.await
|
||||
.expect("stream failed");
|
||||
while let Some(event) = stream.next().await {
|
||||
if matches!(event, Ok(ResponseEvent::Completed { .. })) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
let request = request_recorder.single_request();
|
||||
assert_eq!(
|
||||
request.header("x-openai-parent-conversation-id").as_deref(),
|
||||
Some("conv-123")
|
||||
);
|
||||
assert_eq!(
|
||||
request.header("x-openai-parent-message-id").as_deref(),
|
||||
Some("msg-123")
|
||||
);
|
||||
assert_eq!(
|
||||
request.header("x-openai-parent-turn-id").as_deref(),
|
||||
Some("turn-123")
|
||||
);
|
||||
}
|
||||
|
||||
@@ -51,6 +51,8 @@ async fn interrupt_long_running_tool_emits_turn_aborted() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -105,6 +107,8 @@ async fn interrupt_tool_records_history_entries() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -123,6 +127,8 @@ async fn interrupt_tool_records_history_entries() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -203,6 +209,8 @@ async fn interrupt_persists_turn_aborted_marker_in_next_request() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -221,6 +229,8 @@ async fn interrupt_persists_turn_aborted_marker_in_next_request() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
|
||||
@@ -277,6 +277,8 @@ async fn resume_includes_initial_messages_and_sends_prior_items() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -639,6 +641,8 @@ async fn includes_conversation_id_and_model_headers_in_request() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -687,6 +691,8 @@ async fn includes_base_instructions_override_in_request() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -739,6 +745,8 @@ async fn chatgpt_auth_sends_correct_request() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -841,6 +849,8 @@ async fn prefers_apikey_when_config_prefers_apikey_even_with_chatgpt_tokens() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -877,6 +887,8 @@ async fn includes_user_instructions_message_in_request() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -962,6 +974,8 @@ async fn includes_apps_guidance_as_developer_message_for_chatgpt_auth() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1050,6 +1064,8 @@ async fn omits_apps_guidance_for_api_key_auth_even_when_feature_enabled() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1120,6 +1136,8 @@ async fn skills_append_to_developer_message() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1171,6 +1189,8 @@ async fn includes_configured_effort_in_request() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1213,6 +1233,8 @@ async fn includes_no_effort_in_request() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1253,6 +1275,8 @@ async fn includes_default_reasoning_effort_in_request_when_defined_by_model_info
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1364,6 +1388,8 @@ async fn configured_reasoning_summary_is_sent() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1478,6 +1504,8 @@ async fn reasoning_summary_is_omitted_when_disabled() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1534,6 +1562,8 @@ async fn reasoning_summary_none_overrides_model_catalog_default() -> anyhow::Res
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1570,6 +1600,8 @@ async fn includes_default_verbosity_in_request() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1615,6 +1647,8 @@ async fn configured_verbosity_not_sent_for_models_without_support() -> anyhow::R
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1659,6 +1693,8 @@ async fn configured_verbosity_is_sent() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1708,6 +1744,8 @@ async fn includes_developer_instructions_message_in_request() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1992,6 +2030,8 @@ async fn token_count_includes_rate_limits_snapshot() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2157,6 +2197,8 @@ async fn usage_limit_error_emits_rate_limit_event() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.expect("submission should succeed while emitting usage limit error events");
|
||||
@@ -2231,6 +2273,8 @@ async fn context_window_error_sets_total_tokens_to_model_window() -> anyhow::Res
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -2243,6 +2287,8 @@ async fn context_window_error_sets_total_tokens_to_model_window() -> anyhow::Res
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -2325,6 +2371,8 @@ async fn incomplete_response_emits_content_filter_error_message() -> anyhow::Res
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -2423,6 +2471,8 @@ async fn azure_overrides_assign_properties_used_for_responses_url() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2508,6 +2558,8 @@ async fn env_var_overrides_loaded_auth() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2569,6 +2621,8 @@ async fn history_dedupes_streamed_and_final_messages_across_turns() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2582,6 +2636,8 @@ async fn history_dedupes_streamed_and_final_messages_across_turns() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2595,6 +2651,8 @@ async fn history_dedupes_streamed_and_final_messages_across_turns() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
|
||||
@@ -996,6 +996,8 @@ async fn responses_websocket_usage_limit_error_emits_rate_limit_event() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.expect("submission should succeed while emitting usage limit error events");
|
||||
@@ -1081,6 +1083,8 @@ async fn responses_websocket_invalid_request_error_with_status_is_forwarded() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.expect("submission should succeed while emitting invalid request events");
|
||||
|
||||
@@ -84,6 +84,8 @@ async fn no_collaboration_instructions_by_default() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -143,6 +145,8 @@ async fn user_input_includes_collaboration_instructions_after_override() -> Resu
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -240,6 +244,8 @@ async fn override_then_next_turn_uses_updated_collaboration_instructions() -> Re
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -362,6 +368,8 @@ async fn collaboration_mode_update_emits_new_instruction_message() -> Result<()>
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -389,6 +397,8 @@ async fn collaboration_mode_update_emits_new_instruction_message() -> Result<()>
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -445,6 +455,8 @@ async fn collaboration_mode_update_noop_does_not_append() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -472,6 +484,8 @@ async fn collaboration_mode_update_noop_does_not_append() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -530,6 +544,8 @@ async fn collaboration_mode_update_emits_new_instruction_message_when_mode_chang
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -560,6 +576,8 @@ async fn collaboration_mode_update_emits_new_instruction_message_when_mode_chang
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -619,6 +637,8 @@ async fn collaboration_mode_update_noop_does_not_append_when_mode_is_unchanged()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -649,6 +669,8 @@ async fn collaboration_mode_update_noop_does_not_append_when_mode_is_unchanged()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -712,6 +734,8 @@ async fn resume_replays_collaboration_instructions() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&initial.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -725,6 +749,8 @@ async fn resume_replays_collaboration_instructions() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&resumed.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -781,6 +807,8 @@ async fn empty_collaboration_instructions_are_ignored() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
|
||||
@@ -242,6 +242,8 @@ async fn summarize_context_three_requests_and_instructions() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -264,6 +266,8 @@ async fn summarize_context_three_requests_and_instructions() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -440,6 +444,8 @@ async fn manual_compact_uses_custom_prompt() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.expect("submit first user turn");
|
||||
@@ -584,6 +590,8 @@ async fn manual_compact_emits_context_compaction_items() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -747,6 +755,8 @@ async fn multiple_auto_compact_per_task_runs_after_token_limit_hit() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.expect("submit user input");
|
||||
@@ -1246,6 +1256,8 @@ async fn auto_compact_runs_after_token_limit_hit() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1259,6 +1271,8 @@ async fn auto_compact_runs_after_token_limit_hit() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1272,6 +1286,8 @@ async fn auto_compact_runs_after_token_limit_hit() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1440,6 +1456,8 @@ async fn auto_compact_emits_context_compaction_items() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1518,6 +1536,8 @@ async fn auto_compact_starts_after_turn_started() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1530,6 +1550,8 @@ async fn auto_compact_starts_after_turn_started() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1542,6 +1564,8 @@ async fn auto_compact_starts_after_turn_started() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2029,6 +2053,8 @@ async fn auto_compact_persists_rollout_entries() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2041,6 +2067,8 @@ async fn auto_compact_persists_rollout_entries() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2053,6 +2081,8 @@ async fn auto_compact_persists_rollout_entries() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2139,6 +2169,8 @@ async fn manual_compact_retries_after_context_window_error() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2250,6 +2282,8 @@ async fn manual_compact_non_context_failure_retries_then_emits_task_error() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.expect("submit user input");
|
||||
@@ -2342,6 +2376,8 @@ async fn manual_compact_twice_preserves_latest_user_messages() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2357,6 +2393,8 @@ async fn manual_compact_twice_preserves_latest_user_messages() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2372,6 +2410,8 @@ async fn manual_compact_twice_preserves_latest_user_messages() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2533,6 +2573,8 @@ async fn auto_compact_allows_multiple_attempts_when_interleaved_with_other_turn_
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2635,6 +2677,8 @@ async fn snapshot_request_shape_mid_turn_continuation_compaction() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2829,6 +2873,8 @@ async fn auto_compact_counts_encrypted_reasoning_before_last_user() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -2946,6 +2992,8 @@ async fn auto_compact_runs_when_reasoning_header_clears_between_turns() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -3005,6 +3053,8 @@ async fn snapshot_request_shape_pre_turn_compaction_including_incoming_user_mess
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.expect("submit user input");
|
||||
@@ -3040,6 +3090,8 @@ async fn snapshot_request_shape_pre_turn_compaction_including_incoming_user_mess
|
||||
},
|
||||
],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.expect("submit user input");
|
||||
@@ -3250,6 +3302,8 @@ async fn snapshot_request_shape_pre_turn_compaction_context_window_exceeded() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.expect("submit first user");
|
||||
@@ -3262,6 +3316,8 @@ async fn snapshot_request_shape_pre_turn_compaction_context_window_exceeded() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.expect("submit second user");
|
||||
@@ -3332,6 +3388,8 @@ async fn snapshot_request_shape_manual_compact_without_previous_user_messages()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.expect("submit follow-up user input");
|
||||
|
||||
@@ -235,6 +235,8 @@ async fn remote_compact_replaces_history_for_followups() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -249,6 +251,8 @@ async fn remote_compact_replaces_history_for_followups() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -379,6 +383,8 @@ async fn remote_compact_runs_automatically() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -453,6 +459,8 @@ async fn remote_compact_trims_function_call_history_to_fit_context_window() -> R
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |event| matches!(event, EventMsg::TurnComplete(_))).await;
|
||||
@@ -464,6 +472,8 @@ async fn remote_compact_trims_function_call_history_to_fit_context_window() -> R
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |event| matches!(event, EventMsg::TurnComplete(_))).await;
|
||||
@@ -573,6 +583,8 @@ async fn auto_remote_compact_trims_function_call_history_to_fit_context_window()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |event| matches!(event, EventMsg::TurnComplete(_))).await;
|
||||
@@ -584,6 +596,8 @@ async fn auto_remote_compact_trims_function_call_history_to_fit_context_window()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |event| matches!(event, EventMsg::TurnComplete(_))).await;
|
||||
@@ -601,6 +615,8 @@ async fn auto_remote_compact_trims_function_call_history_to_fit_context_window()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |event| matches!(event, EventMsg::TurnComplete(_))).await;
|
||||
@@ -698,6 +714,8 @@ async fn auto_remote_compact_failure_stops_agent_loop() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |event| matches!(event, EventMsg::TurnComplete(_))).await;
|
||||
@@ -709,6 +727,8 @@ async fn auto_remote_compact_failure_stops_agent_loop() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -800,6 +820,8 @@ async fn remote_compact_trim_estimate_uses_session_base_instructions() -> Result
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&baseline_codex, |event| {
|
||||
@@ -814,6 +836,8 @@ async fn remote_compact_trim_estimate_uses_session_base_instructions() -> Result
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&baseline_codex, |event| {
|
||||
@@ -899,6 +923,8 @@ async fn remote_compact_trim_estimate_uses_session_base_instructions() -> Result
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&override_codex, |event| {
|
||||
@@ -913,6 +939,8 @@ async fn remote_compact_trim_estimate_uses_session_base_instructions() -> Result
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&override_codex, |event| {
|
||||
@@ -981,6 +1009,8 @@ async fn remote_manual_compact_emits_context_compaction_items() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |event| matches!(event, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1059,6 +1089,8 @@ async fn remote_manual_compact_failure_emits_task_error_event() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |event| matches!(event, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1141,6 +1173,8 @@ async fn remote_compact_persists_replacement_history_in_rollout() -> Result<()>
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1282,6 +1316,8 @@ async fn remote_compact_and_resume_refresh_stale_developer_instructions() -> Res
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&initial.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1297,6 +1333,8 @@ async fn remote_compact_and_resume_refresh_stale_developer_instructions() -> Res
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&initial.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1319,6 +1357,8 @@ async fn remote_compact_and_resume_refresh_stale_developer_instructions() -> Res
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&resumed.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1413,6 +1453,8 @@ async fn remote_compact_refreshes_stale_developer_instructions_without_resume()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1427,6 +1469,8 @@ async fn remote_compact_refreshes_stale_developer_instructions_without_resume()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1496,6 +1540,8 @@ async fn snapshot_request_shape_remote_pre_turn_compaction_restates_realtime_sta
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1507,6 +1553,8 @@ async fn snapshot_request_shape_remote_pre_turn_compaction_restates_realtime_sta
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1571,6 +1619,8 @@ async fn remote_request_uses_custom_experimental_realtime_start_instructions() -
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1629,6 +1679,8 @@ async fn snapshot_request_shape_remote_pre_turn_compaction_restates_realtime_end
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1642,6 +1694,8 @@ async fn snapshot_request_shape_remote_pre_turn_compaction_restates_realtime_end
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1714,6 +1768,8 @@ async fn snapshot_request_shape_remote_manual_compact_restates_realtime_start()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1728,6 +1784,8 @@ async fn snapshot_request_shape_remote_manual_compact_restates_realtime_start()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1808,6 +1866,8 @@ async fn snapshot_request_shape_remote_mid_turn_compaction_does_not_restate_real
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1821,6 +1881,8 @@ async fn snapshot_request_shape_remote_mid_turn_compaction_does_not_restate_real
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1909,6 +1971,8 @@ async fn snapshot_request_shape_remote_compact_resume_restates_realtime_end() ->
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&initial.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -1936,6 +2000,8 @@ async fn snapshot_request_shape_remote_compact_resume_restates_realtime_end() ->
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&resumed.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -2029,6 +2095,8 @@ async fn snapshot_request_shape_remote_pre_turn_compaction_including_incoming_us
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -2113,6 +2181,8 @@ async fn snapshot_request_shape_remote_pre_turn_compaction_strips_incoming_model
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -2139,6 +2209,8 @@ async fn snapshot_request_shape_remote_pre_turn_compaction_strips_incoming_model
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -2255,6 +2327,8 @@ async fn snapshot_request_shape_remote_pre_turn_compaction_context_window_exceed
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -2266,6 +2340,8 @@ async fn snapshot_request_shape_remote_pre_turn_compaction_context_window_exceed
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
let error_message = wait_for_event_match(&codex, |event| match event {
|
||||
@@ -2348,6 +2424,8 @@ async fn snapshot_request_shape_remote_mid_turn_continuation_compaction() -> Res
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -2423,6 +2501,8 @@ async fn snapshot_request_shape_remote_mid_turn_compaction_summary_only_reinject
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -2506,6 +2586,8 @@ async fn snapshot_request_shape_remote_mid_turn_compaction_multi_summary_reinjec
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -2520,6 +2602,8 @@ async fn snapshot_request_shape_remote_mid_turn_compaction_multi_summary_reinjec
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -2599,6 +2683,8 @@ async fn snapshot_request_shape_remote_manual_compact_without_previous_user_mess
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
|
||||
@@ -651,6 +651,8 @@ async fn user_turn(conversation: &Arc<CodexThread>, text: &str) {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.expect("submit user turn");
|
||||
|
||||
@@ -52,6 +52,8 @@ async fn fork_thread_twice_drops_to_first_message() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
|
||||
@@ -60,6 +60,8 @@ async fn user_message_item_is_emitted() -> anyhow::Result<()> {
|
||||
.submit(Op::UserInput {
|
||||
items: vec![expected_input.clone()],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -116,6 +118,8 @@ async fn assistant_message_item_is_emitted() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -174,6 +178,8 @@ async fn reasoning_item_is_emitted() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -233,6 +239,8 @@ async fn web_search_item_is_emitted() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -288,6 +296,8 @@ async fn image_generation_call_event_is_emitted() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -341,6 +351,8 @@ async fn image_generation_call_event_is_emitted_when_image_save_fails() -> anyho
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -394,6 +406,8 @@ async fn agent_message_content_delta_has_item_metadata() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -1036,6 +1050,8 @@ async fn reasoning_content_delta_has_item_metadata() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -1095,6 +1111,8 @@ async fn reasoning_raw_content_delta_respects_flag() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
|
||||
@@ -318,6 +318,8 @@ async fn snapshot_model_visible_layout_resume_with_personality_change() -> Resul
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |event| matches!(event, EventMsg::TurnComplete(_))).await;
|
||||
@@ -416,6 +418,8 @@ async fn snapshot_model_visible_layout_resume_override_matches_rollout_model() -
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |event| matches!(event, EventMsg::TurnComplete(_))).await;
|
||||
@@ -461,6 +465,8 @@ async fn snapshot_model_visible_layout_resume_override_matches_rollout_model() -
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&resumed.codex, |event| {
|
||||
|
||||
@@ -107,6 +107,8 @@ async fn responses_api_emits_api_request_event() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -150,6 +152,8 @@ async fn process_sse_emits_tracing_for_output_item() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -193,6 +197,8 @@ async fn process_sse_emits_failed_event_on_parse_error() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -237,6 +243,8 @@ async fn process_sse_records_failed_event_when_stream_closes_without_completed()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -301,6 +309,8 @@ async fn process_sse_failed_event_records_response_error_message() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -363,6 +373,8 @@ async fn process_sse_failed_event_logs_parse_error() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -412,6 +424,8 @@ async fn process_sse_failed_event_logs_missing_error() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -470,6 +484,8 @@ async fn process_sse_failed_event_logs_response_completed_parse_error() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -522,6 +538,8 @@ async fn process_sse_emits_completed_telemetry() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -594,6 +612,8 @@ async fn handle_responses_span_records_response_kind_and_tool_name() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -678,6 +698,8 @@ async fn record_responses_sets_span_fields_for_response_events() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -762,6 +784,8 @@ async fn handle_response_item_records_tool_result_for_custom_tool_call() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -835,6 +859,8 @@ async fn handle_response_item_records_tool_result_for_function_call() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -918,6 +944,8 @@ async fn handle_response_item_records_tool_result_for_local_shell_missing_ids()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -985,6 +1013,8 @@ async fn handle_response_item_records_tool_result_for_local_shell_call() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1093,6 +1123,8 @@ async fn handle_container_exec_autoapprove_from_config_records_tool_decision() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1144,6 +1176,8 @@ async fn handle_container_exec_user_approved_records_tool_decision() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1210,6 +1244,8 @@ async fn handle_container_exec_user_approved_for_session_records_tool_decision()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1276,6 +1312,8 @@ async fn handle_sandbox_error_user_approves_retry_records_tool_decision() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1342,6 +1380,8 @@ async fn handle_container_exec_user_denies_records_tool_decision() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1408,6 +1448,8 @@ async fn handle_sandbox_error_user_approves_for_session_records_tool_decision()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -1475,6 +1517,8 @@ async fn handle_sandbox_error_user_denies_records_tool_decision() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
|
||||
@@ -104,6 +104,8 @@ async fn injected_user_input_triggers_follow_up_request_with_deltas() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -120,6 +122,8 @@ async fn injected_user_input_triggers_follow_up_request_with_deltas() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
|
||||
@@ -66,6 +66,8 @@ async fn permissions_message_sent_once_on_start() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -107,6 +109,8 @@ async fn permissions_message_added_on_override_change() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -134,6 +138,8 @@ async fn permissions_message_added_on_override_change() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -181,6 +187,8 @@ async fn permissions_message_not_added_when_no_change() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -192,6 +200,8 @@ async fn permissions_message_not_added_when_no_change() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -250,6 +260,8 @@ async fn resume_replays_permissions_messages() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&initial.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -279,6 +291,8 @@ async fn resume_replays_permissions_messages() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&initial.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -292,6 +306,8 @@ async fn resume_replays_permissions_messages() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&resumed.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -351,6 +367,8 @@ async fn resume_and_fork_append_permissions_messages() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&initial.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -380,6 +398,8 @@ async fn resume_and_fork_append_permissions_messages() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&initial.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -401,6 +421,8 @@ async fn resume_and_fork_append_permissions_messages() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&resumed.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -429,6 +451,8 @@ async fn resume_and_fork_append_permissions_messages() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&forked.thread, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -483,6 +507,8 @@ async fn permissions_message_includes_writable_roots() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&test.codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
|
||||
@@ -213,6 +213,8 @@ async fn capability_sections_render_in_developer_message_in_order() -> Result<()
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -288,6 +290,8 @@ async fn explicit_plugin_mentions_inject_plugin_guidance() -> Result<()> {
|
||||
path: format!("plugin://{SAMPLE_PLUGIN_CONFIG_NAME}"),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -360,6 +364,8 @@ async fn explicit_plugin_mentions_track_plugin_used_analytics() -> Result<()> {
|
||||
path: format!("plugin://{SAMPLE_PLUGIN_CONFIG_NAME}"),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
|
||||
@@ -151,6 +151,8 @@ async fn prompt_tools_are_consistent_across_requests() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -162,6 +164,8 @@ async fn prompt_tools_are_consistent_across_requests() -> anyhow::Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -247,6 +251,8 @@ async fn gpt_5_tools_without_apply_patch_append_apply_patch_instructions() -> an
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -258,6 +264,8 @@ async fn gpt_5_tools_without_apply_patch_append_apply_patch_instructions() -> an
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -320,6 +328,8 @@ async fn prefixes_context_and_instructions_once_and_consistently_across_requests
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -331,6 +341,8 @@ async fn prefixes_context_and_instructions_once_and_consistently_across_requests
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -412,6 +424,8 @@ async fn overrides_turn_context_but_keeps_cached_prefix_and_key_constant() -> an
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -448,6 +462,8 @@ async fn overrides_turn_context_but_keeps_cached_prefix_and_key_constant() -> an
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
@@ -530,6 +546,8 @@ async fn override_before_first_turn_emits_environment_context() -> anyhow::Resul
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -681,6 +699,8 @@ async fn per_turn_overrides_keep_cached_prefix_and_key_constant() -> anyhow::Res
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
|
||||
@@ -46,6 +46,8 @@ async fn quota_exceeded_emits_single_error_event() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
|
||||
@@ -2036,6 +2036,8 @@ async fn inbound_handoff_request_steers_active_turn() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
|
||||
@@ -45,6 +45,8 @@ async fn request_body_is_zstd_compressed_for_codex_backend_when_enabled() -> any
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -92,6 +94,8 @@ async fn request_body_is_not_compressed_for_api_key_auth_even_when_enabled() ->
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
|
||||
@@ -91,6 +91,8 @@ async fn resume_includes_initial_messages_from_rollout_events() -> Result<()> {
|
||||
text_elements: text_elements.clone(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -176,6 +178,8 @@ async fn resume_includes_initial_messages_from_reasoning_events() -> Result<()>
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
@@ -265,6 +269,8 @@ async fn resume_switches_models_preserves_base_instructions() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |event| matches!(event, EventMsg::TurnComplete(_))).await;
|
||||
@@ -305,6 +311,8 @@ async fn resume_switches_models_preserves_base_instructions() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&resumed.codex, |event| {
|
||||
@@ -320,6 +328,8 @@ async fn resume_switches_models_preserves_base_instructions() -> Result<()> {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&resumed.codex, |event| {
|
||||
@@ -390,6 +400,8 @@ async fn resume_model_switch_is_not_duplicated_after_pre_turn_override() -> Resu
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |event| matches!(event, EventMsg::TurnComplete(_))).await;
|
||||
@@ -433,6 +445,8 @@ async fn resume_model_switch_is_not_duplicated_after_pre_turn_override() -> Resu
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&resumed.codex, |event| {
|
||||
|
||||
@@ -717,6 +717,8 @@ async fn review_history_surfaces_in_parent_session() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
|
||||
@@ -380,6 +380,8 @@ async fn tool_search_returns_deferred_tools_without_follow_up_tool_injection() -
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
|
||||
|
||||
@@ -97,6 +97,8 @@ async fn continue_after_stream_error() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
@@ -116,6 +118,8 @@ async fn continue_after_stream_error() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
|
||||
@@ -81,6 +81,8 @@ async fn retries_on_early_close() {
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await
|
||||
.unwrap();
|
||||
|
||||
@@ -62,6 +62,8 @@ mv "${tmp_path}" "${payload_path}""#,
|
||||
text_elements: Vec::new(),
|
||||
}],
|
||||
final_output_json_schema: None,
|
||||
|
||||
metadata: None,
|
||||
})
|
||||
.await?;
|
||||
wait_for_event(&codex, |ev| matches!(ev, EventMsg::TurnComplete(_))).await;
|
||||
|
||||
Reference in New Issue
Block a user