No wrongnumber goes live
A Binance futures liquidation gauge that counts your other cross positions. An update goes live only if it reproduces Binance's own worked examples.
Same account, two answers
Binance's Example 2 is one cross wallet holding an ETH long and a BTC long. The BTC position's loss and margin eat into the shared balance, so the ETH long liquidates sooner. A tool that reads one position at a time misses it. Both numbers below are computed live by this build; the rate and maintenance amount stay at Example 2's values.
Read alone, the ETH long shows 38.48 USDT more room than the account has. Open it in the gauge
How an update goes live
First, someone proposes a change to the math.
The change: work out each position on its own. It gets a preview, a private copy of the site with the change in it.
The preview shows
1,114.78USDTTestSprite check: failed
Then TestSprite, an automated tester, tries Binance's example on the preview.
Open Binance's ETH example. Check that the liquidation price matches the number Binance publishes.
One number disagrees, so the check fails and the update is held back. The report names the example that failed and suggests a fix. The AI assistant writing the code never gets to see the answers.
Then the fix passes, and only then does the update go live.
The fix: count the other positions again.
The fixed preview shows
1,153.26USDTTestSprite check: passed
The same number Binance publishes for this account. Once live, every page shows which version you are using and whether it passed.
Kept out of the code’s reach:
Example 1’s margin, ETHUSDT’s liquidation price and margin and BTCUSDT’s liquidation price and margin.
Check it yourself
| What | Where | What you will see | Link |
|---|---|---|---|
| Binance’s FAQ | binance.com | Example 2’s numbers | Open |
| The ETH scenario | this gauge | the same inputs | Open |
| The caught mistake | GitHub | red, then green | Open |
| The golden suite | TestSprite | the expected values | Open |
| The source | GitHub | no expected prices | Open |
| This build’s check | Lydit | the commit’s result | Open |
Why Lydit
Lydit works out Binance's one-way liquidation formula with exact decimal math, never rounded floating point, so every figure is right to the cent before it is shown. It counts your other cross positions: their unrealized PnL and maintenance margin feed into the formula the way Binance's own engine uses them. Every input travels in the link, so a shared link reopens the exact scenario, and every result shows its working step by step.
The answers it is checked against are Binance's own worked examples, and they are kept out of the code entirely, in an outside test suite. An update can change the formula but never the answers, so a wrong number fails the check instead of quietly passing. Every page then shows which version is serving you and whether it passed. A number that does not match never goes live.