Codebase Change Analysis
V3 Codebase: https://github.com/sky-ecosystem/chief/blob/newchief/src/Chief.sol
V2 Codebase: https://github.com/sky-ecosystem/chief/blob/d42f10fdf922bbc7636817961a85f540b285d0e6/src/chief.sol
Functional Interface Changes
Section titled âFunctional Interface ChangesâThere have been NO changes to external user-facing function interfaces in the Chief contract upgrade. These functions can continue to be used as before.
lock(uint256): Deposits governance tokens into the Chief contract to gain voting powerfree(uint256): Withdraws governance tokens from the Chief contract, removing associated voting poweretch(address[]): Creates a new slate of candidates (a unique address set to vote for)vote(address[]): Votes for a slate of addresses with your full voting weightlift(address): Elevates an address to authority status if it has sufficient votes
External Considerations
Section titled âExternal ConsiderationsâFlash Loan Protection Changed Flash loan protections remain in the upgraded Chief contract, but now use a new mechanism to prevent manipulation of the voting process with flash-loaned MKR or SKY tokens.
Previous Implementation:
lockandfreecould not be executed within the same block.liftcould be performed at any time, including in the same block aslock.- This allowed a flash loan transaction to perform
lockandliftin a single block, but notfree.
New Implementation:
liftandfreecannot occur in the same block.- Flash loan transactions can still perform
lockandlifttogether, but cannot executefreein that block due to new restrictions betweenfreeandlift. lockandfreecan now occur together in the same block.
Lift Cooldown Period
lift operations now have a cooldown: after a successful lift, further lift actions are blocked until the cooldown period expires, even if attempted within the same block.
- The
lockfunction does not update the last timestamp when tokens are deposited. This behavior differs from previous versions, where the timestamp was updated on each lock operation. - The
liftfunction now updates the last timestamp. This change ensures that the timestamp accurately reflects the most recent lift operation, which is important for enforcing the cooldown period.
IOU Token Removed
IOU tokens are no longer issued for deposited SKY. As a result, actions involving IOU tokensâsuch as approving IOU transfers before calling free on Chiefâare no longer required.
- The
lockfunction no longer mints IOU token balances when governance tokens are deposited. - The
freefunction no longer burns IOU token balances when governance tokens are withdrawn. Since IOU tokens are no longer issued, there is no need to handle their burning during withdrawals.
Vote Delegate V3
Section titled âVote Delegate V3âV3 Codebase: https://github.com/sky-ecosystem/vote-delegate/tree/v3/src
V2 Codebase: https://github.com/sky-ecosystem/vote-delegate/tree/v2/src
Functional Interface Changes
Section titled âFunctional Interface ChangesâThere have been NO changes to external user-facing function interfaces in the Vote Delegate contract upgrade.
External Considerations
Section titled âExternal ConsiderationsâHatch Trigger and Cooldown Removed
The hatch trigger and cooldown mechanisms have been removed from the Vote Delegate contract. As a result, you no longer need to check for previous Vote Delegate V2 restrictions related to hatch triggers or cooldown periods when determining if the lock() function is available for other users within the same Vote Delegate contract. Participants are no longer restricted by othersâ actions, as removing the hatch reserve and cooldown eliminates previous user interaction limitations.
IOU Tokens No Longer Held Vote Delegate no longer manages IOU token balances.
In version 3, the Chief contract has removed IOU tokens entirely, so neither governance participants nor Vote Delegate need to manage IOU tokens.
In version 2, IOU tokens were held within the Vote Delegate contract, removing the need for user approval, but they were still present.
In version 1, IOU tokens were returned to the userâs wallet, requiring MKR holders to approve the contract for their IOU balance before withdrawing.
Getter Function Change
The Chief contractâs GOV() function has been renamed to gov(). The function signature and its usage within Vote Delegate have changed accordingly. For backward compatibility, the GOV() getter remains available in the new Chief contract.
MKR-SKY Converter V2
Section titled âMKR-SKY Converter V2âV2 Codebase: https://github.com/sky-ecosystem/sky/blob/one-direction/src/MkrSky.sol
V1 Codebase: https://github.com/sky-ecosystem/sky/blob/3ddfa5ee55d10b8192f239235bf83e46744314b8/src/MkrSky.sol
Functional Interface Changes
Section titled âFunctional Interface ChangesâOnly the mkrToSky(uint256 mkrAmount) function from version 1 remains available in version 2. The skyToMkr(uint256 skyAmount) function and all related logic have been completely removed. The interface for mkrToSky is unchanged; however, the conversion rate is now affected by a governance-set fee parameter. Users can no longer convert SKY to MKR using this contract.
External Considerations
Section titled âExternal ConsiderationsâPre-minted SKY Token Balance
The Converter V2 contract no longer has permission to mint new SKY tokens. Instead, the full SKY token balance needed to convert all outstanding MKR is pre-minted and deposited into Converter V2. When an upgrade is executed, the SKY tokens held by Converter V2 are distributed to MKR holders.
Governance Control
Converter V2 introduces governance-controlled functionality. Previously, governance could not modify any settings in the contract. Now, governance can update the fee parameter, which determines the fee charged during MKR-to-SKY conversions. All fees collected are tracked in the take variable.
Governance can call the collect function to transfer the accumulated SKY fees from the Converter V2 contract to a designated address.
LockStake Engine (Seal Engine)
Section titled âLockStake Engine (Seal Engine)âV2 Codebase: https://github.com/sky-ecosystem/lockstake/blob/v2/src
V1 Codebase: https://github.com/sky-ecosystem/lockstake/tree/7c71318623f5d6732457fd0c247a1f1760960011/src
Functional Interface Changes
Section titled âFunctional Interface ChangesâThe following changes impact the external functional interface which integrations have to account for:
lock(uint256 amount)andfree(uint256 amount)now operate solely on SKY; thelockSky/freeSkymethods are removed.- Collateral renamed from MKR â SKY and the liquidâstaked wrapper from lsMKR â lsSKY (identical ABI, downstream compatibility).
- Added
migrate(address from, address to, uint256[] positionIds)in the newLockstakeMigratorcontract to move positions from V1 â V2 in one transaction.
External Considerations
Section titled âExternal ConsiderationsâConversion Logic Removed
All MkrSkyLike interfaces and MKRâSKY conversion calls are deleted. The engine now accepts raw SKY and mints/burns lsSKY directly, removing an external call and oracle dependency.
Fixed Exit Fee Exit fee is locked at deployment â governance cannot adjust it postâdeployment. Exit Fee will be set to 0 at deployment.
Migration Path
Users should invoke the LockstakeMigrator (flashâloanâassisted) to migrate V1 positions containing debt to V2.
Proxy / Storage Compatibility
No storageâlayout changes in LockstakeUrn; existing proxy clones remain valid.
Internal Changes
Section titled âInternal ChangesâAccounting Model Simplified Single mapping tracks SKY locks; separate MKR/SKY balances are removed.
LockstakeMigrator Module
Stateless contract enabling vault migration with or without USDS debt:
- Unlock old MKR, convert via external
mkrSky, relock as SKY. - If debt exists, take a USDS flashâloan, wipe debt, migrate collateral, then draw USDS to repay.
Manages approvals and relies on Sky Protocolâs flashâloan callback checks (initiator == self) for safety.
IOU Logic Removed No more IOU token minting/burning; deposits and withdrawals adjust only raw locked balances.
Released into the public domain (CC0Â 1.0 Universal) â trademarks remain with their owners; no warranty. See full license.