tinypool
tinypool copied to clipboard
Installing tinypool causes typescript errors.
Tinypool is conflicting so some dependency:
Error: node_modules/tinypool/dist/index.d.ts(21,15): error TS2417: Class static side 'typeof EventEmitterAsyncResource' incorrectly extends base class static side 'typeof EventEmitter'.
Types of property 'EventEmitterAsyncResource' are incompatible.
Types of construct signatures are incompatible.
Type 'new (options?: string | Options$1 | undefined) => EventEmitterAsyncResource' is not assignable to type 'new (options?: EventEmitterAsyncResourceOptions | undefined) => EventEmitterAsyncResource'.
Construct signature return types 'EventEmitterAsyncResource' and 'EventEmitterAsyncResource' are incompatible.
The types of 'asyncId' are incompatible between these types.
Type '() => number' is not assignable to type 'number'.
Error: node_modules/tinypool/dist/index.d.ts(146,31): error TS2304: Cannot find name 'Worker'.
CI run: https://github.com/mshima/generator-jhipster/actions/runs/7835634934/job/21381450038?pr=914
Could you set up a minimal reproduction for this? Or maybe solve this by not checking types of your dependencies by using skipLibCheck in tsconfig.json?
Disabling skipLibCheck because a single dependency is quite drastic.
We’ve switched to piscina.
Similar issue from Piscina: https://github.com/piscinajs/piscina/issues/426
Tinypool should apply similar changes as in https://github.com/piscinajs/piscina/pull/433.