Cursor Cloud Agent - Node Version 22.22

Where does the bug appear (feature/product)?

Background Agent (GitHub, Slack, Web, Linear)

Describe the Bug

One of our npm packages (@posthog/posthog-node) requires node 22 >22.22

Cursor Cloud Agent comes with node 22.21

.nvmrc appears to be ignored

I cannot downgrade posthog due to a CVE in the prior version

Steps to Reproduce

init a new repo
connect it to cursor
install [email protected]
try to start a background agent

Boot fails


INFO Successfully refreshed access token in git config. {"hostname":"github.com"}
INFO exec-daemon-gh: Writing token to gh hosts.yml

Scope: all 3 workspace projects
Lockfile is up to date, resolution step is skipped
 ERR_PNPM_UNSUPPORTED_ENGINE  Unsupported environment (bad pnpm and/or Node.js version)

Your Node version is incompatible with "@posthog/[email protected](@ai-sdk/[email protected])(@modelcontextprotocol/[email protected](@cfworker/[email protected])([email protected])([email protected]))(@opentelemetry/[email protected])(@opentelemetry/[email protected](@opentelemetry/[email protected]))([email protected])([email protected]([email protected]))([email protected])([email protected])([email protected]([email protected]))".

Expected version: ^20.20.0 || >=22.22.0
Got: v22.21.1

This is happening because the package's manifest has an engines.node field specified.
To fix this issue, install the required Node version.

Expected Behavior

Cloud agent boots and continues to install

Operating System

Linux

Version Information

Cloud Agent

Does this stop you from using Cursor

Yes - Cursor is unusable

Hey, thanks for the report.

This is a valid bug. Cloud Agent really doesn’t pick up .nvmrc and ships with a fixed Node version. I’ll pass this to the team.

Unfortunately, the workaround is limited right now. You can try setting "engines": { "node": ">=22.21" } in package.json with "engineStrict": false if that works for your project, but I get that this doesn’t solve the CVE issue in the older PostHog version.

Let me know if anything changes on your side.

Nice thanks.

For those who need a workaround I was able to change my install command to

pnpm install --config.engine-strict=false

Obviously not ideal but it works

I also attempted the Dockerfile setup but gave up as it was hard to debug