carlos / platform Public

Console plans: Astra round 5 findings

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
claude agent, operated by paul@keymail.dev 30ee5d8709e51873a28f6cc250d58f064e971421 parent 2fb5639
1 file changed, +91 −0
  • docs/superpowers/plans/CODEX-FINDINGS-CONSOLE-PLANS-R5.md +91 −0
diff --git a/docs/superpowers/plans/CODEX-FINDINGS-CONSOLE-PLANS-R5.md b/docs/superpowers/plans/CODEX-FINDINGS-CONSOLE-PLANS-R5.md
new file mode 100644
index 000000000..6a7195930
--- /dev/null
+++ b/docs/superpowers/plans/CODEX-FINDINGS-CONSOLE-PLANS-R5.md
@@ -0,0 +1,91 @@
+| Earlier finding | Disposition at `2fb56393` | Evidence |
+|---|---|---|
+| R4-1: Refresh loses dependencies of the served value | **Resolved** | Separate published/in-flight sets, including failed-refresh witnesses. [Perf-2 T6:259](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:259). |
+| R4-2: Economics caches SQLite-derived values | **Resolved** | Accounts, tiers, registry attribution and period arithmetic move to request-time derivation; tier-save witness added. [Perf-2 T15:569](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:569). New dependency-key issue below. |
+| R4-3: Shared metrics entry has incompatible loaders | **Resolved** | One `loadMetricsFacts`, result type and 60-second window; inner cache bypassed. [Perf-2 T9:411](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:411), [T15:568](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:568). |
+| R4-4: Catch-all cache freezes live status | **Resolved** | Manifest/TXT facts cached separately; rows rebuilt with current readings and clock. [Perf-2 T13:515](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:515). |
+| R4-5: New tombstone cannot satisfy zero-read Trash test | **Resolved** | Explicit tombstone primer creates and validates the new entry before responding. [Perf-2 T8:372](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:372). |
+| R4-6: Coverage oracle skips default targets | **Resolved** | Coverage uses the walk’s expanded `perfWalkTargets`. [Perf-2 T8:385](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:385). |
+| R4-7: Active-user counts perform correlated scans | **Resolved** | Set-based UNION and supporting indexes replace the correlated query. [Operator T4:368](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-operator-pages.md:368). New test-oracle defect below. |
+| R4-8: `over` pages can return errors without failing | **Resolved** | Status checks explicitly cover every request, including `over` and cold requests. [Perf-1 T10:408](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-1-measure.md:408). |
+| R4-9: Split landing reuses census proposal name | **Resolved** | Each landing gets its own proposal, card and ruling. [Operator T15:763](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-operator-pages.md:763). |
+| R4-10: Deleted-account Activity links lose history | **Resolved** | Tombstone-inclusive operator lookup and link-following test. [Operator T11:643](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-operator-pages.md:643). |
+| R2-6, previously partly: Legacy bake clock interface | **Resolved** | Explicit `now` argument and request-time bake computation. [Perf-2 T9:405](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:405). |
+| R2-12c, previously partly: Static traversal response | **Resolved** | Complete 301 → 301 → 404 sequence specified. [Operator T2:313](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-operator-pages.md:313). |
+| R1-9, previously partly: Older versions unreachable | **Resolved** | Pagination, page-specific cache entries and retained acceptance assertions. [Nav T3:233](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-ux-nav.md:233), [Perf-2 T10:437](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:437). |
+| R1-14, previously partly: Sparse fixtures/inaccurate S3 counts | **Resolved** | Production `S3Store`, transport counting, populated/paginated fixtures and whole-session ceiling. [Perf-1 T9:333](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-1-measure.md:333), [T10:382](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-1-measure.md:382). |
+
+“Resolved” describes the revised plan’s treatment of the reported defect, not implementation verification.
+
+1. **P2 — Economics’ singleton keys omit inputs that determine which objects are read.**
+
+ **Perf-2 Task 15** gives recent bills one `economics-bills` key and fleet-meter objects one `economics-fleet-meters` key. Existing reads depend respectively on the current month, and on the requested dates plus locally registered fleets/boxes.
+
+ Concrete stale-after-own-write case: warm bills just before November begins, recording September/October dependencies; after midnight save November’s bill. That write matches neither dependency, so the redirect can serve the old bill collection. Similarly, switching Economics periods or registering a fleet reuses a fleet-meter entry populated for a different object set. Moving attribution to request time does not fetch the missing objects.
+
+ Cache bills per month and fleet-meter facts per fleet/box/day, selecting entries per request. Add month-rollover/save and period-switch witnesses.
+
+ Evidence: [plan T15:569](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:569), [bill selection:801](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/internal/console/economicsview.go:801), [bill save:1274](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/internal/console/economicspass.go:1274), [fleet object selection:684](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/internal/console/economicspass.go:684).
+
+2. **P2 — Task 11 still names aggregate loaders that violate the facts-only boundary.**
+
+ **Perf-2 Task 11** caches `liveEdges` and the complete GeoIP inventory without specifying their required splits:
+
+ - `liveEdges` returns freshness and completeness already derived from the clock and box snapshots. The derivation occurs in another package, beyond the proposed console-only transitive AST check. Caching that result freezes `Fresh` and clock-dependent `BoxesComplete`; refreshing `partBoxes` does not recompute them.
+ - GeoIP inventory includes registry-derived expected boxes and selects heartbeat prefixes through `ListFleets`. A newly registered fleet has no dependency in the existing global entry. Passing a registry snapshot as plain loader arguments would satisfy the type restriction while preserving this defect.
+
+ Cache raw edge facts and individual fleet snapshots; derive liveness and the expected inventory per request. Test crossing the freshness boundary and adding/removing a fleet without an S3 write.
+
+ Evidence: [plan T11:467](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:467), [liveEdges:203](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/internal/console/regioncandidates.go:203), [clock-derived result:152](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/internal/edgesfile/snapshot.go:152), [GeoIP registry/prefix selection:281](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/internal/console/apisystemgeoip.go:281).
+
+3. **P2 — The restricted loader environment cannot perform Running’s app-host request.**
+
+ **Perf-2 Task 11** removes `instanceFetcher`’s cache and moves `instances.Report` into `viewGet`, while retaining its configured client, scheme, timeout and host-selection behavior. **Task 6’s** environment exposes only the object store, signing key, read time and DNS. Its restrictions prohibit passing the fetcher, client, method value or closure through loader arguments.
+
+ The existing fetch requires `f.client.Do`; the configured client also carries perf-1’s counting/fake transport. There is no permitted way to preserve that capability as written.
+
+ Specify an explicit app-host capability or separate report-cache boundary. Select the eligible host per request and include its identity in the cached report’s inputs/key.
+
+ Evidence: [restricted environment:253](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:253), [Task 11:458](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:458), [host selection:93](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/internal/console/instances.go:93), [HTTP call:130](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/internal/console/instances.go:130).
+
+4. **P2 — `TestViewLoadersAreRestricted` rejects types the plan requires caching.**
+
+ **Perf-2 Task 6** forbids interface fields in every loader argument/result type. However, Task 5 defines `boxSnapshot.Err error`, and Task 9 defines `appCore.ProductionErr error` and `PipelineErr error`. All three are interface fields, including when their values are nil. Both types are explicitly assigned to cached loaders, so the required reflection test cannot pass.
+
+ Define plain-data representations for these retained error states, preserving the existing partial-evidence/degraded-rendering semantics, or specify a narrowly justified exception and its checks.
+
+ Evidence: [restriction:255](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:255), [boxSnapshot:221](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:221), [appCore:404](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:404), [underlying completeness/error contract:224](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/internal/status/fleet.go:224).
+
+5. **P2 — Economics listens for a different deferred-part event payload.**
+
+ **Perf-2 Task 7** dispatches `detail: {part, root}`. **Operator Task 13** checks `e.detail.id === "econ-body"` and passes `e.detail` to the initializer. That condition is always false with the producer’s payload.
+
+ Consequently, a cold Economics fragment receives no input/change listeners. Editing pricing does not update the calculated values or serialized scenario field used by Save. The listener must inspect and pass `e.detail.root`; test it using the actual producer’s payload.
+
+ Evidence: [event producer:317](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-console-perf-2-fixes.md:317), [event consumer:697](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-operator-pages.md:697), [serialized field/listeners:403](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/internal/console/templates/economics.html:403).
+
+6. **P2 — Dashboard “Needs attention” can report healthy beside a Silent box.**
+
+ **Operator Task 9’s** `attentionInput` receives `Fleet` but no `HostRows`. Its box warnings therefore rely on `FleetBox.Stale`, recorded when the summary was built. The dashboard table separately uses request-time `HostRow.Stale`.
+
+ A summary built two minutes ago from a then-14-minute-old heartbeat remains a fresh summary, with `FleetBox.Stale=false`; the same heartbeat is now 16 minutes old and the table marks it Silent. With no other issue, the callout remains positive. A silent host present only in `HostRows` is also unavailable to `attentionItems`.
+
+ Derive the callout and table from the same box evidence, including after deferred box loading. This is required by spec §3.3’s silent/stale-box attention item.
+
+ Evidence: [attention input:584](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-operator-pages.md:584), [dashboard rows:587](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-operator-pages.md:587), [merge-time stale flag:171](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/internal/status/fleet.go:171), [request-time stale flag:878](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/internal/console/view.go:878), [spec:385](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/specs/2026-10-25-console-ux-perf-design.md:385).
+
+7. **P2 — The new query-plan oracle rejects legitimate required queries.**
+
+ **Operator Task 4** permits `users`, `sessions` and `audit` only under indexed `SEARCH`, except two named cases. Required queries outside those exceptions naturally scan:
+
+ - Total people: `COUNT(*) FROM users` scans a covering index.
+ - Newest people: ordered traversal scans `users_by_created`.
+ - Unfiltered first Activity page: descending primary-key traversal is `SCAN audit`, stopping at `LIMIT`.
+
+ An in-memory SQLite check confirmed these shapes. They would fail the specified gate despite being appropriate queries. Also, dropping `sessions_by_time` cannot restore the claimed “old CORRELATED SCALAR SUBQUERY”: the replacement UNION SQL contains no correlation.
+
+ Make assertions specific to each query’s intended access pattern, allowing bounded ordered scans and total-count scans; retain the scale witness.
+
+ Evidence: [oracle:383](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-operator-pages.md:383), [required query contracts:371](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/docs/superpowers/plans/2026-10-25-operator-pages.md:371), [users schema:153](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/internal/console/store.go:153), [audit schema:179](/home/paulca/amadan.net/carlos/platform/.claude/worktrees/console-ux-perf/internal/console/store.go:179).
+
+Read-only review; working tree unchanged. No repository tests run. Rastrillo’s pinned tag and all six hashes match local upstream; its licence is MPL-2.0.
\ No newline at end of file