diff --git a/dev-packages/browser-integration-tests/suites/errors/fetch/test.ts b/dev-packages/browser-integration-tests/suites/errors/fetch/test.ts index 5b56f0cd695a..19fe923c7b30 100644 --- a/dev-packages/browser-integration-tests/suites/errors/fetch/test.ts +++ b/dev-packages/browser-integration-tests/suites/errors/fetch/test.ts @@ -24,7 +24,7 @@ sentryTest('handles fetch network errors @firefox', async ({ getLocalTestUrl, pa value: error, mechanism: { handled: false, - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', }, }); }); @@ -51,7 +51,7 @@ sentryTest('handles fetch network errors on subdomains @firefox', async ({ getLo value: error, mechanism: { handled: false, - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', }, }); }); @@ -78,7 +78,7 @@ sentryTest('handles fetch invalid header name errors @firefox', async ({ getLoca value: error, mechanism: { handled: false, - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', }, stacktrace: { frames: expect.any(Array), @@ -110,7 +110,7 @@ sentryTest('handles fetch invalid header value errors @firefox', async ({ getLoc value: error, mechanism: { handled: false, - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', }, stacktrace: { frames: expect.any(Array), @@ -152,7 +152,7 @@ sentryTest('handles fetch invalid URL scheme errors @firefox', async ({ getLocal value: error, mechanism: { handled: false, - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', }, stacktrace: { frames: expect.any(Array), @@ -184,7 +184,7 @@ sentryTest('handles fetch credentials in url errors @firefox', async ({ getLocal value: error, mechanism: { handled: false, - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', }, stacktrace: { frames: expect.any(Array), @@ -215,7 +215,7 @@ sentryTest('handles fetch invalid mode errors @firefox', async ({ getLocalTestUr value: error, mechanism: { handled: false, - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', }, stacktrace: { frames: expect.any(Array), @@ -245,7 +245,7 @@ sentryTest('handles fetch invalid request method errors @firefox', async ({ getL value: error, mechanism: { handled: false, - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', }, stacktrace: { frames: expect.any(Array), @@ -277,7 +277,7 @@ sentryTest( value: error, mechanism: { handled: false, - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', }, stacktrace: { frames: expect.any(Array), diff --git a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/non-string-arg/test.ts b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/non-string-arg/test.ts index 5f014ba2c209..e12abb3baf71 100644 --- a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/non-string-arg/test.ts +++ b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/non-string-arg/test.ts @@ -33,7 +33,7 @@ sentryTest( type: 'Error', value: 'Object captured as exception with keys: otherKey, type', mechanism: { - type: 'onerror', + type: 'auto.browser.global_handlers.onerror', handled: false, }, stacktrace: { diff --git a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/syntax-errors/test.ts b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/syntax-errors/test.ts index 4d7ea3a04883..81a4e0323a49 100644 --- a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/syntax-errors/test.ts +++ b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/syntax-errors/test.ts @@ -28,7 +28,7 @@ sentryTest('should catch syntax errors', async ({ getLocalTestUrl, page, browser type: 'SyntaxError', value: "Failed to execute 'appendChild' on 'Node': Unexpected token '{'", mechanism: { - type: 'onerror', + type: 'auto.browser.global_handlers.onerror', handled: false, }, stacktrace: { diff --git a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/thrown-errors/test.ts b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/thrown-errors/test.ts index bdc878adc16c..426decae095e 100644 --- a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/thrown-errors/test.ts +++ b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/thrown-errors/test.ts @@ -28,7 +28,7 @@ sentryTest('should catch thrown errors', async ({ getLocalTestUrl, page, browser type: 'Error', value: 'realError', mechanism: { - type: 'onerror', + type: 'auto.browser.global_handlers.onerror', handled: false, }, stacktrace: { diff --git a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/thrown-objects/test.ts b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/thrown-objects/test.ts index 27b764334143..4e0ac6478a04 100644 --- a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/thrown-objects/test.ts +++ b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/thrown-objects/test.ts @@ -30,7 +30,7 @@ sentryTest('should catch thrown objects', async ({ getLocalTestUrl, page, browse type: 'Error', value: 'Object captured as exception with keys: error, somekey', mechanism: { - type: 'onerror', + type: 'auto.browser.global_handlers.onerror', handled: false, }, stacktrace: { diff --git a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/thrown-strings/test.ts b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/thrown-strings/test.ts index 787146c02a43..f1f12748dfeb 100644 --- a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/thrown-strings/test.ts +++ b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onError/thrown-strings/test.ts @@ -28,7 +28,7 @@ sentryTest('should catch thrown strings', async ({ getLocalTestUrl, page, browse type: 'Error', value: 'stringError', mechanism: { - type: 'onerror', + type: 'auto.browser.global_handlers.onerror', handled: false, }, stacktrace: { diff --git a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/custom-event/test.ts b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/custom-event/test.ts index 169ad3b4b319..1421ffeedb1d 100644 --- a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/custom-event/test.ts +++ b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/custom-event/test.ts @@ -20,7 +20,7 @@ sentryTest( type: 'Error', value: 'promiseError', mechanism: { - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', handled: false, }, stacktrace: { diff --git a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/event/test.ts b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/event/test.ts index 0dcf24fecc58..db77d3d2db24 100644 --- a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/event/test.ts +++ b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/event/test.ts @@ -15,7 +15,7 @@ sentryTest('should capture a random Event with type unhandledrejection', async ( type: 'Event', value: 'Event `Event` (type=unhandledrejection) captured as promise rejection', mechanism: { - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', handled: false, }, }); diff --git a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-errors/test.ts b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-errors/test.ts index 2eb475919a95..7daf9d8bbaa4 100644 --- a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-errors/test.ts +++ b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-errors/test.ts @@ -13,7 +13,7 @@ sentryTest('should catch thrown errors', async ({ getLocalTestUrl, page }) => { type: 'Error', value: 'promiseError', mechanism: { - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', handled: false, }, stacktrace: { diff --git a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-null/test.ts b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-null/test.ts index f9231fa5cda7..1d15616c716f 100644 --- a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-null/test.ts +++ b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-null/test.ts @@ -13,7 +13,7 @@ sentryTest('should catch thrown strings', async ({ getLocalTestUrl, page }) => { type: 'UnhandledRejection', value: 'Non-Error promise rejection captured with value: null', mechanism: { - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', handled: false, }, }); diff --git a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-number/test.ts b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-number/test.ts index adb3348563c6..cdf6174f568f 100644 --- a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-number/test.ts +++ b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-number/test.ts @@ -13,7 +13,7 @@ sentryTest('should catch thrown strings', async ({ getLocalTestUrl, page }) => { type: 'UnhandledRejection', value: 'Non-Error promise rejection captured with value: 123', mechanism: { - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', handled: false, }, }); diff --git a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-object-complex/test.ts b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-object-complex/test.ts index 71f2b11864b1..e67049774f66 100644 --- a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-object-complex/test.ts +++ b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-object-complex/test.ts @@ -13,7 +13,7 @@ sentryTest('should capture unhandledrejection with a complex object', async ({ g type: 'UnhandledRejection', value: 'Object captured as promise rejection with keys: a, b, c, d, e', mechanism: { - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', handled: false, }, }); diff --git a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-objects/test.ts b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-objects/test.ts index 50f1d712c15d..ce30aac0bb17 100644 --- a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-objects/test.ts +++ b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-objects/test.ts @@ -13,7 +13,7 @@ sentryTest('should capture unhandledrejection with an object', async ({ getLocal type: 'UnhandledRejection', value: 'Object captured as promise rejection with keys: a, b, c', mechanism: { - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', handled: false, }, }); diff --git a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-strings/test.ts b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-strings/test.ts index 15e4fb1bd5f6..9907b5457b80 100644 --- a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-strings/test.ts +++ b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-strings/test.ts @@ -13,7 +13,7 @@ sentryTest('should catch thrown strings', async ({ getLocalTestUrl, page }) => { type: 'UnhandledRejection', value: 'Non-Error promise rejection captured with value: stringError', mechanism: { - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', handled: false, }, }); diff --git a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-undefined/test.ts b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-undefined/test.ts index 51505d6f8333..8603f96c0bbe 100644 --- a/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-undefined/test.ts +++ b/dev-packages/browser-integration-tests/suites/public-api/instrumentation/onUnhandledRejection/thrown-undefined/test.ts @@ -13,7 +13,7 @@ sentryTest('should catch thrown strings', async ({ getLocalTestUrl, page }) => { type: 'UnhandledRejection', value: 'Non-Error promise rejection captured with value: undefined', mechanism: { - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', handled: false, }, }); diff --git a/dev-packages/e2e-tests/test-applications/astro-4/tests/errors.client.test.ts b/dev-packages/e2e-tests/test-applications/astro-4/tests/errors.client.test.ts index e1e13d231fef..730122f5c208 100644 --- a/dev-packages/e2e-tests/test-applications/astro-4/tests/errors.client.test.ts +++ b/dev-packages/e2e-tests/test-applications/astro-4/tests/errors.client.test.ts @@ -31,7 +31,7 @@ test.describe('client-side errors', () => { { mechanism: { handled: false, - type: 'onerror', + type: 'auto.browser.global_handlers.onerror', }, type: 'Error', value: 'client error', diff --git a/dev-packages/e2e-tests/test-applications/astro-5/tests/errors.client.test.ts b/dev-packages/e2e-tests/test-applications/astro-5/tests/errors.client.test.ts index 22572d009202..19e9051ddf69 100644 --- a/dev-packages/e2e-tests/test-applications/astro-5/tests/errors.client.test.ts +++ b/dev-packages/e2e-tests/test-applications/astro-5/tests/errors.client.test.ts @@ -31,7 +31,7 @@ test.describe('client-side errors', () => { { mechanism: { handled: false, - type: 'onerror', + type: 'auto.browser.global_handlers.onerror', }, type: 'Error', value: 'client error', diff --git a/dev-packages/e2e-tests/test-applications/solid-solidrouter/tests/errors.test.ts b/dev-packages/e2e-tests/test-applications/solid-solidrouter/tests/errors.test.ts index b8e2a759886a..a77f107af624 100644 --- a/dev-packages/e2e-tests/test-applications/solid-solidrouter/tests/errors.test.ts +++ b/dev-packages/e2e-tests/test-applications/solid-solidrouter/tests/errors.test.ts @@ -17,7 +17,7 @@ test('sends an error', async ({ page }) => { type: 'Error', value: 'Error thrown from Solid E2E test app', mechanism: { - type: 'onerror', + type: 'auto.browser.global_handlers.onerror', handled: false, }, }, diff --git a/dev-packages/e2e-tests/test-applications/solid/tests/errors.test.ts b/dev-packages/e2e-tests/test-applications/solid/tests/errors.test.ts index b8e2a759886a..a77f107af624 100644 --- a/dev-packages/e2e-tests/test-applications/solid/tests/errors.test.ts +++ b/dev-packages/e2e-tests/test-applications/solid/tests/errors.test.ts @@ -17,7 +17,7 @@ test('sends an error', async ({ page }) => { type: 'Error', value: 'Error thrown from Solid E2E test app', mechanism: { - type: 'onerror', + type: 'auto.browser.global_handlers.onerror', handled: false, }, }, diff --git a/dev-packages/e2e-tests/test-applications/sveltekit-2.5.0-twp/tests/errors.test.ts b/dev-packages/e2e-tests/test-applications/sveltekit-2.5.0-twp/tests/errors.test.ts index 984af2ec23a6..ee7877e82dee 100644 --- a/dev-packages/e2e-tests/test-applications/sveltekit-2.5.0-twp/tests/errors.test.ts +++ b/dev-packages/e2e-tests/test-applications/sveltekit-2.5.0-twp/tests/errors.test.ts @@ -29,7 +29,7 @@ test('errors on frontend and backend are connected by the same trace', async ({ { mechanism: { handled: false, - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', }, stacktrace: expect.any(Object), type: 'Error', diff --git a/packages/browser/src/integrations/globalhandlers.ts b/packages/browser/src/integrations/globalhandlers.ts index 74e78c37679e..ebfdff6d2f58 100644 --- a/packages/browser/src/integrations/globalhandlers.ts +++ b/packages/browser/src/integrations/globalhandlers.ts @@ -72,7 +72,7 @@ function _installGlobalOnErrorHandler(client: Client): void { originalException: error, mechanism: { handled: false, - type: 'onerror', + type: 'auto.browser.global_handlers.onerror', }, }); }); @@ -98,7 +98,7 @@ function _installGlobalOnUnhandledRejectionHandler(client: Client): void { originalException: error, mechanism: { handled: false, - type: 'onunhandledrejection', + type: 'auto.browser.global_handlers.onunhandledrejection', }, }); });