Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] loglevel is ignored by by fund and audit on npm install #1533

Closed
bnb opened this issue Jul 17, 2020 · 4 comments
Closed

[BUG] loglevel is ignored by by fund and audit on npm install #1533

bnb opened this issue Jul 17, 2020 · 4 comments
Assignees
Labels
Bug thing that needs fixing semver:major backwards-incompatible breaking changes

Comments

@bnb
Copy link
Contributor

bnb commented Jul 17, 2020

What / Why

Currently, when you run npm install <module> --silent (or any other log filter), both fund and audit are logged. (Credit where credit is due: Tweet)

When

  • Audit: Whenever I npm install a module.
  • Fund: Whenever I npm install a module that resolves a module with a fund property in its dependency tree.

Where

  • npm/cli

Current Behavior

  • console.log()s both fund and audit no matter

Steps to Reproduce

  • n/a

Expected Behavior

  • Both audit and fund should likely both be considered notice level logs and not appear in anything more strict than that (since notice is the default, this also makes sense with the current default behavior of both of them).

Credit where Credit is Due

@darcyclarke darcyclarke added Bug thing that needs fixing Release 6.x work is associated with a specific npm 6 release semver:patch semver patch level for changes labels Jul 17, 2020
@darcyclarke darcyclarke added this to the OSS - Sprint 11 milestone Jul 17, 2020
@darcyclarke
Copy link
Contributor

/xx @isaacs @ruyadorno has this come up before? I don't remember us talking about it. I'm guessing we could reuse how we implemented --no-audit & --no-fund (?)

@bnb
Copy link
Contributor Author

bnb commented Jul 17, 2020

@darcyclarke I think this may be a major change, depending on if people rely on the fund or audit output in the console.

@isaacs
Copy link
Contributor

isaacs commented Jul 17, 2020

Yeah, we should skip those methods when loglevel is set to silent for sure.

I'd call this a bug, but as @bnb suggests, it's a SemVer-major fix. I'll get it done in the v7 branch right now.

@darcyclarke darcyclarke added semver:major backwards-incompatible breaking changes and removed Release 6.x work is associated with a specific npm 6 release semver:patch semver patch level for changes labels Jul 22, 2020
@isaacs
Copy link
Contributor

isaacs commented Aug 4, 2020

It's covered in v7. Closing now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug thing that needs fixing semver:major backwards-incompatible breaking changes
Projects
None yet
Development

No branches or pull requests

3 participants