1
0
Fork 0

docs: add OpenChamber browser tab hygiene guidance to agent protocol

This commit is contained in:
Jason Fraley 2026-10-05 12:40:47 -04:00
parent d21b36612f
commit 76ca0e1d72

View file

@ -56,6 +56,7 @@ Known pre-existing errors (not yours, don't widen scope to fix them): `src/colle
- If the user says **no**, do **not** start a dev server and do **not** attempt to verify via E2E or Playwright — the user will run the app and test themselves, then report back.
- Stale dev processes: killing the process is not always enough; remove `.next/dev/devserver.lock` before restarting.
- For browser/UI verification, make a reasonable attempt with Playwright. If the browser tooling is unavailable or repeatedly unreliable, stop rather than spending excessive effort on it and defer the manual UI check to the user.
- **Browser tool tab hygiene (OpenChamber)**: when driving the in-app browser, reuse a SINGLE tab. Call `browser.open` once to obtain a `tabId`, then pass that same `tabId` to every subsequent `browser.open` / `browser.snapshot` / `browser.click` / `browser.type` / `browser.capture` / `browser.inspect` call. Calling `browser.open` without a `tabId` opens a NEW tab every time and litters the panel; the tool has no close-tab action, so minimize new tabs by reusing one (re-read the tab list from a snapshot when a `tabId` goes stale, and reuse the matching existing tab rather than opening another).
## Agent debugging SOP (read before fixing any bug)