pub enum ChunkedError {
App(AppError),
NotFound,
TerminalState(String),
ChunkOutOfRange {
index: u64,
chunk_count: u64,
},
DigestMismatch {
expected_digest_multibase: String,
},
ChunkSizeMismatch {
expected: u64,
actual: u64,
},
IncompleteUpload {
missing_count: u64,
missing_indices: Vec<u64>,
},
BundleDigestMismatch,
BundleTooLarge {
size_bytes: u64,
},
InvalidManifest(String),
RateLimited {
retry_after_secs: u64,
},
}Expand description
Why a chunked operation refused. Kept apart from AppError because most
arms are a specification error code the handler must put on the wire as
<task-slug>:<code>, and several carry the details that code declares.
Variants§
App(AppError)
A general failure (authorization, I/O, storage) with no task-specific code of its own.
NotFound
No live chunked bundle of the right kind that this caller owns. Deliberately conflates absent, wrong kind, wrong algorithm and not yours.
TerminalState(String)
The bundle was completed, finalized, aborted, or has expired.
ChunkOutOfRange
index is not below the manifest’s chunk count.
DigestMismatch
The chunk’s bytes, or the digest the request restated, do not match the manifest entry for the index.
ChunkSizeMismatch
The chunk decodes to the wrong length for its index.
IncompleteUpload
A chunked import is missing chunks; missing_indices is the first
MAX_REPORTED_MISSING of them.
BundleDigestMismatch
Every chunk verified but the assembled bytes do not match the committed whole-bundle digest or size.
BundleTooLarge
The serialized state does not fit in the chunk-count bound at the chunk size this request allows.
InvalidManifest(String)
An import manifest that is internally inconsistent or names a digest this build cannot verify.
RateLimited
The caller exceeded its per-DID chunk request budget.