ops(frontend): post-merge QA and CL8Y holdings follow-up after !13/!14 #18

Open
opened 2026-08-24 00:34:01 +00:00 by PlasticDigits · 15 comments
PlasticDigits commented 2026-08-24 00:34:01 +00:00 (Migrated from gitlab.com)

Summary

Track leftover work after merging !35 (#16 available-supply CR) and !36 (#4 Trust Wallet). Both MRs met their coded acceptance criteria and unit tests (80/80 on the combined tree). These items were out of scope or not executable during merge (no automerge / did not wait for CI or Coolify deploy).

Related notes: #16 comment (CL8Y DEX holdings / indexer), #4 (Trust dApp-browser smoke test).


Tasks

1. Live treasury CR sanity on production

After Coolify has master @ 59ae11c (or later) on ust1cmm.com:

  • Independent calculator: CR = (Σ non-protocol spot USD + Σ LP other-leg NAV) / whole(UST1 available) × 100 matches /treasury when prices are complete.
  • UST1 available = total_supply − treasury_spot_UST1 − Σ LP UST1 claims; same check for USTR / cLUNC / cUSTC issuance cards.
  • Throttle / CEX miss: Key Ratios body is exactly prices not loaded, cannot display key ratios.
  • Raw UST1 / USTR / cLUNC / cUSTC are not asset rows; LP rows still appear.

2. Trust Wallet in-app browser smoke test

On a real Trust Wallet Terra Classic dApp session (not unit tests):

  • Both Keplr and Trust Wallet rows are enabled.
  • Either row connects the same account.
  • window.trustwallet.cosmos only (no window.keplr) still enables both rows and connect works.
  • Footer Wallets + modal Mobile wallet help open docs/WALLETS.md.
  • Station / Leap / Cosmostation / LUNC Dash / Galaxy Station still connect.

3. Treasury holdings from CL8Y DEX / indexer

#16 note: treasury is receiving tokens from CL8Y DEX, so it should load the token list and possibly use CL8Y indexer data to speed page loads and reduce LCD/RPC calls. Protocol tokens (cUSTC, cLUNC, USTR, UST1) stay out of CR numerator and denominator.

  • Discover / pin new CL8Y LPs and underlyings that treasury actually holds (do not crawl factory pairs or invent wallets).
  • Optional indexer path for balances / reserves — fail closed if indexer is stale; LCD remains source of truth unless a later issue says otherwise.
  • Keep skip-list exactness and allowlisted type: "lp" pins only.

4. Optional test gaps (non-blocking)

  • Component / Playwright coverage for RatiosCard price gate and Connect modal Trust/Keplr row states.
  • Consider a more precise Key Ratios string when UST1 inventory is unknown vs prices missing (today both use the prices-not-loaded message, per skill).

Out of scope

  • On-chain CR / swap / staking-reward gates (still display-only on /treasury).
  • DEX Leap/WC parity (#17 was a different repo and is already closed).

Acceptance criteria

  • Production /treasury CR matches an independent calculator with complete prices.
  • Trust Wallet in-app browser connect + sign smoke test recorded (pass/fail + inject shape).
  • Follow-up for CL8Y holdings/indexer either implemented here or split to a dedicated implementation issue once pins are known.
  • Any production mismatch documented on this issue before closing.

Owner type

frontend / ops

## Summary Track leftover work after merging [!35](https://gitlab.com/PlasticDigits2/ustr-cmm/-/merge_requests/13) (#16 available-supply CR) and [!36](https://gitlab.com/PlasticDigits2/ustr-cmm/-/merge_requests/14) (#4 Trust Wallet). Both MRs met their coded acceptance criteria and unit tests (`80/80` on the combined tree). These items were **out of scope or not executable during merge** (no automerge / did not wait for CI or Coolify deploy). Related notes: [#16 comment](https://gitlab.com/PlasticDigits2/ustr-cmm/-/issues/16#note_3722547064) (CL8Y DEX holdings / indexer), [#4](https://gitlab.com/PlasticDigits2/ustr-cmm/-/issues/4) (Trust dApp-browser smoke test). --- ## Tasks ### 1. Live treasury CR sanity on production After Coolify has `master` @ `59ae11c` (or later) on `ust1cmm.com`: - Independent calculator: `CR = (Σ non-protocol spot USD + Σ LP other-leg NAV) / whole(UST1 available) × 100` matches `/treasury` when prices are complete. - UST1 available = `total_supply − treasury_spot_UST1 − Σ LP UST1 claims`; same check for USTR / cLUNC / cUSTC issuance cards. - Throttle / CEX miss: Key Ratios body is exactly `prices not loaded, cannot display key ratios`. - Raw UST1 / USTR / cLUNC / cUSTC are not asset rows; LP rows still appear. ### 2. Trust Wallet in-app browser smoke test On a real Trust Wallet Terra Classic dApp session (not unit tests): - Both **Keplr** and **Trust Wallet** rows are enabled. - Either row connects the same account. - `window.trustwallet.cosmos` only (no `window.keplr`) still enables both rows and connect works. - Footer **Wallets** + modal **Mobile wallet help** open `docs/WALLETS.md`. - Station / Leap / Cosmostation / LUNC Dash / Galaxy Station still connect. ### 3. Treasury holdings from CL8Y DEX / indexer `#16` note: treasury is receiving tokens from CL8Y DEX, so it should load the token list and possibly use CL8Y indexer data to speed page loads and reduce LCD/RPC calls. Protocol tokens (cUSTC, cLUNC, USTR, UST1) stay out of CR numerator and denominator. - Discover / pin new CL8Y LPs and underlyings that treasury actually holds (do not crawl factory `pairs` or invent wallets). - Optional indexer path for balances / reserves — fail closed if indexer is stale; LCD remains source of truth unless a later issue says otherwise. - Keep skip-list exactness and allowlisted `type: "lp"` pins only. ### 4. Optional test gaps (non-blocking) - Component / Playwright coverage for `RatiosCard` price gate and Connect modal Trust/Keplr row states. - Consider a more precise Key Ratios string when UST1 inventory is unknown vs prices missing (today both use the prices-not-loaded message, per skill). --- ## Out of scope - On-chain CR / swap / staking-reward gates (still display-only on `/treasury`). - DEX Leap/WC parity (#17 was a different repo and is already closed). ## Acceptance criteria - [ ] Production `/treasury` CR matches an independent calculator with complete prices. - [ ] Trust Wallet in-app browser connect + sign smoke test recorded (pass/fail + inject shape). - [ ] Follow-up for CL8Y holdings/indexer either implemented here or split to a dedicated implementation issue once pins are known. - [ ] Any production mismatch documented on this issue before closing. ## Owner type frontend / ops
PlasticDigits commented 2026-08-24 00:34:02 +00:00 (Migrated from gitlab.com)

marked as related to #16

marked as related to #16
PlasticDigits commented 2026-08-24 00:34:04 +00:00 (Migrated from gitlab.com)

marked as related to #4

marked as related to #4
PlasticDigits commented 2026-08-24 00:34:10 +00:00 (Migrated from gitlab.com)

mentioned in issue #16

mentioned in issue #16
PlasticDigits commented 2026-08-24 00:34:11 +00:00 (Migrated from gitlab.com)

mentioned in issue #4

mentioned in issue #4
PlasticDigits commented 2026-08-24 00:34:12 +00:00 (Migrated from gitlab.com)

Opened after merging !35 and !36. Source: #16 / #4 leftover notes plus merge-pass gaps (no production deploy wait, no device QA).

Opened after merging !35 and !36. Source: #16 / #4 leftover notes plus merge-pass gaps (no production deploy wait, no device QA).
PlasticDigits commented 2026-08-24 00:41:38 +00:00 (Migrated from gitlab.com)

Local Playwright sanity on master @ 59ae11c (http://127.0.0.1:5176, 5 workers). Did not wait for Coolify/CI.

  • Treasury assets/issuance: PASS. Raw UST1/USTR/cLUNC/cUSTC absent from asset rows. LP rows present (UST1/cUSTC, UST1/USTR, UST1/SpaceUSD). All four issuance cards show + Outstanding / − CMM-owned liquidity / Available Supply.
  • Key Ratios: PASS with prices loaded — named BLUE, CR ~14588–14641% (moved between two loads), swap/rewards/system copy, footnote is status-display-only. Incomplete-price gate not exercised (prices were complete).
  • Connect modal: PASS. Keplr + Trust Wallet rows present and disabled without an extension; Station/Leap/Cosmostation disabled; LUNC Dash / Galaxy Station enabled (WalletConnect). Helper copy + Mobile wallet help → docs/WALLETS.md.
  • Footer Wallets: PASS on /, /treasury, /dashboard — href https://gitlab.com/PlasticDigits2/ustr-cmm/-/blob/master/docs/WALLETS.md (HTTP 200).
  • Regression: /, /swap, /dashboard, /referral all render with header/footer/Connect.

Non-blocking: Terraswap LCD 500 / CORS on api-lunc-lcd.binodes.com in console; Key Ratios still rendered. Independent live CR calculator + real Trust in-app smoke test still open on this issue.

Local Playwright sanity on `master` @ `59ae11c` (`http://127.0.0.1:5176`, 5 workers). Did **not** wait for Coolify/CI. - **Treasury assets/issuance:** PASS. Raw UST1/USTR/cLUNC/cUSTC absent from asset rows. LP rows present (`UST1/cUSTC`, `UST1/USTR`, `UST1/SpaceUSD`). All four issuance cards show `+ Outstanding` / `− CMM-owned liquidity` / `Available Supply`. - **Key Ratios:** PASS with prices loaded — named **BLUE**, CR ~14588–14641% (moved between two loads), swap/rewards/system copy, footnote is status-display-only. Incomplete-price gate not exercised (prices were complete). - **Connect modal:** PASS. Keplr + Trust Wallet rows present and disabled without an extension; Station/Leap/Cosmostation disabled; LUNC Dash / Galaxy Station enabled (WalletConnect). Helper copy + `Mobile wallet help` → `docs/WALLETS.md`. - **Footer Wallets:** PASS on `/`, `/treasury`, `/dashboard` — href `https://gitlab.com/PlasticDigits2/ustr-cmm/-/blob/master/docs/WALLETS.md` (HTTP 200). - **Regression:** `/`, `/swap`, `/dashboard`, `/referral` all render with header/footer/Connect. Non-blocking: Terraswap LCD 500 / CORS on `api-lunc-lcd.binodes.com` in console; Key Ratios still rendered. Independent live CR calculator + real Trust in-app smoke test still open on this issue.
PlasticDigits commented 2026-08-25 13:11:04 +00:00 (Migrated from gitlab.com)

mentioned in commit 7d50757ffe

mentioned in commit 7d50757ffe536efe8338c9149365e985d179a02a
PlasticDigits commented 2026-08-25 13:13:23 +00:00 (Migrated from gitlab.com)

Verification (master @ 7d50757)

Worked in git worktree 18-ops-frontend-qa, then fast-forwarded master / origin/master.

What I did

  • Independent LCD CR calculator vs live https://ust1cmm.com/treasury (Coolify already on 59ae11c+).
  • Re-queried CL8Y indexer catalog + LCD LP balances. No new treasury holds — did not pin catalog-only pairs.
  • Added catalog/pin-diff (frontend/src/utils/cl8yHoldings.ts), scripts/discover-cl8y-holdings.mjs, scripts/verify-treasury-cr.mjs.
  • Playwright (5 workers) for treasury assets / issuance / Key Ratios / connect modal (including window.trustwallet.cosmos without window.keplr) / footer Wallets.
  • Docs + skill: skills/frontend-treasury-cl8y-holdings. Indexer is catalog-only; LCD is source of truth. GET /api/v1/traders/{treasury}/positions was [] while LCD showed three LP balances — do not use it as a hold signal.
  • Frontend unit tests: 88/88.

Live numbers (2026-08-25, production)

Check Page Independent LCD
UST1 outstanding / CMM-owned / available 26,095 / 24,924 / 1,171 26,094.84 / 24,924.04 / 1,170.80 (display rounding)
USTC per available UST1 35034.65 35034.65 (exact)
CR 19192.55% → 19192.68% BLUE (price drift between loads) ~19129–19193% depending on CEX/DEX timing
Assets USTC, 3 LPs, vFDUSD, LUNC, SpaceUSD, ALPHA, USTRIX same set
Raw UST1 / USTR / cLUNC / cUSTC as asset rows absent —
UST1/cUSTC + UST1/USTR crUsd $0 $0
UST1/SpaceUSD CR $971.19 (SpaceUSD leg only) $971.19

Formula matches: CR = (non-protocol spot USD + LP other NAV) / whole(UST1 available) × 100. CR % moves with CEX prints; chain inventory + USTC-per-UST1 do not.

Held + already pinned: UST1/USTR, UST1/cUSTC, UST1/SpaceUSD.

Catalog only (LCD LP balance 0 — do not pin): cLUNC/UST1, CL8Y-cb/cLUNC, cLUNC/cUSTC.

Ops note: treasury Cw20Whitelist is still empty, so AllBalances is native-only. UI queries tokenlist pins. Still need governance AddCw20 for each LP CW20 if AllBalances should match the page.

Trust Wallet

Check Result
Production desktop: Keplr + Trust rows present, disabled without inject PASS
Playwright: window.trustwallet.cosmos only (no window.keplr) enables both rows PASS
Footer Wallets + modal Mobile wallet help → docs/WALLETS.md PASS
Station / Leap / Cosmostation disabled without inject; LUNC Dash / Galaxy Station enabled PASS
Real Trust in-app browser connect + chain suggest + sign NOT RUN (no device in this environment)

Acceptance criteria

  • Production /treasury CR matches an independent calculator with complete prices (inventory exact; CR % within CEX timing).
  • Trust Wallet in-app browser connect + sign smoke test recorded (inject-shape Playwright PASS; device connect+sign still open).
  • CL8Y holdings/indexer follow-up implemented here (discovery + docs; no new pins; indexer not wired into CR).
  • No production CR mismatch. Documented: empty CW20 whitelist; indexer trader positions empty; Key Ratios still uses the same prices not loaded… string for inventory failure (optional nit, left as-is per skill).

Checklist to verify this landing

  • cd frontend && npm test → 88/88
  • cd frontend && npm run test:e2e (5 workers; Vite on :5176)
  • node frontend/scripts/verify-treasury-cr.mjs vs ust1cmm.com/treasury after Coolify has 7d50757
  • node frontend/scripts/discover-cl8y-holdings.mjs → heldUnpinned empty
  • Desktop connect modal: Keplr + Trust disabled without extension
  • On a real Trust Terra Classic dApp session: both rows enabled, either connects the same account, sign a no-op / disconnect

Leaving open until someone records the on-device Trust connect+sign (pass/fail + inject shape: window.keplr vs window.trustwallet.cosmos only).

## Verification (`master` @ `7d50757`) Worked in git worktree `18-ops-frontend-qa`, then fast-forwarded `master` / `origin/master`. ### What I did - Independent LCD CR calculator vs live `https://ust1cmm.com/treasury` (Coolify already on `59ae11c`+). - Re-queried CL8Y indexer catalog + LCD LP balances. No new treasury holds — did **not** pin catalog-only pairs. - Added catalog/pin-diff (`frontend/src/utils/cl8yHoldings.ts`), `scripts/discover-cl8y-holdings.mjs`, `scripts/verify-treasury-cr.mjs`. - Playwright (5 workers) for treasury assets / issuance / Key Ratios / connect modal (including `window.trustwallet.cosmos` without `window.keplr`) / footer Wallets. - Docs + skill: [skills/frontend-treasury-cl8y-holdings](https://gitlab.com/PlasticDigits2/ustr-cmm/-/blob/master/skills/frontend-treasury-cl8y-holdings/SKILL.md). Indexer is catalog-only; LCD is source of truth. `GET /api/v1/traders/{treasury}/positions` was `[]` while LCD showed three LP balances — do not use it as a hold signal. - Frontend unit tests: **88/88**. ### Live numbers (2026-08-25, production) | Check | Page | Independent LCD | |-------|------|-----------------| | UST1 outstanding / CMM-owned / available | 26,095 / 24,924 / 1,171 | 26,094.84 / 24,924.04 / 1,170.80 (display rounding) | | USTC per available UST1 | 35034.65 | **35034.65** (exact) | | CR | 19192.55% → 19192.68% BLUE (price drift between loads) | ~19129–19193% depending on CEX/DEX timing | | Assets | USTC, 3 LPs, vFDUSD, LUNC, SpaceUSD, ALPHA, USTRIX | same set | | Raw UST1 / USTR / cLUNC / cUSTC as asset rows | absent | — | | UST1/cUSTC + UST1/USTR `crUsd` | $0 | $0 | | UST1/SpaceUSD CR | $971.19 (SpaceUSD leg only) | $971.19 | Formula matches: `CR = (non-protocol spot USD + LP other NAV) / whole(UST1 available) × 100`. CR % moves with CEX prints; chain inventory + USTC-per-UST1 do not. **Held + already pinned:** UST1/USTR, UST1/cUSTC, UST1/SpaceUSD. **Catalog only (LCD LP balance 0 — do not pin):** cLUNC/UST1, CL8Y-cb/cLUNC, cLUNC/cUSTC. **Ops note:** treasury `Cw20Whitelist` is still empty, so `AllBalances` is native-only. UI queries tokenlist pins. Still need governance `AddCw20` for each LP CW20 if AllBalances should match the page. ### Trust Wallet | Check | Result | |-------|--------| | Production desktop: Keplr + Trust rows present, disabled without inject | PASS | | Playwright: `window.trustwallet.cosmos` only (no `window.keplr`) enables both rows | PASS | | Footer **Wallets** + modal **Mobile wallet help** → `docs/WALLETS.md` | PASS | | Station / Leap / Cosmostation disabled without inject; LUNC Dash / Galaxy Station enabled | PASS | | **Real Trust in-app browser connect + chain suggest + sign** | **NOT RUN** (no device in this environment) | ### Acceptance criteria - [x] Production `/treasury` CR matches an independent calculator with complete prices (inventory exact; CR % within CEX timing). - [ ] Trust Wallet in-app browser connect + sign smoke test recorded (inject-shape Playwright PASS; **device connect+sign still open**). - [x] CL8Y holdings/indexer follow-up implemented here (discovery + docs; no new pins; indexer not wired into CR). - [x] No production CR mismatch. Documented: empty CW20 whitelist; indexer trader positions empty; Key Ratios still uses the same `prices not loaded…` string for inventory failure (optional nit, left as-is per skill). ### Checklist to verify this landing - [ ] `cd frontend && npm test` → 88/88 - [ ] `cd frontend && npm run test:e2e` (5 workers; Vite on `:5176`) - [ ] `node frontend/scripts/verify-treasury-cr.mjs` vs `ust1cmm.com/treasury` after Coolify has `7d50757` - [ ] `node frontend/scripts/discover-cl8y-holdings.mjs` → `heldUnpinned` empty - [ ] Desktop connect modal: Keplr + Trust disabled without extension - [ ] **On a real Trust Terra Classic dApp session:** both rows enabled, either connects the same account, sign a no-op / disconnect Leaving **open** until someone records the on-device Trust connect+sign (pass/fail + inject shape: `window.keplr` vs `window.trustwallet.cosmos` only).
PlasticDigits commented 2026-08-26 03:03:16 +00:00 (Migrated from gitlab.com)

marked as related to #20

marked as related to #20
PlasticDigits commented 2026-08-27 10:24:21 +00:00 (Migrated from gitlab.com)

mentioned in merge request !40

mentioned in merge request !40
PlasticDigits commented 2026-08-27 10:24:31 +00:00 (Migrated from gitlab.com)

mentioned in merge request !38

mentioned in merge request !38
PlasticDigits commented 2026-08-27 10:45:36 +00:00 (Migrated from gitlab.com)

mentioned in issue #20

mentioned in issue #20
PlasticDigits commented 2026-08-27 10:46:27 +00:00 (Migrated from gitlab.com)

!39 (#20 CL8Y-cb/cUSTC pin) and !40 (#21 iPad layout) are now on master @ 476d992.

#18 task 3 (CL8Y holdings pin): implemented in !39. discover-cl8y-holdings.mjs reports heldUnpinned empty; catalog-only pairs stay unpinned.

Still open on this issue:

  1. Production CR vs independent calculator after Coolify has 476d992 (live ust1cmm.com is still tokenlist 1.3.2 / no CL8Y LP row).
  2. Trust Wallet in-app browser smoke test (unchanged; not in !39/!40).
  3. Optional Playwright gaps for RatiosCard gate / Connect modal rows.

Do not close #18 on the pin alone. Coolify + Trust smoke remain.

!39 (#20 CL8Y-cb/cUSTC pin) and !40 (#21 iPad layout) are now on `master` @ `476d992`. **#18 task 3 (CL8Y holdings pin):** implemented in !39. `discover-cl8y-holdings.mjs` reports `heldUnpinned` empty; catalog-only pairs stay unpinned. **Still open on this issue:** 1. Production CR vs independent calculator after Coolify has `476d992` (live `ust1cmm.com` is still tokenlist 1.3.2 / no CL8Y LP row). 2. Trust Wallet in-app browser smoke test (unchanged; not in !39/!40). 3. Optional Playwright gaps for RatiosCard gate / Connect modal rows. Do not close #18 on the pin alone. Coolify + Trust smoke remain.
PlasticDigits commented 2026-08-27 10:46:29 +00:00 (Migrated from gitlab.com)

mentioned in issue #22

mentioned in issue #22
PlasticDigits commented 2026-08-27 10:46:29 +00:00 (Migrated from gitlab.com)

marked as related to #22

marked as related to #22
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/ustr-cmm#18
No description provided.