fix: let HTTPException pass through @handle_db_errors unchanged
All checks were successful
Build Docker Image / build (pull_request) Successful in 2m34s
All checks were successful
Build Docker Image / build (pull_request) Successful in 2m34s
The decorator was catching all exceptions including intentional HTTPException (401, 404, etc.) and re-wrapping them as 500 "Database error". This masked auth failures and other deliberate HTTP errors. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
81baa54681
commit
215085b326
@ -807,6 +807,10 @@ def handle_db_errors(func):
|
||||
|
||||
return result
|
||||
|
||||
except HTTPException:
|
||||
# Let intentional HTTP errors (401, 404, etc.) pass through unchanged
|
||||
raise
|
||||
|
||||
except Exception as e:
|
||||
elapsed_time = time.time() - start_time
|
||||
error_trace = traceback.format_exc()
|
||||
|
||||
Loading…
Reference in New Issue
Block a user