Skip to content

bake: resolve app.root against the cwd and require it to be a string - #39188

Closed
robobun wants to merge 7 commits into
mainfrom
farm/6f856713/bake-app-root-resolve
Closed

bake: resolve app.root against the cwd and require it to be a string#39188
robobun wants to merge 7 commits into
mainfrom
farm/6f856713/bake-app-root-resolve

bake: resolve app.root against the cwd and require it to be a string

84cffc3
Select commit
Loading
Failed to load commit list.
Claude / Claude Code Review completed Aug 15, 2026 in 17m 15s

Code review found 1 potential issue

Found 1 candidates, confirmed 1. See review comments for details.

Details

Severity Count
🔴 Important 0
🟡 Nit 1
🟣 Pre-existing 0
Severity File:Line Issue
🟡 Nit src/runtime/bake/bake_body.rs:233-250 New root-validation error paths leak bundler_options.plugin

Annotations

Check warning on line 250 in src/runtime/bake/bake_body.rs

See this annotation in the file changed.

@claude claude / Claude Code Review

New root-validation error paths leak bundler_options.plugin

The two new early returns (`get_optional_slice` throwing `ERR_INVALID_ARG_TYPE` for a non-string `root`, and the "'app.root' is too long" branch) run after `Framework::from_js` has already stored a protected `Plugin` handle in `bundler_options.plugin` when `framework.plugins` is set — and `SplitBundlerOptions` has no `Drop`, so the JSCell leaks on those paths. This is a pre-existing structural gap (the old shim's `to_slice`, `getcwd_alloc`, and the top-level `plugins` parse already had it) that