URUOIdocs

Error reference

Every error the uruoi program returns, with its code, what caused it and what to do. Anchor custom errors start at 6000; the SDK exports the same table as ERRORS.

CodeNameMessageWhat to do
6000NotUpgradeAuthoritySigner is not the program upgrade authorityOnly the upgrade authority can run initialize.
6001UriTooLongMetadata URI is too longKeep the uSOL metadata URI at 200 bytes or less.
6002NotAdminSigner is not the adminAdmin instructions need the admin key.
6003NotPendingAdminSigner is not the pending adminOnly the proposed key can accept the admin seat.
6004TooManyCollateralsCollateral list is fullThe program holds at most 4 collaterals.
6005InvalidMaxLtvBorrow limit must be above zero and at most 80%Pick 0 < max_ltv_bps <= 8000.
6006InvalidUnwindLtvUnwind threshold must sit above the borrow limit and at most 95%Pick max_ltv_bps < unwind_ltv_bps <= 9500.
6007UnwindLtvLoweredUnwind threshold can only be raisedThresholds never go down, so live positions cannot be made unwindable.
6008UnsupportedRateSourceRate source is neither an SPL stake pool nor the Marinade statePass the pool account or the Marinade state.
6009InvalidRateSourceRate source data does not match its program's layoutThe account is not a stake pool or Marinade state.
6010RateSourceMintMismatchRate source prices a different mintPass the rate source for this LST.
6011StaleRateStake pool has not been updated for the current epochWait for (or send) the pool's epoch update, then retry. Syncing still works.
6012ZeroAmountAmount must be greater than zeroSend a positive amount.
6013MintingPausedBorrowing is paused for this collateralNew borrowing is off for this LST; repaying, withdrawing, syncing and redeeming still work.
6014ExceedsMaxLtvDebt would exceed the borrow limitBorrow less, deposit more, or withdraw less.
6015DebtCeilingReachedCollateral debt ceiling reachedThe LST's total debt is at its ceiling; try a smaller amount or another collateral.
6016InsufficientSharesPosition does not hold that much collateralWithdraw or repay with collateral within your shares.
6017NoDebtPosition has no debtNothing to repay.
6018InsufficientBufferRedemption exceeds what the transmuter holdsRedeem a smaller amount; buffers refill as yield is swept.
6019ZeroOutputAmount is too small to pay out a single base unitUse a larger amount.
6020CollateralAccountsMismatchRemaining accounts must list every collateral in index orderPass four accounts per collateral, ordered by each collateral's index.
6021PositionHealthyPosition is not above its unwind thresholdThe position cannot be unwound; this is the normal state.
6022PositionNotEmptyPosition still holds collateral or debtRepay and withdraw everything before closing.
6023MintMismatchToken account holds a different mintPass a token account for the right mint.
6024MathOverflowMath overflowAmounts this large are not supported; split the operation.
6025FreezableMintLST mint has a freeze authority that could freeze the vaultAdmin only: an LST whose mint can be frozen is refused as collateral. JitoSOL and mSOL have no freeze authority.

Reading an error

A failed transaction log ends with a line such as:

Program log: AnchorError occurred. Error Code: ExceedsMaxLtv. Error Number: 6014. Error Message: Debt would exceed the borrow limit.
import { ERRORS } from "./sdk/src/index.js"

function explain(code: number) {
  return ERRORS[code] ?? `unknown error ${code}`
}

Errors you will see in normal use

  • StaleRate right after an epoch boundary, until the stake pool's update runs. Retry a few minutes later.
  • ExceedsMaxLtv when the app's maximum was computed a moment before a rate change. Borrow slightly less.
  • PositionHealthy for anyone trying to unwind a position that is fine, which is nearly always.