Repository navigation
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… maps, and add a 5.4 release note Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was a problem hiding this comment.
Code Review
This pull request updates the documentation and release notes for Harper v5.4.0 to reflect changes in memory management and source map handling. Specifically, it documents that source maps are no longer enabled by default to reduce per-thread memory usage, and provides instructions on how to re-enable them using the NODE_OPTIONS=--enable-source-maps environment variable. It also highlights a 40% reduction in idle JavaScript heap usage due to optimized compiled code and lazy-loading of specific dependencies. No review comments were provided, so there is no additional feedback.
🚀 Preview DeploymentYour preview deployment is ready! 🔗 Preview URL: https://preview.harper-documentation.harperfabric.com/pr-714 This preview will update automatically when you push new commits. |
Documents that Harper v5.4.0 no longer enables source maps by default, and how to turn them back on. Companion to HarperFast/harper#3072, which turns them off to save several megabytes of heap per thread.
⊙ Problem
After HarperFast/harper#3072, stack traces from Harper's core point at the compiled
dist/*.jsfiles unless source maps are enabled. Nothing in the docs says source maps exist, so an operator who upgrades sees different stack traces with no explanation.💡 Solution
reference/configuration/debugging.md: a new "Source Maps in Stack Traces" section (changedin v5.4.0) explaining the default, the memory reason, andNODE_OPTIONS=--enable-source-maps, which Harper passes on to every worker thread. It scopes the effect to modules Node.js loads itself: Harper's core and natively loaded application code. Harper's VM-based loaders were not mapped before either. Adds a link to Node's--enable-source-mapsdocs under Related.reference/configuration/overview.md: the See Also entry for Worker Thread Debugging mentions source maps.release-notes/v5-lincoln/5.4.md: a "Smaller Per-Thread Baseline" note — an idle thread's heap drops from about 58 MB to 35 MB, some dependencies load on first use, and source maps are off by default.✅ Verification
Not observable end-to-end in this repository; prettier is clean on the changed files. The behavior described was checked against HarperFast/harper#3072 on a running server: source maps are off in the main thread and workers by default, and on in all of them with
NODE_OPTIONS=--enable-source-mapsornode --enable-source-maps.🤖 Generated by Claude Code (Claude Opus 5.5); posted via @kriszyp.
Related PRs: #671 independent, #709 overlaps (also adds a 5.4 release note), #712 overlaps (also adds a 5.4 release note), #710 overlaps (merged; also edits the 5.4 release notes, merges cleanly)
Complexity: easy
Review-Coverage: authored=claude; ran=gemini,cursor-composer,codex,cursor-muse; adjudicated=domain; declined=cursor-grok,cursor-kimi; rounds=3; full=2 @ ebb3ed4
Review-Attention: skim ~2m (decisions: release-note-placement, opt-in-surface, page-home) @ ebb3ed4