auction(dutch): credit VCB when ending an auction #4388
Labels
A-auction
Area: Relates to the auction component
C-bug
Category: a bug
consensus-breaking
breaking change to execution of on-chain data
_P-high
High priority
_P-V1
Priority: slated for V1 release
state-breaking
breaking change to on-chain data
Milestone
Issue
Auctions can be ended by the protocol and users. The component VCB is only credited when a closure is issued by the protocol. Instead, it should credit the component balance in both cases.
Context
The auction component maintains a value circuit breaker (VCB) accounting for a nonnegative
Balance
of assets deployed in the component.This mechanism serves two purposes: fault detection and isolation. The VCB detect value balance irregularities by systematically crediting/debiting the component as assets flows in and out of it. If its invariant is breached (negative balance) the component halts. Halting on a serious invariant breach insulates the rest of the system from excess value leaking into it. x-ref #4363
Remediation
To remediate this, we need a combination of:
Hotfix
The fix for this bug is simple: we need to credit the component with the value it pulls from the DEX engine.
Fix
We have a unit test that reproduces the exact failure conditions for this bug (omitted here) and memorialize context around it, similar to 53 halts.
Migration
The migration for this bug is difficult: we need to reconstruct an accurate tally of the component's balance.
The text was updated successfully, but these errors were encountered: