Skip to content

Update dependency body-parser to v2#36

Open
ivan-flamingo wants to merge 1 commit into
masterfrom
renovate/body-parser-2.x
Open

Update dependency body-parser to v2#36
ivan-flamingo wants to merge 1 commit into
masterfrom
renovate/body-parser-2.x

Conversation

@ivan-flamingo

@ivan-flamingo ivan-flamingo commented Jun 9, 2026

Copy link
Copy Markdown

This PR contains the following updates:

Package Type Update Change
body-parser dependencies major 1.20.42.3.0

Release Notes

expressjs/body-parser (body-parser)

v2.3.0

Compare Source

========================

  • fix: use static exports instead of lazy getters to improve ESM compatibility
  • feat: add subpath exports for individual parsers
  • fix: improve limit option validation (#​698)
    • Invalid limit values (e.g. unparseable strings or NaN) now throw instead of being silently ignored, which previously disabled size limit enforcement
    • null and undefined fall back to the default 100kb limit
  • deps:
    • content-type@^2.0.0
    • http-errors@^2.0.1
    • iconv-lite^0.7.2
    • qs@^6.15.2
    • raw-body@^3.0.2
    • type-is@^2.1.0

v2.2.2

Compare Source

=========================

  • deps: qs@^6.14.1
  • refactor(json): simplify strict mode error string construction

v2.2.1

Compare Source

=========================

  • Security fix for GHSA-wqch-xfxh-vrr4
  • deps:
    • type-is@^2.0.1
    • iconv-lite@^0.7.0
      • Handle split surrogate pairs when encoding UTF-8
      • Avoid false positives in encodingExists by using prototype-less objects
    • raw-body@^3.0.1
    • debug@^4.4.3

v2.2.0

Compare Source

=========================

  • refactor: normalize common options for all parsers
  • deps:
    • iconv-lite@^0.6.3

v2.1.0

Compare Source

=========================

  • deps:
    • type-is@^2.0.0
    • debug@^4.4.0
    • Removed destroy
  • refactor: prefix built-in node module imports
  • use the node require cache instead of custom caching

v2.0.2

Compare Source

=========================

  • remove unpipe package and use native unpipe() method

v2.0.1

Compare Source

=========================

  • Restore expected behavior extended to false

v2.0.0

Compare Source

=========================

Breaking Changes

  • Node.js 18 is the minimum supported version
  • req.body is no longer always initialized to {}
    • it is left undefined unless a body is parsed
  • Remove deprecated bodyParser() combination middleware
  • urlencoded parser now defaults extended to false as released, this is not the case, fixed in 2.0.1
  • urlencoded simple parser now uses qs module instead of querystring module

Features

  • Add brotli support #​406
  • urlencoded: Add option to customize the depth with a default value of 32
  • urlencoded: Support iso-8859-1, utf8 sentinel, and numeric entities
  • Use on-finished to determine when body read

Dependencies

  • deps: raw-body@^3.0.0
  • deps: qs@​6.12.3
  • deps: debug@​3.1.0
  • deps: iconv-lite@​0.5.2

v1.20.5

Compare Source

What's Changed

The reason for this release is a fix to the extended urlencoded parser returning objects instead of arrays for large array inputs (> 100) on qs@​6.14.2+. (#​716)

New Contributors

Special thanks to triager @​krzysdz for keeping this on our radar and effectively triaging the specific issue!

Full Changelog: expressjs/body-parser@1.20.4...1.20.5


Configuration

📅 Schedule: (UTC)

  • Branch creation
    • At any time (no schedule defined)
  • Automerge
    • At any time (no schedule defined)

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Mend Renovate.

@coderabbitai

coderabbitai Bot commented Jun 9, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

Review limit reached

@ivan-flamingo, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 49 minutes and 26 seconds. Learn how PR review limits work.

To continue reviewing without waiting, enable usage-based billing in the billing tab.

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based credits.

🚦 How do rate limits work?

CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability.

For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: aa286007-d2f2-442c-9334-c99e156d6a44

📥 Commits

Reviewing files that changed from the base of the PR and between 93da0b1 and 1621c11.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (1)
  • package.json
📝 Walkthrough

Walkthrough

The body-parser dependency in package.json is updated from version 1.20.4 to 2.2.2. This is a direct version upgrade with no other package or configuration changes.

Changes

Dependency Update

Layer / File(s) Summary
body-parser version upgrade
package.json
The body-parser dependency is updated from 1.20.4 to 2.2.2.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Poem

🐰 A hop, a skip, a version bump,
body-parser climbs the stump,
From one-point-twenty, now it's two,
Fresh and ready, shiny new! 📦✨

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title 'Update dependency body-parser to v2' directly and clearly describes the main change: upgrading body-parser to version 2, which aligns with the changeset that updates body-parser from 1.20.4 to 2.2.2.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch renovate/body-parser-2.x

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@package.json`:
- Line 42: package.json currently pins "body-parser": "2.2.2" which requires
Node >=18 while engines.node allows ">=16.0.0"; update package.json to resolve
the mismatch by either (A) raising engines.node to ">=18.0.0" (so engines.node
matches body-parser@2.2.2) or (B) replacing/downgrading "body-parser" to a
version compatible with Node 16 (e.g., a 1.x release); modify the engines.node
field or the "body-parser" dependency accordingly and run a lockfile update
(npm/yarn/pnpm) to keep manifest and lockfile consistent.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: bfea4119-4532-4d27-a101-bca6cfe47931

📥 Commits

Reviewing files that changed from the base of the PR and between f00ae1e and 93da0b1.

⛔ Files ignored due to path filters (1)
  • package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (1)
  • package.json

Comment thread package.json Outdated
"@seald-io/nedb": "4.1.2",
"archiver": "7.0.1",
"body-parser": "1.20.4",
"body-parser": "2.2.2",

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

echo "Project Node engine:"
jq -r '.engines.node' package.json

echo "Pinned body-parser version:"
jq -r '.dependencies["body-parser"]' package.json

echo "body-parser@2.2.2 Node engine from npm registry:"
curl -s https://registry.npmjs.org/body-parser/2.2.2 | jq -r '.engines.node'

Repository: flamingo-stack/meshcentral

Length of output: 188


Fix package.json Node engine mismatch with body-parser@2.2.2.

package.json pins "body-parser": "2.2.2" (line 42), but engines.node still allows " >=16.0.0" (lines 59-60). body-parser@2.2.2 requires node >=18, so installs/runs on Node 16/17 may fail.

Suggested fix
  "engines": {
-    "node": ">=16.0.0"
+    "node": ">=18.0.0"
  },
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
"body-parser": "2.2.2",
"engines": {
"node": ">=18.0.0"
},
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@package.json` at line 42, package.json currently pins "body-parser": "2.2.2"
which requires Node >=18 while engines.node allows ">=16.0.0"; update
package.json to resolve the mismatch by either (A) raising engines.node to
">=18.0.0" (so engines.node matches body-parser@2.2.2) or (B)
replacing/downgrading "body-parser" to a version compatible with Node 16 (e.g.,
a 1.x release); modify the engines.node field or the "body-parser" dependency
accordingly and run a lockfile update (npm/yarn/pnpm) to keep manifest and
lockfile consistent.

@ivan-flamingo ivan-flamingo force-pushed the renovate/body-parser-2.x branch 3 times, most recently from 101fdc1 to 4037a11 Compare June 17, 2026 11:24
@ivan-flamingo ivan-flamingo force-pushed the renovate/body-parser-2.x branch 2 times, most recently from 80d0089 to 3b14786 Compare June 24, 2026 19:20
@ivan-flamingo ivan-flamingo force-pushed the renovate/body-parser-2.x branch from 3b14786 to 1621c11 Compare June 25, 2026 21:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants