mirror of
https://github.com/openai/codex.git
synced 2026-11-27 23:50:52 +00:00
Record actual Responses endpoints in tracing spans (#40906)
## Why Responses-compatible requests can use routes other than `/responses`, but their tracing spans reported the default route regardless of the selected endpoint. ## What changed - Populate `api.path` from the selected `ResponsesEndpoint` for HTTP and WebSocket requests. - Retain the endpoint on WebSocket connections so stream-request spans report the same route as connection spans. GitOrigin-RevId: 349eca94b27d4cc3a1adde8b257313506bdaf0f4
This commit is contained in:
@@ -96,7 +96,7 @@ impl<T: HttpTransport> ResponsesClient<T> {
|
||||
fields(
|
||||
transport = "responses_http",
|
||||
http.method = "POST",
|
||||
api.path = "responses"
|
||||
api.path = self.endpoint.path()
|
||||
)
|
||||
)]
|
||||
pub async fn stream_request(
|
||||
@@ -136,7 +136,7 @@ impl<T: HttpTransport> ResponsesClient<T> {
|
||||
fields(
|
||||
transport = "responses_http",
|
||||
http.method = "POST",
|
||||
api.path = "responses",
|
||||
api.path = self.endpoint.path(),
|
||||
turn.has_state = turn_state.is_some()
|
||||
)
|
||||
)]
|
||||
|
||||
Reference in New Issue
Block a user