typescript-eslint/typescript-eslint
在 GitHub 查看Files with uppercased letter can't be parsed on case-insensitive filesystem in folder with case-sensitivity support
Open
#4,680 创建于 2022年3月14日
accepting prsbughelp wantedpackage: typescript-estree
描述
- I have tried restarting my IDE and the issue persists.
- I have updated to the latest version of the packages.
- I have read the FAQ and my problem is not listed.
Repro
- Windows machine
- Enable case-sensitivity support by
fsutil.exe file SetCaseSensitiveInfo C:\folder\path enable - Inside case-sensitivity folder create/open project that contains files with uppercased letters
- Run
eslint
Actual Result
Got errors, like this
C:\Users\nflaz\Projects\creevey\creevey\stories\TestViews.stories.tsx
0:0 error Parsing error: "parserOptions.project" has been set for @typescript-eslint/parser.
The file does not match your project config: stories\TestViews.stories.tsx.
The file must be included in at least one of the projects provided
Expected Result
There shouldn't be Parsing error: "parserOptions.project" errors
Additional Info
After many hours of trying to figure out that was happening. I found this piece of code: https://github.com/typescript-eslint/typescript-eslint/blob/6c3816b3831e6e683c1a7842196b34248803d69b/packages/typescript-estree/src/create-program/shared.ts#L51-L55
It seems, like on system-level useCaseSensitiveFileNames is false, but my project folder has case sensitivity support. So I tried to set useCaseSensitiveFileNames to true and voi la, no more parserOptions.project errors.
Versions
| package | version |
|---|---|
@typescript-eslint/typescript-estree |
5.14.0 |
TypeScript |
4.4.3 |
node |
14.19.0 |