Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Various errors that can happen in the RPC part of morley-client
.
Synopsis
- data ClientRpcError
- = ContractFailed ContractAddress Expression
- | BadParameter Address Expression
- | EmptyTransaction ImplicitAddress
- | ShiftOverflow ContractAddress
- | GasExhaustion ContractAddress
- | KeyAlreadyRevealed ImplicitAddress
- | DelegateNotRegistered ImplicitAddress
- | ClientInternalError InternalError
- data RunCodeErrors = RunCodeErrors [RunError]
- data UnexpectedErrors
- data IncorrectRpcResponse
- = RpcUnexpectedSize Int Int
- | RpcOriginatedNoContracts
- | RpcOriginatedMoreContracts [ContractAddress]
- data WaitForOperationError
Documentation
data ClientRpcError Source #
Errors that can happen in the RPC part when a user tries to make failing actions.
ContractFailed | Smart contract execution has failed. |
| |
BadParameter | Parameter passed to a contract does not match its type. |
| |
EmptyTransaction | Transfer of 0 to an implicit account. |
| |
ShiftOverflow | A smart contract execution failed due to a shift overflow. |
| |
GasExhaustion | A smart contract execution failed due gas exhaustion. |
| |
KeyAlreadyRevealed | A key has already been revealed. |
| |
DelegateNotRegistered | Address not registered as delegate |
| |
ClientInternalError InternalError | An error that RPC considers internal occurred. These errors
are considered internal by mistake, they are actually quite
realistic and normally indicate bad user action. Currently we
put |
Instances
Exception ClientRpcError Source # | |
Defined in Morley.Client.RPC.Error | |
Show ClientRpcError Source # | |
Defined in Morley.Client.RPC.Error showsPrec :: Int -> ClientRpcError -> ShowS # show :: ClientRpcError -> String # showList :: [ClientRpcError] -> ShowS # | |
Buildable ClientRpcError Source # | |
Defined in Morley.Client.RPC.Error build :: ClientRpcError -> Builder # |
data RunCodeErrors Source #
Errors that can happen during run_code
endpoint call.
These errors returned along with 500 code, so we have to handle
them a bit differently in comparison to other run errors that are
returned as a part of successful JSON response.
Instances
Exception RunCodeErrors Source # | |
Defined in Morley.Client.RPC.Error | |
Show RunCodeErrors Source # | |
Defined in Morley.Client.RPC.Error showsPrec :: Int -> RunCodeErrors -> ShowS # show :: RunCodeErrors -> String # showList :: [RunCodeErrors] -> ShowS # | |
Buildable RunCodeErrors Source # | |
Defined in Morley.Client.RPC.Error build :: RunCodeErrors -> Builder # |
data UnexpectedErrors Source #
Errors that we don't expect to happen, but they can be reported by the server.
Instances
Exception UnexpectedErrors Source # | |
Defined in Morley.Client.RPC.Error | |
Show UnexpectedErrors Source # | |
Defined in Morley.Client.RPC.Error showsPrec :: Int -> UnexpectedErrors -> ShowS # show :: UnexpectedErrors -> String # showList :: [UnexpectedErrors] -> ShowS # | |
Buildable UnexpectedErrors Source # | |
Defined in Morley.Client.RPC.Error build :: UnexpectedErrors -> Builder # |
data IncorrectRpcResponse Source #
Errors that we can throw when we get a response from a node that doesn't match our expectations. It means that either the node we are talking to misbehaves or our code is incorrect.
RpcUnexpectedSize Int Int | |
RpcOriginatedNoContracts | |
RpcOriginatedMoreContracts [ContractAddress] |
Instances
Exception IncorrectRpcResponse Source # | |
Show IncorrectRpcResponse Source # | |
Defined in Morley.Client.RPC.Error showsPrec :: Int -> IncorrectRpcResponse -> ShowS # show :: IncorrectRpcResponse -> String # showList :: [IncorrectRpcResponse] -> ShowS # | |
Buildable IncorrectRpcResponse Source # | |
Defined in Morley.Client.RPC.Error build :: IncorrectRpcResponse -> Builder # |
data WaitForOperationError Source #
Instances
Exception WaitForOperationError Source # | |
Show WaitForOperationError Source # | |
Defined in Morley.Client.RPC.Error showsPrec :: Int -> WaitForOperationError -> ShowS # show :: WaitForOperationError -> String # showList :: [WaitForOperationError] -> ShowS # | |
Buildable WaitForOperationError Source # | |
Defined in Morley.Client.RPC.Error build :: WaitForOperationError -> Builder # |