Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feat(typescript-estree): added allowInvalidAST option to not throw on invalid tokens#6247

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Conversation

JoshuaKGoldberg
Copy link
Member

@JoshuaKGoldbergJoshuaKGoldberg commentedDec 18, 2022
edited
Loading

PR Checklist

Overview

Adds an opt-inallowInvalidAST option to@typescript-eslint/typescript-estree and@typescript-eslint/parser. It enables checks for some known cases where TypeScript reports a syntactic issue as semantic:

Note that some previously reported cases seem to now be reported as syntactic issues by TypeScript:

Does not tackle more difficult cases:

@typescript-eslint
Copy link
Contributor

Thanks for the PR,@JoshuaKGoldberg!

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 onhttps://opencollective.com/typescript-eslint.

@nx-cloud
Copy link

nx-cloudbot commentedDec 18, 2022
edited
Loading

☁️ Nx Cloud Report

CI is running/has finished running commands for commit7144e90. As they complete they will appear below. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this branch


✅ Successfully ran 51 targets

Sent with 💌 fromNxCloud.

@netlify
Copy link

netlifybot commentedDec 18, 2022
edited
Loading

Deploy Preview fortypescript-eslint ready!

NameLink
🔨 Latest commit7144e90
🔍 Latest deploy loghttps://app.netlify.com/sites/typescript-eslint/deploys/64045ee30711b70008911df0
😎 Deploy Previewhttps://deploy-preview-6247--typescript-eslint.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to yourNetlify site settings.

@JoshuaKGoldbergJoshuaKGoldberg changed the base branch frommain tov6December 18, 2022 03:57
@JoshuaKGoldbergJoshuaKGoldberg changed the titleTypescript estree throw invalid tokenswip: throw on invalid tokensDec 18, 2022
@JoshuaKGoldbergJoshuaKGoldberg changed the titlewip: throw on invalid tokensfeat(typescript-estree): added option to throw on invalid tokensDec 23, 2022
@codecov
Copy link

codecovbot commentedDec 23, 2022
edited
Loading

Codecov Report

Merging#6247 (7144e90) intov6 (f98afd2) willdecrease coverage by0.09%.
The diff coverage is33.33%.

Additional details and impacted files
@@            Coverage Diff             @@##               v6    #6247      +/-   ##==========================================- Coverage   87.81%   87.72%   -0.09%==========================================  Files         365      365                Lines       12455    12479      +24       Branches     3669     3679      +10     ==========================================+ Hits        10937    10947      +10- Misses       1158     1170      +12- Partials      360      362       +2
FlagCoverage Δ
unittest87.72% <33.33%> (-0.09%)⬇️

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

Impacted FilesCoverage Δ
...pt-estree/src/parseSettings/createParseSettings.ts89.79% <ø> (ø)
packages/typescript-estree/src/convert.ts32.30% <26.47%> (+0.43%)⬆️
packages/typescript-estree/src/node-utils.ts65.10% <75.00%> (-0.33%)⬇️
packages/typescript-estree/src/ast-converter.ts100.00% <100.00%> (ø)
packages/eslint-plugin/src/rules/indent.ts88.09% <0.00%> (-4.77%)⬇️

@JoshuaKGoldberg
Copy link
MemberAuthor

JoshuaKGoldberg commentedDec 23, 2022
edited
Loading

I'm not so sure this is the right approach to fixing the issue. It'd be hard to add branching logic forevery possible syntactic issue not reported as such by TypeScript.

Instead, I'll look at using our isolated program to catch them.

Let this PR serve as a reference for what this logiccould look like. 🙂

Edit: the isolated program is too slow. We're going with this! 🚀

@JoshuaKGoldbergJoshuaKGoldberg deleted the typescript-estree-throw-invalid-tokens branchDecember 23, 2022 22:41
@JoshuaKGoldbergJoshuaKGoldberg restored the typescript-estree-throw-invalid-tokens branchDecember 23, 2022 22:42
@JoshuaKGoldbergJoshuaKGoldberg marked this pull request as ready for reviewFebruary 6, 2023 16:25
bradzacher
bradzacher previously approved these changesFeb 17, 2023
@bradzacherbradzacher added the awaiting responseIssues waiting for a reply from the OP or another party labelFeb 17, 2023
@JoshuaKGoldbergJoshuaKGoldberg marked this pull request as draftFebruary 17, 2023 15:41
@JoshuaKGoldbergJoshuaKGoldberg marked this pull request as ready for reviewFebruary 19, 2023 05:25
@JoshuaKGoldbergJoshuaKGoldberg marked this pull request as draftFebruary 21, 2023 20:50
@JoshuaKGoldbergJoshuaKGoldberg added this to the6.0.0 milestoneFeb 23, 2023
@JoshuaKGoldbergJoshuaKGoldberg changed the titlefeat(typescript-estree): added option to throw on invalid tokensfeat(typescript-estree): added allowInvalidAST option to not throw on invalid tokensFeb 23, 2023
@JoshuaKGoldbergJoshuaKGoldberg marked this pull request as ready for reviewFebruary 23, 2023 06:26
@JoshuaKGoldbergJoshuaKGoldberg removed the awaiting responseIssues waiting for a reply from the OP or another party labelFeb 23, 2023
@JoshuaKGoldbergJoshuaKGoldberg requested review frombradzacher and removed request forbradzacherFebruary 23, 2023 06:29
@bradzacherbradzacher merged commita3b177d intotypescript-eslint:v6Mar 5, 2023
@JoshuaKGoldbergJoshuaKGoldberg deleted the typescript-estree-throw-invalid-tokens branchMarch 5, 2023 17:32
@github-actionsgithub-actionsbot locked asresolvedand limited conversation to collaboratorsMar 13, 2023
Sign up for freeto subscribe to this conversation on GitHub. Already have an account?Sign in.
Reviewers

@bradzacherbradzacherbradzacher approved these changes

Assignees
No one assigned
Labels
breaking changeThis change will require a new major version to be released
Projects
None yet
Milestone
6.0.0
Development

Successfully merging this pull request may close these issues.

2 participants
@JoshuaKGoldberg@bradzacher

[8]ページ先頭

©2009-2025 Movatter.jp