fix(indexer): widen trader rolling volume to NUMERIC(38, 0) (#1277) #1292
No reviewers
Labels
No labels
agent:fix_bugfix
agent:fix_conflicts
agent:fix_security
agent:gap_analysis
agent:implement
agent:implement
agent:implement
agent:open_issues
agent:ready
agent:research
agent:security_audit
agent:verify
architecture
backend
blocker:hybrid
blocker:launch
blocker:limit-orders
blocker:v2
block:log_only
block:security
bug
ci
contracts
correctness
deploy
dev
devops
docs
documentation
duplicate
e2e
enhancement
epic
feature
frontend
functional-completion
gas
good first issue
governance
help wanted
high-risk
hooks
hybrid
indexer
infra
infrastructure
integrators
invalid
launch-blocker
limit-orders
localnet
localterra
low priority
missing-implementation
needs-design
ops
performance
priority
high
priority
medium
product
qa
QA
question
ready
ready
research
scripts
security
security-hardening
smartcontracts
tech-debt
testing
ux
UX
v2
verification
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
code/cl8y-dex-terraclassic!1292
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "fix/1277-trader-rolling-numeric"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
traders.volume_24h/volume_7d/volume_30d/total_volumetoNUMERIC(38, 0)so 18-decSUM(offer_amount)no longer overflows the rolling UPDATE (Failed to refresh rolling trader volumes).upsert_traderlifetime raw volume at10^38-1. Keeptotal_volume_usdasNUMERIC(38, 18)with the existing10^20USD cap.bd_plain_string. Addmake verify-issue-1277, invariants R1277-1–R1277-8, and skillAGENTS_INDEXER_TRADER_ROLLING_NUMERIC.md.Fixes #1277
Test plan
make verify-issue-1277(passed, then retested)dex_indexer_test_1277migrate +indexer_trader_rolling_numeric(I1–I9 / A1)#577indexer_volume_window_decaystill green#548volume_usd_catalog+api_tradersIssue criteria
10^21offer:refresh_rolling_volumesOk;volume_24hstores the integer; JSON plain decimalupsert_trader10^21succeeds; A1 caps10^38at10^38-1total_volume_usdstays(38, 18); huge raw refresh does not smash USDmake verify-issue-1277refresh_all_volume_windowsstill runs pair/global with the I1 fixtureOut of scope (unchanged)
SUM(offer_amount)(A9 / #666)(78, 18)(#676)drain skip: no occupying job for rebase/fix-pr/CI-wait; remaining continue
cl8y-agent-control: queued
implementjob42b356df-b7a5-41fe-8bfb-e621be5bb0ab(not executed; no Hetzner VM).