Skip to content
This repository was archived by the owner on Aug 11, 2022. It is now read-only.
This repository was archived by the owner on Aug 11, 2022. It is now read-only.

why is package-lock being ignored? #17979

@kidd3

Description

@kidd3

I'm opening this issue because:

I had been using npm version 5.0.3 in my project and the package-lock.json file had been working exactly as I expected. However, upon updating my npm version to 5.3.0, my package-lock.json no longer works.

Example:

package.json:
"Package-A": "^v1.0.0"

package-lock.json:
"Package-A": { version: 1.0.0 }

When I have no node_modules folder and I attempt to do a fresh npm install, previously in npm version 5.0.3 this would install version 1.0.0 (as this is what the lock file states). However, now on npm version 5.3.0, a fresh install will cause any version from the range ^v1.0.0 to be installed, completely ignoring the lock file.

I want my project to be installed identical every time based on the lock file, this surely is what a lock file is supposed to do?

How can I make my project useable in a projection environment to ensure that the lock file is the only point of reference for npm install?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions