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

Add --quiet-deprecation-warnings flag #6677

Closed
peteduel opened this issue Feb 20, 2023 · 7 comments · Fixed by #6724
Closed

Add --quiet-deprecation-warnings flag #6677

peteduel opened this issue Feb 20, 2023 · 7 comments · Fixed by #6724
Labels
status: ready to implement is ready to be worked on by someone type: enhancement a new feature that isn't related to rules

Comments

@peteduel
Copy link

What is the problem you're trying to solve?

A page of deprecation warnings on v15.x

What solution would you like to see?

The quiet flag (or some other means) to opt-out of the warnings

@Mouvedia
Copy link
Contributor

related discussion: #6561 (comment)

@ybiquitous ybiquitous added the status: needs discussion triage needs further discussion label Feb 21, 2023
@ybiquitous
Copy link
Member

@peteduel @Mouvedia Thanks for the report and for sharing the related discussion.

The current quiet option handles only linting problems with a severity (error or warning). On the other hand, deprecation warnings are not linting problems, so expanding the current option semantics may break something.

If we want to avoid such a breaking possibility, we may need to add a new option to suppress deprecation warnings.

What do you think? @jeddy3

@jeddy3 jeddy3 changed the title Quiet flag should silence deprecation warnings Add option to suppress deprecation warnings Feb 21, 2023
@jeddy3
Copy link
Member

jeddy3 commented Feb 21, 2023

If we want to avoid such a breaking possibility, we may need to add a new option to suppress deprecation warnings.

We could accept a PR for a --quiet-deprecation-warnings flag. It's explicit and clear.

@Mouvedia
Copy link
Contributor

Mouvedia commented Feb 21, 2023

Should we add a disclaimer for the SKIP_WARNINGS environment variable in the documentation?

@ybiquitous
Copy link
Member

@jeddy3 Thanks for the answer. Yes, adding a new flag may be safe. 👍🏼

@Mouvedia Where does that environment variable come from? I believe we have not used any environment variables in Stylelint... 🤔

@Mouvedia
Copy link
Contributor

@ybiquitous you are right.
I misread

You can use environmental variables in your formatter. For example, pass `SKIP_WARNINGS`:

@jeddy3 jeddy3 changed the title Add option to suppress deprecation warnings Add --quiet-deprecation-warnings flag Feb 23, 2023
@jeddy3 jeddy3 added status: ready to implement is ready to be worked on by someone type: enhancement a new feature that isn't related to rules and removed status: needs discussion triage needs further discussion labels Feb 23, 2023
@jeddy3
Copy link
Member

jeddy3 commented Feb 23, 2023

I've labelled the issue as ready to implement. Please consider contributing if you have time.

mattxwang added a commit that referenced this issue Mar 22, 2023
Closes #6677.

---------

Co-authored-by: Masafumi Koba <473530+ybiquitous@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: ready to implement is ready to be worked on by someone type: enhancement a new feature that isn't related to rules
Development

Successfully merging a pull request may close this issue.

4 participants