Skip to content

Honor absolute paths for heap and CPU profiler --*-dir/--*-name options - #32570

Open
robobun wants to merge 4 commits into
mainfrom
farm/b1e7794a/fix-heap-prof-dir-absolute
Open

Honor absolute paths for heap and CPU profiler --*-dir/--*-name options#32570
robobun wants to merge 4 commits into
mainfrom
farm/b1e7794a/fix-heap-prof-dir-absolute

ci: retrigger

96b9f0d
Select commit
Loading
Failed to load commit list.
Claude / Claude Code Review completed Jun 21, 2026 in 12m 48s

Code review found 1 potential issue

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

Details

Severity Count
🔴 Important 0
🟡 Nit 1
🟣 Pre-existing 0
Severity File:Line Issue
🟡 Nit src/jsc/BunHeapProfiler.rs:111-112 Absolute --heap-prof-name still hits append() — same bug class, user-reachable debug_assert

Annotations

Check warning on line 112 in src/jsc/BunHeapProfiler.rs

See this annotation in the file changed.

@claude claude / Claude Code Review

Absolute --heap-prof-name still hits append() — same bug class, user-reachable debug_assert

Same bug class one line down: `path.append(filename)` still runs on `config.name`, which is the unvalidated `--heap-prof-name` value — an absolute path there trips the same `debug_assert!(!is_input_absolute(input))` in debug and strips the leading `/` in release. Pre-existing (and shared with `BunCPUProfiler.rs:189`), and `--heap-prof-name` is documented as a bare filename, so non-blocking — but might be worth a `join` here too while you're in this function.