Look up any revert string to identify the raising contract, failing condition, and concrete fix across YieldBasis core contracts, Curve Twocrypto v3.0.0 pools, pool policies, PythReportBank, hybrid vaults, net-pressure contracts, and the DAO stack.
Reverts inside external Curve pool calls bubble up to the YieldBasis caller:
- On a pool running
YBOraclizedPolicy, a policy revert during add_liquidity (such as LT deviation) bubbles up from LT.deposit.
LT.deposit, LT.withdraw, and AMM.exchange (including VirtualPool.exchange) finish by donating accrued borrower interest to the Curve pool. If that donation fails, the entire call reverts with slippage or donation above cap!. Call LT.distribute_borrower_fees or wait for the donation cap window to clear.
Core
LT.vy
| Revert string | Cause | Remediation |
|---|
Access | Caller is neither admin nor Factory.admin(). | Call from LT.admin() or Factory.admin(). |
Already set | Second set_amm call. | AMM is immutable after initialization; deploy a new market if needed. |
Slippage | Output fell below min_shares (deposit) or min_assets (withdraw). | Re-quote with preview_deposit / preview_withdraw and widen slippage tolerance. |
Debt too high | Post-deposit LEVAMM value exceeds AMM.max_debt() / 2 (also raised by preview_deposit). | Reduce deposit size or wait for debt capacity to increase via allocate_stablecoins. |
Withdrawing nothing | withdraw(0, ...) called. | Pass a non-zero shares amount. |
Withdraw to/from staker | staker (LiquidityGauge) is msg.sender, receiver, or owner in emergency_withdraw. | Unstake from LiquidityGauge to an EOA or non-staker contract first, then withdraw from LT. |
We're dead. Use emergency_withdraw | withdraw called while AMM.is_killed() == True. | Call LT.emergency_withdraw instead of withdraw. |
Remainder too small | Post-operation totalSupply falls in (0, 1e6) (MIN_SHARE_REMAINDER). | Withdraw the full remaining balance or leave at least 1e6 shares. |
Deposit to staker | receiver == staker in LT.deposit. | Deposit to your own address and stake in LiquidityGauge, or use StakeZap / LTDepositZap. |
N>2 | Constructor: Curve pool has more than 2 coins (coins(2) did not revert). | Deploy only against a 2-coin Curve Twocrypto pool. |
receiver | emergency_withdraw by admin or emergency admin with receiver != owner. | Set receiver == owner. |
owner | emergency_withdraw by non-admin with owner != msg.sender. | Call from owner directly. |
Not killed | Non-owner calls emergency_withdraw while LEVAMM is live. | Use normal withdraw while AMM.is_killed() == False. |
Need factory | withdraw_admin_fees when admin is not a contract. | Ensure LT.admin() points to Factory. |
Killed | withdraw_admin_fees while LEVAMM is killed. | Admin fee withdrawal is disabled once a market is killed. |
No fee_receiver | Factory.fee_receiver() == address(0). | Set a non-zero fee_receiver on Factory. |
Staker=fee_receiver | Factory.fee_receiver() == staker. | Configure Factory.fee_receiver() to a contract other than the market's gauge. |
Loss made admin fee negative | withdraw_admin_fees while liquidity.admin < 0. | Wait until accrued admin fees exceed accumulated losses. |
Staker already set | Second set_staker call. | staker can only be set once per LT. |
GAS | GaugeController.checkpoint failed with < 200_000 gas left for the fixed-gas retry. | Supply a higher transaction gas limit. |
AMM.vy
| Revert string | Cause | Remediation |
|---|
Fee too high | Constructor: fee > MAX_FEE (10%). | Pass a fee <= 1e17. |
Unsafe min | debt < coll_value * MIN_SAFE_DEBT / 1e18. | Increase debt or adjust trade size so leverage stays within safe bounds. |
Unsafe max | debt > coll_value * MAX_SAFE_DEBT / 1e18. | Decrease debt or rebalance collateral before retrying. |
Access | set_rate, set_fee, or set_killed called by non-LT. | Route parameter updates through LT / Factory. |
Access violation | _deposit or _withdraw called by non-LT. | Deposit and withdraw through the market's LT contract. |
Rate too high | rate > MAX_RATE (100% APR). | Cap interest rate at MAX_RATE. |
Amount too large | get_dy(0, 1, in_amount) with in_amount > debt. | Cap in_amount at AMM.get_debt(). |
Slippage | exchange output < min_out. | Re-quote with get_dy and update min_out. |
Empty AMM | exchange when collateral_amount == 0. | Market has no liquidity; skip until LPs deposit. |
Bad final state | Post-swap x0 < x0_pre. | Reduce trade size or verify oracle and pool state before retrying. |
Empty-data reverts in AMM.vy: set_fee with fee > MAX_FEE, exchange / _deposit / _collect_fees when is_killed == True, or invalid (i, j) pair.
VirtualPool.vy
| Revert string | Cause | Remediation |
|---|
Wrong caller | onFlashLoan caller != FACTORY.flash(). | Do not call onFlashLoan directly; invoke VirtualPool.exchange. |
Slippage | Output < min_out. | Re-quote via VirtualPool.get_dy and refresh min_out. |
Empty-data reverts in VirtualPool.vy: onFlashLoan with initiator != self or token != STABLECOIN; get_dy or exchange with (i, j) other than (0, 1) or (1, 0).
Factory.vy
| Revert string | Cause | Remediation |
|---|
Access | Caller != Factory.admin(). | Execute via the Factory.admin() governance proxy. |
Wrong stablecoin | pool.coins(0) != STABLECOIN. | Ensure the Curve pool's coins(0) is crvUSD. |
Only set once | Second set_mint_factory call. | mint_factory is immutable once set. |
Minter | set_allocator targets mint_factory. | Choose an allocator address other than mint_factory. |
Already set | Second set_gauge_controller call. | gauge_controller can only be set once. |
Admin fee too high | min_admin_fee > 1e18. | Pass min_admin_fee <= 1e18. |
Bad aggregator | agg.price() not strictly inside (0.9e18, 1.1e18). | Verify the stablecoin price aggregator returns a valid 18-decimal price near 1e18. |
Too many markets | market_count >= 50000. | Factory market limit reached. |
Nonexistent market | fill_staker_vpool(i) with i >= market_count. | Pass an index < Factory.market_count(). |
Pool policies and PythReportBank
YBOraclizedPolicy
| Revert string | Cause | Remediation |
|---|
LT deviation | LT.deposit debt deviates from proportional LEVAMM debt by > policy.ratio_tolerance(). | Compute debt proportionally to existing LEVAMM debt/collateral within policy.ratio_tolerance(), or route through LTDepositZap. See Deposit, withdraw, and migrate. |
auth! | update_pool_state called by non-POOL. | Only the attached Curve pool invokes update_pool_state. |
pool uninitialized | sync() or revive while pool.price_scale() == 0. | Initialize the Curve pool with initial liquidity before calling sync() or reviving. |
access | set_killed caller is neither owner nor EMERGENCY_ADMIN. | Call from owner() or EMERGENCY_ADMIN(). |
ownable: caller is not the owner | Owner-only config or ownership call from non-owner. | Execute through policy.owner() (YB DAO). |
ownable: new owner is the zero address | transfer_ownership(address(0)). | Pass a non-zero new owner address, or call renounce_ownership(). |
coin index out of range | get_dy_with_report with i == j or index > 1. | Pass (0, 1) or (1, 0). |
not attached | get_dy_with_report when pool.POLICY() != self. | Query the pool's active pool.POLICY() contract. |
unsafe value for y | get_dy_with_report with dx draining pool reserves. | Reduce swap input dx. |
base fee | base_fee < 1e5 (0.1 bp) or base_fee > fallback_fee. | Set 1e5 <= base_fee <= fallback_fee. |
fallback fee | fallback_fee > 1e9 (10%). | Set fallback_fee <= 1e9. |
capture | capture > 1e18 (100%). | Set capture <= 1e18. |
relax time | relax_time == 0 or > 3_600 s. | Set 1 <= relax_time <= 3600. |
fast half-life | fast_half_life < 600 s or > slow_half_life. | Set 600 <= fast_half_life <= slow_half_life. |
slow half-life | slow_half_life > 604_800 s (7 days). | Set slow_half_life <= 604800. |
trend gate | trend_gate > 1e17 (10%). | Set trend_gate <= 1e17. |
step cap | step_cap == 0 or > 60 * 1e14 (60 bp). | Set 0 < step_cap <= 6e15. |
report lifetime | report_lifetime > 14_400 s (4 hours). | Set report_lifetime <= 14400. |
price bounds | Bounds outside $1e-12 to $1e12 or min_price > max_price. | Ensure 1e6 <= min_price <= max_price <= 1e30. |
ratio tolerance | ratio_tolerance > 1e15 (10 bp). | Set ratio_tolerance <= 1e15. |
pool=0, emergency admin=0, bank, feed id, channel, basis coin, invert basis, amm collateral, amm stablecoin, pool precision, admin fee | Constructor validation failure. | Verify constructor arguments match the target pool, LEVAMM, and PythReportBank. |
PythReportBank
| Revert string | Cause | Remediation |
|---|
fee | msg.value != verifier.verification_fee() (underpayment or overpayment). | Query bank.verification_fee() immediately before sending and pass exact msg.value. |
signer | Verifier returned address(0). | Fetch a fresh signed EVM update from the Pyth Lazer endpoint. |
update length | len(_update) != 71 + payload_length. | Strip trailing bytes or re-fetch the raw evm payload from Pyth Lazer. |
message ahead | message_us > block.timestamp * 1e6 + 6_000_000 (> 6 s in the future). | Wait for the next block or check local clock / L2 timestamp skew. |
message age | message_us + 60_000_000 < block.timestamp * 1e6 (> 60 s old). | Fetch a fresh Pyth Lazer update and re-submit with sufficient priority fee. |
observation ahead | Any feed observation_us > block.timestamp * 1e6 + 6_000_000. | Wait for the next block and re-submit. |
observation age | Any feed observation_us + 60_000_000 < block.timestamp * 1e6. | Fetch a fresh update; even skipped feeds must fall inside the 60 s delivery window. |
evm magic | decode: update does not start with 0x2a22999a. | Request the evm format from Pyth Lazer. |
channel | decode: payload channel != _channel. | Request the channel returned by policy.CHANNEL(). |
feed | decode: _feed_id not present in the update. | Include policy.FEED_ID() in your Pyth Lazer subscription. |
payload magic | Payload does not start with 0x93c7d375. | Verify the signed payload is a valid Pyth Lazer EVM update. |
feed count | Feed count is 0 or > 8 (MAX_FEEDS). | Subscribe to between 1 and 8 feeds per update. |
payload length | len(payload) != 14 + 27 * feed_count. | Request exactly the 3 expected properties per feed (price, exponent, feed_update_timestamp). |
price property, exponent property, observation property | Missing or misordered feed properties (0x0300, 0x04, 0x0c01). | Configure the Pyth Lazer subscription with properties in exact order: price, exponent, feed update time. |
duplicate feed | Same feed_id appears more than once in one update. | Deduplicate feed IDs in the subscription request. |
observation time | Feed observation_us > message_us. | Re-fetch a valid update from Pyth Lazer. |
verifier | set_verifier or constructor: _verifier is not a contract. | Pass the deployed Pyth Lazer verifier contract address. |
ownable: caller is not the owner | set_verifier or ownership call from non-owner. | Execute via bank.owner(). |
Pyth Lazer verifier reverts during deliver_report: Insufficient fee provided, input too short, invalid evm magic, invalid signature, invalid signer. Updates longer than 301 bytes revert during ABI decoding without a reason string. Stale feeds (observation_us <= latest.observation_us) and unsupported prices (mantissa <= 0 or exponent outside [-18, 0]) are skipped without reverting.
YBTwocryptoPolicy
| Revert string | Cause | Remediation |
|---|
auth! | update_pool_state caller != pool. | Only the attached Curve pool calls update_pool_state. |
pool=0, fast half-life, slow half-life, half-life order, kappa, deadband, max cap, min cap | Constructor validation failure. | Verify constructor parameter bounds. |
Curve pool (Twocrypto v3.0.0)
On pools running Curve Twocrypto v3.0.0 (check pool.version()):
| Revert string | Cause | Remediation |
|---|
!amounts | add_liquidity with both amounts 0. | Provide at least one non-zero coin amount. |
!wl | LP allowlist enabled and msg.sender not allowlisted (exempt for donations). | Add liquidity through LT (allowlisted) rather than directly to the Curve pool. |
!init | First add_liquidity on an uninitialized pool. | Seed both coins during pool initialization. |
nothing minted | add_liquidity mints 0 LP. | Increase deposit amounts. |
nonzero receiver | Donation with receiver != address(0). | Pass receiver = address(0) when donating. |
donation above cap! | Donation shares exceed donation_shares_max_ratio. | Donate a smaller amount or wait for the donation cap window to decay. |
slippage | Output below minimum in add_liquidity, remove_liquidity*, or exchange. | Re-quote and refresh minimum output parameters. |
!coins | exchange_received did not receive at least dx. | Transfer at least dx to the pool before calling exchange_received. |
same coin | exchange with i == j. | Pass distinct coin indices (0, 1) or (1, 0). |
zero dx | exchange with 0 input. | Pass dx > 0. |
negative donation / tweaked supply must shrink | Internal tweak_price or donation share burn invariant failure. | Retry in a subsequent block; report if persistent. |
!amount / !tokens | Removal exceeds total LP supply or yields both amounts 0. | Reduce removal amount or pass a larger non-dust share amount. |
!receiver | LP transfer to pool itself or address(0). | Pass a valid non-zero recipient address. |
!transferFrom / !transfer | Inbound or outbound ERC-20 transfer failed. | Check token balance and allowance to the pool. |
!balance | Post-operation balance is 0 or scaled balances diverge by >= 1,000:1. | Reduce trade or withdrawal size. |
only owner | Admin call not from Curve factory admin. | Execute via the pool admin proxy (pool.admin()). |
Empty-data reverts in Twocrypto v3.0.0: balanced remove_liquidity when the policy callback fails with < 500_000 gas remaining beforehand (supply more gas), or admin parameter bound failures. Pool view contract (get_dy / get_dx) reverts: coin index out of range, do not exchange 0 coins, do not exchange out 0 coins, unsafe value for y.
Hybrid vaults and utilities
HybridVault.vy
| Revert string | Cause | Remediation |
|---|
Already initialized | Second initialize call. | Deploy a new vault via HybridVaultFactory.create_vault. |
Access / Only owner | Non-owner caller on owner-gated operations or set_crvusd_vault. | Call from the vault owner address. |
Only admin | set_personal_limit from non-HybridVaultFactory admin. | Call from HybridVaultFactory admin. |
Vault not allowed | crvusd_vault is not allowlisted on HybridVaultFactory. | Select an allowlisted crvusd_vault. |
Has active positions | set_crvusd_vault while vault holds active LT positions. | Withdraw all active positions before switching crvusd_vault. |
Bad pool_id | market.lt == address(0). | Use a valid pool_id from Factory.markets(pool_id). |
Not enough crvUSD | Insufficient crvUSD backing without deposit_stablecoins. | Supply additional crvUSD or enable deposit_stablecoins. |
Beyond pool limit | Deposit exceeds pool limit or personal limit. | Check HybridVaultFactory.pool_limits(pool_id) and vault.personal_limit(pool_id) (or vault.pool_limits(pool_id) for the combined limit) and reduce deposit size. |
Debt made too high | Sanity check: debt > 1.1 * additional_crvusd. | Re-check oracle pricing and reduce deposit size. |
No liquidity given | lt_shares == 0. | Increase deposit amount above dust. |
Cannot withdraw stables | withdraw_stablecoins == True while an active market's AMM value_oracle() is reverting. | Pass withdraw_stablecoins = False to withdraw LT shares without releasing crvUSD, or wait for oracle recovery. |
Not enough crvUSD left | Withdrawal drops crvUSD backing below required stablecoin_fraction. | Withdraw less crvUSD or reduce LT positions first. |
Token not allowed | recover_tokens targets a protected vault or market token. | Only recover unrelated stray ERC-20 tokens. |
Oracle is broken | Both global and per-pool oracles fail. | Wait for oracle recovery or use emergency_withdraw. |
Zero shares | emergency_withdraw(pool_id, 0, ...) or unstaked LT balance is 0 (for example, shares are still staked). | Unstake gauge shares first and pass a non-zero shares count. |
HybridVaultFactory.vy and owners
| Contract | Revert string | Cause | Remediation |
|---|
HybridVaultFactory | Already created | User already owns a vault. | Query user_to_vault(user) to reuse the existing vault. |
HybridVaultFactory | Vault not allowed | crvusd_vault not allowlisted. | Choose an allowlisted crvusd_vault. |
HybridVaultFactory | Vault impl not set | vault_impl == address(0). | Admin must call set_vault_impl first. |
HybridVaultFactory | Access | Non-ADMIN caller. | Call from ADMIN. |
HybridVaultFactory | Only vaults can call | update_vault_required or lt_allocate_stablecoins from an unregistered address. | Only factory-created vaults call accounting hooks. |
HybridVaultFactory | Vault wind-down | Requirement increase on a disallowed crvusd_vault. | Migrate to an allowlisted crvusd_vault. |
HybridVaultFactory | Beyond vault limit | Increase exceeds crvusd_vault_limits. | Reduce deposit size or switch to a vault with available cap. |
HybridFactoryOwner | Access | Caller is not ADMIN (or limit setter for enabled LT). | Call from ADMIN or an enabled limit setter. |
HybridFactoryOwner / MigrationFactoryOwner | Not enough reserves | Deallocation would drop allocation below 3/4 of LEVAMM oracle value. | Reduce deallocation amount. |
MigrationFactoryOwner | Access / Not disabled | Non-ADMIN caller or lt_allocate_stablecoins(lt, 0) on an enabled LT. | Call from ADMIN, or only zero-allocate disabled LTs. |
Migrators, deposit zap, and lending oracles
| Contract | Revert string | Cause | Remediation |
|---|
LTMigrator / LTMigratorGated | same LT | lt_from == lt_to. | Pass distinct source and target LT addresses. |
LTMigrator / LTMigratorGated | lt_from not in factory | Source LT not registered in Factory. | Verify lt_from against Factory.markets(i). |
LTMigrator / LTMigratorGated | lt_to deprecated | Target LT is disabled (disabled_lts(lt_to) == True). | Migrate into an active target market. |
LTMigrator / LTMigratorGated | lt_to superseded | lt_to is not the newest market for the asset. | Target the latest LT for that underlying asset. |
LTMigrator / LTMigratorGated | not enough out | shares_out < min_out in migrate_staked. | Re-quote and refresh min_out. |
LTDepositZap | Slippage | Staked deposit(..., stake=True) gauge shares < min_shares. | Re-quote and widen min_shares. |
YBLendingOracle / YBLendingOracleLL | AMM reentrancy | Price read while LEVAMM reentrancy lock is active. | Do not read oracle prices inside an AMM / LT callback. |
YBLendingOracle / YBLendingOracleLLFactory | No market | market_id >= market_count or zero LT. | Use a valid market_id < Factory.market_count(). |
YBLendingOracleLL / YBLendingOracleLLFactory | ema_time | ema_time == 0 or > 10**9 s. | Pass 0 < ema_time <= 10**9. |
YBLendingOracleLL | Only factory | set_ema_time from non-factory. | Call YBLendingOracleLLFactory.set_ema_time from the DAO. |
YBLendingOracleLLFactory | Not DAO / No oracles | Non-DAO caller or market has no deployed oracles. | Call from dao() after deploying oracles with create_oracles. |
YBPriceProxy / YBLendingOracleLL | Initialized / Zero | Duplicate initialize or zero-address argument (YBLendingOracleLLUSD, YBLendingOracle, and YBLendingOracleLLFactory only raise Zero on zero-address arguments). | Deploy a fresh proxy and pass non-zero addresses. |
LTSwapZap has no custom revert strings; owner-only functions revert with ownable: caller is not the owner.
Net pressure
Owner-only functions in FeeSplitter, MerklPIDDriver, and PID revert with ownable: caller is not the owner.
FeeSplitter.vy
| Revert string | Cause | Remediation |
|---|
fraction > 1 | split_fraction > 10**18 (100%). | Pass split_fraction <= 1e18. |
MerklPIDDriver.vy
| Revert string | Cause | Remediation |
|---|
Not manager | Caller is neither owner nor manager. | Call from owner() or manager(). |
No wrapper | approve_merkl called while reward wrapper is unset. | Call set_merkl(creator, wrapper) with a non-zero wrapper first. |
No pools | preview_target_apr called while half_tvl == 0. | Ensure at least one pressure LT has non-zero TVL. |
PID.vy, FastGauge.vy, YBNetPressure.vy, MarketRateGetter.vy
| Contract | Revert string | Cause | Remediation |
|---|
PID | No pools | trigger or preview_signals while half_tvl == 0. | Ensure at least one pressure LT has non-zero TVL. |
FastGauge | Below min supply | Post-operation supply in (0, 10e18) (MIN_TOTAL_SUPPLY). | Deposit at least 10e18 or withdraw the entire supply. |
FastGauge | Only PID | set_reward_rate from non-pid. | Call via the configured PID contract. |
FastGauge | ema_time | set_ema_time(0). | Pass ema_time > 0. |
FastGauge | No zap: LP is not a pool | Zap liquidity call while ZAP_ENABLED == False. | Use deposit / withdraw with LP tokens directly. |
FastGauge | Bad amounts length / Bad min_amounts length | Array length != POOL_N_COINS. | Match array length to the underlying pool's coin count. |
FastGauge | erc4626: deposit/mint/withdraw/redeem more than maximum | Amount exceeds ERC-4626 max* bound. | Query maxDeposit / maxWithdraw / maxRedeem first. |
FastGauge | erc4626: transferFrom/transfer operation did not succeed | LP transfer into or out of gauge failed. | Check LP balance and allowance. |
YBNetPressure | AMM reentrancy | Read while LEVAMM reentrancy lock is active. | Avoid reading inside an AMM / LT callback. |
MarketRateGetter | Bad ssr | Constructor: susds.ssr() < 10**27. | Pass a valid sUSDS contract with ray-scaled ssr >= 1e27. |
DAO, veYB, and gauges
YB.vy
| Revert string | Cause | Remediation |
|---|
erc20: access is denied | emit called by non-minter. | Only authorized minters (GaugeController) can call emit. |
VotingEscrow.vy (veYB)
| Revert string | Cause | Remediation |
|---|
Min value | create_lock with _value < UMAXTIME (126_144_000 wei). | Lock at least 126_144_000 wei of YB. |
Withdraw old tokens first | create_lock while a lock already exists. | Use increase_amount / increase_unlock_time, or withdraw an expired lock first. |
Can only lock until time in the future | Rounded unlock_time <= block.timestamp. | Choose an _unlock_time at least one week ahead of block.timestamp. |
Voting lock can be 4 years max | Rounded unlock_time > block.timestamp + UMAXTIME. | Cap _unlock_time at block.timestamp + 4 * 365 * 86400. |
No existing lock found | increase_amount with no active lock. | Call create_lock first. |
Cannot add to expired lock. Withdraw | increase_amount on an expired lock. | Call withdraw first, then create_lock. |
Nothing is locked | increase_unlock_time or infinite_lock_toggle with amount == 0. | Call create_lock first. |
Lock expired | increase_unlock_time or infinite_lock_toggle on an expired lock. | Call withdraw first, then create_lock. |
Can only increase lock duration | New rounded unlock_time <= current end. | Choose a later week boundary than locked[user].end. |
Not allowed | infinite_lock_toggle (off) or transfer rejected by transfer_clearance_checker (active gauge votes). | Reset all gauge weights to 0 in GaugeController (after the 10-day vote delay) before toggling off or transferring. |
The lock didn't expire | withdraw before locked[msg.sender].end. | Wait until block.timestamp >= locked[msg.sender].end (disable infinite lock first if active). |
Not supported | delegate or delegateBySig called. | Delegation is disabled in veYB; vote directly from the locking address. |
erc721: caller is not token owner or approved | Unauthorized NFT transfer. | Call from the lock owner or an approved operator. |
Wrong token ID | token_id != uint256(uint160(owner)). | Pass uint256(uint160(owner)) as token_id. |
Need max veLock | Transfer attempted when owner or to is not max-locked with matching rounded end time. | Ensure both accounts are infinite-locked, or both end at the current maximum week. |
erc721: transfer to non-IERC721Receiver implementer | safeTransferFrom to a contract without onERC721Received. | Use transferFrom or implement IERC721Receiver on to. |
Empty-data revert in VotingEscrow.vy: increase_amount with _value < UMAXTIME.
GaugeController.vy
| Revert string | Cause | Remediation |
|---|
Gauge already added | Duplicate add_gauge. | Gauge is already registered. |
Gauge not alive | checkpoint or emit for an unregistered gauge (time_weight[gauge] == 0). | Register the gauge via add_gauge first. |
Vote checker not set | VotingEscrow.transfer_clearance_checker() != self. | Governance must point VotingEscrow clearance checker to GaugeController. |
Mismatch in lengths | len(_gauge_addrs) != len(_user_weights). | Pass parallel arrays of equal length (<= 50). |
Expired | Caller's veYB lock is expired. | Extend or re-create the veYB lock before voting. |
Weight too large | Single gauge weight > 10000 bp. | Pass weights in 0..10000. |
Killed | Voting non-zero weight for a killed gauge. | Set weight to 0 for killed gauges (is_killed(gauge) == True). |
Gauge not added | Unregistered gauge in vote_for_gauge_weights or set_killed. | Verify gauge address against gauges(i). |
Cannot vote so often | Re-voting on the same gauge within 10 days (WEIGHT_VOTE_DELAY). | Wait until block.timestamp >= last_user_vote[user][gauge] + 864000. |
Used too much power | Total allocated vote weight across all gauges > 10000 bp. | Reduce weights on other gauges first so the sum stays <= 10000. |
LiquidityGauge.vy
| Revert string | Cause | Remediation |
|---|
YB | add_reward, change_reward_distributor, or deposit_reward targets YB. | YB is managed exclusively by GaugeController. |
LP_TOKEN | add_reward targets the gauge's LT token. | Use a distinct external reward token. |
Already added | Duplicate add_reward. | Token is already registered as a reward. |
Not added | change_reward_distributor for an unregistered token. | Call add_reward first. |
No rewards | deposit_reward with amount == 0. | Pass amount > 0. |
Finishes in the past | deposit_reward with finish_time <= block.timestamp. | Pass a future finish_time timestamp. |
Rate unknown | deposit_reward(..., finish_time=0) after previous finish_time already passed. | Pass an explicit future finish_time. |
No reward | Reward token has no distributor during checkpoint or preview_claim. | Verify the token is in reward_tokens(i). |
erc4626: deposit/mint/withdraw/redeem more than maximum | Amount exceeds ERC-4626 max* bound. | Query maxDeposit / maxWithdraw / maxRedeem first. |
erc4626: leave MIN_SHARES | Post-operation supply falls in (0, 1e12). | Stake at least 1e12 shares, or redeem the full remaining supply. |
ownable: caller is not the owner | Owner-only call from non-owner. | Execute via gauge.owner() (Factory.admin()). |
receiver | Kill-mode redeem by emergency_admin with receiver != owner. | Set receiver == owner. |
erc4626: transferFrom/transfer operation did not succeed | LT transfer into or out of gauge failed. | Check LT balance and approval to the gauge. |
FeeDistributor.vy, vesting escrows, and governance
| Contract | Revert string / Error | Cause | Remediation |
|---|
FeeDistributor | Ded | fill_epochs (or claim) called while is_killed == True. | Wait for governance to unkill FeeDistributor or recover tokens. |
FeeDistributor | Might be a vest | Third-party claim with use_vest == False targeting a CliffEscrow address. | Pass the beneficiary's address as receiver with use_vest = True. |
InflationaryVest | Admin required | start or set_recipient from non-owner. | Call from owner(). |
InflationaryVest | Already started | Second start() call. | Vest is already active. |
VestingEscrow | Lengths mismatch | fund array-length mismatch. | Pass equal-length _recipients and _amounts arrays (<= 100). |
VestingEscrow | Rugged | Target recipient was already reclaimed via rug_disabled. | Rugged recipients cannot be funded, toggled, or rugged again. |
VestingEscrow | Disabled | fund for a disabled recipient. | Re-enable the recipient with toggle_disable before funding. |
VestingEscrow | Cannot disable | toggle_disable when can_disable == False. | Disabling was permanently turned off for this escrow. |
VestingEscrow | Not disabled | rug_disabled for an enabled recipient. | Call toggle_disable before rug_disabled. |
CliffEscrow | Empty recipient / Already initialized | initialize with address(0) or called twice. | Deploy a new minimal proxy via VestingEscrow.fund. |
CliffEscrow | Cliff still applies | transfer, approve, or transferFrom before unlock_time. | Wait until block.timestamp >= unlock_time. |
CliffEscrow | Not authorized | Non-recipient calls restricted escrow action (or transfer with to != recipient). | Call from CliffEscrow.recipient(). |
CliffEscrow | Cannot recover YB | recover_token(YB, ...). | Use transfer after unlock_time expires. |
SnapshotSplitter | Already claimed | Duplicate claim for the same address. | Each snapshot allocation can be claimed once. |
CallComparator | Not equal, Equal, Not greater, Not less, Timestamp not greater, Timestamp not less, Too early | Governance precondition check failed. | Wait for the required on-chain state or cooldown before executing the proposal. |
Aragon TokenVoting | ProposalCooldownNotMet | createProposal called within getProposalCooldownPeriod() of the caller's last proposal. | Wait until the cooldown period elapses before creating another proposal. |
StakeZap, TokenSender, and Multisend define no custom revert strings; reverts originate from underlying token transfers or target contract calls.