Repository navigation
fix: handle an empty Scorecard catalog - #142
Conversation
Show a catalog link before rendering metrics when there are no entities to score. Cover empty, populated, filtered, loading and failure states. Co-authored-by: OpenAI Codex <noreply@openai.com>
|
Revalidated commit 961a9a6 in the next scheduled run. Rebase against origin/main was a no-op. No code changes were needed.
Inspected both committed screenshots linked in the PR body. The prior browser capture succeeded and remains valid for this unchanged commit; no new capture was needed. Confirmed that CI run 43593597411 passed install, lint, test and Docker build on this exact commit. The dependency setup attempt initially overlapped an install and the early local checks failed on missing install state; a single completed install and fresh lint/test runs resolved that local setup error. Ready to merge as the existing Scorecard slice. Part of #85; the parent stays open. |
Scorecard now shows a clear empty-catalog notice and a link to browse the catalog when there are no components, APIs or systems to score. It avoids rendering invalid averages and charts, while preserving populated results, unmatched filters, loading and catalog errors.
Part of #85. Closes #141. The parent epic remains open.
Verified locally through the repository tasks.
mise run installpassed with existing peer dependency warnings.mise run lintpassed, including TypeScript and ESLint across all workspaces.mise run test --runInBand --verbosepassed with 55 tests in nine suites. One existing test and suite remain skipped. Jest emitted CSS parsing and React deprecation warnings.BROWSER=none mise run devcompiled successfully and served the frontend on localhost:3000 and backend on localhost:7007.mise run proof-browser -- open about:blank --browser=chrome, thenmise run proof-browser -- goto http://localhost:3000/scorecardand Guest > Enter, rendered the real catalog with 22 scored entities.mise run proof-browser -- resize 1440 1000andmise run proof-browser -- screenshot --filename=.tmp/proof/issue-141-scorecard-populated.png --full-pagecaptured the populated page.mise run proof-browser -- route 'http://localhost:7007/api/catalog/entities?filter=kind%3Dcomponent&filter=kind%3Dapi&filter=kind%3Dsystem' --body='[]' --content-type=application/json, thenmise run proof-browser -- reload, exercised the empty result through the running app. Only that catalog request was intercepted in the proof browser; the development catalog was preserved.mise run proof-browser -- screenshot --filename=.tmp/proof/issue-141-scorecard-empty.png --full-pagecaptured the changed surface. Both screenshots were visually inspected. Clicking Browse the catalog opened the catalog successfully.proof-browserwas a temporary local mise task wrapping the installed Playwright CLI. It was removed after capture. The commands usedMISE_TRUSTED_CONFIG_PATHSfor this worktree. This frontend-only slice does not require a Docker image build.The five new component tests passed using the actual Scorecard and metrics components.
Browser capture succeeded. No capture method was blocked and no evidence fallback was needed. The proof images are committed and pinned to the reviewed commit.
The empty state uses the empty response described above.
The populated state uses the real local sample catalog.
Scoring rules and filters are unchanged. Runtime logs still show a Signals websocket 404 and unavailable TechDocs search indexes, also recorded on earlier PRs. These did not block Scorecard rendering and remain follow-up work outside this slice.