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

should sprocket warn or fail when an unknown rule is passed to --except? #38

Open
a-frantz opened this issue Oct 23, 2024 · 3 comments
Open

Comments

@a-frantz
Copy link
Member

Current behavior is essentially ignoring bad values to --except. They are assumed to be valid and never checked. The result of passing an unknown rule to --except is the same as just not specifying the arg at all. Is this desired behavior?

@a-frantz
Copy link
Member Author

Thoughts on this @adthrasher @peterhuene ?

I think my and Peter talked about this back when the --except flag was first added, but I'm not sure we made the right call anymore.

@adthrasher
Copy link
Member

I'd probably go with a warning. It's worth noting to the user that a specified rule doesn't exist, but I don't think it's necessarily an error.

@a-frantz
Copy link
Member Author

I'd probably go with a warning. It's worth noting to the user that a specified rule doesn't exist, but I don't think it's necessarily an error.

Should it just be prepended to the list of printed diagnostics? I assume that if we don't consider it an error, we'll continue with the full lint analysis. That would be a special case, as I don't think sprocket currently emits any diagnostics of its own.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants