Skip to main content

Module error

Module error 

Source
Expand description

What a passalong-server answers when it refuses, and what this client does about it.

Errors are application/problem+json with a stable code; the client decides from the code alone. A single command repeats only what the server marks retryable, at most three attempts, one, two, then four seconds apart. RATE_LIMITED waits for Retry-After when that is a minute or less. A 401 is never repeated: an address that sends too many bad keys is locked out, and every device behind it with it.

Structs§

Problem
An application/problem+json answer.

Enums§

Code
A problem’s stable code.
HttpsError
Why a request to a server failed.
Next
What to do after a failed attempt.

Constants§

ATTEMPTS
The most attempts a single request gets.
MAX_RETRY_AFTER
The longest Retry-After a command waits out instead of failing.

Functions§

next
Whether to repeat a request after attempts attempts ended with err.