Skip to content

runtime: make uncaught exceptions during top-level await immediately fatal - #34627

Closed
robobun wants to merge 4 commits into
mainfrom
claude/farm/e93f85a4/tla-uncaught-exception-fatal
Closed

robobun wants to merge 4 commits into
mainfrom
claude/farm/e93f85a4/tla-uncaught-exception-fatal

test: add unhandled-rejection-during-TLA case for #22546

3d15675
Select commit
Loading
Failed to load commit list.
Claude / Claude Code Review completed Jul 18, 2026 in 15m 46s

Code review found 4 potential issues

Found 2 candidates, confirmed 4. See review comments for details.

Details

Severity Count
🔴 Important 0
🟡 Nit 4
🟣 Pre-existing 0
Severity File:Line Issue
🟡 Nit src/jsc/VirtualMachine.rs:2484-2499 Two more unpatched TLA-wait sibling sites: --preload and bun test entry point

Annotations

Check warning on line 2499 in src/jsc/VirtualMachine.rs

See this annotation in the file changed.

@claude claude / Claude Code Review

Two more unpatched TLA-wait sibling sites: --preload and bun test entry point

Beyond the watcher arm already noted, two more sibling TLA-wait sites still call the unguarded generic `wait_for_promise`: the `--preload` non-watcher arm at `src/runtime/jsc_hooks.rs:836` (one call frame deeper on the *same* `Run::start` → `load_entry_point` → `reload_entry_point` → `load_preloads` stack — the guard here would *not* be a no-op), and `load_entry_point_for_test_runner` at `VirtualMachine.rs:4686` (a near byte-identical copy of this function). The PR description's `wait_for_promis