vitest-dev / vscode

VS Code extension for Vitest
https://vitest.dev/vscode
MIT License
728 stars 79 forks source link

Intermittent complete loss of functionality #375

Closed pierznewton-john closed 2 months ago

pierznewton-john commented 2 months ago

Describe the bug

Sometimes when a test times out, or under other circumstances which are not clear, the icons to allow you to run a test disappear and the whole extension has to be restarted.

Reproduction

I can only say that this was not an issue in 0.4.x, and that it occurs intermittently but regularly enough to make using the extension difficult. Timeouts while debugging produce the problem frequently but not every time. I understand you want a minimum reproducible example, but I am filing this for your awareness anyway as it is a bit of a showstopper for us. We are suing vitest in an nx monorepo for further background.

Output

[INFO 09:30:32] [v0.10.0] Vitest extension is activated because Vitest is installed or there is a Vite/Vitest config file in the workspace.
[INFO 09:30:32] [API] Running Vitest: v1.5.0 (vitest.workspace.ts)
[INFO 09:30:32] [API] Starting Vitest process with Node.js: /Users/pierz.newton-john/.nvm/versions/node/v20.12.2/bin/node
[Worker] The CJS build of Vite's Node API is deprecated. See https://vitejs.dev/guide/troubleshooting.html#vite-cjs-node-api-deprecated for more details.
[Worker]  Vitest  "cache.dir" is deprecated, use Vite's "cacheDir" instead if you want to change the cache director. Note caches will be written to "cacheDir/vitest"
[INFO 09:30:33] [API] Vitest process 87860 created
[INFO 09:30:33] [API] Collecting tests: libs/core-lib/src/integration-tests/tests/migration.spec.ts
[Worker] (node:87860) NOTE: The AWS SDK for JavaScript (v2) will enter maintenance mode
on September 8, 2024 and reach end-of-support on September 8, 2025.

Please migrate your code to use AWS SDK for JavaScript (v3).
For more information, check blog post at https://a.co/cUPnyil
(Use `node --trace-warnings ...` to show where the warning was created)
[INFO 09:30:41] [DEBUG] Starting debugging on localhost:9229
[INFO 09:30:41] Running 1 file(s) with name pattern: ^\s?migration should make a patch the 'latest release' if it patches the latest non-patch version$
[Worker] Debugger listening on ws://127.0.0.1:9229/5789b622-eec6-4d59-945b-a2d1e641581e
For help, see: https://nodejs.org/en/docs/inspector
[Worker] Debugger attached.
[INFO 09:30:41] [DEBUG] Debugging started
[Worker] (node:87860) NOTE: The AWS SDK for JavaScript (v2) will enter maintenance mode
on September 8, 2024 and reach end-of-support on September 8, 2025.

Please migrate your code to use AWS SDK for JavaScript (v3).
For more information, check blog post at https://a.co/cUPnyil
(Use `node --trace-warnings ...` to show where the warning was created)
[Worker] Collecting tests due to file changes: libs/core-lib/src/lib/metadata/schema.ts
[Worker] Collecting tests due to file changes: libs/core-lib/src/integration-tests/tests/migration.spec.ts
[Worker] (node:87860) NOTE: The AWS SDK for JavaScript (v2) will enter maintenance mode
on September 8, 2024 and reach end-of-support on September 8, 2025.

Please migrate your code to use AWS SDK for JavaScript (v3).
For more information, check blog post at https://a.co/cUPnyil
(Use `node --trace-warnings ...` to show where the warning was created)
[Worker] Collecting tests due to file changes: libs/core-api-types/src/lib/coreapi.ts
[Worker] Collecting tests due to file changes: libs/core-lib/src/integration-tests/tests/migration.spec.ts
[INFO 10:00:39] [API] Vitest process 87860 closed successfully
[INFO 10:00:39] [API] Running Vitest: v1.5.0 (vitest.workspace.ts)
[INFO 10:00:39] [API] Starting Vitest process with Node.js: /Users/pierz.newton-john/.nvm/versions/node/v20.12.2/bin/node
[Worker] The CJS build of Vite's Node API is deprecated. See https://vitejs.dev/guide/troubleshooting.html#vite-cjs-node-api-deprecated for more details.
[Worker]  Vitest  "cache.dir" is deprecated, use Vite's "cacheDir" instead if you want to change the cache director. Note caches will be written to "cacheDir/vitest"
[INFO 10:00:40] [API] Vitest process 89493 created
[INFO 10:00:42] [API] Collecting tests: libs/core-lib/src/integration-tests/tests/migration.spec.ts
[Worker] (node:89493) NOTE: The AWS SDK for JavaScript (v2) will enter maintenance mode
on September 8, 2024 and reach end-of-support on September 8, 2025.

Please migrate your code to use AWS SDK for JavaScript (v3).
For more information, check blog post at https://a.co/cUPnyil
(Use `node --trace-warnings ...` to show where the warning was created)
[INFO 10:01:01] Running 1 file(s) with name pattern: ^\s?migration contexts should retain schemas correctly$
[Worker] (node:89493) NOTE: The AWS SDK for JavaScript (v2) will enter maintenance mode
on September 8, 2024 and reach end-of-support on September 8, 2025.

Please migrate your code to use AWS SDK for JavaScript (v3).
For more information, check blog post at https://a.co/cUPnyil
(Use `node --trace-warnings ...` to show where the warning was created)
[INFO 10:02:36] [DEBUG] Starting debugging on localhost:9229
[INFO 10:02:36] Running 1 file(s) with name pattern: ^\s?migration contexts should retain schemas correctly$
[Worker] Debugger listening on ws://127.0.0.1:9229/60ed52f3-d10f-442c-be07-d2effdf7f650
For help, see: https://nodejs.org/en/docs/inspector
[Worker] Debugger attached.
[INFO 10:02:36] [DEBUG] Debugging started
[Worker] (node:89493) NOTE: The AWS SDK for JavaScript (v2) will enter maintenance mode
on September 8, 2024 and reach end-of-support on September 8, 2025.

Please migrate your code to use AWS SDK for JavaScript (v3).
For more information, check blog post at https://a.co/cUPnyil
(Use `node --trace-warnings ...` to show where the warning was created)
[Worker] Collecting tests due to file changes: libs/core-lib/src/integration-tests/tests/migration.spec.ts
[Worker] (node:89493) NOTE: The AWS SDK for JavaScript (v2) will enter maintenance mode
on September 8, 2024 and reach end-of-support on September 8, 2025.

Please migrate your code to use AWS SDK for JavaScript (v3).
For more information, check blog post at https://a.co/cUPnyil
(Use `node --trace-warnings ...` to show where the warning was created)

Version

0.10.0

Validations

ffMathy commented 2 months ago

Highly related (if not the same): #374

pierznewton-john commented 2 months ago

Appreciate the rapid response. Alas I am still experiencing this with the latest release. Hard to pin down a pattern to when it happens, but it's a lot, and not always associated with debugging.

sheremet-va commented 2 months ago

I would need some kind of reproduction then,