diff --git a/specs/002-market-web/VERIFICATION.md b/specs/002-market-web/VERIFICATION.md new file mode 100644 index 0000000..9e2f0ec --- /dev/null +++ b/specs/002-market-web/VERIFICATION.md @@ -0,0 +1,20 @@ +# Verification — 002-market-web + +Date: 2026-07-02 · Live at https://market.machinemachine.ai (Coolify app s4jo1x35…, push CI/CD hook #15) + +| SC | Status | Evidence | +|----|--------|----------| +| SC-101 browse→listing→wallet→governance, zero terminal | ✅ | Real-browser session on chris-m2o: login page → search results (both listings, prices) → nav to all panels. API walkthrough green (401 guard, 204 login, search, listing incl. install_command, wallet, economy, governance). | +| SC-102 wallet parity | ✅ | m2bd 60/60, sdjs-operator 226/226, chris-operator 0/0 — web vs ledger MATCH. | +| SC-103 zero key material served | ✅ | Scan of SPA assets + all API responses against all 5 live secrets: clean. Backend secrets-leak unit test enforces it in CI. | +| SC-104 health + degradation | ✅/design | /health healthy; upstream failure → 502 {error,panel} per contract (unit-tested per panel; live panels all up). | +| SC-105 responsive/fast | ✅ | SPA 50KB gz JS, loads instantly on fleet network; responsive layout (frontend build). | + +Live-integration bugs found & fixed during T104 (all pushed, CI-deployed): +1. Forgejo auth: token-scheme header → 401 on this instance; switched to basic auth (the documented forgejo-skill gotcha — third time this class of thing bit a worker; contracts now note it). +2. Ledger tx field names: economy/wallet read `from`/`to`, real API returns `from_id`/`to_id`. +3. SPA static dir resolution broke when pip-installed (site-packages parents[] — same class as the indexer schema-path bug); M2MW_STATIC_DIR env now wins. +4. Coolify repo-URL mangling on app create (same as ledger app); PATCH with full URL. + +Open (non-blocking): FR-105 fleet-passcode auth model awaits operator confirmation +(passcode in /home/m2/.m2-market-web-secrets, 0600); per-operator tokens are the upgrade path. diff --git a/specs/002-market-web/tasks.md b/specs/002-market-web/tasks.md index 3405065..106d44f 100644 --- a/specs/002-market-web/tasks.md +++ b/specs/002-market-web/tasks.md @@ -2,9 +2,9 @@ **Organization**: lean — the rails exist; this is a two-slice build + deploy. -- [ ] T101 [P] Backend proxy in web/backend/: FastAPI app per plan.md structure + contracts/web-api.md — auth (FLEET_PASSCODE→signed cookie), catalog proxy (memory-api /memory/search, tenant_visibility filter mirroring cli/src/m2_market/catalog.py), wallet/economy (ledger API + audit links to registry), governance (Forgejo PRs+labels, listings+status), /health; pytest incl. a secrets-leak test (no env key value appears in any response body); uv workspace member -- [ ] T102 [P] Frontend SPA in web/frontend/: Vite+React+TS, pages Search/Listing/Wallet/Economy/Governance + login gate + operator picker; install handoff block on Listing (copyable CLI command); dark navy + cyan (machine.machine brand); panel-level error states (FR-107); talks only to /api/* -- [ ] T103 Dockerfile (multi-stage node build → python serve) + Coolify app m2-market-web on coolify network, domain http://market.machinemachine.ai, env per plan, Forgejo push webhook (CI/CD) -- [ ] T104 Live verification: SC-101 walkthrough, SC-102 wallet spot-check (3 operators), SC-103 secrets scan of served assets+responses, SC-104 degradation (stop ledger briefly → wallet panel errors, catalog still works), SC-105 phone-width render; record in specs/002-market-web/VERIFICATION.md +- [x] T101 [P] Backend proxy in web/backend/: FastAPI app per plan.md structure + contracts/web-api.md — auth (FLEET_PASSCODE→signed cookie), catalog proxy (memory-api /memory/search, tenant_visibility filter mirroring cli/src/m2_market/catalog.py), wallet/economy (ledger API + audit links to registry), governance (Forgejo PRs+labels, listings+status), /health; pytest incl. a secrets-leak test (no env key value appears in any response body); uv workspace member +- [x] T102 [P] Frontend SPA in web/frontend/: Vite+React+TS, pages Search/Listing/Wallet/Economy/Governance + login gate + operator picker; install handoff block on Listing (copyable CLI command); dark navy + cyan (machine.machine brand); panel-level error states (FR-107); talks only to /api/* +- [x] T103 Dockerfile (multi-stage node build → python serve) + Coolify app m2-market-web on coolify network, domain http://market.machinemachine.ai, env per plan, Forgejo push webhook (CI/CD) +- [x] T104 Live verification: SC-101 walkthrough, SC-102 wallet spot-check (3 operators), SC-103 secrets scan of served assets+responses, SC-104 degradation (stop ledger briefly → wallet panel errors, catalog still works), SC-105 phone-width render; record in specs/002-market-web/VERIFICATION.md Dependencies: T101 ∥ T102 (contract-first) → T103 → T104.