threads.js icon indicating copy to clipboard operation
threads.js copied to clipboard

silence "Message from worker before finishing initialization" if the message is an init message

Open claycoleman opened this issue 1 year ago • 0 comments

using DEBUG=threads:* to debug some threads stuff, and was confused for a second about seeing debug messages with "Message from worker before finishing initialization". Turns out the messages it was receiving before initialization were actually the init messages.

This led me into a small rabbit hole, where I thought I was somehow sending messages to the pool too soon, so I looked in the docs to figure out if there was a way to await pool initialization, but didn't find anything, etc.

claycoleman avatar Mar 16 '23 18:03 claycoleman