refactor(errors): replace silent exception handling in core packages
This commit is contained in:
1 parent
584bb2d09c
commit
47e7cb6620
21 files changed
+132
-58
No files matched your search
@@ -43,7 +43,8 @@ def _extract_error_message(resp: httpx.Response) -> str:
|
||||
return str(data["message"])
|
||||
if "detail" in data:
|
||||
return str(data["detail"])
|
||||
except Exception:
|
||||
except ValueError:
|
||||
# Response body is not valid JSON; fall through to the text fallback.
|
||||
pass
|
||||
|
||||
# Fallback to response text or HTTP status
|
||||
|
||||
Reference in new issue
Block a user