andywer / andywer/threads.js

completed promise does not resolve after terminate

Aperta
#316 11 commenti 0 reazioni 0 assegnatari Vedi su GitHub
bug
Lingua principale
TypeScript
Stelle
3.5k
Fork
173
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

My code is waiting for the completed promise, eg `await this.pool.completed()` but after using `await this.pool.terminate(true)`, the completed promise still waits.
Is that intended? Shouldn't it either throw or resolve?

I can work around it with a second promise and using `Promise.any()` but that seems unintuitive.

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.