FA-84608 / Betting odds conversion / Member archive
Prices below the ladder minimum not rejected · case 03
A 1.00 request crashes the snapping loop or the 1.01 minimum is rejected.
Case contract
Snap a requested price onto an exchange tick ladder. Bands in hundredths [lo, hi, step]: [(101, 200, 1), (200, 300, 2), (300, 400, 5), (400, 600, 10), (600, 1000, 20), (1000, 2000, 50), (2000, 3000, 100), (3000, 5000, 200), (5000, 10000, 500), (10000, 100001, 1000)]. Prices outside 1.01..1000 return "invalid". A back request rounds down to a valid tick and a lay request rounds up (ticks counted from the band lower bound). Return the tick as "%d.%02d".
Why this case matters
Exchange order entry must snap arbitrary prices to valid ticks in the customer-safe direction.
One recorded failure
Sample boundary fixtureThis sample comes from the broken implementation of a controlled reproducer.
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| boundary below ladder | "raised UnboundLocalError" | "invalid" | Failed |
MEMBER ARCHIVE
The complete case is available to members.
This record includes three runnable implementations, regression fixtures, execution results, and source hashes.
Member access is invitation-based. Sign in with your invited account to inspect the sources.
Sign in to the archive ↗