Skip to content

fix: add engines field to package.json#379

Merged
Junman140 merged 1 commit into
Pi-Defi-world:devfrom
icodeBisola:fix/engines-field-319
Jun 4, 2026
Merged

fix: add engines field to package.json#379
Junman140 merged 1 commit into
Pi-Defi-world:devfrom
icodeBisola:fix/engines-field-319

Conversation

@icodeBisola

@icodeBisola icodeBisola commented Jun 1, 2026

Copy link
Copy Markdown
Contributor

Closes #319

Adds an engines field to package.json specifying the minimum required Node.js (>=20) and pnpm (>=10) versions. This prevents deployments on incompatible runtimes and makes the version requirement explicit to tooling (npm, pnpm, CI).

Summary by CodeRabbit

  • Chores
    • Updated minimum required versions for Node.js (20.0.0 or higher) and pnpm package manager (10.0.0 or higher).

@drips-wave

drips-wave Bot commented Jun 1, 2026

Copy link
Copy Markdown

@icodeBisola Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@coderabbitai

coderabbitai Bot commented Jun 1, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

package.json is updated to declare minimum runtime version requirements: Node.js >=20.0.0 and pnpm >=10.0.0. The new engines field is added at the package root level with no changes to scripts, dependencies, or other metadata.

Changes

Runtime Version Constraints

Layer / File(s) Summary
Engines field addition
package.json
package.json updated with engines field specifying minimum Node.js >=20.0.0 and pnpm >=10.0.0 versions.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Poem

🐇 A rabbit hops through versions,
Setting bounds with care,
Node and pnpm constrained,
No surprises in the air! 🚀
Engines locked, all is right.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Description check ❓ Inconclusive The description provides a summary and links the issue, but is missing the required Scope, Validation, and Related PR sections from the template. Complete the description by adding Scope (mark 'Build/CI only'), Validation (list tested commands), and any related PR references following the repository template.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly and accurately describes the main change: adding an engines field to package.json.
Linked Issues check ✅ Passed The pull request successfully addresses issue #319 by adding the engines field to package.json with Node.js >=20 and pnpm >=10 specifications.
Out of Scope Changes check ✅ Passed All changes in the pull request are directly related to the linked issue #319; only the engines field was added to package.json with no extraneous modifications.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

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

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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 and usage tips.

@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`:
- Around line 5-8: Add strict engine enforcement by updating the project's npm
configuration: open the existing .npmrc (which currently contains
`@jsr`:registry=...) and add the line engine-strict=true so the package.json
"engines" block (node >=20.0.0, pnpm >=10.0.0) is enforced and installs fail on
incompatible runtimes; save and commit the updated .npmrc alongside the
package.json changes.
🪄 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

Run ID: 2ceb6873-c156-4485-b3d7-b57aadbced11

📥 Commits

Reviewing files that changed from the base of the PR and between 493d266 and eb04288.

📒 Files selected for processing (1)
  • package.json

Comment thread package.json
Comment on lines +5 to +8
"engines": {
"node": ">=20.0.0",
"pnpm": ">=10.0.0"
},

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 | ⚡ Quick win

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Check for .npmrc and engine-strict setting

if [ -f .npmrc ]; then
  echo "=== .npmrc exists ==="
  cat .npmrc
  echo ""
  echo "=== Checking for engine-strict setting ==="
  if grep -q "engine-strict" .npmrc; then
    echo "✓ engine-strict found in .npmrc"
  else
    echo "✗ engine-strict NOT found in .npmrc"
    echo "Consider adding: engine-strict=true"
  fi
else
  echo "✗ .npmrc does not exist"
  echo "Consider creating .npmrc with: engine-strict=true"
fi

Repository: Pi-Defi-world/acbu-backend

Length of output: 242


Enforce the engines constraint (engine-strict)

  • .npmrc exists but does not set engine-strict=true (it only has @jsr:registry=https://npm.jsr.io/), so the package.json engines block (node >=20.0.0, pnpm >=10.0.0) is not strictly enforced and will only warn.
  • Add engine-strict=true to .npmrc to fail installs/deploys on incompatible runtimes.
🤖 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` around lines 5 - 8, Add strict engine enforcement by updating
the project's npm configuration: open the existing .npmrc (which currently
contains `@jsr`:registry=...) and add the line engine-strict=true so the
package.json "engines" block (node >=20.0.0, pnpm >=10.0.0) is enforced and
installs fail on incompatible runtimes; save and commit the updated .npmrc
alongside the package.json changes.

@Junman140 Junman140 merged commit 4f53964 into Pi-Defi-world:dev Jun 4, 2026
2 of 3 checks passed
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.

package.json engines field missing – T

2 participants