-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Open
Labels
Description
Describe the bug
At 1 test file I've consistently gotten errors raised when a pool fails. However at enough files it stops. For me this happens after 4 test files but apparently it can happen later so I've put 10 in the reproduction. I suspect this will happen when it's at files = workers or files = workers + 1.
Reproduction
/// <reference types="vitest/config" />
import type { PoolWorker } from 'vitest/node';
// Configure Vitest (https://vitest.dev/config/)
import { defineConfig } from 'vite';
export default defineConfig({
test: {
pool: {
name: 'custom-pool',
createPoolWorker: () => {
return {
async start() {
throw new Error('Pool errored but will not be logged');
},
} as unknown as PoolWorker; // A full pool would be overkill
},
},
},
});https://stackblitz.com/edit/vitest-dev-vitest-mdw4zimi
Please note the LACK of an error in the stackblitz. Go to 1 test file and it should begin erroring. You'll have to bisect to find the exact breakpoint for you.
The test files all have throw 123; // Test should obviously not pass. as well so they're clearly not running.
System Info
System:
OS: Linux 6.6 Ubuntu 24.04.3 LTS 24.04.3 LTS (Noble Numbat)
CPU: (16) x64 AMD Ryzen 7 7840HS w/ Radeon 780M Graphics
Memory: 3.50 GB / 27.31 GB
Container: Yes
Shell: 5.2.21 - /bin/bash
Binaries:
Node: 24.5.0 - /home/david/.nvm/versions/node/v24.5.0/bin/node
Yarn: 1.22.22 - /home/david/.nvm/versions/node/v24.5.0/bin/yarn
npm: 11.5.1 - /home/david/.nvm/versions/node/v24.5.0/bin/npm
pnpm: 10.23.0 - /home/david/.nvm/versions/node/v24.5.0/bin/pnpm
bun: 1.2.4 - /home/david/.bun/bin/bun
Deno: 2.1.1 - /home/david/.deno/bin/deno
npmPackages:
vitest: ^4.0.15 => 4.0.15Used Package Manager
npm
Validations
- Follow our Code of Conduct
- Read the Contributing Guidelines.
- Read the docs.
- Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
- 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.