Uh oh!
There was an error while loading. Please reload this page.
Restore ESLint warnings as errors (ignoring them for now) - #4382
Conversation
d025d55 to
3c84ac6CompareCurrently, `yarn lint` produces a bunch of warnings from ESLint. These warnings were added in a previous commit that upgraded ESLint packages as a way to avoid fixing lint violations created by the upgrade. However, this causes two problems: 1. They produce a lot of noise that makes it very difficult to find true errors, especially when looking at a CI run. 2. They allow new instances of these violations to show up (because warnings don't cause `eslint` to fail). This commit removes the overrides from the ESLint config for these rules so that they go back to being errors and adds `eslint-disable` directives above the lines that cause the violations. Note that this is not intended to be a long-term solution, and in the future, we should dedicate time to either fixing the violations or explaining why ignoring them is necessary.
3c84ac6 to
4476162Compare
This comment was marked as duplicate.
This comment was marked as duplicate.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
MajorLift
left a comment
There was a problem hiding this comment.
LGTM! Hopefully the presence of these comments nudge people towards providing an explanation when disabling lint rules in general.
In future PRs, enabling the 'prefer' rules should remove the need for some style guide entries, and no-unnecessary-type-assertion should also be helpful for minimizing redundant or silent-failure assertions. I can create a PR for those if you don't already have them planned @mcmire
mcmire
commented
Jun 10, 2024
@MajorLift I don't have plans for the changes you mention, but they sound good, so feel free to create tickets/PRs! |
rekmarks
left a comment
There was a problem hiding this comment.
My terminal thanks you for this change. 🙇
Explanation
Currently,
yarn lintproduces a bunch of warnings from ESLint. These warnings were added in a previous commit that upgraded ESLint packages as a way to avoid fixing lint violations created by the upgrade. However, this causes two problems:eslintto fail).This commit removes the overrides from the ESLint config for these rules so that they go back to being errors and adds
eslint-disabledirectives above the lines that cause the violations. Note that this is not intended to be a long-term solution, and in the future, we should dedicate time to either fixing the violations or explaining why ignoring them is necessary.References
Fixes#4381.
Changelog
(There are no changes to functionality.)
Checklist