Closed
Description
Before You File a Bug Report Please Confirm You Have Done The Following...
- I have tried restarting my IDE and the issue persists.
- I have updated to the latest version of the packages.
- I have searched for related issues and found none that matched my issue.
- I have read the FAQ and my problem is not listed.
Repro link
https://stackblitz.com/edit/vitejs-vite-rv1ac6?file=eslint.config.js
Relevant Package
parser
I am in the process of upgrading to ESLint 9 from 8, but running into issues with this package complaining about files that are not source code (they are config files, script files, etc)
ESLint Config
import baseConfig from './eslint.config.mjs';
export default [
...baseConfig,
{
languageOptions: {
parserOptions: {
projectService: {
allowDefaultProject: ['*.js', '*.mjs'],
},
tsconfigRootDir: import.meta.dirname,
},
},
},
{
rules: {
'@typescript-eslint/await-thenable': 'warn',
'@typescript-eslint/no-floating-promises': 'warn',
'@typescript-eslint/require-await': 'warn',
'no-return-await': 'warn',
},
},
];
tsconfig
Expected Result
I expect no errors as previously was the case on ESLint 8.57.
Actual Result
A bunch of errors similar to:
/Users/sam/repo/prettier.config.mjs
0:0 error Parsing error: /Users/sam/repo/prettier.config.mjs was not found by the project service. Consider either including it in the tsconfig.json or including it in allowDefaultProject
Additional Info
No response
Versions
package | version |
---|---|
@typescript-eslint/eslint-plugin |
8.0.1 |
@typescript-eslint/parser |
8.0.1 |
@typescript-eslint/rule-tester |
X.Y.Z |
@typescript-eslint/scope-manager |
X.Y.Z |
@typescript-eslint/typescript-estree |
X.Y.Z |
@typescript-eslint/type-utils |
X.Y.Z |
@typescript-eslint/utils |
X.Y.Z |
TypeScript |
5.5.4 |
ESLint |
9.8.0 |
node |
20.12.2 |