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
one thing I have noticed while using the Client type is that failures are annoying to diagnose
the API is strongly-typed and so if URL endpoints and message types are correct, things work well
if they aren't, it is usually hard to know what went wrong
options:
add some type of "debug" flag inside the Client that exposes the information we need (e.g. which endpoint, what does the HTTP message look like as text, what does the response look like as text)
more tolerant response parsing (e.g. try to parse within the realm we expect but if that fails, then make an Error variant that dumps the response status code and body (if any))
this last route actually sounds better (even if ultimately we do need the former)
The text was updated successfully, but these errors were encountered:
ralexstokes
changed the title
add support for a "debug" mode
add support for a "debug" mode, or just make error handling more robust
Aug 8, 2023
one thing I have noticed while using the
Client
type is that failures are annoying to diagnosethe API is strongly-typed and so if URL endpoints and message types are correct, things work well
if they aren't, it is usually hard to know what went wrong
options:
Client
that exposes the information we need (e.g. which endpoint, what does the HTTP message look like as text, what does the response look like as text)Error
variant that dumps the response status code and body (if any))this last route actually sounds better (even if ultimately we do need the former)
The text was updated successfully, but these errors were encountered: