lean4-htt/stage0
Sebastian Ullrich 654017fb3c
feat: serve trace.profiler data via local HTTP server (#13530)
This PR adds a `trace.profiler.serve` option that, when enabled, serves
the Firefox Profiler-compatible profile JSON on an ephemeral `127.0.0.1`
port and opens `https://profiler.firefox.com/from-url/...` in the user's
default browser, à la `samply`. The server shuts down once the profile
has been fetched.

Compared to `trace.profiler.output`, which writes the profile to a file
that the user must then manually upload to `profiler.firefox.com`, this
is a single-command workflow not touching the file system.

Implementation notes:
* `Std.Http.Server` now exposes the bound socket address so the caller
can read back the OS-assigned ephemeral port when binding to port `0`.
* `addTraceAsMessages` and the import-time trace recording now check a
shared `trace.profiler.isExporting` predicate; the previous
`trace.profiler.output`-only check would otherwise consume the trace
state before serving could see it.
2026-05-10 17:55:25 +00:00
..
src feat: serve trace.profiler data via local HTTP server (#13530) 2026-05-10 17:55:25 +00:00
stdlib chore: update stage0 2026-05-10 17:22:00 +00:00