Skip to content

[BUG] npm does not respect package.json dependencies #996

@yuri-karadzhov

Description

@yuri-karadzhov

What / Why

Npm does not respect package.json dependencies. Lock file is missing and switched off in .npmrc:

package-lock=false

In package.json dependencies are set to latest minor e.g.

"dependencies": {
  "@hqjs/hq": "^0.0.15"
}

later versions of dependencies are available (e.g. @hqjs/hq@0.0.16), but during npm install instead of latest minor the exact ones (ignoring minor flag) that are specified in package.json are installed (e.g. @hqjs/hq@0.0.15).

When

Every time during npm install

Where

Any npm public repository

Steps to Reproduce

  1. Create new project folder
  2. Create .npmrc configuration inside this project folder with package-lock=false content
  3. Init npm project with npm init
  4. Specify dependencies "@hqjs/hq": "^0.0.15"
  5. Run npm install

Current Behavior

@hqjs/hq@0.0.15 will be installed. Newest version 0.0.16 will be ignored despite of package.json configuration

Expected Behavior

@hqjs/hq@0.0.16 should be installed (as a latest minor for this moment)

System

OS: macOS Catalina 10.15.3
node: v12.6.0
npm: 6.14.2

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions