Skip to content

fix(web): keep dashboard on published swissd APIs - #57

Merged
imneov merged 1 commit into
mainfrom
fix/dashboard-current-swiss-apis
Oct 12, 2026
Merged

imneov merged 1 commit into
mainfrom
fix/dashboard-current-swiss-apis

Conversation

@imneov

@imneov imneov commented Oct 12, 2026

Copy link
Copy Markdown
Contributor

What type of PR is this?

  • bug fix
  • documentation

What this PR does and why

Keep the current Console dashboard independent of unmerged swissd work.

The deployment activity reader previously tried /api/runs/timeline before falling back to the published run log. The timeline endpoint is only an unmerged local backend prototype, so probing it violated the agreed delivery boundary: implement the Console dashboard using existing backend capabilities first, then review future backend metrics separately.

This patch:

  • Reads only the published /api/runs?limit=500 endpoint and aggregates the returned audit records on the client.
  • Removes the speculative endpoint call and special handling of its unsupported-route errors.
  • Preserves the existing integrity rules: a response reaching the history cap is incomplete, no persistence is not a zero curve, and real HTTP failures are not hidden by another request.
  • Rejects malformed run-log responses and tests that each read issues exactly one request to the existing endpoint.
  • Updates the design documentation to distinguish current frontend capabilities from future backend work.

No swissd changes, restart, or unreleased endpoint are required for this Console patch. Full server-side aggregation and runtime serving metrics remain separate work.

Which issue(s) this PR fixes

Refs #55 and modelsphere/swiss#19 for the agreed frontend/backend delivery boundary.

Corrects the optional unmerged endpoint probe introduced in the dashboard implementation, #54. It does not implement or close either serving-metrics issue.

How it was tested

  • npm run typecheck: passed for Console and Swiss standalone configurations.
  • npm test: 31 files, 272 tests passed.
  • npm run build: passed; the existing large-chunk warning remains.
  • Regression tests assert the exact published endpoint, a single request, timestamp aggregation, empty persisted history, missing persistence, capped history, malformed responses, and HTTP 400/403/404/500/503 failures.
  • No layout or styling changes.

Checks

  • npm run typecheck && npm test && npm run build in web/
  • Documentation updated
  • No internal hostnames, IPs, registries or credentials added
  • Go and chart checks are not applicable: this patch only changes frontend API reading, its tests, and documentation.

Notes for reviewers

Start with web/src/modules/inferences/dashboard-api.ts and its regression tests. The existing 500-row limit means high-volume or long histories may still be incomplete; the UI explicitly reports that limitation instead of inventing a complete curve.

The local swissd timeline prototype is intentionally not submitted or consumed by this PR. This draft is for user review and should not be merged automatically.

Release note

The home dashboard deployment chart now uses only the existing swissd run-log API and no longer probes an unmerged backend endpoint.

Read the existing run log directly instead of probing the unmerged timeline prototype. Preserve unknown history and capped-response handling, and require one published API request in regression tests. Server-side aggregation and serving metrics remain separate backend work.

Refs #55
@imneov
imneov marked this pull request as ready for review October 12, 2026 17:30
@imneov
imneov merged commit 6af6dc6 into main Oct 12, 2026
4 checks passed
@imneov
imneov deleted the fix/dashboard-current-swiss-apis branch October 12, 2026 17:30
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