Program

Errors

Every error the Geode program can return to a client's transaction, with its code, its message, the instructions that raise it and why.

Program errors are Anchor custom errors: code 6000 plus the variant's index in GeodeError. A refused transaction reports them as custom program error: 0x... with the code in hex, and its logs name the variant. The relayer surfaces the program's refusal in programError (see API errors): UnknownRoot, InvalidProof and DuplicateNullifier become UNKNOWN_ROOT, PROOF_INVALID and NULLIFIER_SPENT, never retryable, and InsufficientPoolFunds becomes INSUFFICIENT_BALANCE.

Program errors

CodeHexNameMessageRaised byWhy
60010x1771UnauthorizedRelayerThe signing relayer is not authorized.pay, unshieldThe signer is not in config.relayers
60020x1772InvalidFeeThe fee does not equal the configured rounded-down share.payfee is not floor(price * fee_bps / 10000)
60040x1774InvalidRecipientThe destination does not match the proof or configured payee.unshield, and every lamport moveunshield: recipient differs from recipient_account, or is the pool vault. Any direct lamport move whose source and destination are the same account
60050x1775InvalidAmountThe amount must be positive.shield, pay, unshieldamount (or price in pay) is 0
60060x1776ArithmeticOverflowA lamport calculation overflowed.pay, unshieldrelayer_refund overflows u64; price + fee + relayer_refund (pay) or amount + relayer_refund (unshield) overflows u64; or a destination balance would overflow u64
60070x1777MemoTooLargeEach encrypted note memo must be at most 80 bytes.shield, pay, unshieldA memo is longer than 80 bytes
60080x1778InvalidReceiptThe storage bucket or term is invalid.payreceipt.bucket is not a power of two from 65,536 through 67,108,864, or receipt.term is above 2
60090x1779NonCanonicalFieldA scalar is not a canonical BN254 field element.shield, pay, unshieldA public input (root, a nullifier or a commitment) is not below the BN254 scalar modulus, or a Poseidon input is not
60100x177aPoseidonFailedThe Poseidon syscall failed.shield, pay, unshieldThe Poseidon syscall returned an error while hashing the tree, the receipt or a binding
60110x177bDuplicateNullifierBoth input nullifiers must differ.shield, pay, unshieldnullifiers[0] equals nullifiers[1]. Both nullifier PDAs are created during account validation, before this check, so equal nullifiers name one PDA and its second creation is refused first (see below)
60120x177cUnknownRootThe proof root is not in the recent-root ring.shield, pay, unshieldroot is not among the ring's recent roots: the pool never produced it, or 128 later spends have replaced it. Refresh the tree and prove again
60130x177dTreeFullThe commitment tree is full.shield, pay, unshieldnext_leaf_index is above 226 - 2, so two more leaves do not fit
60140x177eInvalidProofThe Groth16 proof does not verify for this instruction.shield, pay, unshieldThe proof does not verify over the seven public inputs. Raised whenever any bound value differs from what was proven: depositor, recipient, relayer, amount, price, fee, relayer_refund, receipt fields or memos
60150x177fInsufficientPoolFundsThe vault cannot cover the transfer and its rent minimum.pay, unshieldA debit (the price, fee or relayer_refund in pay, the amount or relayer_refund in unshield) would take the pool vault below its rent-exempt minimum

Errors outside the program

Some refusals come before the handler runs and carry no Geode code.

RefusalRaised byWhy
System Program custom program error: 0x0, "already in use"shield, pay, unshieldA nullifier PDA already exists, so the note was already spent
System Program insufficient lamportsshield, pay, unshieldThe signer cannot fund the deposit or the rent of the accounts it creates
Anchor ConstraintSeeds (2006)Every instructionA PDA account is not at its seeds
Anchor signer and writable checks (3010, 2000)Every instructionThe signer did not sign, or a writable account was passed read-only