Skip to content

fix: consistent full-width dashboard errors, background failures as toasts - #172

Merged
devhims merged 3 commits into
mainfrom
fix/agent-run-error-layout
Oct 9, 2026
Merged

devhims merged 3 commits into
mainfrom
fix/agent-run-error-layout

Conversation

@devhims

@devhims devhims commented Oct 9, 2026

Copy link
Copy Markdown
Owner

Problem

Dashboard errors rendered inconsistently. The agent run failure was inset (the global .alert kept a 42px side margin) and split into a "This run failed" label column. Other pages mixed inline banners, bare text and a custom bottom-right box, including for background failures the user didn't trigger.

What changed

One error style. .alert.error, .trend-alert, .plan-error and .source-data-warning share a full-width banner that leads with a warning icon (added in CSS, so call sites need no markup). Retry actions sit on the right. The run failure drops its label, and screen readers still hear "Run failed."

Inline only for the user's own request. Background loads now report through the existing sonner toast (bottom-right) with a retry action, via a new useLoadErrorToast hook:

Toast (background) Inline (user's request)
Projects list, recent sources, credits Search and inspect, failed saves, comment pages
Session list, session load Prompt submit, run failure, answer warnings, run details, saved evidence, delete confirmation
Project sources Trend scan, AI plan
Billing, notification preferences (cards show a neutral "unavailable" line) Delete account
API key list (the duplicate in-list retry button is removed) API key create and revoke
Access check, sign-out (the custom box moves to sonner) Admin grant, trace inspector

Testing

  • npx tsc --noEmit in web
  • npm run test:agent:dashboard: 139 passed (assertions for errors that moved to toasts now use the existing [data-sonner-toast][data-type=error] locator)
  • Checked desktop and mobile in the dev dashboard against the e2e fixture API: run failure, search failure inline, projects and recent-sources failures as toasts, billing failure on Settings.

…ailures to toasts

Error banners span their section and lead with a warning icon instead of
labels like "This run failed". Errors from the user's own request stay
inline next to it. Failures of background loads (projects, recent sources,
credits, session lists, billing, preferences, API keys, access checks and
sign-out) now use the bottom-right toast with a retry action.
@vercel

vercel Bot commented Oct 9, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
video2ctx-web Ready Ready Preview Oct 9, 2026 9:56am UTC

Sonner dismisses a toast after its action runs. A retry that failed with
the same message left the error state unchanged, so the warning and its
retry button never returned. The retry action now keeps the toast, which
closes once the error clears. Monitors uses the same hook.
@devhims
devhims merged commit 687a134 into main Oct 9, 2026
10 checks passed
@devhims
devhims deleted the fix/agent-run-error-layout branch October 9, 2026 10:06

This branch was successfully deployed

1 active deployment
Preview — 381a84d1 Deployed Oct 9, 2026 by vercel[bot]
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