npm / npm/cli

[BUG] Missing minified files after second install

Open
#4,174 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Bug Needs Triage Release 8.x
Dominant language
JavaScript
Stars
10.1k
Forks
4.7k
Avg merge
2d 2h
Merged PRs (30d)
19

Description

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

Missing .min.js files.

Expected Behavior

Existing .min.js files.

Steps To Reproduce
  1. empty dir
  2. npm init
  3. npm i bignumber.js@9.0.1
  4. Notice .min.js files are present in node_modules/bignumber.js/
  5. Delete node_modules and .package-lock.json so only file remaining is package.json
  6. npm i
  7. Notice missing .min.js files are present in node_modules/bignumber.js/
Environment
  • npm: 8.3.0
  • Node: v16.13.1
  • OS: Win10
  • platform: desktop
  • npm config:
; "builtin" config from C:\Users\Alex\AppData\Roaming\npm\node_modules\npm\npmrc

prefix = "C:\\Users\\Alex\\AppData\\Roaming\\npm"

; node bin location = C:\Program Files\nodejs\node.exe
; cwd = C:\Developer\playground\npm
; HOME = C:\Users\Alex
; Run `npm config ls -l` to show all defaults.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the two npm install sequences in an empty directory with bignumber.js@9.0.1, then compare the package contents after each install. Investigate why the second install omits the .min.js files; done means the files are present after reinstalling from package.json, with the reproduction no longer showing the discrepancy.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, node.js
Domain
cli, tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.