Skip to content

Kadia DEX: if something goes wrong

Kadia DEX has one way to stop new trading quickly and one slow, public way to change the market contracts. Your way out stays open the whole time.

Six keyholders hold the governance keys, and any 2 of the 6 can pause a market (on testnet today the box holds five keys, and any 2 of the 5 can). A pause stops new trades and new liquidity deposits, nothing else. It lasts at most about 30 days (21,600 blocks) and can be renewed, and the same keyholders can lift it early. The pause lives in a single governance box on chain, so anyone can see whether a market is paused and until when.

A pause can’t change any contract. A fix that needs new market code goes through an upgrade, which 4 of the 6 keyholders must sign (3 of the 5 keys on testnet today), and which must be announced 14 days (10,080 blocks) before it can happen. The announcement names the exact new contract (its hash), and the code is published, so you can read what is coming and leave before it arrives if you don’t like it. While an upgrade is announced, new liquidity deposits are paused; trading carries on.

The upgrade path has an end date: after block 2,550,000 (about two years from launch) no upgrade is possible at all, and the keyholders can give the path up for good before that.

  • Cancelling your order with your own key.
  • Refunds of orders that expire unfilled: anyone can send your funds back to you.
  • Withdrawing your liquidity (an LP redeem).

None of these ask the governance box, so no pause, announcement or wind-down can block them. If an upgrade happens, orders made for the old contract can’t be filled any more, but you can still cancel them or wait for the refund. A firm vault still waits for the lock time its maker chose.

The keyholders can also wind a market down, which stops trades and deposits for good. It takes the same signatures as an upgrade: 4 of the 6 (3 of 5 on testnet today). Your exits above still work after it.

The rules are in the contracts and the governance specification; the assumptions page says what you are trusting.

Technical details

Source: kadia-dex docs/guide/if-something-goes-wrong.md at commit 5aa1725 (5aa1725fe82346b8181c20d50f5d75a481b58829).