Package convex.core
Class ErrorCodes
java.lang.Object
convex.core.ErrorCodes
Standard codes used for CVM Exceptional Conditions.
An Exceptional Condition may include a Message, which is kept outside CVM state but may be user to return
information to the relevant client.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Keyword
Error code for when an argument is of the correct type, but is not an allowable value.static final Keyword
Error code when function or expander application has an inappropriate number of arguments.static final Keyword
Error code indicating that an asserted condition was not met.static final Keyword
Error code for when indexed access is attempted that is out of bounds for some sequential object.static final Keyword
Error code when the type of some argument cannot be cast to a suitable type for some requested operation.static final Keyword
ErrorCode indicating failure of a child transactionstatic final Keyword
Error code caused by compilation failure with an invalid AST.static final Keyword
Error code for when a transaction exceeds execution depth limits.static final Keyword
Error code for unhandled exceptionsstatic final Keyword
Error code caused by failure to successfully expand an AST node.static final Keyword
ErrorCode for a FATAL Error.static final Keyword
ErrorCode for a message format error.static final Keyword
Error code for when the specified account does not have enough available funds to perform an operationstatic final Keyword
Exceptional Condition indicating a halt operation was executed.static final Keyword
Error code for when a transaction runs out of available juicestatic final Keyword
static final Keyword
Error code for situations where a transaction is unable to complete due to insufficient Memory Allowance.static final Keyword
Error code when attempting to perform an action using a non-existent Accountstatic final Keyword
Exceptional Condition indicating a recur operation was executed This will return execution to the surrounding loop or function binding, which will be re-executed with new bindings provided to the recur operation.static final Keyword
Exceptional condition indicated a 'reduced' result.static final Keyword
Exceptional Condition indicating a return operation was executed This will return execution to the caller of surrounding function binding, with whatever value is passed to the return operation as a result.static final Keyword
Exceptional Condition indicating a halt operation was executed.static final Keyword
Error code for a bad sequence.static final Keyword
Exceptional Condition indicating a bad signature on a transaction.static final Keyword
Error code for a request that would normally be valid, but failed because some aspect of actor / system state was wrong.static final Keyword
Exceptional Condition indicating a tailcall operation has been executed This will return execution to the surrounding loop or function binding, which will be re-executed with new bindings provided to the recur operation.static final Keyword
static final Keyword
Exceptional Condition indicating something is not yet implementedstatic final Keyword
Error code indicating that an a trust condition was violated.static final Keyword
Error code when an undeclared symbol is accessedstatic final Keyword
ErrorCode for an unexpected Error. -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
SEQUENCE
Error code for a bad sequence. This Error Condition is generated by the CVM only during transaction preparation if the Sequence Number for the new transaction is wrong for the given Account (it must be one greater than the Sequence Number of the last transaction executed which is stored in the Account). This Error code may be returned by Peers before publishing a transaction to the network, if the Sequence Number cannot possibly be correct (i.e. less than the current Sequence Number). The message is expected to be the current sequence number: Clients may use this to automatically correct and re-submit transactions with the correct sequence, although this is unreliable if multiple clients are sending transactions for the same Account. -
FUNDS
Error code for when the specified account does not have enough available funds to perform an operation -
JUICE
Error code for when a transaction runs out of available juice -
DEPTH
Error code for when a transaction exceeds execution depth limits. Typically, this indicates infinite recursion. -
MEMORY
Error code for situations where a transaction is unable to complete due to insufficient Memory Allowance. This Error Condition is only be generated by the CVM during the failure of transaction completion. Within transactions, memory usage may exceed allowances as long as there is enough juice to pay for the temporary allocations. -
NOBODY
Error code when attempting to perform an action using a non-existent Account -
ARITY
Error code when function or expander application has an inappropriate number of arguments. Arity is checked first: it takes precedence over CAST and ARGUMENT errors. -
UNDECLARED
Error code when an undeclared symbol is accessed -
CAST
Error code when the type of some argument cannot be cast to a suitable type for some requested operation. ARITY errors take predecence over CAST errors if both are applicable. -
BOUNDS
Error code for when indexed access is attempted that is out of bounds for some sequential object. -
ARGUMENT
Error code for when an argument is of the correct type, but is not an allowable value. -
STATE
Error code for a request that would normally be valid, but failed because some aspect of actor / system state was wrong. Typically indicates that some preparatory step was omitted, appropriate pre-conditions were not checked, or an operation was attempted at an inappropriate time -
COMPILE
Error code caused by compilation failure with an invalid AST. Should only occur during compile phase of on-chain Compiler -
EXPAND
Error code caused by failure to successfully expand an AST node. Should only occur during expand phase of on-chain Compiler -
ASSERT
Error code indicating that an asserted condition was not met. This usually indicates invalid input that failed a precondition check. The message should be used to give meaningful feedback to the User. -
TRUST
Error code indicating that an a trust condition was violated. This usually means a USer or Actor attempted to perform an unauthorised operation. -
UNEXPECTED
ErrorCode for an unexpected Error. Likely fatal. -
EXCEPTION
Error code for unhandled exceptions -
HALT
Exceptional Condition indicating a halt operation was executed. This will halt the currently executing transaction context and return to the caller. -
RECUR
Exceptional Condition indicating a recur operation was executed This will return execution to the surrounding loop or function binding, which will be re-executed with new bindings provided to the recur operation. -
TAILCALL
Exceptional Condition indicating a tailcall operation has been executed This will return execution to the surrounding loop or function binding, which will be re-executed with new bindings provided to the recur operation. -
RETURN
Exceptional Condition indicating a return operation was executed This will return execution to the caller of surrounding function binding, with whatever value is passed to the return operation as a result. -
REDUCED
Exceptional condition indicated a 'reduced' result. -
ROLLBACK
Exceptional Condition indicating a halt operation was executed. This will terminate the currently executing transaction context, roll back any state changes and return to the caller with whatever value is passed as the rollback result. -
SIGNATURE
Exceptional Condition indicating a bad signature on a transaction. -
TODO
Exceptional Condition indicating something is not yet implemented -
FATAL
ErrorCode for a FATAL Error. Should trigger Peer shutdown. -
FORMAT
ErrorCode for a message format error. -
LOAD
-
CHILD
ErrorCode indicating failure of a child transaction -
TIMEOUT
-
-
Constructor Details
-
ErrorCodes
public ErrorCodes()
-