Skip to content

feat(typescript-eslint): improve undefined extension handling #10177

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

Conversation

mstykow
Copy link
Contributor

@mstykow mstykow commented Oct 19, 2024

PR Checklist

Overview

Addresses #10176 by checking if any of the extensions are undefined and throwing a helpful error if true.

An alternative would be to filter out undefined extensions and again swallow the errors silently. But I think it's overall an improvement to actually raise an error because an undefined an extension is likely not what the user intended.

@typescript-eslint
Copy link
Contributor

Thanks for the PR, @mstykow!

typescript-eslint is a 100% community driven project, and we are incredibly grateful that you are contributing to that community.

The core maintainers work on this in their personal time, so please understand that it may not be possible for them to review your work immediately.

Thanks again!


🙏 Please, if you or your company is finding typescript-eslint valuable, help us sustain the project by sponsoring it transparently on https://opencollective.com/typescript-eslint.

Copy link

netlify bot commented Oct 19, 2024

Deploy Preview for typescript-eslint ready!

Name Link
🔨 Latest commit 988d742
🔍 Latest deploy log https://app.netlify.com/sites/typescript-eslint/deploys/671a50b6f16eae0008a2f919
😎 Deploy Preview https://deploy-preview-10177--typescript-eslint.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: 96 (🟢 up 2 from production)
Accessibility: 100 (no change from production)
Best Practices: 92 (no change from production)
SEO: 98 (no change from production)
PWA: 80 (no change from production)
View the detailed breakdown and full score reports

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

Copy link

nx-cloud bot commented Oct 19, 2024

Copy link

codecov bot commented Oct 19, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 86.19%. Comparing base (af4743f) to head (988d742).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #10177   +/-   ##
=======================================
  Coverage   86.18%   86.19%           
=======================================
  Files         430      430           
  Lines       15055    15064    +9     
  Branches     4368     4371    +3     
=======================================
+ Hits        12975    12984    +9     
  Misses       1728     1728           
  Partials      352      352           
Flag Coverage Δ
unittest 86.19% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
packages/typescript-eslint/src/config-helper.ts 100.00% <100.00%> (ø)

@mstykow mstykow marked this pull request as ready for review October 19, 2024 16:32
Addresses typescript-eslint#10176 by checking if any of the extensions are undefined and throwing a helpful error if true.

Signed-off-by: Maxim Stykow <maxim.stykow@gmail.com>
@mstykow mstykow force-pushed the feat-improve-undefined-extensions-handling branch from 015b762 to 80f6ba5 Compare October 19, 2024 16:59
Copy link
Member

@JoshuaKGoldberg JoshuaKGoldberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A good start! 🚀

@JoshuaKGoldberg JoshuaKGoldberg added the awaiting response Issues waiting for a reply from the OP or another party label Oct 22, 2024
@github-actions github-actions bot removed the awaiting response Issues waiting for a reply from the OP or another party label Oct 22, 2024
Copy link
Member

@JoshuaKGoldberg JoshuaKGoldberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@JoshuaKGoldberg JoshuaKGoldberg added the 1 approval >=1 team member has approved this PR; we're now leaving it open for more reviews before we merge label Oct 22, 2024
Signed-off-by: Maxim Stykow <maxim.stykow@gmail.com>
@mstykow
Copy link
Contributor Author

mstykow commented Oct 22, 2024

@JoshuaKGoldberg sorry to bug you for another review but i didn't know how to retrigger the pipeline without another commit (it was failing at a step that looked unrelated to my changes).

@github-actions github-actions bot removed the 1 approval >=1 team member has approved this PR; we're now leaving it open for more reviews before we merge label Oct 22, 2024
@mstykow
Copy link
Contributor Author

mstykow commented Oct 23, 2024

@JoshuaKGoldberg friendly ping :)

@JoshuaKGoldberg
Copy link
Member

@mstykow mstykow requested a review from JoshuaKGoldberg yesterday

Looks like you found the right way 🙂! Any PR that's not labeled awaiting changes is on our queue to review when we get a chance. Re-requesting review explicitly goes through an automation our end to remove the label.

Copy link
Member

@JoshuaKGoldberg JoshuaKGoldberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Just one suggestion that we can auto-apply before merge IMO.

@JoshuaKGoldberg JoshuaKGoldberg added the 1 approval >=1 team member has approved this PR; we're now leaving it open for more reviews before we merge label Oct 23, 2024
Signed-off-by: Maxim Stykow <maxim.stykow@gmail.com>
@github-actions github-actions bot removed the 1 approval >=1 team member has approved this PR; we're now leaving it open for more reviews before we merge label Oct 23, 2024
kirkwaiblinger
kirkwaiblinger previously approved these changes Oct 23, 2024
Copy link
Member

@kirkwaiblinger kirkwaiblinger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, thanks!

@kirkwaiblinger kirkwaiblinger merged commit ad9d3ba into typescript-eslint:main Oct 24, 2024
62 of 63 checks passed
@mstykow mstykow deleted the feat-improve-undefined-extensions-handling branch October 25, 2024 07:29
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 2, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Bug: better error handling for undefined extensions
3 participants