forked from kenzuya/unshackle
fix(session): name the API error code and the short rnet cause of an exhausted request
This commit is contained in:
@@ -170,7 +170,9 @@ exception that is not an `APIError` bubbles up, the server gives it a code in tw
|
||||
|
||||
1. **The code the failure names.** An unshackle core failure states its own code: a region
|
||||
check gives `GEOFENCE`, a proxy that fails gives `INVALID_PROXY`, a login that needs
|
||||
an absent user gives `AUTH_FAILED`, and a DRM failure gives `DRM_ERROR`. The server
|
||||
an absent user gives `AUTH_FAILED`, and a DRM failure gives `DRM_ERROR`. A request that
|
||||
fails on each retry gives `NETWORK_ERROR` for a connection fault or a body that ended early,
|
||||
`RATE_LIMITED` for a `429` and `SERVICE_UNAVAILABLE` for a `503`. The server
|
||||
reads this code first, so the wording of the message does not change it.
|
||||
2. **The keywords of the message.** A failure that names no code, such as the plain text
|
||||
that a service raises, gets a code from the words in its message, checked in order:
|
||||
|
||||
Reference in New Issue
Block a user