pub enum EnvelopeParseError {
NotAnEnvelopeForm,
WrongArity {
found: usize,
},
MalformedHash,
MalformedPerformative,
MalformedFromList,
MalformedKey(KeyIdError),
MalformedToList,
RecipientBoundExceeded {
count: usize,
max: usize,
},
MalformedThread,
MalformedSignature,
UnexpectedField,
MalformedCausedBy,
}Expand description
Typed rejection for the CON-700 envelope parser — full recognition before any semantic action; nothing is repaired.
Variants§
NotAnEnvelopeForm
The input is not a list headed by the envelope symbol.
WrongArity
Wrong number of items: 7 (no :caused-by) or 9 (with it).
MalformedHash
The hash position is not a well-formed f1220<hex64> symbol.
MalformedPerformative
The perf-name position is not a symbol.
MalformedFromList
The sender position is not a list of exactly one key.
MalformedKey(KeyIdError)
A key does not parse as @[suite:]name (REQ-708).
MalformedToList
The recipient position is not a list of keys.
RecipientBoundExceeded
The recipient set exceeds the caller’s R2-derived bound (CON-700).
MalformedThread
The thread position is neither a string nor a symbol.
MalformedSignature
The sig position is not a non-empty lowercase-hex string.
UnexpectedField
Item 7 of a 9-item form is not the :caused-by keyword — any other
additional field is rejected, never repaired (CON-700).
MalformedCausedBy
The caused-ref is not begin, a hash, or a non-empty hash list.