fix: log 503 client error to stderr

This commit is contained in:
M. Taimoor Zaeem
2025-02-08 21:08:29 -05:00
committed by Steve Chavez
parent 3f78615dff
commit c96dc3ee90
3 changed files with 23 additions and 2 deletions
+3 -2
View File
@@ -261,8 +261,9 @@ usePool AppState{stateObserver=observer, stateMainThreadId=mainThreadId, ..} ses
SQL.ServerError{} ->
when (Error.status (Error.PgError False err) >= HTTP.status500) $
observer $ QueryErrorCodeHighObs err
SQL.SessionUsageError (SQL.QueryError _ _ (SQL.ClientError _)) ->
pure ()
err@(SQL.SessionUsageError (SQL.QueryError _ _ (SQL.ClientError _))) ->
-- An error on the client-side, usually indicates problems wth connection
observer $ QueryErrorCodeHighObs err
)
return res