openai/codex · error · anyhow::Error
inference response payload {} did not contain output_items
Error message
inference response payload {} did not contain output_items What it means
Error "inference response payload {} did not contain output_items" thrown in openai/codex.
Source
Thrown at codex-rs/rollout-trace/src/reducer/conversation.rs:140
if post_compaction_snapshot.is_some() {
self.pending_compaction_replacement_item_ids
.remove(thread_id);
}
self.thread_conversation_snapshots
.insert(thread_id.to_string(), request_item_ids.clone());
Ok(request_item_ids)
}
/// Reduces an inference response payload into conversation items produced by the call.
pub(super) fn reduce_inference_response(
&mut self,
wall_time_unix_ms: i64,
inference_call_id: &InferenceCallId,
response_payload: &RawPayloadRef,
) -> Result<Vec<String>> {
let payload = self.read_payload_json(response_payload)?;
let Some(output_items) = payload.get("output_items").and_then(Value::as_array) else {
bail!(
"inference response payload {} did not contain output_items",
response_payload.raw_payload_id
);
};
let Some((thread_id, codex_turn_id)) = self
.rollout
.inference_calls
.get(inference_call_id)
.map(|inference| (inference.thread_id.clone(), inference.codex_turn_id.clone()))
else {
bail!("inference response referenced unknown call {inference_call_id}");
};
let items = normalize::normalize_model_items(output_items, response_payload)?;
// Response output is appended immediately: it was produced by the model,
// so it is conversation even before a later request carries it forward.
let append_at = selfView on GitHub (pinned to 339751715c)
When it happens
Trigger: Thrown at codex-rs/rollout-trace/src/reducer/conversation.rs:140 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of openai/codex@339751715c (2026-08-25).
Data as JSON: /api/errors/42b50bafb73cd6f8.
Report an issue: GitHub.