Errors of the token suite
Every custom error of the token suite, grouped by the contract that raises it. The errors are declared in ErrorsLib (contracts/libraries/ErrorsLib.sol). Those that belong to the standard are also declared in ERC3643ErrorsLib, with the same names and arguments. The errors of the ERC-20 base, of the pause, of the access manager and of ERC-7786 are OpenZeppelin's and are listed at the end.
Common
ZeroAddress()
A required address is zero
ZeroValue()
An amount is zero: a transfer, a mint or a burn of zero, or a validation with nothing available
EmptyString()
A name, a symbol or a salt is empty
ArrayLengthMismatch()
The arrays of a batch call differ in length
ArraySizeLimited(uint256 maxSize)
More than five setting calls in addAndSetModule
AuthorityMismatch()
Two contracts that must share an access manager do not
Deprecated()
A function kept for the standard that T-REX does not serve: the country functions, the setters of the topics and issuers registries
Token
ComplianceNotFollowed()
The rules refuse a transfer or a mint
UnverifiedIdentity()
The recipient is not eligible
FrozenWallet(address user)
The sender or the recipient is frozen
AmountAboveFrozenTokens(uint256 amount, uint256 maxAmount)
An unfreeze exceeds the frozen amount
SpenderNotAllowed(address spender, address from, address to, uint256 value)
The spender policy refuses the caller of transferFrom
NotLinkedIdentity(address from, address caller)
identityTransfer is called by another address than the identity from resolves to
DecimalsOutOfRange(uint256 decimals)
Decimals above 18 at deployment
InvalidIdentityRegistry(), InvalidCompliance()
A setter receives a contract that is not a registry, not a compliance
ComplianceAlreadyBoundToToken()
The compliance given to setCompliance serves another token
TokenCirculating()
The registry or the compliance is replaced, or a token is bound, while the supply is not zero
SameWalletRecovery(), NoTokenToRecover(), RecoveryNotPossible()
A recovery names the same address twice, an empty address, or two addresses the registry does not know
OnlyBoundCompliance()
A ledger function reserved to the compliance is called by another address
InsufficientBridgedBalance(bytes wallet, uint256 balance, uint256 needed)
The position of a satellite wallet is smaller than the amount to move out of it
TransitAlreadyHeld(uint256 validationId), NothingInTransit(uint256 validationId), TransitAmountMismatch(uint256 validationId, uint256 held, uint256 amount)
The in-transit amount of a validation is held twice, absent, or different from the amount settled
NotASatelliteWallet(bytes wallet)
A wallet of the reference chain is given where a satellite wallet is required
Registry and storage
ClaimTopicAlreadyExists()
A required topic is added twice
MaxClaimTopicsReached(uint256 max), MaxTrustedIssuersReached(uint256 max)
A limit of the registry, or of the factory at deployment, is reached
InvalidIdentityType()
A topic is set for identity type 0
TrustedIssuerAlreadyExists(), NotATrustedIssuer()
A trusted issuer is added twice, or is unknown
TrustedClaimTopicsCannotBeEmpty(), ClaimTopicsCannotBeEmpty()
A trusted issuer is added, or updated, with no topic
EligibilityChecksDisabledAlready(), EligibilityChecksEnabledAlready()
The switch is already in the requested state
InvalidIdentityRegistryStorage(), RegistryNotBoundToStorage()
A new storage does not support the interface, or does not list the registry
InvalidClaimPattern()
At deployment, the issuers and their topics differ in length
AddressAlreadyStored(), AddressNotYetStored()
A registration exists already, or does not exist
IdentityRegistryNotStored(), MaxIRByIRSReached(uint256 max)
A registry to unbind is not bound, or 300 registries are bound
Compliance and modules
AddressNotATokenBoundToComplianceContract()
A function reserved to the bound token is called by another address
OnlyOwnerOrTokenCanCall(), TokenNotBound()
bindToken or unbindToken by an unauthorized caller, or for a token that is not bound
MaxModulesReached(uint256 maxValue), ModuleAlreadyBound(), ModuleNotBound()
25 modules are bound, a module is bound twice, or is not bound
ComplianceNotSuitableForBindingToModule(address module)
A module refuses the compliance
ModuleHasNoType(), DuplicateModuleType(uint8 moduleType)
A module declares no type, or one type twice
InvalidCompliancePattern()
At deployment, more settings than modules
InsufficientPosition(address identity, uint256 held, uint256 amount), FromAndToAreTheSame()
fixPosition moves more than the position, or between one identity and itself
OnlyBoundComplianceCanCall(), OnlyComplianceContractCanCall()
A module function is called by an address that is not a bound compliance, or not the compliance concerned
ComplianceAlreadyBound(), ComplianceNotBound(), ModuleStillBound()
A module is asked to bind a compliance twice, to serve one it does not know, or to unbind one that still lists it
SpenderAlreadyAllowed(bytes spender), SpenderNotListed(bytes spender)
The list of named operators already has, or lacks, the spender
Transfer validation
InvalidRequestedRange(uint256 requestedMin, uint256 requestedMax)
The minimum is above the maximum
SenderNotOnSatellite(bytes wallet)
from is on the reference chain
UnverifiedWallet(bytes wallet)
from resolves to no identity, or to is not eligible
NotAuthorizedForWallet(address caller, bytes wallet)
The caller is neither the identity of from nor an AGENT
ValidityWindowNotSet(), ReconciliationWindowNotSet(bytes32 chainKey), ZeroDuration()
A window is missing, or set to zero
ValidationIssuancePaused(bytes32 chainKey)
Issuance is paused for a chain involved
EmptyValidationRange(uint256 min, uint256 max)
The available balance or the rules leave no amount to authorize
ValidationSpenderRefused(bytes spender)
A SPENDER module refuses the named spender
UnknownValidation(uint256 validationId)
The id was never issued
ValidationNotDiscardable(uint256 validationId, uint8 status), ValidationNotReleasable(uint256 validationId, uint64 releaseAt)
A discard of a validation that is not Pending, or before releaseAt
ValidationNotStuck(uint256 validationId, uint8 status), ValidationNotYetResolvable(uint256 validationId, uint64 resolvableAt)
A resolution of a validation that awaits no leg, or too early
SettlementLegMismatch(uint256 validationId)
The wallets or the origin chain of a report do not match the validation
SettlementOutOfBounds(uint256 validationId, uint256 amount)
The executed amount is outside the range
SettlementAmountMismatch(uint256 validationId, uint256 expected, uint256 amount)
The second report does not repeat the amount of the first
Messaging
ChainNotOpen(bytes32 chainKey), ChainNotRegistered(bytes32 chainKey)
A message is sent to a chain with no usable route and peer. A peer is set for a chain with no route
GatewayNotTrusted(address gateway)
A route names a gateway the network does not trust
InvalidChainReference(bytes2 chainType, bytes chainReference), InvalidPeer(bytes peer), PeerChainMismatch(bytes32 chainKey, bytes32 peerChainKey)
A route or a peer is malformed, or on another chain
NonCanonicalInteroperableAddress(bytes envelope)
A wallet is not in the canonical ERC-7930 form
SenderNotCompliance(address sender)
A validation is dispatched by another address than the compliance
ValidationAlreadyRouted(uint256 validationId, bytes32 chainKey, address gateway)
A validation is sent again to a chain through another gateway
SenderNotPeer(bytes32 chainKey, bytes sender)
The author of a delivery is not the peer of its chain
UnsupportedMessageVersion(uint8 messageVersion), MessageTypeNotInbound(MessageTypesLib.Message messageType)
A payload has another version than 1, or a type the token does not receive
MessageAlreadyReceived(address gateway, bytes32 receiveId)
A gateway delivers the same receiveId twice
GatewayNotPinned(address gateway, uint256 validationId, bytes32 chainKey), GatewayNotRouted(address gateway, bytes32 chainKey)
A delivery comes through another gateway than the one expected
Factory, versions and access
TokenAlreadyDeployed()
The salt was already used
MaxClaimIssuersReached(uint256 max)
More than five trusted issuers at deployment
InvalidAccessManagerAdmin(), AccessManagerNotAContract(address accessManager)
The administrator of a new manager is the factory or the manager itself. A supplied manager has no code
StorageAuthorityMismatch(address identityRegistryStorage, address expected, address actual)
A supplied storage answers to another manager
IsolatedSuiteCannotReuseIRS()
An isolated suite is given an existing storage
TokenIdentityAlreadyBound(address token, address boundIdentity)
The token address is already linked to another identity
InvalidImplementationAuthority()
The authority given to the factory has a zero beacon
EmptyImplementations(), VersionAlreadyPublished(), UnknownVersion(), VersionNotNewer()
A version with a zero implementation, published twice, unknown, or not above the current one
DomainNotFound(uint32 domainId), InvalidDomain()
A domain does not exist. A role is built for domain 0 or for the platform domain
NotAssigned(address target)
A suite is commissioned for a token that has no domain
RoleNotHeld(address account, uint64 role), PendingRoleGrant(address account, uint64 role), PendingDelayChange(address account, uint64 role)
A role is carried from one domain to another for an account that does not hold it, whose grant is not effective, or whose delay is changing
Errors from OpenZeppelin
ERC20InsufficientBalance(address sender, uint256 balance, uint256 needed)
An amount exceeds the free balance, or the balance for a burn or a forced transfer
ERC20InsufficientAllowance(address spender, uint256 allowance, uint256 needed)
transferFrom above the allowance
EnforcedPause(), ExpectedPause()
An action that the pause stops. unpause while not paused
AccessManagedUnauthorized(address caller)
A restricted function is called without the role
ERC7786RecipientUnauthorizedGateway(address gateway, bytes sender)
A delivery by a gateway the network does not trust
InteroperableAddressParsingError(bytes), InteroperableAddressEmptyReferenceAndAddress()
A sender that is not a valid ERC-7930 address
Last updated