fix(charts): blank price chart for ALPHA pairs #1320
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!1320
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "issue/1315"
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?
Fixes #1315
Summary
UST1/ALPHA and CL8Y/ALPHA price candles now have a subject. Factory
open/high/low/closestay USD of 1 humanasset_0. Whenusd_leg=asset_1, GET/api/v1/pairs/{addr}/candlesomits those four fields and sends the subject OHLC onsubject_open/high/low/close, so a cached client drops the bar instead of plotting USD ofasset_1as USD ofasset_0. Neither-catalog rows stay human-only (*_human, no USD label).swap_events.price_usdis unchanged. There is no ALPHA or CL8Y peg./chartsdefaults both the price pane and the pill toasset_1whenusd_leg=asset_1and there is no?price=or Charts session flag.defaultChartsDisplayInverted()stays false for every other pair. 24h OHLC, TWAP, and tape Price stay on swapprice_usd.Boot gap-fill writes candles only for pairs that have a positive swap price and zero candle rows. The done marker is set only when the failure count is 0, so the next boot retries pairs that still have zero rows.
down.sqldeletes stamped gap-fill keys, everyusd_leg = 'asset_1'row, and every row with NULLopen, then dropscandles.usd_legand the stamp objects.ADR 0012 stays Proposed.
Acceptance
*_humanis present.Validation
cargo test --lib candle_subject— 5 passedcargo test --lib project_tests— 3 passedcargo test --lib gap_fill— 2 passedtsc -p frontend-dapp/tsconfig.app.json --noEmit— passedpriceChartCandles.test.ts,tradePairDisplayOrientation.test.ts,PriceChart.test.tsx— passed (including the human-only fixture and theusd_leg=asset_1default)make verify-issue-1315is the gate (those lib filters plus the three Vitest files). It was not run as one Make target on this VM becausescripts/with-node.shneeds nvm; the same cargo filters and Vitest files were run directly.Gaps
candle_usd_mark,candle_human_usd,candle_skip_zero_price) compiled and were not executed (no Postgres on this run).usd_leg=asset_1until they load the new bundle. That is the wire contract.drain skip: no occupying job for rebase/fix-pr/CI-wait; remaining continue
Re-checked head
issue/1315ated3b9705. No further commit.Validation on this checkout:
cargo test --lib candle_subject— 5 passedcargo test --lib project_tests— 3 passedcargo test --lib gap_fill— 2 passedpriceChartCandles.test.ts,PriceChart.test.tsx,tradePairDisplayOrientation.test.ts— 90 passedmake verify-issue-1315still invokesscripts/with-node.shfor the Vitest step. That helper fails on this VM because nvm is not installed. The same three files passed with Node 24.11 directly.Acceptance and the design revisions are already on this PR: classic OHLC stays USD of
asset_0and is omitted whenusd_leg=asset_1(subject_*on the wire),down.sqldeletes stamped keys plususd_leg=asset_1and NULLopen, the gap-fill done marker is set only when the failure count is 0, and/chartsdefaults both the pane and the pill toasset_1when there is no?price=and no Charts session flag.drain skip: default autoland requires tip ACCEPT (#77)