post-merge: deploy !362–!366 and wire portfolio P&L USD to hub prices #560

Closed
opened 2026-08-18 03:12:08 +00:00 by PlasticDigits · 28 comments
PlasticDigits commented 2026-08-18 03:12:08 +00:00 (Migrated from gitlab.com)

Why

!1080–!1084 are on main (Android Chrome connect, trader volume USD, portfolio P&L scale, DEX hub USD, zap floors). CI was not green (ci_quota_exceeded). Several issue AC items are manual/ops, and one code gap appeared only after stacking #551 on #556.

Code follow-up (blocking for honest USD P&L)

After !1083, indexer Charts/Trade price_usd and volume_usd use hub_prices (USTR is market-priced, not 2.5 × USTC). /portfolio and /trader/:addr Total realized P&L still convert human base via frontend quoteTokenUsd in traderPositionDisplay.ts:

  • UST1 = $1
  • USTR = 2.5 × USTC

That disagrees with H1–H3. Per-pair human token amounts from #551 are fine. Header USD should read GET /api/v1/hub-prices (same source as Protocol DEX card), omit unpriced hubs (not $0), and keep CEX /oracle/price/ustr as 400.

Out of scope here: tape Amount in/out/Price (#557).

Deploy / migrate

  1. Coolify frontend rebuild (npm ci so !1080 cosmes patch applies).
  2. Indexer migrate + restart:
    • 20260818140000_traders_total_volume_usd.sql (#553)
    • 20260818180000_hub_prices.sql (#556)
  3. Confirm ingest: GET /api/v1/hub-prices, overview additive hub fields, trader total_volume_usd.

Manual AC still open on closed issues

Issue Check
#554 Android 16 Chrome: Lunc Dash / Galaxy Station / Keplr WC; cancel/timeout; desktop Keplr; in-app Keplr
#553 dex.cl8y.com/charts Volume (USD) is not 10,000,000T
#551 Mixed-decimal /portfolio rows human + labeled; header not unitless 38.29M
#556 /protocol DEX hub card shows USTR; /oracle/price/ustr still 400
#559 UST1/cUSTC one-sided Add at 5% slippage does not Cannot Sub at msg index 3

Verify (after deploy)

  • make verify-issue-554 553 551 556 559 (local)
  • Production smoke as in the table
## Why !1080–!1084 are on `main` (Android Chrome connect, trader volume USD, portfolio P&L scale, DEX hub USD, zap floors). CI was not green (`ci_quota_exceeded`). Several issue AC items are **manual/ops**, and one **code gap** appeared only after stacking #551 on #556. ## Code follow-up (blocking for honest USD P&L) After !1083, indexer Charts/Trade `price_usd` and `volume_usd` use **hub_prices** (USTR is market-priced, not `2.5 ×` USTC). `/portfolio` and `/trader/:addr` **Total realized P&L** still convert human base via frontend `quoteTokenUsd` in [`traderPositionDisplay.ts`](frontend-dapp/src/utils/traderPositionDisplay.ts): - UST1 = `$1` - USTR = `2.5 ×` USTC That disagrees with H1–H3. Per-pair human token amounts from #551 are fine. Header USD should read `GET /api/v1/hub-prices` (same source as Protocol DEX card), omit unpriced hubs (not `$0`), and keep CEX `/oracle/price/ustr` as 400. Out of scope here: tape Amount in/out/Price ([#557](https://gitlab.com/PlasticDigits/cl8y-dex-terraclassic/-/issues/557)). ## Deploy / migrate 1. Coolify frontend rebuild (`npm ci` so !1080 cosmes patch applies). 2. Indexer migrate + restart: - `20260818140000_traders_total_volume_usd.sql` (#553) - `20260818180000_hub_prices.sql` (#556) 3. Confirm ingest: `GET /api/v1/hub-prices`, overview additive hub fields, trader `total_volume_usd`. ## Manual AC still open on closed issues | Issue | Check | |-------|--------| | #554 | Android 16 Chrome: Lunc Dash / Galaxy Station / Keplr WC; cancel/timeout; desktop Keplr; in-app Keplr | | #553 | `dex.cl8y.com/charts` Volume (USD) is not `10,000,000T` | | #551 | Mixed-decimal `/portfolio` rows human + labeled; header not unitless `38.29M` | | #556 | `/protocol` DEX hub card shows USTR; `/oracle/price/ustr` still 400 | | #559 | UST1/cUSTC one-sided Add at 5% slippage does not `Cannot Sub` at msg index 3 | ## Verify (after deploy) - `make verify-issue-554` `553` `551` `556` `559` (local) - Production smoke as in the table
PlasticDigits commented 2026-08-18 03:12:08 +00:00 (Migrated from gitlab.com)

marked as related to #551

marked as related to #551
PlasticDigits commented 2026-08-18 03:12:09 +00:00 (Migrated from gitlab.com)

marked as related to #553

marked as related to #553
PlasticDigits commented 2026-08-18 03:12:09 +00:00 (Migrated from gitlab.com)

marked as related to #554

marked as related to #554
PlasticDigits commented 2026-08-18 03:12:10 +00:00 (Migrated from gitlab.com)

marked as related to #556

marked as related to #556
PlasticDigits commented 2026-08-18 03:12:10 +00:00 (Migrated from gitlab.com)

marked as related to #559

marked as related to #559
PlasticDigits commented 2026-08-18 03:12:11 +00:00 (Migrated from gitlab.com)

marked as related to #557

marked as related to #557
PlasticDigits commented 2026-08-18 03:12:51 +00:00 (Migrated from gitlab.com)

mentioned in issue #554

mentioned in issue #554
PlasticDigits commented 2026-08-18 03:12:52 +00:00 (Migrated from gitlab.com)

mentioned in issue #553

mentioned in issue #553
PlasticDigits commented 2026-08-18 03:12:53 +00:00 (Migrated from gitlab.com)

mentioned in issue #551

mentioned in issue #551
PlasticDigits commented 2026-08-18 03:12:54 +00:00 (Migrated from gitlab.com)

mentioned in issue #556

mentioned in issue #556
PlasticDigits commented 2026-08-18 03:12:56 +00:00 (Migrated from gitlab.com)

mentioned in issue #559

mentioned in issue #559
PlasticDigits commented 2026-08-18 03:14:38 +00:00 (Migrated from gitlab.com)

Review extras to include in this issue (beyond hub P&L + deploy):

  • #551 Best/Worst header shows N/A not — (PnlValue). Align to P551-5.
  • #551 Positions with a missing asset row are dropped from the API instead of rendered as —.
  • #553 After hub migrate, re-run backfill_swap_volume_usd so trader lifetime USD includes hub-priced legs.
  • #556 Set HUB_*_ADDRESS in prod/LocalTerra indexer env. Fix stale /protocol one-liner in docs/frontend.md (hub card omitted).
  • #559 Optional: P9 e2e that actually forces a worse-than-quote fill; manual UST1/cUSTC Add is still required.
  • #554 No extra code defects; device QA + Coolify as already listed.
Review extras to include in this issue (beyond hub P&L + deploy): - **#551** Best/Worst header shows `N/A` not `—` (`PnlValue`). Align to P551-5. - **#551** Positions with a missing asset row are dropped from the API instead of rendered as `—`. - **#553** After hub migrate, re-run `backfill_swap_volume_usd` so trader lifetime USD includes hub-priced legs. - **#556** Set `HUB_*_ADDRESS` in prod/LocalTerra indexer env. Fix stale `/protocol` one-liner in `docs/frontend.md` (hub card omitted). - **#559** Optional: P9 e2e that actually forces a worse-than-quote fill; manual UST1/cUSTC Add is still required. - **#554** No extra code defects; device QA + Coolify as already listed.
PlasticDigits commented 2026-08-18 05:16:42 +00:00 (Migrated from gitlab.com)

Production smoke after indexer + frontend redeploy

Checked https://indexer.dex.cl8y.com and https://dex.cl8y.com (Playwright Chromium, 5 parallel page loads). Local make verify-issue-* was not re-run.

Indexer ingest

Check Result
GET /api/v1/hub-prices 200. Tickers custc / ust1 / ustr. Metadata says DEX marks, not CEX. CORS Access-Control-Allow-Origin: https://dex.cl8y.com.
GET /api/v1/hub-prices/{custc,ust1,ustr} 200
GET /api/v1/oracle/price/ustr (and ust1) 400 — Supported: ustc, lunc, vfdusd
Overview additive hub fields Present: custc_price_usd, ust1_price_usd, ustr_price_usd plus ustc_price_usd
GET /api/v1/traders/leaderboard?sort=total_volume_usd 200. total_volume_usd populated (null only for unpriced activity).
HUB_*_ADDRESS Effectively set — UST1/USTR have source_pair + tvl_usd (not a null/empty snapshot).

Snapshot around this check (USD marks, not settlement):

  • cUSTC ≈ $0.00473 (tracks USTC CEX)
  • UST1 ≈ $0.976 (deepest UST1/cUSTC pool terra1cepr…cw55f, TVL ~$5.8k) — not $1
  • USTR ≈ $0.00879 (UST1/USTR terra16vxr…5hgqy, TVL $5.1k) — not 2.5 × USTC ($0.0118)

Overview USD: 24h ~$1.12k, 7d/30d ~$1.72k. Mixed-unit total_volume_24h remains API-only.

Trader lifetime USD looks backfilled enough to be usable (top total_volume_usd ~$1.23k / 1172 trades; USTR-heavy wallets show ~$167 / $113 rather than raw 18-dec sums). One idle/unpriced row correctly returns JSON null.

Manual AC table

Issue Result Evidence
#554 Not run (no Android 16 / in-app Keplr / WC cancel-timeout on this host). Deployed bundle still contains Lunc Dash, Galaxy Station, WalletConnect. Desktop Chrome connect + WC device QA still needed.
#553 Pass on Charts Volume (USD). /charts Volume tab sorted by USD: $1.226K, $166.7, $113.0, $96.55, … unpriced —. No 10,000,000T in that column.
#551 Pass on per-row human + labeled; header is USD not unitless 38.29M. Public trader terra12z8v…sdtjj3: net/cost/PnL labeled (+38.29 UST1, 9.869 CORAL, 20.00 UST1). Mixed 6/18-dec terra1hu4z…q5k2lv: 9.297 USTR not a T-compact raw. Header Total Volume (USD) $96.55 / $166.7. /portfolio needs a connected wallet (same TraderSummaryStats).
#556 Pass /protocol DEX hub prices card shows cUSTC / UST1 / USTR with $ marks and source-pair rows. CEX tabs are USTC / LUNC / vFDUSD only (no USTR tab). /oracle/price/ustr still 400.
#559 UI deployed; live Add not executed /pool one-sided Add / Withdraw cards render (pool-one-sided-add, submit gated on Connect wallet). No funded columbus-5 wallet here, so UST1/cUSTC 5% Add → Cannot Sub at msg index 3 was not re-tried on-chain.

Tape Amount in/out still prints 10,000,000T / 9,297,048T on USTR legs (example: USTR → UST1 on terra1hu4z…). That is #557, out of scope here. Charts Volume (USD) is the #553 surface and is fine.

Code follow-up still open (hub P&L)

Header Total realized P&L is USD, but it still uses frontend quoteTokenUsd (UST1 = $1, USTR = 2.5 × USTC), not GET /api/v1/hub-prices.

Live: terra12z8v… priced rows are +38.29 UST1 → header +$38 (“Priced pairs only”). Hub UST1 ~$0.976 would be ~$37. EMBER/CORAL omitted (unpriced), not $0.

Also still true vs extras on this issue:

  • Best / Worst header still N/A (PnlValue null), not — (P551-5).
  • Fees correctly —.

Residual QA

  1. Wire /portfolio + /trader realized P&L USD to hub prices (omit unpriced hubs; keep CEX /oracle/price/ustr as 400).
  2. Align Best/Worst to —.
  3. #554 device matrix (Android 16 Chrome WC + desktop Keplr).
  4. #559: one live UST1/cUSTC one-sided Add at 5% slippage on columbus-5.
## Production smoke after indexer + frontend redeploy Checked `https://indexer.dex.cl8y.com` and `https://dex.cl8y.com` (Playwright Chromium, 5 parallel page loads). Local `make verify-issue-*` was **not** re-run. ### Indexer ingest | Check | Result | |-------|--------| | `GET /api/v1/hub-prices` | **200**. Tickers `custc` / `ust1` / `ustr`. Metadata says DEX marks, not CEX. CORS `Access-Control-Allow-Origin: https://dex.cl8y.com`. | | `GET /api/v1/hub-prices/{custc,ust1,ustr}` | **200** | | `GET /api/v1/oracle/price/ustr` (and `ust1`) | **400** — `Supported: ustc, lunc, vfdusd` | | Overview additive hub fields | Present: `custc_price_usd`, `ust1_price_usd`, `ustr_price_usd` plus `ustc_price_usd` | | `GET /api/v1/traders/leaderboard?sort=total_volume_usd` | **200**. `total_volume_usd` populated (null only for unpriced activity). | | `HUB_*_ADDRESS` | Effectively set — UST1/USTR have `source_pair` + `tvl_usd` (not a null/empty snapshot). | Snapshot around this check (USD marks, not settlement): - cUSTC ≈ **$0.00473** (tracks USTC CEX) - UST1 ≈ **$0.976** (deepest UST1/cUSTC pool `terra1cepr…cw55f`, TVL ~$5.8k) — **not $1** - USTR ≈ **$0.00879** (UST1/USTR `terra16vxr…5hgqy`, TVL ~$5.1k) — **not** `2.5 ×` USTC (~$0.0118) Overview USD: 24h **~$1.12k**, 7d/30d **~$1.72k**. Mixed-unit `total_volume_24h` remains API-only. Trader lifetime USD looks backfilled enough to be usable (top `total_volume_usd` ~$1.23k / 1172 trades; USTR-heavy wallets show ~$167 / $113 rather than raw 18-dec sums). One idle/unpriced row correctly returns JSON `null`. ### Manual AC table | Issue | Result | Evidence | |-------|--------|----------| | **#554** | **Not run** (no Android 16 / in-app Keplr / WC cancel-timeout on this host). | Deployed bundle still contains **Lunc Dash**, **Galaxy Station**, **WalletConnect**. Desktop Chrome connect + WC device QA still needed. | | **#553** | **Pass** on Charts Volume (USD). | `/charts` Volume tab sorted by USD: `$1.226K`, `$166.7`, `$113.0`, `$96.55`, … unpriced `—`. **No** `10,000,000T` in that column. | | **#551** | **Pass** on per-row human + labeled; header is USD not unitless `38.29M`. | Public trader [`terra12z8v…sdtjj3`](https://dex.cl8y.com/trader/terra12z8vz3vgnalt8trykd6nntdyp54e95yqsdtjj3): net/cost/PnL labeled (`+38.29 UST1`, `9.869 CORAL`, `20.00 UST1`). Mixed 6/18-dec [`terra1hu4z…q5k2lv`](https://dex.cl8y.com/trader/terra1hu4zggf3f8yw6jw3rxrjxn2drwad675gq5k2lv): `9.297 USTR` not a T-compact raw. Header **Total Volume (USD)** `$96.55` / `$166.7`. `/portfolio` needs a connected wallet (same `TraderSummaryStats`). | | **#556** | **Pass** | `/protocol` **DEX hub prices** card shows cUSTC / UST1 / USTR with `$` marks and source-pair rows. CEX tabs are **USTC / LUNC / vFDUSD** only (no USTR tab). `/oracle/price/ustr` still 400. | | **#559** | **UI deployed; live Add not executed** | `/pool` one-sided **Add** / **Withdraw** cards render (`pool-one-sided-add`, submit gated on Connect wallet). No funded columbus-5 wallet here, so UST1/cUSTC 5% Add → `Cannot Sub` at msg index 3 was **not** re-tried on-chain. | Tape Amount in/out still prints **`10,000,000T`** / **`9,297,048T`** on USTR legs (example: `USTR → UST1` on `terra1hu4z…`). That is **#557**, out of scope here. Charts Volume (USD) is the #553 surface and is fine. ### Code follow-up still open (hub P&L) Header **Total realized P&L** is USD, but it still uses frontend `quoteTokenUsd` (**UST1 = $1**, **USTR = 2.5 × USTC**), not `GET /api/v1/hub-prices`. Live: `terra12z8v…` priced rows are **+38.29 UST1** → header **`+$38`** (“Priced pairs only”). Hub UST1 ~$0.976 would be ~**$37**. EMBER/CORAL omitted (unpriced), not `$0`. Also still true vs extras on this issue: - Best / Worst header still **`N/A`** (`PnlValue` null), not **—** (P551-5). - Fees correctly **—**. ### Residual QA 1. Wire `/portfolio` + `/trader` realized P&L USD to hub prices (omit unpriced hubs; keep CEX `/oracle/price/ustr` as 400). 2. Align Best/Worst to **—**. 3. #554 device matrix (Android 16 Chrome WC + desktop Keplr). 4. #559: one live UST1/cUSTC one-sided Add at 5% slippage on columbus-5.
PlasticDigits commented 2026-08-19 01:06:07 +00:00 (Migrated from gitlab.com)

mentioned in merge request !1090

mentioned in merge request !1090
PlasticDigits commented 2026-08-19 01:06:29 +00:00 (Migrated from gitlab.com)

Code follow-up implemented in !1090 (fix/560-hub-pnl-usd).

Done (code)

  • Wire /portfolio + /trader realized P&L USD to GET /api/v1/hub-prices (never $1 / 2.5×; unpriced omitted; CEX /oracle/price/ustr unused)
  • Align Best/Worst to — (PnlValue), not N/A
  • Keep positions with a missing asset row (null decimals / — symbols) instead of dropping them
  • Invariants P560-1–P560-6, skill skills/AGENTS_FRONTEND_HUB_PNL.md, make verify-issue-560 (5/5, retested)

Not done (ops / device / out of scope)

  • Coolify frontend rebuild (npm ci) so production picks this up
  • Indexer migrate + HUB_*_ADDRESS already confirmed in an earlier production smoke note
  • Re-run backfill_swap_volume_usd after hub migrate (#553 extra)
  • #554 Android 16 Chrome WC / desktop Keplr / in-app Keplr matrix
  • #559 live UST1/cUSTC one-sided Add at 5% on columbus-5
  • Optional P9 e2e worse-than-quote fill
  • Tape Amount in/out/Price (10,000,000T) remains #557
Code follow-up implemented in !1090 (`fix/560-hub-pnl-usd`). **Done (code)** - [x] Wire `/portfolio` + `/trader` realized P&L USD to `GET /api/v1/hub-prices` (never `$1` / `2.5×`; unpriced omitted; CEX `/oracle/price/ustr` unused) - [x] Align Best/Worst to **—** (`PnlValue`), not `N/A` - [x] Keep positions with a missing asset row (null decimals / **—** symbols) instead of dropping them - [x] Invariants **P560-1–P560-6**, skill `skills/AGENTS_FRONTEND_HUB_PNL.md`, `make verify-issue-560` (5/5, retested) **Not done (ops / device / out of scope)** - [ ] Coolify frontend rebuild (`npm ci`) so production picks this up - [ ] Indexer migrate + `HUB_*_ADDRESS` already confirmed in an earlier production smoke note - [ ] Re-run `backfill_swap_volume_usd` after hub migrate (#553 extra) - [ ] #554 Android 16 Chrome WC / desktop Keplr / in-app Keplr matrix - [ ] #559 live UST1/cUSTC one-sided Add at 5% on columbus-5 - [ ] Optional P9 e2e worse-than-quote fill - [ ] Tape Amount in/out/Price (`10,000,000T`) remains #557
PlasticDigits commented 2026-08-19 02:16:41 +00:00 (Migrated from gitlab.com)

Post-merge note (!1090 on main). Code follow-up P560-1–P560-6 is merged (hub-priced header P&L, Best/Worst —, missing asset rows kept). This issue stays open for ops.

Still required:

  • Coolify frontend rebuild (npm ci) so production header uses hub UST1 (~$0.976), not $1.
  • Indexer migrate/restart if hub_prices / total_volume_usd migrations are not live.
  • Production smoke: public trader with UST1 P&L (e.g. terra12z8v…) — header USD ≈ hub UST1 × human P&L.
  • Manual AC still open on #554 / #553 / #551 / #556 / #559 as listed in the issue body.
**Post-merge note (!1090 on main).** Code follow-up P560-1–P560-6 is merged (hub-priced header P&L, Best/Worst **—**, missing asset rows kept). This issue stays **open** for ops. Still required: - Coolify frontend rebuild (`npm ci`) so production header uses hub UST1 (~$0.976), not `$1`. - Indexer migrate/restart if `hub_prices` / `total_volume_usd` migrations are not live. - Production smoke: public trader with UST1 P&L (e.g. `terra12z8v…`) — header USD ≈ hub UST1 × human P&L. - Manual AC still open on #554 / #553 / #551 / #556 / #559 as listed in the issue body.
PlasticDigits commented 2026-08-19 02:28:46 +00:00 (Migrated from gitlab.com)

mentioned in issue #573

mentioned in issue #573
PlasticDigits commented 2026-08-19 02:28:46 +00:00 (Migrated from gitlab.com)

marked as related to #573

marked as related to #573
PlasticDigits commented 2026-08-19 02:28:49 +00:00 (Migrated from gitlab.com)

Sanity after stack: frontend hub P&L tests PASS. Indexer cargo rungs FAIL on this agent VM (root-owned indexer/target lock files). Same chown as #557. Ops items in the issue body are unchanged.

**Sanity after stack:** frontend hub P&L tests **PASS**. Indexer cargo rungs **FAIL** on this agent VM (root-owned `indexer/target` lock files). Same chown as #557. Ops items in the issue body are unchanged.
PlasticDigits commented 2026-08-20 01:18:32 +00:00 (Migrated from gitlab.com)

mentioned in commit f2b2929f37

mentioned in commit f2b2929f371dd7daa22193648c3d1a6eaafde0f4
PlasticDigits commented 2026-08-20 01:19:21 +00:00 (Migrated from gitlab.com)

Verification (worktree verify/560-hub-pnl → main @ f2b2929f)

Re-ran P560 in a git worktree from origin/main. Code path from !1090 is already on main; this pass added skill/docs crosslinks so volume/oracle agents do not reintroduce $1 / 2.5× header P&L.

Local make verify-issue-560

Step Result
Docs + skill + AGENTS crosslinks (P560-6) PASS
Source: no quoteTokenUsd pegs; CEX ustr unused (P560-1 / P560-3) PASS
Indexer lib: missing-asset mapper keeps rows (P560-5) PASS
Indexer integration: positions still expose decimals PASS
Frontend hub P&L + summary + positions + portfolio (P560-2 / P560-4) PASS (35 tests)

Postgres-only infra (make setup-indexer-postgres). First docs grep failed because of a single-quoted grep -E inside bash -c; fixed and re-ran — 5/5.

Production smoke (dex.cl8y.com / indexer.dex.cl8y.com) 2026-08-20

Coolify frontend rebuild is live (bundle includes useProtocolHubPricesQuery + traderUsdMarksFromHub; HTML last-modified 2026-08-19 12:06 UTC).

Check Result
GET /api/v1/hub-prices 200 — custc / ust1 / ustr. UST1 ≈ $0.981 (not $1). USTR market-priced (not 2.5×).
GET /api/v1/oracle/price/ustr and /ust1 400 — Supported: ustc, lunc, vfdusd
Overview additive hub fields Present (custc_price_usd, ust1_price_usd, ustr_price_usd)
Public trader https://dex.cl8y.com/trader/terra12z8vz3vgnalt8trykd6nntdyp54e95yqsdtjj3 Per-row +95.65 UST1. Header +$94 (“Priced pairs only”) ≈ hub UST1 × 95.65 (~$93.8), not $1 → ~$96. EMBER omitted, not $0.
Best / Worst —, not N/A
Fees —
/protocol DEX hub card Present (cUSTC / UST1 / USTR). CEX tabs USTC / LUNC / vFDUSD only.
/charts 24h Volume (USD) $6.051K — no 10,000,000T on that strip

Docs landed on main

  • Routes table /protocol one-liner now includes the DEX hub card + #560 header P&L (review extra from this issue).
  • Reverse crosslinks: skills/AGENTS_FRONTEND_TRADER_VOLUME_USD.md, skills/AGENTS_INDEXER_EXTERNAL_ORACLE.md.
  • scripts/qa/verify-issue-560.sh greps those links.

Checklist to re-verify

  • make verify-issue-560
  • Header realized P&L uses GET /api/v1/hub-prices (never $1 / 2.5×)
  • Unpriced hubs omitted, not $0; pending → —; empty → $0
  • CEX /oracle/price/ustr stays 400; trader/portfolio do not call it
  • Best / Worst is —, not N/A; fees —
  • Missing asset rows kept (symbol —, decimals omitted)
  • Coolify frontend rebuild (npm ci) — production header matches hub
  • Indexer hub_prices ingest live
  • make verify-issue-554 553 551 556 559 (local stacked suite — not re-run this pass; #560 frontend tests overlap #551)
  • #554 Android 16 Chrome WC + desktop Keplr + in-app Keplr matrix
  • #559 live UST1/cUSTC one-sided Add at 5% slippage on columbus-5 (Cannot Sub at msg index 3)
  • Optional P9 e2e worse-than-quote fill

Leaving open. P560-1–P560-6 and the Coolify/hub production smoke pass. Remaining issue-body / comment ACs are device QA (#554) and live zap (#559), plus the stacked make verify-issue-* list above. Tape Amount in/out compact T remains #557 (out of scope).

## Verification (worktree `verify/560-hub-pnl` → `main` @ `f2b2929f`) Re-ran **P560** in a git worktree from `origin/main`. Code path from !1090 is already on `main`; this pass added skill/docs crosslinks so volume/oracle agents do not reintroduce `$1` / `2.5×` header P&L. ### Local `make verify-issue-560` | Step | Result | |------|--------| | Docs + skill + AGENTS crosslinks (P560-6) | **PASS** | | Source: no `quoteTokenUsd` pegs; CEX `ustr` unused (P560-1 / P560-3) | **PASS** | | Indexer lib: missing-asset mapper keeps rows (P560-5) | **PASS** | | Indexer integration: positions still expose decimals | **PASS** | | Frontend hub P&L + summary + positions + portfolio (P560-2 / P560-4) | **PASS** (35 tests) | Postgres-only infra (`make setup-indexer-postgres`). First docs grep failed because of a single-quoted `grep -E` inside `bash -c`; fixed and re-ran — **5/5**. ### Production smoke (`dex.cl8y.com` / `indexer.dex.cl8y.com`) 2026-08-20 Coolify frontend rebuild **is live** (bundle includes `useProtocolHubPricesQuery` + `traderUsdMarksFromHub`; HTML `last-modified` 2026-08-19 12:06 UTC). | Check | Result | |-------|--------| | `GET /api/v1/hub-prices` | **200** — custc / ust1 / ustr. UST1 ≈ **$0.981** (not $1). USTR market-priced (not 2.5×). | | `GET /api/v1/oracle/price/ustr` and `/ust1` | **400** — `Supported: ustc, lunc, vfdusd` | | Overview additive hub fields | Present (`custc_price_usd`, `ust1_price_usd`, `ustr_price_usd`) | | Public trader https://dex.cl8y.com/trader/terra12z8vz3vgnalt8trykd6nntdyp54e95yqsdtjj3 | Per-row **+95.65 UST1**. Header **+$94** (“Priced pairs only”) ≈ hub UST1 × 95.65 (~$93.8), **not** `$1` → ~$96. EMBER omitted, not `$0`. | | Best / Worst | **—**, not `N/A` | | Fees | **—** | | `/protocol` DEX hub card | Present (cUSTC / UST1 / USTR). CEX tabs USTC / LUNC / vFDUSD only. | | `/charts` 24h Volume (USD) | **$6.051K** — no `10,000,000T` on that strip | ### Docs landed on main - Routes table `/protocol` one-liner now includes the DEX hub card + #560 header P&L (review extra from this issue). - Reverse crosslinks: `skills/AGENTS_FRONTEND_TRADER_VOLUME_USD.md`, `skills/AGENTS_INDEXER_EXTERNAL_ORACLE.md`. - `scripts/qa/verify-issue-560.sh` greps those links. ### Checklist to re-verify - [x] `make verify-issue-560` - [x] Header realized P&L uses `GET /api/v1/hub-prices` (never `$1` / `2.5×`) - [x] Unpriced hubs omitted, not `$0`; pending → **—**; empty → `$0` - [x] CEX `/oracle/price/ustr` stays **400**; trader/portfolio do not call it - [x] Best / Worst is **—**, not `N/A`; fees **—** - [x] Missing asset rows kept (symbol **—**, decimals omitted) - [x] Coolify frontend rebuild (`npm ci`) — production header matches hub - [x] Indexer `hub_prices` ingest live - [ ] `make verify-issue-554` `553` `551` `556` `559` (local stacked suite — **not re-run this pass**; #560 frontend tests overlap #551) - [ ] **#554** Android 16 Chrome WC + desktop Keplr + in-app Keplr matrix - [ ] **#559** live UST1/cUSTC one-sided Add at 5% slippage on columbus-5 (`Cannot Sub` at msg index 3) - [ ] Optional P9 e2e worse-than-quote fill **Leaving open.** P560-1–P560-6 and the Coolify/hub production smoke pass. Remaining issue-body / comment ACs are device QA (#554) and live zap (#559), plus the stacked `make verify-issue-*` list above. Tape Amount in/out compact `T` remains **#557** (out of scope).
PlasticDigits (Migrated from gitlab.com) closed this issue 2026-08-20 12:18:08 +00:00
leonardocolucci commented 2026-08-20 14:04:17 +00:00 (Migrated from gitlab.com)

Real-device QA (Android 16, Chrome) — #554 UI verified working; residual failure is Lunc Dash WC v1, not the DEX

The #519/#554 reporter retested on Android 16 Chrome against production dex.cl8y.com (bundle index-Bqd2luvk.js, wallet chunk wallet-terra-DhLsGGzr.js), 2026-08-19 ~16:45 UTC. Two runs: a two-device QR attempt (hung), then the same-device "Open" deep-link path as intended. Recordings reviewed frame-by-frame.

DEX side: passes the #554 acceptance criteria

The mobile connect sheet is now correct on-device:

connect_sheet

  • Pairing sheet is the foreground UI (no longer hidden behind Connect Wallet).
  • New copy present: "Then use Open or Copy. Wallet browser also works."
  • All wallets listed as WALLETCONNECT; Cancel button present during the connecting state.
  • Tapping Lunc Dash fires the luncdash://wallet_connect deep link and the Lunc Dash app actually opens (splash → wallet home). This is the exact flow that failed pre-#554.

Residual failure is in Lunc Dash (WalletConnect v1), wallet-side

After the app opens, Lunc Dash shows "Ready to Connect", spins, and then throws its own error:

session_timeout

So the pairing request reaches the wallet, but the WC session never settles and Lunc Dash times out. Lunc Dash uses WalletConnect v1 with its own bridge https://walletconnect.luncdash.com. I probed it during the failure window:

  • DNS resolves (Cloudflare), GET /hello → Hello World, this is Relay Server v1.0.0
  • WebSocket upgrade succeeds: HTTP/1.1 101 Switching Protocols (Sec-WebSocket-Accept returned)

The relay is reachable, yet the v1 handshake still doesn't complete — consistent with the deprecated WC v1 stack. "Session timeout" is emitted by the wallet, not the dApp.

Suggested next steps (not DEX code)

  1. Treat #554's DEX-side AC as met on real hardware (deep link + pairing sheet + cancel all confirmed); the remaining Lunc Dash timeout is out of the DEX's control.
  2. Consider documenting Keplr Mobile (WalletConnect v2) as the recommended same-device mobile path in AGENTS_FRONTEND_WALLETCONNECT_MOBILE.md / QA template — the DEX already exposes Keplr as a WALLETCONNECT row, and v2 avoids the dead v1 bridge.
  3. Raise the "Ready to Connect → Session timeout" behavior with the Lunc Dash vendor (WC v1 EOL); nothing to change in walletConnectPairing / the cosmes patch for this.

Happy to have the reporter retest the Keplr Mobile path if that would help close the manual matrix.

## Real-device QA (Android 16, Chrome) — #554 UI verified working; residual failure is Lunc Dash WC v1, not the DEX The #519/#554 reporter retested on Android 16 Chrome against production `dex.cl8y.com` (bundle `index-Bqd2luvk.js`, wallet chunk `wallet-terra-DhLsGGzr.js`), 2026-08-19 ~16:45 UTC. Two runs: a two-device QR attempt (hung), then the **same-device "Open" deep-link path** as intended. Recordings reviewed frame-by-frame. ### DEX side: passes the #554 acceptance criteria The mobile connect sheet is now correct on-device: ![connect_sheet](/uploads/27e1a19b75783f1c2abd21ddbe1e214e/connect_sheet.png) - Pairing sheet is the **foreground** UI (no longer hidden behind Connect Wallet). - New copy present: "Then use Open or Copy. Wallet browser also works." - All wallets listed as **WALLETCONNECT**; **Cancel** button present during the connecting state. - Tapping **Lunc Dash** fires the `luncdash://wallet_connect` deep link and **the Lunc Dash app actually opens** (splash → wallet home). This is the exact flow that failed pre-#554. ### Residual failure is in Lunc Dash (WalletConnect v1), wallet-side After the app opens, Lunc Dash shows **"Ready to Connect"**, spins, and then throws its own error: ![session_timeout](/uploads/01563c92b348ed8f12120e760b7cc4dc/session_timeout.png) So the pairing request reaches the wallet, but the WC session never settles and Lunc Dash times out. Lunc Dash uses **WalletConnect v1** with its own bridge `https://walletconnect.luncdash.com`. I probed it during the failure window: - DNS resolves (Cloudflare), `GET /hello` → `Hello World, this is Relay Server v1.0.0` - WebSocket upgrade succeeds: `HTTP/1.1 101 Switching Protocols` (`Sec-WebSocket-Accept` returned) The relay is reachable, yet the v1 handshake still doesn't complete — consistent with the deprecated WC v1 stack. "Session timeout" is emitted by the wallet, not the dApp. ### Suggested next steps (not DEX code) 1. Treat #554's DEX-side AC as **met on real hardware** (deep link + pairing sheet + cancel all confirmed); the remaining Lunc Dash timeout is out of the DEX's control. 2. Consider documenting **Keplr Mobile** (WalletConnect **v2**) as the recommended same-device mobile path in `AGENTS_FRONTEND_WALLETCONNECT_MOBILE.md` / QA template — the DEX already exposes Keplr as a WALLETCONNECT row, and v2 avoids the dead v1 bridge. 3. Raise the "Ready to Connect → Session timeout" behavior with the Lunc Dash vendor (WC v1 EOL); nothing to change in `walletConnectPairing` / the cosmes patch for this. Happy to have the reporter retest the Keplr Mobile path if that would help close the manual matrix.
PlasticDigits commented 2026-08-22 03:10:05 +00:00 (Migrated from gitlab.com)

mentioned in issue #589

mentioned in issue #589
PlasticDigits commented 2026-08-26 03:07:40 +00:00 (Migrated from gitlab.com)

mentioned in issue #656

mentioned in issue #656
PlasticDigits commented 2026-08-26 03:08:08 +00:00 (Migrated from gitlab.com)

mentioned in issue #657

mentioned in issue #657
PlasticDigits commented 2026-08-26 04:17:22 +00:00 (Migrated from gitlab.com)

mentioned in issue #666

mentioned in issue #666
PlasticDigits commented 2026-08-27 00:34:50 +00:00 (Migrated from gitlab.com)

mentioned in merge request !1178

mentioned in merge request !1178
PlasticDigits commented 2026-08-27 00:35:06 +00:00 (Migrated from gitlab.com)

mentioned in merge request !1179

mentioned in merge request !1179
Sign in to join this conversation.
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#560
No description provided.