fix: show roborev review costs#448
Conversation
Roborev jobs already expose priced token usage in the proxied job payload, but Middleman's Reviews table only showed timing and status columns. That made the cost visible in roborev's own TUI but not in the dashboard scan line. Add a Cost column that mirrors roborev's estimate format only when token_usage has has_cost=true and a numeric cost_usd value. Rows without a priced estimate keep a quiet placeholder so the column stays stable without implying an unpriced token count is a dollar cost.
|
I tried this out locally, works. |
roborev: Combined Review (
|
The CI lint job runs the workspace-wide Vite+ check, which also validates existing tracked frontend tests outside this feature's main diff. Two tests were not in the current formatter shape, causing the PR lint job to fail before the roborev cost change could be evaluated. Apply the formatter's mechanical line wrapping only, with no behavior changes.
roborev: Combined Review (
|
CI exposed two unrelated problems on this branch: frontend unit teardown could schedule inline diff annotation mounts while DiffFile was being destroyed, and golangci-lint flagged older test helper patterns already present in the tree. DiffFile now defers imperatively mounted annotation components until their host is connected and disables those deferred mounts during teardown, which prevents child onMount effects from running inside Svelte cleanup. The Go test fixtures also use the current go-github pointer helper and testify's float-aware assertion so the lint job can pass.
The deprecated go-github String helper was replaced with gh.Ptr to satisfy staticcheck, but the modernize linter still flags that shape. Use local fixture strings and take direct pointers, which matches the surrounding test setup and satisfies both lint rules.
roborev: Combined Review (
|
Firefox and WebKit CI were failing in existing browser-sensitive e2e paths after the cost-column work was otherwise green. The failed assertions depended on focus reporting and pointer hit-testing through shadow DOM and overlay-heavy controls, which can vary by browser while the user-visible workflows still work. Activate the resolved controls directly in the specs and keep the inline composer test focused on visibility, typing, save, and draft persistence instead of a transient focus state.
roborev: Combined Review (
|
Firefox CI still failed after the first cross-browser e2e cleanup because the virtualized file-tree scroll wrapper intercepted pointer clicks on visible tree items. The target buttons were present and stable, but Playwright could not deliver a pointer click through Firefox hit-testing. Use a shared helper to activate resolved file-tree items for navigation-oriented specs, while keeping the follow-up assertions on selected rows, visible target files, and rendered previews as the behavior checks.
roborev: Combined Review (
|
roborev-ci pointed out that the cost column was only covered by component and mocked workspace tests. That left the SQLite-backed roborev e2e path unpinned, even though that is where schema drift in token_usage would show up. Seed the deterministic top-row roborev job with cost-bearing token_usage and assert the Cost header/value in the full-stack roborev e2e spec. Local roborev e2e reached the daemon build/start path with the CI-pinned roborev ref, but stopped when Playwright tried to sudo-install host browser dependencies in this environment.
roborev: Combined Review (
|
~$x.xxand leaves--when cost data is missing or unpriced.