Enum concordium_rust_sdk::types::RejectReason
source · pub enum RejectReason {
Show 54 variants
ModuleNotWF,
ModuleHashAlreadyExists {
contents: ModuleReference,
},
InvalidAccountReference {
contents: AccountAddress,
},
InvalidInitMethod {
contents: (ModuleReference, OwnedContractName),
},
InvalidReceiveMethod {
contents: (ModuleReference, OwnedReceiveName),
},
InvalidModuleReference {
contents: ModuleReference,
},
InvalidContractAddress {
contents: ContractAddress,
},
RuntimeFailure,
AmountTooLarge {
contents: (Address, Amount),
},
SerializationFailure,
OutOfEnergy,
RejectedInit {
reject_reason: i32,
},
RejectedReceive {
reject_reason: i32,
contract_address: ContractAddress,
receive_name: OwnedReceiveName,
parameter: OwnedParameter,
},
InvalidProof,
AlreadyABaker {
contents: BakerId,
},
NotABaker {
contents: AccountAddress,
},
InsufficientBalanceForBakerStake,
StakeUnderMinimumThresholdForBaking,
BakerInCooldown,
DuplicateAggregationKey {
contents: Box<BakerAggregationVerifyKey>,
},
NonExistentCredentialID,
KeyIndexAlreadyInUse,
InvalidAccountThreshold,
InvalidCredentialKeySignThreshold,
InvalidEncryptedAmountTransferProof,
InvalidTransferToPublicProof,
EncryptedAmountSelfTransfer {
contents: AccountAddress,
},
InvalidIndexOnEncryptedTransfer,
ZeroScheduledAmount,
NonIncreasingSchedule,
FirstScheduledReleaseExpired,
ScheduledSelfTransfer {
contents: AccountAddress,
},
InvalidCredentials,
DuplicateCredIDs {
contents: Vec<CredentialRegistrationID>,
},
NonExistentCredIDs {
contents: Vec<CredentialRegistrationID>,
},
RemoveFirstCredential,
CredentialHolderDidNotSign,
NotAllowedMultipleCredentials,
NotAllowedToReceiveEncrypted,
NotAllowedToHandleEncrypted,
MissingBakerAddParameters,
FinalizationRewardCommissionNotInRange,
BakingRewardCommissionNotInRange,
TransactionFeeCommissionNotInRange,
AlreadyADelegator,
InsufficientBalanceForDelegationStake,
MissingDelegationAddParameters,
InsufficientDelegationStake,
DelegatorInCooldown,
NotADelegator {
address: AccountAddress,
},
DelegationTargetNotABaker {
target: BakerId,
},
StakeOverMaximumThresholdForPool,
PoolWouldBecomeOverDelegated,
PoolClosed,
}
Expand description
A reason for why a transaction was rejected. Rejected means included in a block, but the desired action was not achieved. The only effect of a rejected transaction is payment.
NOTE: Some of the variant definitions can look peculiar, but they are made to be compatible with the serialization of the Haskell datatype.
Variants§
ModuleNotWF
Error raised when validating the Wasm module.
ModuleHashAlreadyExists
Fields
contents: ModuleReference
As the name says.
InvalidAccountReference
Fields
contents: AccountAddress
Account does not exist.
InvalidInitMethod
Fields
contents: (ModuleReference, OwnedContractName)
Reference to a non-existing contract init method.
InvalidReceiveMethod
Fields
contents: (ModuleReference, OwnedReceiveName)
Reference to a non-existing contract receive method.
InvalidModuleReference
Fields
contents: ModuleReference
Reference to a non-existing module.
InvalidContractAddress
Fields
contents: ContractAddress
Contract instance does not exist.
RuntimeFailure
Runtime exception occurred when running either the init or receive method.
AmountTooLarge
When one wishes to transfer an amount from A to B but there are not enough funds on account/contract A to make this possible. The data are the from address and the amount to transfer.
SerializationFailure
Serialization of the body failed.
OutOfEnergy
We ran of out energy to process this transaction.
RejectedInit
Rejected due to contract logic in init function of a contract.
RejectedReceive
InvalidProof
Proof that the baker owns relevant private keys is not valid.
AlreadyABaker
Tried to add baker for an account that already has a baker
NotABaker
Fields
contents: AccountAddress
Tried to remove a baker for an account that has no baker
InsufficientBalanceForBakerStake
The amount on the account was insufficient to cover the proposed stake
StakeUnderMinimumThresholdForBaking
The amount provided is under the threshold required for becoming a baker
BakerInCooldown
The change could not be made because the baker is in cooldown for another change
DuplicateAggregationKey
Fields
contents: Box<BakerAggregationVerifyKey>
A baker with the given aggregation key already exists
NonExistentCredentialID
Encountered credential ID that does not exist
KeyIndexAlreadyInUse
Attempted to add an account key to a key index already in use
InvalidAccountThreshold
When the account threshold is updated, it must not exceed the amount of existing keys
InvalidCredentialKeySignThreshold
When the credential key threshold is updated, it must not exceed the amount of existing keys
InvalidEncryptedAmountTransferProof
Proof for an encrypted amount transfer did not validate.
InvalidTransferToPublicProof
Proof for a secret to public transfer did not validate.
EncryptedAmountSelfTransfer
Fields
contents: AccountAddress
Account tried to transfer an encrypted amount to itself, that’s not allowed.
InvalidIndexOnEncryptedTransfer
The provided index is below the start index or above startIndex + length incomingAmounts
ZeroScheduledAmount
The transfer with schedule is going to send 0 tokens
NonIncreasingSchedule
The transfer with schedule has a non strictly increasing schedule
FirstScheduledReleaseExpired
The first scheduled release in a transfer with schedule has already expired
ScheduledSelfTransfer
Fields
contents: AccountAddress
Account tried to transfer with schedule to itself, that’s not allowed.
InvalidCredentials
At least one of the credentials was either malformed or its proof was incorrect.
DuplicateCredIDs
Fields
contents: Vec<CredentialRegistrationID>
Some of the credential IDs already exist or are duplicated in the transaction.
NonExistentCredIDs
Fields
contents: Vec<CredentialRegistrationID>
A credential id that was to be removed is not part of the account.
RemoveFirstCredential
Attemp to remove the first credential
CredentialHolderDidNotSign
The credential holder of the keys to be updated did not sign the transaction
NotAllowedMultipleCredentials
Account is not allowed to have multiple credentials because it contains a non-zero encrypted transfer.
NotAllowedToReceiveEncrypted
The account is not allowed to receive encrypted transfers because it has multiple credentials.
NotAllowedToHandleEncrypted
The account is not allowed to send encrypted transfers (or transfer from/to public to/from encrypted)
MissingBakerAddParameters
A configure baker transaction is missing one or more arguments in order to add a baker.
FinalizationRewardCommissionNotInRange
Finalization reward commission is not in the valid range for a baker
BakingRewardCommissionNotInRange
Baking reward commission is not in the valid range for a baker
TransactionFeeCommissionNotInRange
Transaction fee commission is not in the valid range for a baker
AlreadyADelegator
Tried to add baker for an account that already has a delegator.
InsufficientBalanceForDelegationStake
The amount on the account was insufficient to cover the proposed stake.
MissingDelegationAddParameters
A configure delegation transaction is missing one or more arguments in order to add a delegator.
InsufficientDelegationStake
Delegation stake when adding a delegator was 0.
DelegatorInCooldown
Account is not a delegation account.
NotADelegator
Fields
address: AccountAddress
Account is not a delegation account.
DelegationTargetNotABaker
Delegation target is not a baker
StakeOverMaximumThresholdForPool
The amount would result in pool capital higher than the maximum threshold.
PoolWouldBecomeOverDelegated
The amount would result in pool with a too high fraction of delegated capital.
PoolClosed
The pool is not open to delegators.
Trait Implementations§
source§impl Clone for RejectReason
impl Clone for RejectReason
source§fn clone(&self) -> RejectReason
fn clone(&self) -> RejectReason
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for RejectReason
impl Debug for RejectReason
source§impl<'de> Deserialize<'de> for RejectReason
impl<'de> Deserialize<'de> for RejectReason
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
source§impl From<RejectReason> for Cis2DryRunError
impl From<RejectReason> for Cis2DryRunError
source§fn from(err: RejectReason) -> Self
fn from(err: RejectReason) -> Self
source§impl From<RejectReason> for Cis2QueryError
impl From<RejectReason> for Cis2QueryError
source§fn from(err: RejectReason) -> Self
fn from(err: RejectReason) -> Self
source§impl From<RejectReason> for Cis4QueryError
impl From<RejectReason> for Cis4QueryError
source§fn from(value: RejectReason) -> Self
fn from(value: RejectReason) -> Self
source§impl From<RejectReason> for DryRunModuleDeployError
impl From<RejectReason> for DryRunModuleDeployError
source§fn from(value: RejectReason) -> Self
fn from(value: RejectReason) -> Self
source§impl From<RejectReason> for DryRunNewInstanceError
impl From<RejectReason> for DryRunNewInstanceError
source§fn from(value: RejectReason) -> Self
fn from(value: RejectReason) -> Self
source§impl From<RejectReason> for ViewError
impl From<RejectReason> for ViewError
source§fn from(value: RejectReason) -> Self
fn from(value: RejectReason) -> Self
Auto Trait Implementations§
impl Freeze for RejectReason
impl RefUnwindSafe for RejectReason
impl Send for RejectReason
impl Sync for RejectReason
impl Unpin for RejectReason
impl UnwindSafe for RejectReason
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> FmtForward for T
impl<T> FmtForward for T
source§fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
fn fmt_binary(self) -> FmtBinary<Self>where
Self: Binary,
self
to use its Binary
implementation when Debug
-formatted.source§fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
fn fmt_display(self) -> FmtDisplay<Self>where
Self: Display,
self
to use its Display
implementation when
Debug
-formatted.source§fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
fn fmt_lower_exp(self) -> FmtLowerExp<Self>where
Self: LowerExp,
self
to use its LowerExp
implementation when
Debug
-formatted.source§fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
fn fmt_lower_hex(self) -> FmtLowerHex<Self>where
Self: LowerHex,
self
to use its LowerHex
implementation when
Debug
-formatted.source§fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
fn fmt_octal(self) -> FmtOctal<Self>where
Self: Octal,
self
to use its Octal
implementation when Debug
-formatted.source§fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
fn fmt_pointer(self) -> FmtPointer<Self>where
Self: Pointer,
self
to use its Pointer
implementation when
Debug
-formatted.source§fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
fn fmt_upper_exp(self) -> FmtUpperExp<Self>where
Self: UpperExp,
self
to use its UpperExp
implementation when
Debug
-formatted.source§fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
fn fmt_upper_hex(self) -> FmtUpperHex<Self>where
Self: UpperHex,
self
to use its UpperHex
implementation when
Debug
-formatted.source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request
source§impl<T> Pipe for Twhere
T: ?Sized,
impl<T> Pipe for Twhere
T: ?Sized,
source§fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
source§fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
self
and passes that borrow into the pipe function. Read moresource§fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
self
and passes that borrow into the pipe function. Read moresource§fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
source§fn pipe_borrow_mut<'a, B, R>(
&'a mut self,
func: impl FnOnce(&'a mut B) -> R
) -> R
fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R ) -> R
source§fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
self
, then passes self.as_ref()
into the pipe function.source§fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
self
, then passes self.as_mut()
into the pipe
function.source§fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
self
, then passes self.deref()
into the pipe function.source§impl<T> Pointable for T
impl<T> Pointable for T
source§impl<T> Tap for T
impl<T> Tap for T
source§fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
Borrow<B>
of a value. Read moresource§fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
BorrowMut<B>
of a value. Read moresource§fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
AsRef<R>
view of a value. Read moresource§fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
AsMut<R>
view of a value. Read moresource§fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
Deref::Target
of a value. Read moresource§fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
Deref::Target
of a value. Read moresource§fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
.tap()
only in debug builds, and is erased in release builds.source§fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
.tap_mut()
only in debug builds, and is erased in release
builds.source§fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
.tap_borrow()
only in debug builds, and is erased in release
builds.source§fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
.tap_borrow_mut()
only in debug builds, and is erased in release
builds.source§fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
.tap_ref()
only in debug builds, and is erased in release
builds.source§fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
.tap_ref_mut()
only in debug builds, and is erased in release
builds.source§fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
.tap_deref()
only in debug builds, and is erased in release
builds.