Skip to content

feat: minimal panel by default + start the dashboard from the UI (v0.4.0)#11

Merged
mabry1985 merged 2 commits into
mainfrom
feat/minimal-default-and-ui-dashboard-control
Jun 16, 2026
Merged

feat: minimal panel by default + start the dashboard from the UI (v0.4.0)#11
mabry1985 merged 2 commits into
mainfrom
feat/minimal-default-and-ui-dashboard-control

Conversation

@mabry1985

Copy link
Copy Markdown
Contributor

Fixes the blank Browser panel and lets you start the dashboard from the UI (no terminal) — both reported.

Why it was blank (reproduced with the installed binary, v0.27.1)

Full mode iframes agent-browser's dashboard through our sub-path reverse proxy (/plugins/agent_browser/panel/dash/). But that dashboard is a Next.js app whose assets are root-absolute (/_next/static/..., /favicon.ico). The browser resolves those against the console root, which we don't proxy → every chunk 404s → the app never hydrates → blank. The dashboard only supports being proxied at a distinct origin (its --help: "a proxied/forwarded URL such as dashboard.agent-browser.localhost") — never a sub-path, and there's no base-path flag. So our proxy embed can't be fixed cleanly.

The fix

  • Default panel_modeminimal — a live screenshot + nav toolbar through the gated same-origin routes. No dashboard, no daemon, no proxy; works on host and member. Verified e2e against the real binary (typed example.com → Go → a live 1280px frame rendered in the panel).
  • Dashboard control in the UI (both modes) — a status dot + Start / Stop, gated GET/POST /api/plugins/agent_browser/dashboard. Start it up entirely from the panel. Verified e2e (status → start → running → stop → stopped). Status is a live loopback probe (there's no dashboard status CLI subcommand).
  • Full mode is honest — keeps the embed but explains the blank and links out to the dashboard's own origin ("open directly ↗"), which works on a local/host setup; the port is interpolated into the page.

No change to the browser tools. Tests +2 (dashboard control endpoint, default-mode), updated panel assertions — 20 tests, ruff clean.

🤖 Generated with Claude Code

…4.0)

Fixes the long-standing blank Browser panel and lets you manage the dashboard without a terminal.

Root cause of the blank panel: full mode iframes agent-browser's dashboard through our sub-path
reverse proxy, but that dashboard is a Next.js app whose assets are ROOT-ABSOLUTE (/_next/...,
/favicon.ico). Served at /plugins/agent_browser/panel/dash/, the browser then fetches /_next/...
at the console root — which we don't proxy → every chunk 404s → blank. The dashboard only supports
being proxied at a distinct ORIGIN (its --help: "a proxied/forwarded URL such as
dashboard.agent-browser.localhost"), never a sub-path; there's no base-path flag. Unfixable cleanly
from our side. (Reproduced with the installed binary, v0.27.1.)

Fix:
- **Default panel_mode → minimal**: a live screenshot + nav toolbar through the gated same-origin
  routes. Works everywhere (host + member), no dashboard/daemon/proxy needed. Verified e2e against
  the real binary (navigated example.com → a live 1280px frame rendered in the panel).
- **Dashboard control in the UI** (both modes): a status dot + Start/Stop, gated
  GET/POST /api/plugins/agent_browser/dashboard. Start it up entirely from the panel — verified e2e
  (status→start→running→stop). Status is a live loopback probe (there's no `dashboard status` CLI).
- **Full mode is honest now**: keeps the embed but explains the blank ("can't load through a
  sub-path proxy") and links out to the dashboard's own origin ("open directly ↗"), which works
  on a local/host setup. The port is interpolated into the page.

Tests +2 (dashboard control endpoint, default-mode), updated panel-page assertions. 20 tests, ruff
clean. No change to the browser tools.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@protoquinn

protoquinn Bot commented Jun 16, 2026

Copy link
Copy Markdown

👀 Quinn is reviewing — verdict (PASS / WARN / FAIL) + findings to follow.

@protoquinn protoquinn Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

QA Audit — PR #11 | feat: minimal panel by default + start the dashboard from the UI (v0.4.0)

VERDICT: WARN (non-blocking — CI still queued; formal PASS/FAIL on re-dispatch)


CI Status

  • test: queued

Diff Review

  • Default panel_modeminimal fixes the long-standing blank panel (Next.js root-absolute assets can't resolve through sub-path proxy). Solid root-cause analysis.
  • New GET/POST /api/plugins/agent_browser/dashboard endpoints: live loopback probe + start/stop subprocess. Gated under plugin-data router — safe.
  • __DASH_PORT__ server-side injection into page HTML is clean — no extra API roundtrip needed.
  • Both panel modes now surface dashboard status + control. Full mode explains the blank and links out to dashboard origin.

Observations

  • LOW: clawpatch unavailable — repo not in project registry. Review limited to diff analysis.
  • LOW: CI (test) still queued — formal verdict deferred until checks terminal.
  • MEDIUM: dashAct("start") in both panel pages has no guard against double-clicks — two rapid starts could spawn duplicate daemon processes. The UI shows "…" but the button remains clickable. Consider a busy flag (the existing go() handler already has this pattern at line ~395).
  • Observation: page.replace("__DASH_PORT__", str(port)) runs against the minimal page too (no-op since no placeholder there). Harmless but slight waste — could gate on mode == "full".
  • Positive: all error paths degrade gracefully (null render on fetch failure, caught exceptions in status probe). Subprocess calls use asyncio.to_thread — consistent with existing nav actions.

— Quinn, QA Engineer

@protoquinn

protoquinn Bot commented Jun 16, 2026

Copy link
Copy Markdown

Submitted COMMENT review on #11.

…se proxy

Per the design call (minimal is the real panel; full is an honest launcher): full mode no
longer ships a blank/half-rendered proxy iframe. It's now a launcher card — "Open dashboard ↗"
(the dashboard's own origin, which is the only place its root-absolute Next.js assets load) +
the Start/Stop control + a pointer to minimal mode.

Removes the now-dead sub-path reverse proxy (HTTP + WebSocket /panel/dash) that could never
serve the dashboard's assets, plus its unused imports (Request/WebSocket/StreamingResponse) and
the 502 test. Also fixes a stale code-level default (build_panel_router defaulted panel_mode to
"full" while the manifest defaults to "minimal").

Launcher render verified headless (card + Open-↗ to the real origin + Start control, no errors).
19 tests, ruff clean.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

@protoquinn protoquinn Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

CI terminal-green, no blockers on prior review — auto-approving on green (#748).

@protoquinn protoquinn Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

QA Audit — PR #11 | feat: minimal panel by default + start the dashboard from the UI (v0.4.0)

VERDICT: WARN (CI queued — non-terminal; re-review on green)


CI Status

  • test: queued ⏳

Diff Review (first 200 of 608 lines visible)

  • ✅ Default panel_modeminimal — correct fix for the blank-panel root cause (Next.js root-absolute assets can't resolve under a sub-path reverse proxy)
  • ✅ Removed the entire /panel/dash HTTP+WS reverse proxy — dead code that could never work; removal is clean
  • ✅ Import cleanup mirrors the proxy removal (Request, WebSocket, StreamingResponse dropped)
  • ✅ CHANGELOG + README updated with honest explanation of the full mode limitation

Observations

  • GAP/MEDIUM: Diff truncated at 200/608 lines — the dashboard control endpoint implementation (POST /api/plugins/agent_browser/dashboard), the _FULL_PAGE template, and test changes are beyond the visible prefix. Can't verify the new endpoint's error handling, loopback probe logic, or that the port interpolation in _FULL_PAGE uses the configured dashboard_port.
  • LOW: Clawpatch structural review unavailable — repo not in project registry. Diff-based review only.
  • No unresolved CodeRabbit threads.

The architectural direction is sound. Re-review on CI green to confirm tests pass and to assess the unseen 408 lines.

— Quinn, QA Engineer

@protoquinn

protoquinn Bot commented Jun 16, 2026

Copy link
Copy Markdown

Submitted COMMENT review on protoLabsAI/agent-browser-plugin#11.

@mabry1985 mabry1985 merged commit 3f69efd into main Jun 16, 2026
1 check passed
@mabry1985 mabry1985 deleted the feat/minimal-default-and-ui-dashboard-control branch June 16, 2026 02:29
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