Skip to content

[BUG] unsupported engine warning only displays after initial install #4987

@lukekarrys

Description

@lukekarrys

Is there an existing issue for this?

  • I have searched the existing issues

This issue exists in the latest npm version

  • I am using the latest npm

Current Behavior

❯ npm i npm@latest

added 1 package, and audited 202 packages in 2s

11 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities

❯ npm ls node-gyp
[email protected] /Users/lukekarrys/Desktop/garbage/npm-test
└─┬ [email protected]
  ├─┬ @npmcli/[email protected]
  │ └── [email protected] deduped
  └── [email protected]


❯ npm i npm
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE   package: '[email protected]',
npm WARN EBADENGINE   required: { node: '^12.22 || ^14.13 || >=16' },
npm WARN EBADENGINE   current: { node: 'v12.13.0', npm: '8.12.0' }
npm WARN EBADENGINE }

up to date, audited 202 packages in 985ms

11 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities

❯ npm ls node-gyp
[email protected] /Users/lukekarrys/Desktop/garbage/npm-test
└─┬ [email protected]
  ├─┬ @npmcli/[email protected]
  │ └── [email protected] deduped
  └── [email protected]


❯ npm i npm
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE   package: '[email protected]',
npm WARN EBADENGINE   required: { node: '^12.22 || ^14.13 || >=16' },
npm WARN EBADENGINE   current: { node: 'v12.13.0', npm: '8.12.0' }
npm WARN EBADENGINE }

up to date, audited 202 packages in 934ms

11 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities

Expected Behavior

I expect to see the unsupported engines warning on the initial install.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Bugthing that needs fixingRelease 8.xwork is associated with a specific npm 8 release

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions