should throw an error when disabling a non-existent rule
See original GitHub issueTell us about your environment
- **ESLint Version:**master
- Node Version:
- npm Version:
What parser (default, Babel-ESLint, etc.) are you using? default
What did you do? Please include the actual source code causing the issue.
/* eslint foo: 0 */
// edit: or in a config file
{
"rules": { "foo": 0}
}
What did you expect to happen?
throw an error, since there is no rule named foo
.
What actually happened? Please include the actual, raw output from ESLint.
no error thrown.
Issue Analytics
- State:
- Created 6 years ago
- Comments:33 (33 by maintainers)
Top Results From Across the Web
throwing an eslint error if disabling a rule that is not triggered
I'm heavily using eslint in a React project and there seems that there could be many practical uses for such a rule. eslint...
Read more >Errors and Warnings — Verilator 5.005 documentation
Disable the warning globally invoking Verilator with the -Wno-{warning-code} option. This should be avoided, as it removes all checking across the designs, and ......
Read more >Documentation: 15: 43.9. Errors and Messages - PostgreSQL
This example will abort the transaction with the given error message and hint: RAISE EXCEPTION 'Nonexistent ID --> %', user_id USING HINT =...
Read more >12 Errors and Error Handling
Generated errors are exceptions of class exit or throw. ... The only exception to this rule is the class error with the reason...
Read more >NGINX only not working when Custom Error Documents is ...
Go into Apache & NGINX settings -> disable NGINX Proxy. This will put the server into the nginx-only operation. Wordpress site under that ......
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
TSC Summary: The main issue is that if a rule is disabled, either in a config file or in an inline comment, the disable would silently do nothing and the user would never know. We thought this would be a problem for end users, but Jordan Harband pointed out that this has a large negative effect on plugin maintainers that want to support multiple versions of ESLint. This issue was originally created and accepted as a bug and I don’t believe sufficient discussion has occurred that takes into account the negative side effects of the original design. I believe this should not be in 6.0.0 and that this needs more discussion, possibly even an RFC.
TSC Question: Should we remove this from 6.0.0 and ask for further design discussion? As an ancillary question, should we require an RFC for this change?
thanks @kaicataldo Ill hold off. Plenty of other stuff I can get done.