HWAN

Error reference

The errors a trader, reporter, arbiter or market operator can meet in the kimchi program, grouped by the step that raises them. Messages are the program's own.

Setup

ErrorMessage
NotUpgradeAuthorityOnly the program's upgrade authority may initialize
ArbiterSetInvalidArbiter set must be 1 to 5 distinct keys with a strict-majority threshold
TreasuryInvalidTreasury must be a USDC token account
BandInvalidBand must satisfy -10000 <= floor < cap <= 10000 ibp and be at most 3000 ibp wide
FeeTooHighFee is above the maximum
BondInvalidBond must be positive
OiCapInvalidOpen-interest cap must be positive
WindowTooShortDispute or arbitration window is shorter than the minimum
ExpiryInPastExpiry must be in the future
ExpiryNotOnScheduleExpiry must be 16:00, 17:00 or 20:00 UTC on a weekday (Korea, India, Argentina)

Trading

ErrorMessageWhat to do
MarketNotTradingMarket is not tradingpick an open series
ExpiredMarket has expiredtrade the next series
PriceOutsideBandPrice is outside the market bandquote between floor and cap
UnitsInvalidUnits must be positiveenter a size
OfferTooSmallOffer has fewer units left than requestedtake fewer units or refresh the book
OfferChangedOffer price or side changed since the taker quoted itrefresh and quote again
SelfTradeMaker and taker are the same walletuse a different offer
OiCapExceededFill would push open interest above the market captrade a smaller size
CancelNotAllowedOnly the maker may cancel before expiry

Settlement

ErrorMessage
BeforeExpiryReports are accepted only after expiry
AlreadyReportedMarket already has a report
ValueOutsideBandReported value must be clipped to the band
NothingToDisputeNothing to dispute
DisputeWindowClosedDispute window has closed
DisputeSameValueA dispute must name a different value than the report
NoDisputeNo dispute is open
NotArbiterSigner is not an arbiter of this market
AlreadyVotedArbiter has already voted
ArbitrationClosedArbitration window has closed
NotReportedMarket has no report yet
DisputeWindowOpenDispute window is still open
ArbitrationOpenArbitration window is still open
AlreadySettledMarket is already settled

Payouts and closing

ErrorMessage
NotSettledMarket is not settled
NothingToNetPosition holds no long and short pair to net
NothingOwedNothing is owed to this account
NoFeesNo fees to sweep
MarketNotEmptyMarket still holds open offers, positions, fees or bonds
MathOverflowArithmetic overflow