fix: normalize limit price band for UST1/USTR (#529) #1060

Merged
PlasticDigits merged 2 commits from feat/529-limit-price-decimals-normalized into main 2026-08-16 08:45:28 +00:00
PlasticDigits commented 2026-08-16 07:32:50 +00:00 (Migrated from gitlab.com)

Summary

  • Apply [MIN_LIMIT_PRICE, MAX_LIMIT_PRICE] to the human-scale limit price raw × 10^(decimals0 − decimals1) so 6-vs-18 pairs (UST1/USTR ~79 human, raw ~7.9e13) can place and update limits.
  • Execution still stores raw token1-units/token0-units. #467 dust rejection on like-decimal pairs and match-time overflow skip are unchanged.
  • dApp converts human↔raw at the chain edge (limitOrderPriceScale.ts) so /trade and /limits submit and display stay human.

Closes #529.

Test plan

  • make verify-issue-529
  • make verify-issue-467 (no regression)
  • LocalTerra: place a UST1/USTR limit at ~79 human after pair migrate
  • Confirm book / my placements show human 79, not 7.9e13
  • Confirm reverse orientation (USTR/UST1) places at ~0.0127 human
## Summary - Apply `[MIN_LIMIT_PRICE, MAX_LIMIT_PRICE]` to the **human-scale** limit price `raw × 10^(decimals0 − decimals1)` so 6-vs-18 pairs (UST1/USTR ~79 human, raw ~7.9e13) can place and update limits. - Execution still stores **raw** token1-units/token0-units. #467 dust rejection on like-decimal pairs and match-time overflow skip are unchanged. - dApp converts human↔raw at the chain edge (`limitOrderPriceScale.ts`) so `/trade` and `/limits` submit and display stay human. Closes #529. ## Test plan - [x] `make verify-issue-529` - [x] `make verify-issue-467` (no regression) - [ ] LocalTerra: place a UST1/USTR limit at ~79 human after pair migrate - [ ] Confirm book / my placements show human 79, not `7.9e13` - [ ] Confirm reverse orientation (USTR/UST1) places at ~0.0127 human
PlasticDigits commented 2026-08-16 08:43:17 +00:00 (Migrated from gitlab.com)

mentioned in issue #532

mentioned in issue #532
PlasticDigits commented 2026-08-16 08:43:22 +00:00 (Migrated from gitlab.com)

mentioned in issue #529

mentioned in issue #529
PlasticDigits commented 2026-08-16 08:45:17 +00:00 (Migrated from gitlab.com)

added 3 commits

  • 91d90ddb...dac47e80 - 2 commits from branch main
  • c03dbdf1 - merge: resolve Makefile after #531 on main

Compare with previous version

added 3 commits <ul><li>91d90ddb...dac47e80 - 2 commits from branch <code>main</code></li><li>c03dbdf1 - merge: resolve Makefile after #531 on main</li></ul> [Compare with previous version](/PlasticDigits/cl8y-dex-terraclassic/-/merge_requests/342/diffs?diff_id=1964221955&start_sha=91d90ddba401db8de8ebad59f41479c2ba3def6c)
PlasticDigits commented 2026-08-16 08:45:29 +00:00 (Migrated from gitlab.com)

mentioned in commit f77caabb5c

mentioned in commit f77caabb5c91d1041076190bc2767d416caabf75
PlasticDigits (Migrated from gitlab.com) merged commit f77caabb5c into main 2026-08-16 08:45:29 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
code/cl8y-dex-terraclassic!1060
No description provided.