Skip to content

v2.0.0

Choose a tag to compare

@zhongeric zhongeric released this 16 Jun 19:12
· 3 commits to main since this release
e3d4316

v2.0.0 (latest)

Major release with breaking changes to the auction constructor, factory constructor, sweep authorization, the factory's distribution interface, and a number of interface renames. Adds supply rollover settlement math, a protocol fee controller, and new lens contracts for offchain reads. Integrators must redeploy and update integrations.

Changed

  • Breaking: Moved ClaimBlockIsBeforeEndBlock, NotClaimable, and AuctionIsNotOver errors out of IContinuousClearingAuction and into IStepStorage. Integrators importing these from the auction interface must update imports. (#321)
  • Added CCALens and TickDataLens periphery contracts for offchain reads of auction state and initialized tick data. Non-breaking addition. (#325)
  • Breaking: sweepCurrency() is now restricted to FUNDS_RECIPIENT and sweepUnsoldTokens() is now restricted to TOKENS_RECIPIENT. Adds new NotAuthorized(address authorized, address caller) error. Callers other than the configured recipients will revert. (#329)
  • Breaking: Reworked auction settlement to support supply rollover so that demand above the clearing price carries forward over the remaining schedule. Adds new getters remainingSupplyQ96X7, remainingSupply, requiredDemandQ96, and requiredDemandQ96AtNextActiveTick. Final clearing prices, per-block fills, and bid economics may differ from v1.x for the same inputs. (#327)
  • Removed obsolete DoS test. Non-breaking. (#333)
  • Breaking: Renamed ITokenCurrencyStorage to IAuctionStorage and moved currencyRaised, currencyRaisedQ96X7, sumCurrencyDemandAboveClearingQ96, totalCleared, totalClearedQ96X7, remainingSupply, and remainingSupplyQ96X7 into that interface. Renamed currencyRaisedQ96_X7 → currencyRaisedQ96X7 and totalClearedQ96_X7 → totalClearedQ96X7. (#332)
  • Fixed an edge case where the clearing price could be incorrectly advanced when rounding caused remainingSupply to reach zero before the schedule completed. New bids submitted with zero remaining supply now revert. (#331)
  • Breaking: Tightened MIN_FLOOR_PRICE from 2^32 to 2^32 + 1 so that its Q96 reciprocal fits in a uint160 for downstream LBP / v4 initialization math. Auctions configured with floor price exactly 2^32 are no longer accepted. (#336)
  • Internal refactor to call CheckpointAccountingLib helpers directly from ContinuousClearingAuction, removing thin wrappers from CheckpointStorage. Non-breaking. (#338)
  • Breaking: Added an owner-controlled IProtocolFeeController and threaded it through the factory and auction. ContinuousClearingAuctionFactory constructor now takes address _protocolFeeController and exposes a protocolFeeController() getter; ContinuousClearingAuction constructor takes an additional address _protocolFeeController argument. sweepCurrency() now transfers the protocol fee to the controller and sweeps currencyRaised − protocolFee to the funds recipient. currencyRaised() no longer subtracts protocol fees, and lbpInitializationParams() returns the post-fee currencyRaised. ILBPInitializer is now imported from the liquidity-launcher submodule rather than src/interfaces/external. (#340)
  • Updated TickDataLens to use the rollover-aware requiredDemandQ96 helper so tick data reflects the remaining supply over the remaining issuance schedule. (#334)
  • Breaking: lbpInitializationParams() now reverts with NotGraduated if the auction did not graduate. Previously it returned stale values for unsuccessful auctions. (#342)
  • Expanded stateful invariant test coverage. Test-only, non-breaking. (#337)
  • sweepCurrency() no longer reverts for auctions that did not graduate; it now performs a no-op sweep (sweeping zero currency) rather than reverting NotGraduated. (#343)
  • Breaking: Standardized the factory's distribution interface to the liquidity-launcher submodule's IDistributorFactory. initializeDistribution() is renamed to create() and getAuctionAddress() is renamed to getAddress() (now returning IDistributor); the local IDistributionStrategy and IDistributionContract interfaces are removed. (#356)
  • Fixed bid submission to take the block checkpoint before invoking the validation hook. (#346)
  • Fixed requiredDemandQ96AtNextActiveTick() to return zero when there is no next active tick. (#345)
  • Prevented same-block forceIterateOverTicks() from changing bid admission: bid admission now uses the checkpoint clearing price, and force iteration reverts with the new CheckpointAlreadyExistsForBlock error when a checkpoint already exists for the current block. (#355)