-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Labels
Bugthing that needs fixingthing that needs fixingPriority 2secondary priority issuesecondary priority issueRelease 7.xwork is associated with a specific npm 7 releasework is associated with a specific npm 7 release
Description
Is there an existing issue for this?
- I have searched the existing issues
Current Behavior
Progressbar is shown when it should not:
$ TERM=dumb npm install --progress=false
[ .........] - idealTree: timing idealTree Completed in 388m
Expected Behavior
Progressbar disabling works:
$ TERM=dumb npm install --progress=false
up to date, audited 702 packages in 2s
Steps To Reproduce
The 'progress' config value and TERM=dumb checks work correctly in setup-log.js.
But later on, progress is enabled unconditionally, regardless of the config, here:
./node_modules/@npmcli/arborist/lib/tracker.js:35: this.log.enableProgress()
Disabling this line fixes the behaviour, so TERM=dumb and --progress=false have an effect again.
Note that there are other places that still disable/enable progress unconditionally without regards to the config setting, these might need review as well:
$ fgrep enableProgress . -rn
./node_modules/@npmcli/arborist/lib/tracker.js:35: this.log.enableProgress() // <- unconditional progress bar
./node_modules/libnpmexec/lib/run-script.js:82: log.enableProgress()
./lib/config.js:132: this.npm.log.enableProgress()
./lib/explore.js:87: this.npm.log.enableProgress()
./lib/init.js:164: this.npm.log.enableProgress()
Environment
- OS: linux
- npm: 7.14.0
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
Bugthing that needs fixingthing that needs fixingPriority 2secondary priority issuesecondary priority issueRelease 7.xwork is associated with a specific npm 7 releasework is associated with a specific npm 7 release