From 8d8309d8aabec8e4ad985b637316110de184b604 Mon Sep 17 00:00:00 2001 From: Lukas Stracke Date: Thu, 31 Jul 2025 11:25:36 +0200 Subject: [PATCH 1/2] ref(node-core): Add more specific `mechanism.type` to worker thread errors from `childProcessIntegration` --- packages/node-core/src/integrations/childProcess.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/node-core/src/integrations/childProcess.ts b/packages/node-core/src/integrations/childProcess.ts index 6fc6046c7e2f..9f63dd4bca66 100644 --- a/packages/node-core/src/integrations/childProcess.ts +++ b/packages/node-core/src/integrations/childProcess.ts @@ -99,7 +99,7 @@ function captureWorkerThreadEvents(worker: Worker, options: Options): void { .on('error', error => { if (options.captureWorkerErrors !== false) { captureException(error, { - mechanism: { type: 'instrument', handled: false, data: { threadId: String(threadId) } }, + mechanism: { type: 'child_process.worker_thread', handled: false, data: { threadId: String(threadId) } }, }); } else { addBreadcrumb({ From 944e80eea04fe4b833edd7c20b22390277ff304f Mon Sep 17 00:00:00 2001 From: Lukas Stracke Date: Tue, 9 Sep 2025 16:32:19 +0200 Subject: [PATCH 2/2] ref(node-core): Set mode specific event `mechanism` in `childProcessIntegration` --- .../node-core-integration-tests/suites/child-process/test.ts | 2 +- .../node-integration-tests/suites/child-process/test.ts | 2 +- packages/node-core/src/integrations/childProcess.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/dev-packages/node-core-integration-tests/suites/child-process/test.ts b/dev-packages/node-core-integration-tests/suites/child-process/test.ts index 798cd48d86d0..1d04772c351e 100644 --- a/dev-packages/node-core-integration-tests/suites/child-process/test.ts +++ b/dev-packages/node-core-integration-tests/suites/child-process/test.ts @@ -10,7 +10,7 @@ const WORKER_EVENT: Event = { type: 'Error', value: 'Test error', mechanism: { - type: 'instrument', + type: 'auto.child_process.worker_thread', handled: false, data: { threadId: expect.any(String), diff --git a/dev-packages/node-integration-tests/suites/child-process/test.ts b/dev-packages/node-integration-tests/suites/child-process/test.ts index 798cd48d86d0..1d04772c351e 100644 --- a/dev-packages/node-integration-tests/suites/child-process/test.ts +++ b/dev-packages/node-integration-tests/suites/child-process/test.ts @@ -10,7 +10,7 @@ const WORKER_EVENT: Event = { type: 'Error', value: 'Test error', mechanism: { - type: 'instrument', + type: 'auto.child_process.worker_thread', handled: false, data: { threadId: expect.any(String), diff --git a/packages/node-core/src/integrations/childProcess.ts b/packages/node-core/src/integrations/childProcess.ts index 9f63dd4bca66..0e3fcfe4633a 100644 --- a/packages/node-core/src/integrations/childProcess.ts +++ b/packages/node-core/src/integrations/childProcess.ts @@ -99,7 +99,7 @@ function captureWorkerThreadEvents(worker: Worker, options: Options): void { .on('error', error => { if (options.captureWorkerErrors !== false) { captureException(error, { - mechanism: { type: 'child_process.worker_thread', handled: false, data: { threadId: String(threadId) } }, + mechanism: { type: 'auto.child_process.worker_thread', handled: false, data: { threadId: String(threadId) } }, }); } else { addBreadcrumb({