Trace RAW sse events (#2056)

For easier parsing.
This commit is contained in:
pakrym-oai
2025-08-11 10:35:03 -07:00
committed by GitHub
parent c61911524d
commit 0aa7efe05b

View File

@@ -403,6 +403,8 @@ async fn process_sse<S>(
} }
}; };
trace!("SSE event: {}", sse.data);
let event: SseEvent = match serde_json::from_str(&sse.data) { let event: SseEvent = match serde_json::from_str(&sse.data) {
Ok(event) => event, Ok(event) => event,
Err(e) => { Err(e) => {
@@ -411,7 +413,6 @@ async fn process_sse<S>(
} }
}; };
trace!(?event, "SSE event");
match event.kind.as_str() { match event.kind.as_str() {
// Individual output item finalised. Forward immediately so the // Individual output item finalised. Forward immediately so the
// rest of the agent can stream assistant text/functions *live* // rest of the agent can stream assistant text/functions *live*