pub enum DslError {
Show 19 variants
Empty,
TooManyOps {
count: usize,
max: usize,
},
InputTooLarge {
len: usize,
max: usize,
},
NestingTooDeep {
pos: usize,
depth: usize,
max: usize,
},
UnexpectedChar {
pos: usize,
found: char,
expected: &'static str,
},
UnexpectedEof {
expected: &'static str,
},
InvalidIdentifier {
pos: usize,
},
DuplicateArg {
name: String,
},
InvalidValue {
pos: usize,
error: String,
},
InvalidJson {
error: String,
},
UnclosedString,
UnclosedBracket {
kind: char,
},
PrevRefOutsideChain {
pos: usize,
},
PrevRefInJsonForm {
arg_name: String,
},
MixedSeparators,
EmptyBatch,
UnsupportedVerbNesting {
pos: usize,
},
WriteKeyConflict {
id: String,
first_op: String,
second_op: String,
},
ReservedEnvelopeArg {
arg_name: String,
verb: String,
},
}Expand description
Parser error — surfaced as invalid_params at the MCP boundary.
Variants§
Empty
TooManyOps
InputTooLarge
Raw ops input exceeds MAX_OPS_INPUT_LEN, rejected before any parsing begins.
NestingTooDeep
Container nesting ([/{) exceeds NESTING_DEPTH_LIMIT. Covers the
function-call array/object parser, the JSON-form pre-pass scan, and any
$prev reference nested inside array/object literals (bounded at the
same construction sites).
UnexpectedChar
UnexpectedEof
InvalidIdentifier
DuplicateArg
InvalidValue
InvalidJson
UnclosedString
UnclosedBracket
PrevRefOutsideChain
$prev reference used outside a chain context — emitted for Single-op
and Parallel-batch forms, and for JSON form.
$prev references are only meaningful in chain (|) mode. If they
appear in a non-chain context the parser rejects the request here so
downstream consumers get a typed error rather than a runtime string.
PrevRefInJsonForm
$prev found in JSON-form input — JSON form does not support chains.
JSON form ([{"tool":"...","args":{...}},...]) always runs in parallel.
To use $prev substitution, use the function-call DSL with the |
chain operator: verb1(...) | verb2(id=$prev.id).
MixedSeparators
Mixing , and | at the top level.
EmptyBatch
Empty batch [] — no ops provided.
UnsupportedVerbNesting
Dotted verb name with more than one level (e.g. a.b.c). Only
single-level dotted names are supported (a.b).
WriteKeyConflict
Two or more ops in a parallel batch write to the same UUID.
Write-key conflict detection is a preflight check applied after parsing.
Write ops are: update, delete, merge, link. When two ops share
the same id (or into_id / from_id for merge,
source_id/target_id for link) the batch is rejected before any op
is dispatched.
Fields
ReservedEnvelopeArg
presentation and presentation_per_op are envelope-only fields and
must not appear inside individual verb argument lists.
Trait Implementations§
Source§impl Error for DslError
impl Error for DslError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()