Indexer: Volume calculation uses offer_amount only — needs USD denomination via USTC wrapper #35
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#35
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
Ref: QA item 20.8\n\nCurrent: Global volume stats sum offer_amount raw values only. There is no USD-denominated volume because there is no price oracle or USTC reference pair.\n\nRequired:\nOnce the wrap/unwrap system is live with USTC-C pairs on the DEX, volume can be denominated in USD by:\n1. Creating USTC-C pairs (e.g. EMBER/USTC-C) so the indexer has a USD price reference\n2. Updating the volume aggregation to convert amounts to USD equivalent using USTC-C pair prices\n3. May also need an oracle connection for accurate USD pricing\n\nBlocked by: Wrap/unwrap router integration (#28). Once router supports native denom swaps, USTC-C pairs can be created and used as the USD price feed.\n\nNote from dev: We need USD which will be available once we have wrapper for USTC, will also need a test USTC in the infra + oracle connection. Waiting on wrap/unwrap system first.
mentioned in commit
fdfbe43993@Brouie — USD denomination is implemented and pushed in
fdfbe43. Please review when you get a chance.What's in:
ustc_pricestable +volume_usdonswap_eventsandtoken_volume_statstotal_volume_24h_usd,ustc_price_usd), pair stats, token stats, and CG tickers (liquidity_in_usd)GET /api/v1/oracle/priceandGET /api/v1/oracle/historyBug fixes included:
SwapEventRowwas missingvolume_usdfield — would have crashed allSELECT *trade queries at runtimeGovernorLayerrate limiter was breaking the entire test suite (Unable To Extract Key)Known limitations (for follow-up):
volume_usd = None— transitive pricing not yet implementedasset.decimalsif wrapped CW20 has different precisionmentioned in issue #28