chore: align with upstream changes from Node qs v6.15.2#54
Conversation
…15.2 bracket parsing and stringify edge cases
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (8)
WalkthroughThis PR aligns bracket parsing and stringify behaviours with Node's qs 6.15.2 by refactoring key segmentation logic in the decoder, applying formatter/delimiter rules consistently in the encoder, and extending test coverage for edge cases including encoded brackets, null handling, and RFC1738 formatting. ChangesNode qs 6.15.2 Compatibility
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~22 minutes Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 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 |
Up to standards ✅🟢 Issues
|
| Metric | Results |
|---|---|
| Duplication | 0 |
🟢 Coverage 100.00% diff coverage · -0.02% coverage variation
Metric Results Coverage variation ✅ -0.02% coverage variation (-1.00%) Diff coverage ✅ 100.00% diff coverage Coverage variation details
Coverable lines Covered lines Coverage Common ancestor commit (5c68de1) 1402 1370 97.72% Head commit (6ac8a88) 1391 (-11) 1359 (-11) 97.70% (-0.02%) Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch:
<coverage of head commit> - <coverage of common ancestor commit>Diff coverage details
Coverable lines Covered lines Diff coverage Pull request (#54) 11 11 100.00% Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified:
<covered lines added or modified>/<coverable lines added or modified> * 100%
NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #54 +/- ##
==========================================
- Coverage 97.71% 97.69% -0.02%
==========================================
Files 20 20
Lines 1402 1391 -11
==========================================
- Hits 1370 1359 -11
Misses 32 32 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This pull request updates the Dart
qsport to match Node.jsqs6.15.2 behavior for bracket parsing, encoding, and edge cases, and improves compatibility and correctness in several key areas. The changes ensure literal and encoded brackets, depth limiting, delimiter handling, and edge-case encoding/decoding now closely follow the latest Node.js implementation. The test suite and documentation are also updated accordingly.Compatibility and Behavior Alignment with Node.js
qs6.15.2:Improved bracket parsing to match Node.js
qs6.15.2, including correct handling of nested/literal bracket groups, percent-encoded brackets, andallowDotswithdepth: 0. This includes removing synthetic bracket normalization and updating the key splitting logic to wrap raw remainders as literal segments and to apply dot-to-bracket normalization before depth limiting. [1] [2] [3] [4] [5] [6] [7] [8] [9] [10]Updated encoding logic to match Node.js
qs6.15.2 edge cases, including:Test and Dependency Updates:
Expanded and updated the test suite to cover new edge cases, including literal and encoded brackets, delimiter handling, null-slot behavior, and round-trip encoding/decoding for tricky keys. [1] [2] [3] [4] [5] [6] [7] [8] [9]
Updated Node.js
qsdependency in the test comparison suite to6.15.2and switched install instructions to usepnpmwith a frozen lockfile for reproducible testing. [1] [2] [3] [4] [5]Documentation:
1.7.5-devsummarizing the main fixes.References:
[1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [11] [12] [13] [14] [15] [16] [17] [18] [19] [20] [21] [22] [23]