question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Feature] Add `--silent` back

See original GitHub issue

Describe the user story

IMO, this was an important feature, heavily requested for the original yarn. Not sure why it was taken out. Really useful for CI environments and a no-brainer for most CLI tools out there. As an example, this is how a fairly typical CI log would look for us, making it really hard to mentally parse and navigate.

11:23:44  ➤ YN0002: │ @company/molecule-masked-field@npm:0.23.1::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-masked-field%2F-%2F%40bubble-ui%2Fmolecule-masked-field-0.23.1.tgz [d5ba3] doesn't provide @bubble-dev/typescript-config (p8fd76), requested by @bubble-dev/types
11:23:44  ➤ YN0002: │ @company/molecule-masked-field@npm:0.23.1::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-masked-field%2F-%2F%40bubble-ui%2Fmolecule-masked-field-0.23.1.tgz [d5ba3] doesn't provide lottie-ios (pdcaff), requested by @company/molecule-loader
11:23:44  ➤ YN0002: │ @company/molecule-masked-field@npm:0.23.1::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-masked-field%2F-%2F%40bubble-ui%2Fmolecule-masked-field-0.23.1.tgz [d5ba3] doesn't provide lottie-react-native (p05561), requested by @company/molecule-loader
11:23:44  ➤ YN0002: │ @company/molecule-masked-field@npm:0.23.1::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-masked-field%2F-%2F%40bubble-ui%2Fmolecule-masked-field-0.23.1.tgz [d5ba3] doesn't provide prop-types (pf82f5), requested by proper-types
11:23:44  ➤ YN0002: │ @company/molecule-masked-field@npm:0.23.1::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-masked-field%2F-%2F%40bubble-ui%2Fmolecule-masked-field-0.23.1.tgz [d5ba3] doesn't provide prop-types (p9eab9), requested by @company/higher-order-components
11:23:44  ➤ YN0002: │ @company/molecule-masked-field@npm:0.23.1::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-masked-field%2F-%2F%40bubble-ui%2Fmolecule-masked-field-0.23.1.tgz [d5ba3] doesn't provide ramda (pde188), requested by @company/particle-colors
11:23:44  ➤ YN0002: │ @company/molecule-masked-field@npm:0.23.1::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-masked-field%2F-%2F%40bubble-ui%2Fmolecule-masked-field-0.23.1.tgz [d5ba3] doesn't provide ramda (pb2e74), requested by @company/atom-spacer-horizontal
11:23:44  ➤ YN0002: │ @company/molecule-masked-field@npm:0.23.1::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-masked-field%2F-%2F%40bubble-ui%2Fmolecule-masked-field-0.23.1.tgz [d5ba3] doesn't provide ramda (pcebba), requested by @company/atom-spacer-vertical
11:23:44  ➤ YN0002: │ @company/molecule-masked-field@npm:0.23.1::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-masked-field%2F-%2F%40bubble-ui%2Fmolecule-masked-field-0.23.1.tgz [d5ba3] doesn't provide ramda (pacec0), requested by @company/primitive-motion
11:23:44  ➤ YN0002: │ @company/molecule-masked-field@npm:0.23.1::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-masked-field%2F-%2F%40bubble-ui%2Fmolecule-masked-field-0.23.1.tgz [d5ba3] doesn't provide ramda (p40221), requested by @company/molecule-link-detail
11:23:44  ➤ YN0002: │ @company/molecule-masked-field@npm:0.23.1::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-masked-field%2F-%2F%40bubble-ui%2Fmolecule-masked-field-0.23.1.tgz [d5ba3] doesn't provide react-context-props (p367ba), requested by @company/higher-order-components
11:23:44  ➤ YN0002: │ @company/molecule-masked-field@npm:0.23.1::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-masked-field%2F-%2F%40bubble-ui%2Fmolecule-masked-field-0.23.1.tgz [d5ba3] doesn't provide react-motion (pb0cbc), requested by @company/primitive-motion
11:23:44  ➤ YN0002: │ @company/molecule-mega-paragraph@npm:0.17.0::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-mega-paragraph%2F-%2F%40bubble-ui%2Fmolecule-mega-paragraph-0.17.0.tgz [d5ba3] doesn't provide prop-types (p4e34a), requested by proper-types
11:23:44  ➤ YN0002: │ @company/molecule-mega-paragraph@npm:0.17.0::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-mega-paragraph%2F-%2F%40bubble-ui%2Fmolecule-mega-paragraph-0.17.0.tgz [d5ba3] doesn't provide ramda (p8c8c8), requested by @company/particle-colors
11:23:44  ➤ YN0002: │ @company/molecule-mega-paragraph@npm:0.17.0::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-mega-paragraph%2F-%2F%40bubble-ui%2Fmolecule-mega-paragraph-0.17.0.tgz [d5ba3] doesn't provide ramda (paad60), requested by @company/hoc-with-debug-mode
11:23:44  ➤ YN0002: │ @company/molecule-mega-title-display@npm:0.17.0::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-mega-title-display%2F-%2F%40bubble-ui%2Fmolecule-mega-title-display-0.17.0.tgz [d5ba3] doesn't provide prop-types (pb11c2), requested by proper-types
11:23:44  ➤ YN0002: │ @company/molecule-mega-title-display@npm:0.17.0::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-mega-title-display%2F-%2F%40bubble-ui%2Fmolecule-mega-title-display-0.17.0.tgz [d5ba3] doesn't provide ramda (p38edc), requested by @company/particle-colors
11:23:44  ➤ YN0002: │ @company/molecule-mega-title-display@npm:0.17.0::__archiveUrl=https%3A%2F%2Fartifactory.company.net%2Fartifactory%2Fapi%2Fnpm%2Fv-npm-production%2F%40bubble-ui%2Fmolecule-mega-title-display%2F-%2F%40bubble-ui%2Fmolecule-mega-title-display-0.17.0.tgz [d5ba3] doesn't provide ramda (p7e63e), requested by @company/hoc-with-debug-mode
# ...

As far as I could gather, --silent was added as a “hidden” flag for compatibility purposes - but doesn’t really do anything. This is bound to trip people up.

Describe the solution you’d like

yarn --silent should not print anything at all and return the appropriate status code.

Describe alternatives you’ve considered

Right now, we are adding a bunch of general exclusions in .yarnrc.yml as logFilters for each project. Maybe those could be exposed as CLI flags?

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:12
  • Comments:9 (4 by maintainers)

github_iconTop GitHub Comments

6reactions
nfantonecommented, Oct 11, 2021

Agree with @davwheat here. Environments such as Docker and CI/CD were the main use cases for the addition of --silent in v1.

@arcanis I’ve been thinking about this:

The --silent flag was a blanket flag that couldn’t be controlled;

Isn’t that the exact reason why it was useful in the first place? When applying this kind of logging control flags, like --quiet, --verbose or --silent, having a dedicated, aptly named option for quickly altering the output is the right way to think about them. Giving users finer controls on that is great, but it should not come at the detriment of what is arguably the most common scenario you’d want to apply those controls in, anyway.

6reactions
nfantonecommented, Oct 8, 2021

Yeah - I’m aware of what the logs are saying. Thanks for pointing that out, but this is not what this issue is about, really.

Like I mentioned before, the pattern: * solution doesn’t work (requires at least one character that is not a wildcard). And also yarn config set logFilters --json '[{"pattern": "*", "level": "discard"}]' seems awfully verbose and awkward when all we’d like is --silent.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to Turn On/Off Silent Mode on iPhone Without the Switch
Method 2. Turn On/Off Silent Mode Using Back Tap ; Go to Accessibility > Touch > Back Tap.
Read more >
How to Automatically Toggle Silent Mode on Android: 3 Methods
1. Toggle Silent Mode Using Do Not Disturb · 2. Control Your Android Ringer With IFTTT · 3. Advanced Control Over Silent Mode...
Read more >
How to Quickly Set iPhone Mute (in Silent Mode) By Tapping ...
You can now avoid toggling the ringer button always to put the iPhone in silent mode, using the Back Tap feature. Back Tap...
Read more >
How to put your iPhone on vibrate, ring or silent mode
Turn Ring/Silent mode on or off on your iPhone · Change ringtones, sounds and vibrations · Change ringtone and alert volume with buttons...
Read more >
Limit interruptions with Do Not Disturb on Android - Android Help
Option 1: Silence sounds during certain times · Open your phone's Settings app. · Tap Sound And then Do Not Disturb preferences. ·...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found