Runtime
node.js
Runtime version
22.12.0
Module version
26.0.0
Used with
No response
Any other relevant information
After upgrading to eslint 9 and lab 26, coverage failed with:
Cannot read properties of undefined (reading 'includes')
TypeError: Cannot read properties of undefined (reading 'includes')
at validateResolvedConfig (/project/node_modules/@babel/eslint-parser/lib/worker/configuration.cjs:53:37)
at Object.normalizeBabelParseConfigSync (/project/node_modules/@babel/eslint-parser/lib/worker/configuration.cjs:88:10)
at Function.handleMessage (/project/node_modules/@babel/eslint-parser/lib/worker/handle-message.cjs:26:48)
at LocalClient.<anonymous> (/project/node_modules/@babel/eslint-parser/lib/client.cjs:98:79)
at LocalClient.maybeParse (/project/node_modules/@babel/eslint-parser/lib/client.cjs:52:47)
at parse (/project/node_modules/@babel/eslint-parser/lib/parse.cjs:28:14)
at Object.parse (/project/node_modules/@babel/eslint-parser/lib/index.cjs:19:10)
at Object.internals.instrument (/project/node_modules/@hapi/lab/lib/modules/coverage.js:326:31)
at Object.require.extensions.<computed> [as .ts] (/project/node_modules/@hapi/lab/lib/modules/coverage.js:116:59)
Which is resolved by adding requireConfigFile to the eslint config:
languageOptions: {
parser: tseslint.parser,
parserOptions: { requireConfigFile: false },
},
I am using eslint.config.mjs in case that matters.
Was this expected? Is there a better solution? Should this be added to lab itself?
Thanks!
Runtime
node.js
Runtime version
22.12.0
Module version
26.0.0
Used with
No response
Any other relevant information
After upgrading to eslint 9 and lab 26, coverage failed with:
Which is resolved by adding
requireConfigFileto the eslint config:I am using
eslint.config.mjsin case that matters.Was this expected? Is there a better solution? Should this be added to lab itself?
Thanks!