mirror of
https://github.com/BerriAI/litellm.git
synced 2026-11-16 09:22:22 +00:00
fix(gateway): log the upstream error when forwarding returns 502
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
e361f7acae
commit
7a581ae3f1
1 changed files with 4 additions and 1 deletions
|
|
@ -82,7 +82,10 @@ async fn forward(
|
|||
.client
|
||||
.request(request)
|
||||
.await
|
||||
.map_err(|_| StatusCode::BAD_GATEWAY)?;
|
||||
.map_err(|error| {
|
||||
tracing::warn!(%error, "python proxy unreachable");
|
||||
StatusCode::BAD_GATEWAY
|
||||
})?;
|
||||
strip_hop_headers(response.headers_mut());
|
||||
Ok(response.map(Body::new))
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue