pub enum StatusCode {
Show 85 variants Success, ConvertIntError, NoneStatusCode, FatalError, MisbehaveNode, BannedNode, AddressOriginCheckError, ProvideAddressError, NoProvideAddress, NoBlock, NoProof, NoTxHeight, NoTxIndex, NoTransaction, NoBlockHeight, NoBlockHash, NoneProposal, NoneBlockBody, NoneBlockHeader, NoneChainStatus, NoneWitness, NoneTransaction, NoneUtxo, NoneRawTx, EarlyStatus, ExecuteError, EncodeError, DecodeError, NoCandidate, NoEarlyStatus, NoForkTree, DupTransaction, ProposalTooHigh, ProposalTooLow, ProposalCheckError, ConsensusProposalCheckError, BlockCheckError, CSISigCheckError, VersionOrIdCheckError, HashCheckError, HashLenError, SigLenError, SigCheckError, NodeInSyncMode, HistoryDupTx, EmergencyBrake, InvalidVersion, InvalidTo, InvalidNonce, InvalidValidUntilBlock, InvalidValue, InvalidChainId, InvalidWitness, InvalidLockId, InvalidPreHash, AdminCheckError, ModuleNotController, TransactionsExceed, ConsensusServerNotReady, ProposalProofError, KmsServerNotReady, NoneHashResult, NotFoundAccount, ConstructSigError, ConstructKeyPairError, SignError, InsertAccountError, NetworkServerNotReady, SendMsgError, BroadcastMsgError, MultiAddrParseError, DialNodeFail, AddExistedPeer, ExecuteServerNotReady, InternalChannelDisconnected, ReenterBlock, ReenterInvalidBlock, StorageServerNotReady, NotFound, InvalidRegion, InvalidKey, BadRegion, StoreError, LoadError, DeleteError,
}
Expand description

The response status code

Variants

Success

Success: 0

ConvertIntError

Convert int to status Error

NoneStatusCode

status code is none

FatalError

fate error

MisbehaveNode

controller error, start from 100 node in misbehave list

BannedNode

node in ban list

AddressOriginCheckError

address not consistent with record origin

ProvideAddressError

provide address len is not 20

NoProvideAddress

message not provide address

NoBlock

not get the block

NoProof

not get the proof

NoTxHeight

not get height of block which wrap tx

NoTxIndex

not get tx index

NoTransaction

not get transaction

NoBlockHeight

not get the block height base on hash

NoBlockHash

not get the block hash base on height

NoneProposal

proposal is none

NoneBlockBody

block body is none

NoneBlockHeader

block header is none

NoneChainStatus

chain status is none

NoneWitness

transaction’s witness is none

NoneTransaction

transaction is none

NoneUtxo

utxo is none

NoneRawTx

raw tx is none

EarlyStatus

early status received

ExecuteError

execute error

EncodeError

proto struct encode error

DecodeError

proto struct encode error

NoCandidate

no candidate block

NoEarlyStatus

not get early status

NoForkTree

fork tree no block

DupTransaction

find dup transaction

ProposalTooHigh

proposal too high

ProposalTooLow

proposal too low

ProposalCheckError

proposal check error

ConsensusProposalCheckError

consensus check proposal error

BlockCheckError

block hash check error

CSISigCheckError

the sig of chain status init check error

VersionOrIdCheckError

chain version or chain id check error

HashCheckError

hash check error

HashLenError

hash len is not correct

SigLenError

signature len is not correct

SigCheckError

signature check error

NodeInSyncMode

the node in sync mode

HistoryDupTx

Dup tx in history

EmergencyBrake

emergency brake

InvalidVersion

auth check tx’s version error

InvalidTo

auth check tx’s to error

InvalidNonce

auth check tx’s nonce error

InvalidValidUntilBlock

auth check tx’s valid until block error

InvalidValue

auth check tx’s value error

InvalidChainId

auth check tx’s chain id error

InvalidWitness

auth limit utxo’s witness only one

InvalidLockId

auth check utxo’s lock id error

InvalidPreHash

auth check utxo’s pre tx hash error

AdminCheckError

auth check send is not admin

ModuleNotController

network msg’s module not controller

TransactionsExceed

the size of txs has exceeded package-limit

ConsensusServerNotReady

Consensus from 200 check proposal proof error

ProposalProofError

proof of proposal error

KmsServerNotReady

Kms from 300 Kms server not ready

NoneHashResult

hash result is none

NotFoundAccount

kms not found account base on id

ConstructSigError

construct signature error

ConstructKeyPairError

construct key pair error

SignError

sign error

InsertAccountError

insert account error

NetworkServerNotReady

Network from 400 Network server not ready

SendMsgError

send message error

BroadcastMsgError

broadcast message error

MultiAddrParseError

multi-addr error

DialNodeFail

dial node failed

AddExistedPeer

ExecuteServerNotReady

executor from 500 Executor server not ready

InternalChannelDisconnected

internal channel disconnected

ReenterBlock

early same block reenter

ReenterInvalidBlock

invalid block reenter

StorageServerNotReady

storage from 600 storage server not ready

NotFound

kv not found

InvalidRegion

invalid region

InvalidKey

invalid key

BadRegion

bad region

StoreError

store data error

LoadError

load data error

DeleteError

delete data error

Implementations

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Formats the value using the given formatter. Read more

The lower-level source of this error, if any. Read more

🔬 This is a nightly-only experimental API. (backtrace)

Returns a stack backtrace, if available, of where this error occurred. Read more

👎 Deprecated since 1.42.0:

use the Display impl or to_string()

👎 Deprecated since 1.33.0:

replaced by Error::source, which can support downcasting

Converts to this type from the input type.

Converts to this type from the input type.

Converts to this type from the input type.

Converts to this type from the input type.

Converts to this type from the input type.

Converts to this type from the input type.

Converts to this type from the input type.

Converts to this type from the input type.

Converts to this type from the input type.

Converts an i64 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an u64 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an isize to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an i8 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an i16 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an i32 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an i128 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts a usize to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an u8 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an u16 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an u32 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts an u128 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts a f32 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts a f64 to return an optional value of this type. If the value cannot be represented by this type, then None is returned. Read more

Converts this type into the (usually inferred) input type.

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Compare self to key and return true if they are equal.

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Wrap the input message T in a tonic::Request

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

Converts the given value to a String. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more