Closed programmer24601 closed 1 month ago
This is a problem with your config file somehow
Interesting. I'll try and reduce the project down to something I can share. In the mean time this is the (simplified) repo structure:
.
├── package.json
├── package-lock.json
├── packages
│ ├── backend
│ │ ├── bin
│ │ │ └── index.ts
│ │ ├── functions
│ │ │ ├── function-1
│ │ │ │ ├── handler.test.ts
│ │ │ │ └── handler.ts
│ │ │ ├── function-2
│ │ │ │ ├── handler.test.ts
│ │ │ │ └── handler.ts
│ │ │ └── function-3
│ │ │ ├── handler.test.ts
│ │ │ └── handler.ts
│ │ ├── lib
│ │ │ ├── stack.test.ts
│ │ │ ├── stack.ts
│ │ ├── package.json
│ │ ├── tsconfig.json
│ │ └── vitest.config.ts
│ └── frontend
│ ├── index.html
│ ├── package.json
│ ├── src
│ │ ├── App.test.tsx
│ │ ├── App.tsx
│ │ ├── index.tsx
│ │ ├── setupTests.ts
│ │ └── vite-env.d.ts
│ ├── tsconfig.json
│ └── vite.config.ts
├── tsconfig.json
├── vitest.config.ts
└── vitest.workspace.ts
Vitest 1.6.0 is installed as a devDependency in each of the three package.json.
It shouldn't load vitest.workspace.d.ts
file - why do you have it? And where? I don't see it in your example. You can add it to vitest.configSearchPatternExclude
in the vscode settings
You've solved it! tsc had transpiled vitest.workspace.ts into my outDir dist.
Describe the bug
I'm getting a Vitest startup error on:
Vitest itself runs fine, however, the extension falls over on startup. The latest version of the vitest extension to fully work for me is 0.4.1.
Experimenting with right-click -> Install Another Version...
0.6.0 - 0.8.5
- no "Output" errors, no test run buttons, and the Testing pane contains: Vitest -> Resolving Vitest...0.8.6 - 0.10.7
- the below "Output" error, no test run buttons, and Testing pane is empty.Reproduction
At the moment I'm struggling to provide a reproduction of this. I've tried running the extension against the basic, workspace, react official examples here, which works in all cases, but for my own current project (a two-package npm workspace) consistently gets this error. Is there a debug mode I can enable to get a stack trace to help with this?
If there's nothing to go on I can try and whittle down the project into something barebones I can share, but that will take some time.
Output
Version
0.10.7
Validations