-
Notifications
You must be signed in to change notification settings - Fork 3.2k
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
Your configFile is invalid [ERR_UNKNOWN_FILE_EXTENSION]: Unknown file extension ".ts" #27450
Comments
Adding my voice to the group. Experiencing this with latest version of Cypress (^13.0.0). We then get this
Followed by this
|
I've created a very basic repro repo: https://github.com/AStoker/nx-angular-yarnpnp-cypress-bug Steps:
|
I see that your issue is reproducible using Yarn Modern Plug'n'Play and if the repo is switched to Which version of Yarn are you using and if it is Yarn Modern, which |
@MikeMcC399 I was using yarn 1.5.1, I've upgraded to Yarn Modern and I also started using JS file instead as a workaround |
Thanks for the feedback and update! Yarn |
@MikeMcC399 as long as its working with the latest version, I don't have a problem |
@MikeMcC399 , is that something that is on the roadmap to work on? |
I'm not sure exactly what you are referring to, however I should say that I'm just a community member, not a representative of Cypress. This issue has been reviewed but not otherwise worked on by a member of the Cypress team. Since it has not been rejected nor has it been given the label of a feature request then I would understand it as a candidate for further triaging. |
i think this is a duplicate of #22747 |
Having this issue and the only way I was able to resolve it was by downgrading to TypeScript v5.2.2. I'm using Cypress v13.6.0 and Yarn 1.22.19. |
This worked for me - sigh. |
This also worked for me. Typescript 5.3 or greater causes issues for some reason... |
https://yarnpkg.com/configuration/yarnrc#nodeLinker In
This solved my issue. |
Same here. Does anybody know what specifically in TS 5.3 is breaking cypress functionality to read the config? |
Having same issue on GitHub action only, workflow log: https://github.com/hbstack/announcement-bar/actions/runs/9239217450/job/25418111856. It's weird that everything is OK on local development. |
Seeing same issue after updating typescript from 5.0. to 5.5 |
I'm getting the same error, but it only happens when I use {
"compilerOptions": {
...
},
"extends": ["@tsconfig/strictest/tsconfig.json"] // it works fine removing this line
}
{
"extends": "../../tsconfig.base.json",
"compilerOptions": {
"sourceMap": false,
"outDir": "../../dist/out-tsc",
"types": ["cypress", "node"]
},
"include": ["src/**/*.ts", "cypress.config.ts"]
} Using Cypress v13.10.0, Typescript 5.4.5 in a Nx monorepo. |
Just to add my fix for this. It turned out it came from trying to consume files using ESM syntax instead of CJS. I have a bunch of commands/plugins that are published to a separate package and I import some of those into the config file. Recently changed those to build as Somewhat related to #22747 I believe |
Looks like the issue was fixed with 13.6.2 release |
Current behavior
package.json
cypress.config.ts
error
tsconfig.json
tsconfig.build.json
tsconfig.tests.json
Desired behavior
Cypress should run all the tests since typescript is installed, Its a monorepo, The issue occurs even after yarn install after deleting the yarn lock file, I've tried everything in other issues but issue doesn't seem to resolve, however changing the
type
field inpackage.json
does change the output of the errorTest code to reproduce
Currenlty the project is huge, Requires a bit of work to reproduce
Cypress Version
v12.17.2
Node version
v18.12.1
Operating System
Windows 11
Debug Logs
No response
Other
No response
The text was updated successfully, but these errors were encountered: