Add the Consort live dashboard (apps/dashboard) + fix the DriftBanner false-alarm - #190
Conversation
Adds the Next.js live/replay observability dashboard under apps/dashboard/ so it lives alongside the framework it observes. It complements (does not replace) the VS Code Consort extension: the extension is the in-editor viewer, this is the standalone web board for a live run or a recorded replay corpus. Self-contained: it keeps its own package.json / lockfile / build / test and is NOT wired into the root tsup build (consort is not an npm-workspaces monorepo). The only root-level change is excluding apps/dashboard from the root tsconfig "include" (apps/**/*.ts) so `npm run typecheck` / CI does not pull the app's Next.js/React sources into the substrate program. Root vitest (tests/** only) and the explicit tsup entry list are already unaffected. Co-authored-by: Isaac <no-reply@databricks.com>
On a live run the DriftBanner sometimes rendered a critical-red banner next to
the orchestrator, so viewers read it as "the orchestrator/run is failing". It is
only an observability signal: the dashboard cannot cleanly PAIR the run to a
recorded corpus. It says nothing about the run, the build, the deploy, or the
telemetry ingest.
Two changes, per the report:
1. Distinguish benign caveats from genuine drift. New driftSeverity() in
correlate.ts classifies an unhealthy report:
- warning: a role the corpus never recorded => the RECORD_DIR likely points
at a DIFFERENT run. The one case worth flagging prominently.
- info: a kit-version mismatch (expected-with-caveat) or a plain log-ahead
tail (the normal live edge). A quiet note.
The "no companion / healthy" case already produced no banner and is unchanged.
Threaded through the correlation summary (new `severity` field on the type,
set by both the live and replay sources).
2. Downgrade severity + reword. The banner no longer uses --status-critical.
A warning renders amber (role="alert"); an info renders as a quiet muted note
(role="note"). Both attribute explicitly to pairing and add "Turn drill-downs
may be approximate; the run itself is unaffected."
Tests: render.test.tsx DriftBanner cases rewritten for info vs warning; driftSeverity
covered in correlate.test.ts. 400 pass, tsc clean.
Co-authored-by: Isaac <no-reply@databricks.com>
…istry The vendored package-lock.json resolved 144 packages from the internal npm-proxy.cloud.databricks.com, which fails the lockfile-public-registry guard and would hang `npm install` off the Databricks network. Rewrite the resolved host to registry.npmjs.org (integrity hashes unchanged). Root suite green (4373).
|
Reviewed end-to-end and pushed one fix to this branch before merge. Fix ( Verification: full root suite green (4373 passed, 0 failed); the guard now passes. Review notes: integration is minimal and clean (one The three known dashboard follow-ups ( |
What this does
Two commits:
feat(dashboard): vendor the Consort live dashboard asapps/dashboard. The Next.js live/replay observability board that watches a Consort run (or replays a recorded corpus), now living alongside the framework it observes. It complements — does not replace — the VS Code Consort extension: the extension is the in-editor viewer; this is the standalone web board.package.json/ lockfile / build / test; not wired into the roottsupbuild (consort isn't an npm-workspaces monorepo). The only root change is excludingapps/dashboardfrom the roottsconfiginclude(apps/**/*.ts) sonpm run typecheck/ CI doesn't pull the app's Next.js/React sources into the substrate program. Root vitest (tests/**only) and the explicit tsup entry list are unaffected. Verified: the root program resolvesapps/mcp-server+dev-playgroundbut zeroapps/dashboardfiles.fix(dashboard): DriftBanner attributes to corpus pairing, not run health. On a live run the DriftBanner sometimes rendered a critical-red banner next to the orchestrator, so viewers read it as "the run is failing". It's only an observability signal — the dashboard can't cleanly pair the run to a recorded corpus — and says nothing about the run/build/deploy/telemetry. Per the report:driftSeverity():warning= a role the corpus never recorded (theRECORD_DIRlikely points at a different run — worth flagging);info= a kit-version mismatch or a plain log-ahead tail (the normal live edge — quiet). The healthy/no-companion case still shows no banner.--status-critical:warningrenders amber (role="alert"),inforenders as a quiet muted note (role="note"), both attributing explicitly to pairing.Verification
apps/dashboard:npx tsc --noEmitclean, 401 tests pass (npx vitest run)./review); its one finding against this change (a live-edge false-positive where severity was derived from the stricterreport.healthy) is fixed in commit 2 with a regression test.Known follow-ups (pre-existing in the dashboard, not introduced here — will be separate PRs)
lib/reducer.ts: a divergent FeatureSwitcher pin at the live edge shows 0 stories for the pinned past feature (nopinnedDivergentstories-derivation path).app/AgentBubble.tsx: the "working {elapsed}" readout usesDate.now(), so on replay/scrub it shows an absurd elapsed value + a green "live" dot (the bubble never receivesatLive).app/usePolledState.ts: a non-2xx/api/state(500) is treated as a successful poll — no backoff, and "connected" is reported despite every response being an error.