Skip to content

Commit 3cb6b5e

Browse files
authored
docs(bun): note WebSocket limitation with remote browser connections (#3537)
1 parent f8ddb76 commit 3cb6b5e

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

docs/guides/frameworks/bun.mdx

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,13 @@ import CliRunTestStep from "/snippets/step-run-test.mdx";
1010
import CliViewRunStep from "/snippets/step-view-run.mdx";
1111

1212
<Warning>
13-
The trigger.dev CLI does not yet support Bun. So you will need to run the CLI using Node.js.
14-
Bun will still be used to execute your tasks, even in the `dev` environment.
13+
The trigger.dev CLI does not yet support Bun. So you will need to run the CLI using Node.js. Bun
14+
will still be used to execute your tasks, even in the `dev` environment.
1515
</Warning>
1616

1717
<Note>
18-
**Supported Bun version:** Deployed tasks run on Bun 1.3.3. For local development, use Bun 1.3.x for compatibility.
18+
**Supported Bun version:** Deployed tasks run on Bun 1.3.3. For local development, use Bun 1.3.x
19+
for compatibility.
1920
</Note>
2021

2122
<Prerequisites framework="Bun" />
@@ -27,6 +28,7 @@ import CliViewRunStep from "/snippets/step-view-run.mdx";
2728
```bash
2829
mkdir -p ~/.bun/bin && ln -s $(which bun) ~/.bun/bin/bun
2930
```
31+
- Bun's WebSocket client does not handle the `101 Switching Protocols` upgrade response correctly, so connecting to a remote browser via `puppeteer.connect()` / `playwright.connectOverCDP()` (e.g. BrowserBase, Browserless) fails silently — typically with an empty `{}` `ErrorEvent`. The remote session opens and immediately drops. **Workaround:** set `runtime: "node"` in `trigger.config.ts` for tasks that connect to a remote browser.
3032

3133
## Initial setup
3234

0 commit comments

Comments
 (0)