perf(history): avoid generating unused location keys - #8349
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (3)
Included review availability: Your plan provides up to 10 included reviews per hour; 8 remain after this review. 📝 WalkthroughWalkthrough
ChangesHistory state preservation
Priority: ⬇️ Low Estimated code review effort: 2 (Simple) | ~10 minutes Suggested reviewers: Merge Risk: ⚪ Minimal · up to The change avoids unnecessary key generation while preserving existing history-state behavior. No actionable merge risk remains. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 1 functions across 2 files. (1 skipped: 1 unsupported.)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
View your CI Pipeline Execution ↗ for commit 9eeb94f
☁️ Nx Cloud last updated this comment at |
🚀 Changeset Version Preview1 package(s) bumped directly, 23 bumped as dependents. 🟩 Patch bumps
|
Bundle Size Benchmarks
The following scenarios have bundle-size changes compared with the baseline:
Current gzip tracks all emitted client JS chunks. Initial gzip tracks only the entry/import graph. Trend sparkline is historical current gzip ending with this PR measurement; lower is better. |
There was a problem hiding this comment.
Nx Cloud has identified a possible root cause for your failed CI:
We determined these E2E failures are environment-related and not caused by this PR. The parseHref change is a functionally identical performance optimization, and neither failing project is in the set of projects touched by the diff. The React test shows explicit ECONNRESET network errors from the test server, and the Solid test is a router-idle timeout — both pointing to infrastructure instability rather than a logic regression.
No code changes were suggested for this issue.
Trigger a rerun:
🎓 Learn more about Self-Healing CI on nx.dev
Merging this PR will improve performance by 5.91%
Performance Changes
Tip Curious why performance improved? Comment Comparing |
🎯 Changes
Generate a fallback history key in
parseHrefonly when no state is supplied. Parsing a location with existing state no longer creates and discards a random key.Performance
Local Node.js 24.12.0 microbenchmark comparing
6494e75362with9eeb94f921. Nine alternating baseline/candidate rounds per case, with 100,000 warmup calls and 2,000,000 timed calls per sample. The URL is/items/123?tab=details#top; times below are medians.parseHrefwith existing stateparseHrefwithout stateExisting-state parsing removes one discarded key-generation operation per call. These are isolated runtime results, not an end-to-end navigation speedup or a retained-heap measurement.
✅ Checklist
🚀 Release Impact
Summary by CodeRabbit