[test] Enable type-unaware versions of disabled typed-aware lint rules - #24873
Merged
Conversation
eps1lon
marked this pull request as ready for review
February 12, 2021 11:28
oliviertassinari
approved these changes
Feb 12, 2021
oliviertassinari
left a comment
Member
There was a problem hiding this comment.
Agree with all you said.
TIMING=1 yarn lint returns in this PR and in my env:
| Rule | Time (ms) | Relative |
|---|---|---|
| import/no-cycle | 43641.930 | 29.9% |
| mocha/no-nested-tests | 10677.706 | 7.3% |
| mocha/no-identical-title | 10191.786 | 7.0% |
| mocha/no-exclusive-tests | 7090.581 | 4.9% |
| mocha/no-skipped-tests | 6822.207 | 4.7% |
| import/extensions | 3665.945 | 2.5% |
| mocha/no-pending-tests | 3598.851 | 2.5% |
| mocha/no-async-describe | 3582.821 | 2.5% |
| mocha/no-global-tests | 3578.034 | 2.5% |
| mocha/no-top-level-hooks | 3531.212 | 2.4% |
On a related note, I wonder why eslint runs in 3mins now, when it was running in /2 the time in #21758 6 months ago. Maybe it's pickers related.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Re-enable the following lint rules:
dot-notationno-implied-evalno-throw-literalContext
Noticed during #24810 that we have disabled some type-aware lint rules for "performance considerations". I suspect this actually refers to the required type checking not because the rules themselves are slow.
If they were in fact only disabled to avoid type-ware linting, we should enable their type-unaware counterparts. The typescript-eslint repo says these versions "don't work with typescript" but it's unclear what they mean: do these versions have false-negatives or false-positives1? False positives would be fine since we don't expect linting to catch every error anyway. false-negatives would be more problematic but I haven't seen false-negatives yet.
1
false-negative: error reported that isn't one
false-positive: no error reported even though it is one