From d69aab62b0789dd54b8c09b54af022a38f060b5b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bartek=20Iwa=C5=84czuk?= Date: Mon, 11 Mar 2024 22:18:03 +0000 Subject: fix(ext/node): make worker setup synchronous (#22815) This commit fixes race condition in "node:worker_threads" module were the first message did a setup of "threadId", "workerData" and "environmentData". Now this data is passed explicitly during workers creation and is set up before any user code is executed. Closes https://github.com/denoland/deno/issues/22783 Closes https://github.com/denoland/deno/issues/22672 --------- Co-authored-by: Satya Rohith --- cli/worker.rs | 1 + 1 file changed, 1 insertion(+) (limited to 'cli') diff --git a/cli/worker.rs b/cli/worker.rs index 47658e594..697514477 100644 --- a/cli/worker.rs +++ b/cli/worker.rs @@ -841,6 +841,7 @@ fn create_web_worker_callback( stdio: stdio.clone(), cache_storage_dir, feature_checker, + maybe_worker_metadata: args.maybe_worker_metadata, }; WebWorker::bootstrap_from_options( -- cgit v1.2.3