bthreads
bthreads copied to clipboard
Error thrown "stdin.unref is not a function" during Parent instance initialization
When running bthreads with BTHREADS_BACKEND = 'child_process'; configuration stdin.unref error pops up from time to time without clear reproduction scenario.
stdin.unref is not a function
----------------------------------------
TypeError: stdin.unref is not a function
at Parent._init (/home/REDACTED/node_modules/bthreads/lib/process/parent.js:129:11)
at new Parent (/home/REDACTED/node_modules/bthreads/lib/process/parent.js:81:10)
at Object.<anonymous> (/home/REDACTED/node_modules/bthreads/lib/process/thread.js:15:16)
at Module._compile (internal/modules/cjs/loader.js:1138:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1158:10)
at Module.load (internal/modules/cjs/loader.js:986:32)
at Function.Module._load (internal/modules/cjs/loader.js:879:14)
at Module.require (internal/modules/cjs/loader.js:1026:19)
at require (internal/modules/cjs/helpers.js:72:18)
at Object.<anonymous> (/home/REDACTED/node_modules/bthreads/lib/process/index.js:10:20)
Environment details:
- Node v12.18.0
- [email protected]
- used through bree@4.0.0 job scheduling module
- worker threads are initialized this way in bree
@chjj would appreciate any tips on tackling this and thanks for all your work on this project!
Notes:
- possibly linked to https://github.com/chjj/bthreads/commit/b5214a2f9fa374d7e7784904456152de7c2ceb82 and https://github.com/nodejs/node/pull/28153