feat(browse): drive Zen over WebDriver BiDi; release v0.2.0 #115

Merged
john merged 1 commit from feat/browse-zen-0.2.0 into main 2026-11-28 11:01:36 +00:00
Owner

John 2026-11-28: original Zen and Chromium are agent-ready; release as minor 0.2.0.

Depends on john/browse #21 being released first.

  • Zen driven over WebDriver BiDi via Playwright's in-process BiDi Firefox (no public attach API in 1.65), adopting open tabs.
  • Protocol per session from the gateway; non-owned / non-capable sessions refused before any worker.
  • dev.11 fixes folded in: f1e9 refs accepted; browse_browsers returns an object.
  • Version 0.2.0 (stable → :latest). Note: managed Compose still follows :dev; see the PR thread for the follow-up.

602 tests pass locally with real Chromium + Firefox.

John 2026-11-28: original Zen and Chromium are agent-ready; release as minor **0.2.0**. Depends on john/browse #21 being released first. - Zen driven over WebDriver BiDi via Playwright's in-process BiDi Firefox (no public attach API in 1.65), adopting open tabs. - Protocol per session from the gateway; non-owned / non-capable sessions refused before any worker. - dev.11 fixes folded in: `f1e9` refs accepted; `browse_browsers` returns an object. - Version **0.2.0** (stable → `:latest`). Note: managed Compose still follows `:dev`; see the PR thread for the follow-up. 602 tests pass locally with real Chromium + Firefox.
feat(browse): drive Zen over WebDriver BiDi; release v0.2.0
All checks were successful
Corn CI / host (pull_request) Successful in 14s
Corn CI / release-check-1 (pull_request) Successful in 15s
Corn CI / release-check (pull_request) Successful in 0s
Security / scan (pull_request) Successful in 32s
Security / security (pull_request) Successful in 0s
Corn CI / test (pull_request) Successful in 2m41s
Corn CI / release (pull_request) Has been skipped
Review / change impact (pull_request_target) Successful in 3m7s
4bd7a02059
- Worker: sessions whose browser speaks BiDi (Zen/Firefox) are driven with
  the normal Playwright API: for that one connection the firefox
  BrowserType's connectOverCDP is backed by Playwright's in-process BiDi
  Firefox over the gateway WebSocket. A small transport shim adopts the
  user's open tabs (answers the first browsingContext.create with the
  existing tab after replaying contexts and script realms).
- BrowseService.act asks the gateway (with the user's key) for the
  session's protocol and refuses sessions that are not the user's or not
  Playwright-capable before starting a worker.
- From the first live run (dev.11 notes folded in): frame-prefixed refs
  (f1e9) accepted; browse_browsers returns {"browsers": [...]}.
- Version 0.2.0 (stable, :latest), release notes deploy/releases/0.2.0.md.

Tests: 602 pass with a real Chromium and a real Firefox 161 (as Zen)
behind a copy of the gateway: tabs adopted, snapshot, click, type,
screenshot, repeated calls after Firefox's sticky BiDi session.

Change review · e10c261bcd88 → 4bd7a02059f6

Call paths changed by this PR

Caller → changed symbol → callee. Each edge labels the line in the caller. One detected entry path (up to 3 hops) is included when found. Static evidence, not a runtime stack trace.

After

flowchart LR
    n0["BrowseService.act - modified"]
    n1["register - modified"]
    n2["test_mcp_tools_need_a_user_and_validate_inputs"]
    n3["register._locals_.browse_browsers - modified"]
    n4["register._locals_.browse_browsers._locals_.go - added"]
    n5["register._locals_.browse_snapshot - modified"]
    n6["protocol - added"]
    n7["Handler.websocket"]
    n8["launch"]
    n9["sessions"]
    n7 -->|L425| n6
    n8 -->|L356| n6
    n9 -->|L332| n6
    n2 -->|L197| n1

Changed symbols:

  • modified BrowseService.act — src/corn/integrations/browse.py:260
  • modified register — src/corn/integrations/browse.py:277
  • modified register._locals_.browse_browsers — src/corn/integrations/browse.py:291
  • added register._locals_.browse_browsers._locals_.go — src/corn/integrations/browse.py:293
  • modified register._locals_.browse_snapshot — src/corn/integrations/browse.py:320
  • added protocol — tests/fixtures/cdp_gateway_reference.py:258
    Bounded view: 43 more changed symbols and 0 neighbour references omitted.
Overall architecture after this change

Source: 4bd7a02059f6 · code-review 0.1.0-dev.1.

Generated from resolved static calls between reviewed code areas. Numbers are call sites, not request counts.
Framework registration, dynamic dispatch, and unresolved calls are not shown. This is not a deployment map.
Showing 7 of 7 inter-area edges. Edit the reviewed source instead of this generated page.

flowchart LR
    n1["Console"]
    n2["Identity"]
    n3["Linked MCP"]
    n4["NSW integrations"]
    n5["Persistence"]
    n6["REST handlers"]
    n7["Server composition"]
    n8["Shared contracts"]
    n9["Shopping"]
    n5 -->|"9"| n2
    n7 -->|"5"| n6
    n7 -->|"2"| n8
    n1 -->|"1"| n4
    n1 -->|"1"| n9
    n3 -->|"1"| n2
    n7 -->|"1"| n2

This diagram is for the linked commit. It refreshes after required checks pass for a new head.

<!-- john/release:architecture-review:v1 --> # Change review · `e10c261bcd88` → [`4bd7a02059f6`](https://code.yawn.dev/john/corn/commit/4bd7a02059f6fd878ca8a5e85238ea53cbe74a5a) ## Call paths changed by this PR Caller → changed symbol → callee. Each edge labels the line in the caller. One detected entry path (up to 3 hops) is included when found. Static evidence, not a runtime stack trace. ### After ```mermaid flowchart LR n0["BrowseService.act - modified"] n1["register - modified"] n2["test_mcp_tools_need_a_user_and_validate_inputs"] n3["register._locals_.browse_browsers - modified"] n4["register._locals_.browse_browsers._locals_.go - added"] n5["register._locals_.browse_snapshot - modified"] n6["protocol - added"] n7["Handler.websocket"] n8["launch"] n9["sessions"] n7 -->|L425| n6 n8 -->|L356| n6 n9 -->|L332| n6 n2 -->|L197| n1 ``` Changed symbols: - **modified** `BrowseService.act` — `src/corn/integrations/browse.py:260` - **modified** `register` — `src/corn/integrations/browse.py:277` - **modified** `register._locals_.browse_browsers` — `src/corn/integrations/browse.py:291` - **added** `register._locals_.browse_browsers._locals_.go` — `src/corn/integrations/browse.py:293` - **modified** `register._locals_.browse_snapshot` — `src/corn/integrations/browse.py:320` - **added** `protocol` — `tests/fixtures/cdp_gateway_reference.py:258` Bounded view: 43 more changed symbols and 0 neighbour references omitted. <details><summary>Overall architecture after this change</summary> Source: [4bd7a02059f6](https://code.yawn.dev/john/corn/commit/4bd7a02059f6fd878ca8a5e85238ea53cbe74a5a) · `code-review 0.1.0-dev.1`. Generated from resolved static calls between reviewed code areas. Numbers are call sites, not request counts. Framework registration, dynamic dispatch, and unresolved calls are not shown. This is not a deployment map. Showing 7 of 7 inter-area edges. Edit the reviewed source instead of this generated page. ```mermaid flowchart LR n1["Console"] n2["Identity"] n3["Linked MCP"] n4["NSW integrations"] n5["Persistence"] n6["REST handlers"] n7["Server composition"] n8["Shared contracts"] n9["Shopping"] n5 -->|"9"| n2 n7 -->|"5"| n6 n7 -->|"2"| n8 n1 -->|"1"| n4 n1 -->|"1"| n9 n3 -->|"1"| n2 n7 -->|"1"| n2 ``` </details> This diagram is for the linked commit. It refreshes after required checks pass for a new head.
john merged commit 336538aea5 into main 2026-11-28 11:01:36 +00:00
john deleted branch feat/browse-zen-0.2.0 2026-11-28 11:01:36 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
john/corn!115
No description provided.