v0.5.2 failing on my repo
Describe the bug
Activating extension 'vitest.explorer' failed: Vitest failed to start:
Error: The service was stopped
Reproduction
Repro will come soon.
System Info
System:
OS: macOS 14.4
CPU: (10) arm64 Apple M1 Pro
Memory: 1.93 GB / 32.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 18.15.0 - /usr/local/bin/node
Yarn: 1.22.19 - /usr/local/bin/yarn
npm: 9.5.0 - /usr/local/bin/npm
pnpm: 8.6.12 - /usr/local/bin/pnpm
IDEs:
VSCode: 1.87.2 - /opt/homebrew/bin/code
Vim: 9.0 - /usr/bin/vim
Xcode: 15.3/15E204a - /usr/bin/xcodebuild
Browsers:
Chrome: 122.0.6261.129
Edge: 122.0.2365.92
Safari: 17.4
npmPackages:
@vitejs/plugin-react: ^4.2.1 => 4.2.1
@vitest/coverage-v8: ^1.3.1 => 1.3.1
@vitest/ui: ^1.3.1 => 1.3.1
vite: ^5.1.6 => 5.1.6
vitest: ^1.4.0 => 1.4.0
Used Package Manager
pnpm
Validations
- [X] Follow our Code of Conduct
- [X] Read the Contributing Guidelines.
- [X] Read the docs.
- [X] Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- [X] Check that this is a concrete bug. For Q&A open a GitHub Discussion or join our Discord Chat Server.
- [ ] The provided reproduction is a minimal reproducible example of the bug.
I just tried using #296 against my repo, and I get the following log output:
[INFO 21:42:21] [Vitest] Extension is activated because Vitest is installed or there is a Vite/Vitest config file in the workspace. [INFO 21:42:21] [API] Vitest config {"folder":{"uri":{"$mid":1,"fsPath":"/Users/redacted/Documents/src/redacted","external":"file:///Users/redacted/Documents/src/redacted","path":"/Users/redacted/Documents/src/redacted","scheme":"file"},"name":"redacted","index":0},"id":"/Users/redacted/Documents/src/redacted/vitest.workspace.ts","vitestNodePath":"file:///Users/redacted/Documents/src/redacted/node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]/node_modules/vitest/dist/node.js","version":"1.4.0"} [INFO 21:42:21] [API] Running Vitest: v1.4.0 (redacted) [INFO 21:42:22] [WORKER] onMessage {"type":"init","meta":[{"vitestNodePath":"file:///Users/redacted/Documents/src/redacted/node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]/node_modules/vitest/dist/node.js","folder":"/Users/redacted/Documents/src/redacted","workspaceFile":"/Users/redacted/Documents/src/redacted/vitest.workspace.ts","id":"/Users/redacted/Documents/src/redacted/vitest.workspace.ts"}]} [INFO 21:42:22] [WORKER] initializing [INFO 21:42:22] [WORKER] loading vitest instance {"vitestNodePath":"file:///Users/redacted/Documents/src/redacted/node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]/node_modules/vitest/dist/node.js","folder":"/Users/redacted/Documents/src/redacted","workspaceFile":"/Users/redacted/Documents/src/redacted/vitest.workspace.ts","id":"/Users/redacted/Documents/src/redacted/vitest.workspace.ts"} [INFO 21:42:22] [WORKER] importing vitest node file:///Users/redacted/Documents/src/redacted/node_modules/.pnpm/[email protected]_@[email protected]_@[email protected][email protected][email protected][email protected]/node_modules/vitest/dist/node.js [INFO 21:42:22] [WORKER] creating vitest instance
So it is freezing at await vitestNode.createVitest. It never terminates, nor throws an exception. How can I debug it further?
Interesting. I was suspecting something with the import. I had a .npmrc file which contained:
symlink=true
I deleted it, deleted node_modules and ran pnpm install again. That worked. Hmmm. Perhaps that's repro enough (just having symlink to true for PNPM).
I tried reproing the .npmrc thing with the sample repos. I couldn't make it re-occur. I suspect maybe my node_modules folder maybe got corrupted? It's just strange.
Any advice I can use to continue debugging is still useful.
There is still no repro. Let's close this issue for now, I cannot give you more debugging tips unfortunately.