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

fix(linter): correctly override linter presets #1606

Merged
merged 1 commit into from
Jan 20, 2024
Merged

Conversation

Conaclos
Copy link
Member

@Conaclos Conaclos commented Jan 19, 2024

Summary

Fix #1349

The issue was coming from the default value of recommended that resulted in adding disabled rules in the rule's filter.
I solved the issue by first merging config with overrides before extracting the enabled rules.
This makes the code simpler and more robust because we reuse the config merge logic.

To reduce the potential cost of cloning the config for every file, I used Cow. Thus, the config is only cloned when a file has at least one override.

  • Add tests
  • Add Changelog entry

Copy link

netlify bot commented Jan 19, 2024

Deploy Preview for biomejs ready!

Name Link
🔨 Latest commit b6bb7ec
🔍 Latest deploy log https://app.netlify.com/sites/biomejs/deploys/65abbc0954edad0008cce2f6
😎 Deploy Preview https://deploy-preview-1606--biomejs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 100 (🟢 up 1 from production)
Accessibility: 97 (no change from production)
Best Practices: 100 (no change from production)
SEO: 93 (no change from production)
PWA: -
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify site configuration.

@github-actions github-actions bot added A-Project Area: project A-Tooling Area: internal tools labels Jan 19, 2024
Copy link
Contributor

Parser conformance results on

js/262

Test result main count This PR count Difference
Total 49701 49701 0
Passed 48721 48721 0
Failed 980 980 0
Panics 0 0 0
Coverage 98.03% 98.03% 0.00%

jsx/babel

Test result main count This PR count Difference
Total 40 40 0
Passed 37 37 0
Failed 3 3 0
Panics 0 0 0
Coverage 92.50% 92.50% 0.00%

symbols/microsoft

Test result main count This PR count Difference
Total 6322 6322 0
Passed 2036 2036 0
Failed 4286 4286 0
Panics 0 0 0
Coverage 32.20% 32.20% 0.00%

ts/babel

Test result main count This PR count Difference
Total 662 662 0
Passed 592 592 0
Failed 70 70 0
Panics 0 0 0
Coverage 89.43% 89.43% 0.00%

ts/microsoft

Test result main count This PR count Difference
Total 17646 17646 0
Passed 13452 13452 0
Failed 4192 4192 0
Panics 2 2 0
Coverage 76.23% 76.23% 0.00%

@Conaclos Conaclos force-pushed the conaclos/linter/1349 branch from 7643adb to b6bb7ec Compare January 20, 2024 12:26
@github-actions github-actions bot added A-CLI Area: CLI A-Website Area: website A-Changelog Area: changelog labels Jan 20, 2024
@Conaclos Conaclos marked this pull request as ready for review January 20, 2024 12:27
@Conaclos Conaclos merged commit a03bf85 into main Jan 20, 2024
21 checks passed
@Conaclos Conaclos deleted the conaclos/linter/1349 branch January 20, 2024 13:25
ematipico pushed a commit to DaniGuardiola/biome that referenced this pull request Jan 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Changelog Area: changelog A-CLI Area: CLI A-Project Area: project A-Tooling Area: internal tools A-Website Area: website
Projects
None yet
Development

Successfully merging this pull request may close these issues.

💅 Biome encountered an unexpected error when setting noExplicitAny=off in an override in CLI
1 participant