Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/deepbook-mainnet-liquidation-upgraded.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@mysten/deepbook-v3': patch
---

Bump mainnet `LIQUIDATION_PACKAGE_ID` to the `margin_liquidation` publication carrying the upgraded-Pyth entrypoints: `0xf17bff1b…` → `0xba2b39c026650fef52038c93c526fc5314a4286318a0d2a7054b65815178fb74`. This is what gives `liquidateBase` and `liquidateQuote` a mainnet target: they call `liquidation_vault::liquidate_base_upgraded` / `liquidate_quote_upgraded`, which the previous mainnet publication (v4, `0xf17bff1b…`) did not carry. Every other vault builder takes no oracle and is unaffected. The upgrade is live on chain as v5 and keeps the lineage — the new package's `LIQUIDATION_VAULT` type is still defined by the original `0x73c59388…`, so the deployed vault needs no migration.
8 changes: 1 addition & 7 deletions packages/deepbook-v3/src/utils/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,7 @@ export const mainnetPackageIds = {
MARGIN_PACKAGE_ID: '0x55ee8099674e46266df2bf0ffed9569e1511aa269f2a9b8c63a2c72f16404e72',
MARGIN_V1: '0x97d9473771b01f77b0940c589484184b49f6444627ec121314fae6a6d36fb86b',
MARGIN_REGISTRY_ID: '0x0e40998b359a9ccbab22a98ed21bd4346abf19158bc7980c8291908086b3a742',
// margin_liquidation v4 — the latest mainnet publication, and it predates the upgraded
// entrypoints: its `liquidation_vault` exposes only `liquidate_base`/`liquidate_quote`.
// `MarginLiquidationsContract` targets the `_upgraded` pair, so those two builders have
// no mainnet target until `margin_liquidation` is upgraded there. Every other vault
// entrypoint (deposit, withdraw, balance, swaps, trader authorization) takes no oracle
// and works against this id today.
LIQUIDATION_PACKAGE_ID: '0xf17bff1bf21e9587acc5708714e520aa967f82f256f626938a33c4109b08adb9',
LIQUIDATION_PACKAGE_ID: '0xba2b39c026650fef52038c93c526fc5314a4286318a0d2a7054b65815178fb74',
} satisfies DeepbookPackageIds;

/**
Expand Down
Loading