Skip to content

fix(web): launch Chromium with its sandbox on where it can start - #1621

Merged
okwasniewski merged 17 commits into
e2e-inc:mainfrom
Varshith-Kali:fix-1613-chromium-sandbox
Nov 20, 2026
Merged

okwasniewski merged 17 commits into
e2e-inc:mainfrom
Varshith-Kali:fix-1613-chromium-sandbox

Conversation

@Varshith-Kali

@Varshith-Kali Varshith-Kali commented Nov 7, 2026 •

Copy link
Copy Markdown
Contributor

Issue

Fixes #1613.

  • @e2e-dev/web launched Chromium without chromiumSandbox, so Playwright added --no-sandbox to every browser process.
  • The agent can follow the app to another origin, so a renderer exploit on a page it reaches ran unsandboxed as the user running e2e run.

What changed

  • A locally launched Chromium runs with its OS sandbox on by default on macOS and Windows.
  • On Linux the default stays off. The sandbox needs unprivileged user namespaces there, which root, most containers, and Ubuntu 23.10+ block, so on would fail the launch on most CI hosts.
  • web({ chromiumSandbox }) sets it either way: true on a Linux host that can sandbox, false elsewhere.
  • A sandbox that is on and cannot start fails with an ENGINE_FAILURE that names the option, in place of Playwright's launch call log.
  • connect, browser providers, Firefox and WebKit are untouched.
web({ chromiumSandbox: true }); // default: true on macOS and Windows, false on Linux
  • packages/web/src/browser-connection.ts: defaultChromiumSandbox(), and acquire takes an options object.
  • Docs: docs/reference/web.mdx, docs/security.mdx (plus ja and zh), SECURITY.md, the skill's setup.md.

Verified

Ran it locally: yes

  • testbed, e2e run tests/todos.e2e.ts on macOS, watching the Chromium the CLI spawned:
main this branch
browser process carries --no-sandbox default: no --no-sandbox, renderers start with --seatbelt-client; 7 passed
no option to change it web({ chromiumSandbox: false }): --no-sandbox is back; 7 passed
  • Web integration suite on macOS, now sandboxed by default: 484 passed, 1 skipped.
  • Not run: chromiumSandbox: true on a Linux host that allows user namespaces. Linux CI runs the default, which is the same launch as main.

@github-actions github-actions Bot added the size:L Up to 499 changed lines, not counting tests, fixtures, translated docs, or the lockfile label Nov 7, 2026

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

All reported issues were addressed across 48 files

Reply with feedback, questions, or to request a fix.

View guided diff | Re-trigger cubic

Comment thread SECURITY.md Resolved
Comment thread docs/reference/web.mdx Resolved

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

0 issues found across 5 files (changes from recent commits).

View guided diff | Re-trigger cubic

@Varshith-Kali

Copy link
Copy Markdown
Contributor Author

CI on 869b879: the check job failed on one testbed web test, tests/screenshot.e2e.ts > page screenshot > should work while navigating (ENGINE_FAILURE: screenshot failed because the execution context was destroyed by a navigation; 508 of 511 passed). This head is docs-only (SECURITY.md, reference page, skill reference, one JSDoc comment), so it cannot cause a screenshot race; it reads as a timing flake in that navigation test. A re-run of the check job should clear it.

@okwasniewski okwasniewski left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Automated review (agent-run triage).

Thanks, the code is correct and well tested:

  • One local launch path (browser-connection.ts:85-92), CDP attach/provider leases/smol take connect() and are untouched, Firefox/WebKit untouched.
  • Flag read from the run env (info.env), never process.env; option > env > default on.
  • Real launch on macOS: default has no --no-sandbox, E2E_CHROMIUM_SANDBOX=0 adds it. 50 integration tests pass sandboxed, 338 web unit tests pass.
  • 11 of 15 mutations killed (default flip, env drop, process.env read, precedence swap, chromium-only guard, validation, init resolution).

The blocker is what this does to users on Linux.

Must fix

  1. Docker/Linux CI users break after a patch bump. In the official mcr.microsoft.com/playwright:v1.65.0-noble image, a sandboxed launch fails both as root and as pwuser ("Chromium sandboxing failed!"); unsandboxed works. Same on ubuntu-2404 runners (the PR's own CI opt-outs show it), likely on most Linux containers. The changeset is a patch and says nothing about it. At minimum a minor bump with a line telling users to set E2E_CHROMIUM_SANDBOX=0.
  2. The failure is a raw Playwright error. It surfaces as ENGINE_FAILURE: browser launch failed: browserType.launch: Target page, context or browser has been closed ... Chromium sandboxing failed! plus a ~40-flag call log, and only hints at a chromiumSandbox: false option, never E2E_CHROMIUM_SANDBOX=0, which is what a CI user can actually use. Catch that one failure in acquireBrowser and throw an e2e error naming both opt-outs, without the call log.
  3. CI docs not updated. docs/ci/github-actions.mdx, the other docs/ci/*.mdx and docs/visual-testing.mdx don't mention the opt-out, and nobody has checked whether the documented ubuntu-latest recipe still launches.

Should fix (structure)

  • Parsing is split: readChromiumSandboxFlag (browser-connection.ts:40) is exported only to return a lowercased string, and surface.ts:293-300 decides what it means. One resolveChromiumSandbox(configured, env): boolean in one place, drop the export.
  • configuredChromiumSandbox plus a mutable chromiumSandbox = true (surface.ts:312-315): one field would do; the pre-init true is untested (mutation to false survives).
  • acquire(name, headed, timeoutMs, chromiumSandbox, connect?): four primitives in a row, switch to an options object.
  • surface.ts is already 1.3k lines; ~15 of the 43 added lines are a JSDoc repeating the paragraph that also appears in web.mdx, both setup.md copies, SECURITY.md, security.mdx and the changeset. One or two lines.

Nits

  • cdp-attach test edits are pointless (flag doesn't apply to attach). screenshot-caret and stalled-frame hardcode false, so they never run sandboxed even on macOS.
  • Shrink each 4-line workflow comment to one line; drop the comment lines in mcp-test-run.test.ts and artifact-path.test.ts.
  • Surviving mutations: .trim() / .toLowerCase() dropped, retry recursion passing !chromiumSandbox.
  • Docs explain the "why" in six places; keep it in security.mdx, link from the rest.
  • Red CI is screenshot.e2e.ts > should work while navigating, a known flake unrelated to this.

For maintainers: default policy. Always on (this PR), or on for macOS/Windows and off on Linux, which is what Playwright MCP does for the same agent-browsing threat model (bundled Chromium on Linux defaults to sandbox off). That keeps dev laptops (where the keys live) protected and drops the workflow edits, most of the test churn and the Docker breakage. Also: patch vs minor, whether the env var is worth it, smol's VM --no-sandbox stays.

@Varshith-Kali

Copy link
Copy Markdown
Contributor Author

Thanks for the thorough review. The screenshot.e2e.ts failure is the known flake, confirmed unrelated: the 869b879 head is docs-only, and the same test passed on the earlier head. On the must-fix items: I will add the friendly launch-failure error naming both opt-outs, update the CI docs (github-actions, the other ci pages, visual-testing) and verify the ubuntu-latest recipe, and bump the changeset to minor with a line telling Linux and Docker users to set E2E_CHROMIUM_SANDBOX=0. I will also do the should-fix restructuring (single resolveChromiumSandbox, one field, options object for acquire, shorter JSDoc) and the nits. The default-policy question (always on, or on for macOS and Windows and off on Linux) is yours to decide; I am keeping the always-on default unless you say otherwise, since the must-fix items assume it.

@Varshith-Kali

Copy link
Copy Markdown
Contributor Author

All addressed in f9147f3 (two commits on the PR branch):

  • Must-fix 1: changeset is now minor (with the Release: opening the bump check requires) and tells Linux and Docker users to set E2E_CHROMIUM_SANDBOX=0.
  • Must-fix 2: acquireBrowser now catches a local-launch failure containing 'Chromium sandboxing failed!' and throws an ENGINE_FAILURE naming both opt-outs, with no call log and no cause attached (the runner would surface the call log back through the cause chain). Other launch failures keep the old wrapping.
  • Must-fix 3: docs/ci/github-actions.mdx (web job) and docs/visual-testing.mdx (screenshots job) now set E2E_CHROMIUM_SANDBOX: '0' on ubuntu-latest, matching this repo's own CI. The other docs/ci pages run mobile targets only, so there is nothing to add there.
  • Should-fix: one resolveChromiumSandbox(configured, env) in browser-connection.ts, readChromiumSandboxFlag export deleted; one chromiumSandbox field; acquire takes a BrowserAcquireOptions object; the JSDoc is two lines linking to /security. New tests pin .trim()/.toLowerCase() and the opt-out surviving a failed relaunch.
  • Nits: cdp-attach edits reverted, screenshot-caret and stalled-frame now run sandboxed by default, workflow comments shrunk to one line, comment lines dropped in mcp-test-run and artifact-path tests, and the 'why' lives in security.mdx only with links from the rest.
  • Verification: web unit suite 358/358 with E2E_CHROMIUM_SANDBOX=0; chromium-sandbox 8, chromium-sandbox-surface 9, browser-connection 2, surface-lifecycle 8; tsc clean for web and e2e, oxlint clean, docs check chain clean, plugin check clean. Without the opt-out on this Linux host the suite fails with the new friendly error, as expected (this host cannot sandbox).
  • Left for you: the default-policy question (always on, or on for macOS and Windows and off on Linux). The default is unchanged.

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

All reported issues were addressed across 21 files (changes from recent commits).

Tip: Review your code locally with the cubic CLI to iterate faster.

View guided diff | Re-trigger cubic

Comment thread docs/visual-testing.mdx Resolved
Comment thread skills/e2e/references/setup.md Resolved
@okwasniewski
okwasniewski dismissed their stale review November 7, 2026 22:14

Superseded by re-review of f9147f3 (automated review)

@okwasniewski okwasniewski left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

[claude-opus-5-5] automated review on behalf of @okwasniewski

Re-review of f9147f3. The minor bump, the friendly launch error, the CI docs and the single resolveChromiumSandbox are all done. You were right about the /docs/security link: it returns 200. One small round left.

Must fix

  1. skills/e2e/references/running.md:230-247 (and the plugins/e2e copy): the skill's GitHub Actions recipe runs ubuntu-latest without E2E_CHROMIUM_SANDBOX: '0'. This is the workflow agents copy into user repos, so every web job built from it fails at launch once this ships. Add the env line there.

Should fix
2. Move the friendly-error mapping out of surface.ts (around line 424, with verb === 'launch' and a string match) and into BrowserConnection's local launch (browser-connection.ts around line 101). There name === 'chromium' && chromiumSandbox is already known, so you can throw the EngineError directly. The surface already rethrows EngineError as is. This shrinks surface.ts, which is already 1278 lines, and removes the untested verb guard. Removing that guard currently survives the tests.
3. The message can name an opt-out that does nothing. With web({ chromiumSandbox: true }), the option wins, so E2E_CHROMIUM_SANDBOX=0 changes nothing. Only name the env var when the option is unset, or say "unless the config sets chromiumSandbox".
4. chromiumSandbox on the surface holds the configured option before init and the resolved value after. The ?? true fallback in acquireBrowser is said never to run, but startAttempt without init reaches it. That is why artifact-path.test.ts needed an init call. Use a readonly option field plus private chromiumSandbox = true, the same pattern as headed.
5. Test gap: the relaunch recursion passing !chromiumSandbox still survives. The "relaunch fails while another caller waits" test only uses false and recurses twice, so the flip cancels itself out. A case that starts with true would kill it.

Nits

  • resolveChromiumSandbox: value === undefined || value === '' || is dead code, because value !== '0' && value !== 'false' already covers both.
  • docs/reference/web.mdx:113-118 still describes Playwright's "Chromium sandboxing failed!" error. Point it to the new e2e error and add a launch ENGINE_FAILURE row to the Throws table.
  • docs/visual-testing.mdx:71: limit "the Linux runners block" to ubuntu-latest, the same way the github-actions page does.
  • The acquire JSDoc repeats the BrowserAcquireOptions.chromiumSandbox field doc.

Mutation run: 15 of 21 mutants were killed. The real survivors are items 2, 4 and 5 above. The web suite passes 740 tests on macOS.

Maintainer decisions (not for you)

  • Always on, or off on Linux like Playwright MCP. Off on Linux would make item 1 and most of the workflow churn unnecessary.
  • **Release:** or **Breaking:** as the changeset opener.
  • Whether an explicit chromiumSandbox: true beats E2E_CHROMIUM_SANDBOX=0.

This was an automated review.

@Varshith-Kali

Copy link
Copy Markdown
Contributor Author

Review round addressed as 3a0ee17 (plus 2b24558 for the visual-testing nit below).

Must fix:

  1. The skill GitHub Actions recipe now sets E2E_CHROMIUM_SANDBOX: 0 in the run step env, in both skills/ and the synced plugins/ copy.

Should fix:
2. The friendly-error mapping moved out of surface.ts into BrowserConnection.launchLocal, where the browser name and resolved sandbox flag are known. The untested verb guard is gone; any other launch failure passes through unchanged.
3. The launch error names the environment opt-out only when the option did not set the value. When web({ chromiumSandbox: true }) set it, the message names only web({ chromiumSandbox: false }).
4. The surface keeps the option as a readonly field and resolves it into a private field defaulting to true, the same pattern as headed. The ?? true fallback in acquireBrowser is gone.
5. Added a relaunch test starting with true, so the flag flip no longer survives mutation, plus tests for the friendly error in both message variants and the passthrough.

Nits:

  • resolveChromiumSandbox lost its dead branches.
  • docs/reference/web.mdx now points at the new ENGINE_FAILURE instead of Playwright error text, with a launch row in the Throws table.
  • The acquire JSDoc no longer repeats the field doc.
  • The visual-testing nit (limit "the Linux runners block" to ubuntu-latest) is fixed as 2b24558, replied in its thread.

Verified: web unit suite 362/363 pass and tsc --noEmit plus oxlint are clean. The one failure is artifact-path.test.ts, which fails identically on the base head here because a real Chromium cannot start sandboxed in this container; CI is the check that matters for it.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

0 issues found across 8 files (changes from recent commits).

View guided diff | Re-trigger cubic

@okwasniewski
okwasniewski dismissed their stale review November 8, 2026 04:14

Superseded by new review

@okwasniewski okwasniewski left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

[claude-opus-5-5] automated review on behalf of @okwasniewski

Re-review of 3a0ee17. CR 2 asks 1-4 and every nit are done:

  • the opt-out is in both skill copies
  • the friendly error now lives in BrowserConnection.launchLocal
  • the message names the env var only when the option is unset
  • the readonly option field is in
    The precedence is option, then run env, then on, and it's tested. I reproduced the matcher's Playwright text with a real root launch in playwright:v1.63.0-noble. CI is green and there are no em dashes.

Should fix

  1. The relaunch flip survivor (ask 5) is still alive. The new test that starts with true recurses twice, so the flip cancels out. Add a case where a waiter calls acquire while the relaunch's pending is unresolved: the second launch mock rejects after setTimeout(20), the waiter joins after setTimeout(0), and you assert the sandbox flags are [true, true, true]. That kills the mutant.
  2. The friendly-error test should also assert retryable === false. A retryable: true mutant survives today.
  3. docs/reference/environment.mdx: E2E_CHROMIUM_SANDBOX is missing from the env var reference. Add a row: 0 turns the Chromium sandbox off unless web({ chromiumSandbox }) is set.
  4. skills/e2e/references/running.md:248 (and the plugins copy) and packages/web/src/surface.ts:176 link [Security](/security). That link is dead outside the docs site, and in the skill it sits in a YAML comment users copy. Use https://e2e.com/docs/security, as setup.md and SECURITY.md do.
  5. browser-connection.ts ~55-73 and 129: two parallel fields, chromiumSandbox and an optional chromiumSandboxConfigured?, hold one resolved value, and the surface always passes the second. Have resolveChromiumSandbox return { enabled, fromOption } and pass that one object. Also pass options to launchLocal instead of 5 positional args.

Nits

  • The changeset says the error names "both opt-outs". That's no longer always true.
  • The acquire JSDoc says "a relaunch keeps the value the first launch used", but BrowserConnection doesn't enforce that. It holds only because the surface fixes the value in init.

Open for @okwasniewski

  • Always on, or off on Linux like Playwright MCP?
  • Should an explicit chromiumSandbox: true beat E2E_CHROMIUM_SANDBOX=0?
  • **Release:** or **Breaking:** in the changeset?
  • Our CI sets the opt-out everywhere, so no job ever launches with the sandbox on. Do we want one sandbox-on smoke job?

@Varshith-Kali

Copy link
Copy Markdown
Contributor Author

Done in de15327, all five asks plus the two nits.

  1. New test in chromium-sandbox.test.ts: a waiter joins a relaunch that is still in flight (second launch rejects after 20ms, waiter joins after 0ms), flags assert [true, true, true]. Verified it kills a flip injected on the re-acquire; the old test passes with the mutant, this one fails on it.
  2. The friendly-error test now asserts retryable is false.
  3. E2E_CHROMIUM_SANDBOX has a row in docs/reference/environment.mdx.
  4. The Security links in running.md (both copies) and surface.ts now point at https://e2e.com/docs/security.
  5. resolveChromiumSandbox returns { enabled, fromOption } and that one object goes through acquire into launchLocal, which now takes the options object instead of five positional args.

Nits: the changeset says the error names the opt-out that applies, and the acquire JSDoc states the actual guarantee (a launch takes the value its own call passes).

Left for you: always on vs off on Linux, whether explicit chromiumSandbox: true beats E2E_CHROMIUM_SANDBOX=0, Release: vs Breaking:, and the sandbox-on smoke job. Web unit suite 364/364 green with E2E_CHROMIUM_SANDBOX=0.

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

All reported issues were addressed across 9 files (changes from recent commits).

Reply with feedback, questions, or to request a fix.

View guided diff | Re-trigger cubic

Comment thread docs/reference/environment.mdx Resolved

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

0 issues found across 1 file (changes from recent commits).

View guided diff | Re-trigger cubic

@Varshith-Kali

Copy link
Copy Markdown
Contributor Author

CI note on head 86c6cf8: the only failing job is check, and it fails on an infra step, not the change. The mcp-publisher download step got HTTP 504 from the modelcontextprotocol/registry release four times in a row, then exited 22. Lint, typecheck, dead code, error codes, peer ranges, changesets, examples, and the plugin and MCP registry checks all passed, and the test job is green. A re-run of the check job should clear it.

@okwasniewski

Copy link
Copy Markdown
Member

Automated review.

Re-review of 86c6cf8: all five CR 3 asks are done and verified. Labeling Ready for Human Review.

  • The new in-flight relaunch waiter test kills the flip mutant. Overall, mutation testing killed 15 of 17. The two that survived: retryable: true, which is equivalent because EngineError forces ENGINE_FAILURE to non-retryable, and the enabled guard before the friendly error, which is nearly unreachable.
  • https://e2e.com/docs/security resolves. The env row is there, and { enabled, fromOption } flows through acquire into launchLocal.
  • Web unit tests pass 364/364 with and without E2E_CHROMIUM_SANDBOX=0. The integration tests (lifecycle, app-log, init-scripts) pass 37/37 with the sandbox on (macOS).
  • The check job fails only on the mcp-publisher download, which gets a 504 from the registry. It failed again on rerun, so this is an upstream outage and not this PR.

Optional nits:

  • surface.ts:287-289: the placeholder { enabled: true, fromOption: false } that init overwrites. Make the resolved value optional, or resolve it in init.
  • browser-connection.ts:100-104: the acquire JSDoc repeats the options doc. :154-156: the two error strings share their first sentence, and only the remedy needs to differ.
  • chromium-sandbox.test.ts: the options literal is repeated about 20 times (a helper would cut that), the :90 test is mostly superseded by :114, and :240 should also assert code: 'INVALID_CONFIG'.
  • environment.mdx:176: say that false is accepted too.

For maintainers to decide:

  • Always on, or off by default on Linux.
  • Explicit chromiumSandbox wins over E2E_CHROMIUM_SANDBOX (current behavior). Keep it?
  • Changeset uses **Release:**, but launches can now fail on root, container, and Ubuntu 23.10+ hosts, which reads as **Breaking:** per CONTRIBUTING.
  • A Linux smoke job with the sandbox on (CI runs sandbox-off only).

@okwasniewski
okwasniewski dismissed their stale review November 8, 2026 10:13

CR 3 asks addressed in de15327/86c6cf80

@okwasniewski okwasniewski added the Ready for Human Review Green, conflict-free, every thread handled. Waiting on a maintainer. label Nov 8, 2026
@Varshith-Kali

Copy link
Copy Markdown
Contributor Author

Thanks for the re-review, all five CR 3 asks verified and the Ready for Human Review label noted. The optional nits are left as-is for now: the placeholder in surface.ts, the JSDoc repeats, and the test-literal repetition are cosmetic, and I did not want another push to strip the label. Happy to fold any of them in if you would like them done, and the open questions (always-on vs off-on-Linux, explicit option vs env var, Release vs Breaking, a Linux sandbox-on smoke job) are yours to decide.

@Varshith-Kali
Varshith-Kali force-pushed the fix-1613-chromium-sandbox branch from 86c6cf8 to fbf2a4f Compare November 11, 2026 01:04
@github-actions github-actions Bot removed the Ready for Human Review Green, conflict-free, every thread handled. Waiting on a maintainer. label Nov 11, 2026
@Varshith-Kali

Copy link
Copy Markdown
Contributor Author

Rebased onto current main (d8b694f). New head fbf2a4f.

All five CR 3 asks remain addressed, and the rebase kept all eight commits. The only conflicts were mechanical: upstream additions alongside our change in packages/e2e/tests/integration/mcp-test-run.test.ts and docs/ci/github-actions.mdx, resolved by keeping both sides.

Verified locally: web typecheck and lint clean, web unit 364/364 with E2E_CHROMIUM_SANDBOX=0, and the e2e package typecheck clean. The one unit test that launches a real browser fails without the opt-out on a host whose sandbox cannot start, which is the friendly error this PR adds, not a regression.

Ready for human review.

@Varshith-Kali

Copy link
Copy Markdown
Contributor Author

Follow-up: the rebase dropped the first half of the new Cache the timings history section in docs/ci/github-actions.mdx, and CI caught it (docs anchor check: docs/ci.mdx links to #cache-the-timings-history). Restored in full as f30af13; the docs check chain passes locally now. Nothing else changed; the rebase note above still stands.

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

All reported issues were addressed across 52 files

Reply with feedback, questions, or to request a fix.

View guided diff | Re-trigger cubic

Comment thread docs/security.mdx Resolved

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

0 issues found across 1 file (changes from recent commits).

View guided diff | Re-trigger cubic

@okwasniewski

Copy link
Copy Markdown
Member

Re-checked after the rebase onto d8b694f. git range-diff against the labeled head 86c6cf8: conflicts were mechanical (mcp-test-run.test.ts around the new loadEngineConfig, docs/ci/github-actions.mdx). f30af13 restores the timings-history section, so docs/ci/github-actions.mdx now only adds the E2E_CHROMIUM_SANDBOX: '0' env line and its paragraph against main. 1807223's softer docs/security.mdx wording is accurate. CI green. Re-labeling Ready for Human Review.

Nit: docs/security.mdx:58 now runs past the 80-column wrap.

Maintainer decisions unchanged: default on Linux, option vs env precedence, Release vs Breaking, a sandbox-on smoke job.

This was an automated review.

@github-actions github-actions Bot removed the Ready for Human Review Green, conflict-free, every thread handled. Waiting on a maintainer. label Nov 20, 2026
@Varshith-Kali

Copy link
Copy Markdown
Contributor Author

Thanks for the re-check. Both nits are fixed in 904f8db: the sandbox paragraph in docs/security.mdx is re-wrapped at 80 columns, and the changeset now matches the softened wording (helps contain, does not prevent sandbox escapes) with only the user-facing part, what changed and the two opt-outs. The 3 remaining Nov 8 items are maintainer calls and stay on hold. Web unit tests pass 394/395 locally; the one failure is artifact-path.test.ts, which fails the same way on the previous head because Chromium cannot start its sandbox on this Linux host.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

0 issues found across 2 files (changes from recent commits).

Heads up: you’ve reached your flex budget. Increase your flex budget or wait for usage to reset.

Requires human review: Auto-approval skipped because cubic reviewed only this push, not the earlier force-push. Comment @cubic review to review the whole pull request.

View guided diff | Re-trigger cubic

@Varshith-Kali

Copy link
Copy Markdown
Contributor Author

CI note: the two failures on this head are a flake, not this change. test (22) fails in cli-pause.test.ts (expected pause hint text, got the RUN header instead), and spec gate fails only because test (22) failed. The diff since the fully green head ddc9429 is docs only (docs/security.mdx re-wrap plus changeset wording), so nothing in this push can change CLI pause output. The previous head was green on all 28 checks. A re-run should clear it.

@okwasniewski okwasniewski left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

[claude-opus-5-5] automated review on behalf of @okwasniewski

Re-checked 904f8db72 against our check at ddc9429c0. Merges cleanly into main 160cbfe7a.

The new commit only touches docs/security.mdx and .changeset/chromium-sandbox-default.md, and both nits are done:

  • docs/security.mdx: the sandbox paragraph is re-wrapped. No line goes past 80 columns, and the text is unchanged.
  • Changeset: it now matches the docs wording ("helps contain a renderer exploit ... but does not prevent sandbox escapes") and keeps to the user-facing part: what changed and the two opt-outs.

Must fix

  • None.

CI

  • test (22) fails in tests/integration/cli-pause.test.ts:294 ("resumes the paused test on next or rest alike"), and spec gate fails only because of it. This is not caused by this PR. The diff since the all-green ddc9429c0 is docs only, and the race is in the test on main: it waits for Paused in pauses three times and then checks right away that stdout already has the Next: e2e run --step next ... hint. That hint arrives in a later write. The other test in the file does it correctly at :165 (await run.shows('Next: e2e run --step next')). A maintainer should rerun the failed jobs of the spec run (44651191139, test (22)). The test-side fix is a separate PR.

Verified at 904f8db72:

  • git diff ddc9429c0 904f8db72 is 2 files, +3/-4, no code.
  • No em or en dashes in added lines. cubic found nothing new on this commit.

@okwasniewski okwasniewski added the Ready for Human Review Green, conflict-free, every thread handled. Waiting on a maintainer. label Nov 20, 2026
@Varshith-Kali

Copy link
Copy Markdown
Contributor Author

Thanks for the re-check. Both nits are in at 904f8db (docs re-wrapped at 80 columns, changeset wording matched to the docs). Agree on test (22): the diff since the all-green ddc9429 is docs only, and the cli-pause race is in the test on main, so the rerun of spec run 44651191139 is a maintainer action. The 3 Nov items stay on hold for the maintainer call.

@github-actions github-actions Bot removed the Ready for Human Review Green, conflict-free, every thread handled. Waiting on a maintainer. label Nov 20, 2026
@okwasniewski okwasniewski changed the title fix(web): launch Chromium with its sandbox on by default fix(web): launch Chromium with its sandbox on where it can start Nov 20, 2026
@okwasniewski

Copy link
Copy Markdown
Member

Thanks for carrying this through so many rounds, @Varshith-Kali. I pushed a maintainer rework on top of your commits (b86f6ae) that settles the open decisions:

  • Default is by platform: on for macOS and Windows, off on Linux, where root, most containers and Ubuntu 23.10+ cannot start the sandbox. web({ chromiumSandbox: true }) opts a Linux host in.
  • E2E_CHROMIUM_SANDBOX is gone. With no failing default there is nothing for CI to opt out of, so the workflow edits, the test env forwarding and the CI recipe edits are reverted.
  • The launch error names the one option.
  • docs/ja and docs/zh are synced, and the changeset stays a non-breaking minor.

Please don't rebase the branch; pull before any further push.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

0 issues found across 1 file (changes from recent commits).

Heads up: you’ve reached your flex budget. Increase your flex budget or wait for usage to reset.

Requires human review: Auto-approval skipped because cubic reviewed only this push, not the earlier force-push. Comment @cubic review to review the whole pull request.

View guided diff | Re-trigger cubic

@okwasniewski okwasniewski added the Ready for Human Review Green, conflict-free, every thread handled. Waiting on a maintainer. label Nov 20, 2026
@okwasniewski
okwasniewski added this pull request to the merge queue Nov 20, 2026
Merged via the queue into e2e-inc:main with commit a06b931 Nov 20, 2026
29 checks passed
@okwasniewski

Copy link
Copy Markdown
Member

Merged as a06b931. Thank you @Varshith-Kali: you found the gap in #1613, wrote the fix, and stayed with it through four review rounds and as many rebases. The option, the launch path, the error and the tests are your work; the rework on top only changed the default policy. Chromium is now sandboxed by default on macOS and Windows because of this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Ready for Human Review Green, conflict-free, every thread handled. Waiting on a maintainer. security Secrets, sandboxing, and the trust model size:L Up to 499 changed lines, not counting tests, fixtures, translated docs, or the lockfile

Projects

None yet

Development

Successfully merging this pull request may close these issues.

web: launch Chromium with the sandbox on (agent can navigate off-origin)

2 participants