A value that doesn't fit its Michelson type, returned by Tezex.Michelson.encode/2
and raised by Tezex.Michelson.encode!/2.
reason: what went wrong, seereason/0.path: where in the value, root first. A segment is a field or branch name (string), a tuple or list position (integer),:left/:rightfor anorbranch without a name,{:key, k}for a map key or set element, and{:value, k}for the value under map keyk.value: the value that was rejected (nilfor a missing field).expected: what would have been accepted there.
Summary
Types
@type reason() ::
:invalid_value
| :missing_field
| :unknown_field
| :duplicate_field
| :unknown_branch
| :ambiguous_branch
| :duplicate_key
| :not_comparable
| :not_passable
| :unsupported_type
@type segment() :: String.t() | non_neg_integer() | :left | :right | {:key, term()} | {:value, term()}