Skip to content

Insights: fix running-now window bug, frozen elapsed label, undisclosed run cap - #272

Merged
TheGreatAxios merged 2 commits into
mainfrom
cl-insights-fixes
Aug 21, 2026
Merged

Insights: fix running-now window bug, frozen elapsed label, undisclosed run cap#272
TheGreatAxios merged 2 commits into
mainfrom
cl-insights-fixes

Conversation

@TheGreatAxios

Copy link
Copy Markdown
Contributor

Summary

  • "Running now" (KPI tile + strip) no longer reads off the 7-day range-filtered run set — a run that started before the window and is still running now stays visible and counted, since liveness is not a windowed property.
  • The elapsed label next to the strip's pulsing live status dot now ticks once a second while a run is running, instead of freezing at whatever instant it last rendered for an unrelated reason.
  • The landing view now discloses when the runs feed's fixed limit=100 fetch truncates the runs backing its KPIs, sparkline, and outcome chart — matching the disclosure InsightsRunsHistory already gives on its own view.

Known, deliberate gap (not touched here): the mock's "Recommendations" rail stays unbuilt — no backing signal exists yet (credential-expiry, skill-regression, model-fit data), so nothing was fabricated.

Fixes CL-6559.

Test plan

  • bun test on the insights page suites (src/pages/insights-page.test.ts, src/pages/insights-page-render.test.tsx, test/insights-page.test.tsx, src/insights-stats.test.ts, src/pages/run-status-tone-parity.test.ts) — 78 pass
  • bun run typecheck in apps/web — clean
  • Confirmed all three new tests fail without the fix (red) and pass with it (green)
  • Checked the owner's local Postgres workflow_run/inference_turn data directly — small dataset (20 runs, 4 running) so the 100-run truncation doesn't currently reproduce there, but the fix is correct at scale

…, and run-cap disclosure

Covers three Insights defects: a run started before the 7-day window but
still running must stay in the "Running now" strip and KPI; the elapsed
label next to the live status dot must tick instead of freezing at first
render; and the landing view must disclose when the 100-run fetch cap
truncates the runs backing its KPIs, sparkline, and outcome chart.
… label, disclose the run-fetch cap

Three fixes to the landing dashboard:
- "Running now" (both the KPI tile and the strip) now reads off every
  fetched run rather than the range-filtered subset, since being in
  flight is not a windowed property — a run that started before the
  7-day window and is still running no longer disappears or reads 0.
- The elapsed label beside the pulsing live status dot now ticks once a
  second while a run is running, instead of freezing at whatever instant
  the strip last rendered for an unrelated reason.
- The landing now discloses when the feed's fixed limit=100 fetch caps
  the runs backing its KPIs, sparkline, and outcome chart, matching the
  disclosure InsightsRunsHistory already gives on its own view.
@TheGreatAxios
TheGreatAxios merged commit fc33c9e into main Aug 21, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant