You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
apiRequestXhr and performXhrRequests use Either Text to report an error condition. However, the only possible error string ever generated is Response could not be decoded for request: plus the JSON encoding of the request.
Even if we aren't really meant to use HTTP errors for application errors, it is still useful to be able to distinguish different types of non-application errors, e.g. internal server errors, timeouts, authentication issues, etc.
As it stands, the error reporting is no more useful than Maybe. For maximum flexibility I think it would help if the actual XHR response was returned on a non-successful status or JSON decoding failure.
The text was updated successfully, but these errors were encountered:
apiRequestXhr
andperformXhrRequests
useEither Text
to report an error condition. However, the only possible error string ever generated isResponse could not be decoded for request:
plus the JSON encoding of the request.Even if we aren't really meant to use HTTP errors for application errors, it is still useful to be able to distinguish different types of non-application errors, e.g. internal server errors, timeouts, authentication issues, etc.
As it stands, the error reporting is no more useful than
Maybe
. For maximum flexibility I think it would help if the actual XHR response was returned on a non-successful status or JSON decoding failure.The text was updated successfully, but these errors were encountered: