Skip to content

feat(ui): Explorer interactivity — Model Runs & Jobs detail views, comparison, verify, sorting (PRP-21)#190

Merged
w7-mgfcode merged 6 commits into
devfrom
feat/explorer-runs-jobs-interactivity
May 18, 2026
Merged

feat(ui): Explorer interactivity — Model Runs & Jobs detail views, comparison, verify, sorting (PRP-21)#190
w7-mgfcode merged 6 commits into
devfrom
feat/explorer-runs-jobs-interactivity

Conversation

@w7-mgfcode
Copy link
Copy Markdown
Owner

Summary

Implements PRP-21 — extends the Model Runs and Jobs Explorer pages
from flat, read-only tables into an interactive investigation surface, the
direct sibling of PRP-20 (#187) applied to the registry and jobs slices.

Closes #189.

Backend (additive — no migration, no new slice, no app/main.py change)

  • GET /registry/runs gains optional sort_by + sort_order query params.
  • GET /jobs gains the identical params.
  • Both resolve sort_by through an allow-list dict to a real mapped column
    (security-patterns.md — never raw SQL); an unknown sort_by falls back to
    the prior created_at desc default rather than erroring; sort_order outside
    {asc,desc} is rejected 422 via the Query regex.

Frontend

  • Three new deep-linkable routes: /explorer/runs/:runId,
    /explorer/jobs/:jobId, /explorer/runs/compare?a=&b=.
  • Run detail — profile, JSON config/metrics/runtime info, store/product
    cross-links, and a SHA-256 artifact "Verify integrity" action.
  • Job detail — profile, params/result JSON, error details, linked run, cancel
    action; live-polls while running.
  • Run comparison — two run pickers, side-by-side profile, config_diff, and
    metrics_diff with neutral ▲/▼ delta indicators.
  • Both tables — server-side column sorting, row-click navigation, and
    URL-persisted filter/sort/page state; the Jobs table also gains CSV export +
    column-visibility (Runs already had them).
  • New: useVerifyArtifact hook, JsonBlock component, ArtifactVerifyResponse
    type; sortBy/sortOrder threaded into useRuns/useJobs.

Tests

  • New registry integration tests for sort + unknown-fallback + 422.
  • New jobs DB test infrastructure (db_session/client/sample_jobs_multi)
    and a first jobs/tests/test_routes.py — closes the jobs slice's route-test gap.

Validation

  • ruff check / ruff format --check / mypy --strict / pyright --strict — clean.
  • pytest -m "not integration" — 1101 passed.
  • Registry + jobs integration sort tests — 15 new tests pass.
  • tsc --noEmit / eslint / vitest — clean (27 frontend tests pass).
  • Dogfooded in a real browser — 15/15 UI scenarios pass, zero console errors
    (run/job detail, verify, compare, sorting, URL round-trip).

Notes

  • No Alembic migration — sorting is a read-only ORDER BY change.
  • The pre-existing test_list_runs_empty integration test assumes an empty DB
    and fails on a stale local Postgres with leftover demo runs; it passes on the
    fresh DB CI provisions. Unrelated to this PR.

Copy link
Copy Markdown

@sourcery-ai sourcery-ai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry @w7-mgfcode, you have reached your weekly rate limit of 500000 diff characters.

Please try again later or upgrade to continue using Sourcery

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 18, 2026

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: d50d78ec-cb15-41ac-84a9-cd3438149c94

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/explorer-runs-jobs-interactivity

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@w7-mgfcode w7-mgfcode merged commit 39dc0a3 into dev May 18, 2026
8 checks passed
@w7-mgfcode w7-mgfcode deleted the feat/explorer-runs-jobs-interactivity branch May 18, 2026 19:58
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