Enum miniscript::Error [−][src]
pub enum Error {}Show 36 variants
InvalidOpcode(All), NonMinimalVerify(Token), InvalidPush(Vec<u8>), Script(Error), CmsTooManyKeys(u32), Unprintable(u8), ExpectedChar(char), UnexpectedStart, Unexpected(String), MultiColon(String), MultiAt(String), AtOutsideOr(String), NonCanonicalTrue, NonCanonicalFalse, LikelyFalse, UnknownWrapper(char), NonTopLevel(String), Trailing(String), BadPubkey(Error), MissingHash(Hash), MissingSig(PublicKey), RelativeLocktimeNotMet(u32), AbsoluteLocktimeNotMet(u32), CouldNotSatisfy, TypeCheck(String), BadDescriptor(String), Secp(Error), PolicyError(PolicyError), LiftError(LiftError), ContextError(ScriptContextError), MaxRecursiveDepthExceeded, ScriptSizeTooLarge, NonStandardBareScript, AnalysisError(AnalysisError), ImpossibleSatisfaction, BareDescriptorAddr,
Expand description
Miniscript
Variants
Opcode appeared which is not part of the script subset
Tuple Fields of InvalidOpcode
0: All
Some opcode occurred followed by OP_VERIFY
when it had
a VERIFY
version that should have been used instead
Tuple Fields of NonMinimalVerify
0: Token
Push was illegal in some context
rust-bitcoin script error
Tuple Fields of Script
0: Error
A CHECKMULTISIG
opcode was preceded by a number > 20
Tuple Fields of CmsTooManyKeys
0: u32
Encountered unprintable character in descriptor
Tuple Fields of Unprintable
0: u8
expected character while parsing descriptor; didn’t find one
Tuple Fields of ExpectedChar
0: char
While parsing backward, hit beginning of script
Got something we were not expecting
Tuple Fields of Unexpected
0: String
Name of a fragment contained :
multiple times
Tuple Fields of MultiColon
0: String
Name of a fragment contained @
multiple times
Tuple Fields of MultiAt
0: String
Name of a fragment contained @
but we were not parsing an OR
Tuple Fields of AtOutsideOr
0: String
Fragment was an and_v(_, true)
which should be written as t:
Fragment was an or_i(_, false)
or or_i(false,_)
which should be written as u:
or l:
Encountered a l:0
which is syntactically equal to u:0
except stupid
Encountered a wrapping character that we don’t recognize
Tuple Fields of UnknownWrapper
0: char
Parsed a miniscript and the result was not of type T
Tuple Fields of NonTopLevel
0: String
Parsed a miniscript but there were more script opcodes after it
Tuple Fields of Trailing
0: String
Failed to parse a push as a public key
Tuple Fields of BadPubkey
0: Error
Could not satisfy a script (fragment) because of a missing hash preimage
Could not satisfy a script (fragment) because of a missing signature
Tuple Fields of MissingSig
0: PublicKey
Could not satisfy, relative locktime not met
Tuple Fields of RelativeLocktimeNotMet
0: u32
Could not satisfy, absolute locktime not met
Tuple Fields of AbsoluteLocktimeNotMet
0: u32
General failure to satisfy
Typechecking failed
Tuple Fields of TypeCheck
0: String
General error in creating descriptor
Tuple Fields of BadDescriptor
0: String
Forward-secp related errors
Errors related to policy
Tuple Fields of PolicyError
0: PolicyError
Errors related to lifting
Tuple Fields of LiftError
0: LiftError
Forward script context related errors
Recursion depth exceeded when parsing policy/miniscript from string
Script size too large
Anything but c:pk(key) (P2PK), c:pk_h(key) (P2PKH), and thresh_m(k,…) up to n=3 is invalid by standardness (bare)
Analysis Error
Tuple Fields of AnalysisError
Miniscript is equivalent to false. No possible satisfaction
Bare descriptors don’t have any addresses
Trait Implementations
replaced by Error::source, which can support downcasting
The lower-level source of this error, if any. Read more
backtrace
)Returns a stack backtrace, if available, of where this error occurred. Read more
use the Display impl or to_string()