diff --git a/dev-packages/bun-integration-tests/suites/basic/index.ts b/dev-packages/bun-integration-tests/suites/basic/index.ts index c760e61d6ba5..e357d8866a89 100644 --- a/dev-packages/bun-integration-tests/suites/basic/index.ts +++ b/dev-packages/bun-integration-tests/suites/basic/index.ts @@ -1,6 +1,7 @@ import * as Sentry from '@sentry/bun'; Sentry.init({ + traceLifecycle: 'static', dsn: process.env.SENTRY_DSN, tracesSampleRate: 1.0, }); diff --git a/dev-packages/bundler-tests/fixtures/basic/index.js b/dev-packages/bundler-tests/fixtures/basic/index.js index f3d47c97f7a2..014e0e40e3d6 100644 --- a/dev-packages/bundler-tests/fixtures/basic/index.js +++ b/dev-packages/bundler-tests/fixtures/basic/index.js @@ -1,5 +1,6 @@ import { init } from '@sentry/browser'; init({ + traceLifecycle: 'static', dsn: 'https://00000000000000000000000000000000@o000000.ingest.sentry.io/0000000', }); diff --git a/dev-packages/deno-integration-tests/suites/orchestrion-mysql/test.ts b/dev-packages/deno-integration-tests/suites/orchestrion-mysql/test.ts index a7c92d675f44..65a8cfe5f09a 100644 --- a/dev-packages/deno-integration-tests/suites/orchestrion-mysql/test.ts +++ b/dev-packages/deno-integration-tests/suites/orchestrion-mysql/test.ts @@ -56,7 +56,7 @@ function withTimeout(p: Promise, ms: number, what: string): Promise { Deno.test('mysql instrumentation: included in default integrations (Deno 2.8.0+)', () => { resetGlobals(); - const client = init({ dsn: 'https://username@domain/123' }) as DenoClient; + const client = init({ traceLifecycle: 'static', dsn: 'https://username@domain/123' }) as DenoClient; const names = client.getOptions().integrations.map(i => i.name); assert(names.includes('Mysql'), `Mysql should be in defaults, got ${names.join(', ')}`); }); @@ -99,6 +99,7 @@ Deno.test('mysql instrumentation: orchestrion:mysql:query channel produces a nes resetGlobals(); const sink = transactionSink(); init({ + traceLifecycle: 'static', dsn: 'https://username@domain/123', tracesSampleRate: 1, beforeSendTransaction: sink.beforeSendTransaction, diff --git a/dev-packages/deno-integration-tests/suites/orchestrion-postgres/test.ts b/dev-packages/deno-integration-tests/suites/orchestrion-postgres/test.ts index 4d08d5e2505b..b08afa15c203 100644 --- a/dev-packages/deno-integration-tests/suites/orchestrion-postgres/test.ts +++ b/dev-packages/deno-integration-tests/suites/orchestrion-postgres/test.ts @@ -56,7 +56,7 @@ function withTimeout(p: Promise, ms: number, what: string): Promise { Deno.test('pg instrumentation: included in default integrations (Deno 2.8.0+)', () => { resetGlobals(); - const client = init({ dsn: 'https://username@domain/123' }) as DenoClient; + const client = init({ traceLifecycle: 'static', dsn: 'https://username@domain/123' }) as DenoClient; const names = client.getOptions().integrations.map(i => i.name); assert(names.includes('Postgres'), `Postgres should be in defaults, got ${names.join(', ')}`); }); @@ -99,6 +99,7 @@ Deno.test('pg instrumentation: orchestrion:pg:query channel produces a nested db resetGlobals(); const sink = transactionSink(); init({ + traceLifecycle: 'static', dsn: 'https://username@domain/123', tracesSampleRate: 1, beforeSendTransaction: sink.beforeSendTransaction, diff --git a/packages/ember/tests/dummy/app/app.ts b/packages/ember/tests/dummy/app/app.ts index 6aacd6a729cc..92724e1f00ad 100644 --- a/packages/ember/tests/dummy/app/app.ts +++ b/packages/ember/tests/dummy/app/app.ts @@ -5,6 +5,7 @@ import Resolver from 'ember-resolver'; import config from './config/environment'; Sentry.init({ + traceLifecycle: 'static', replaysSessionSampleRate: 1, replaysOnErrorSampleRate: 1, }); diff --git a/packages/node/test/integration/scope.test.ts b/packages/node/test/integration/scope.test.ts index 20b01d6fce47..6a6fe3e0a68b 100644 --- a/packages/node/test/integration/scope.test.ts +++ b/packages/node/test/integration/scope.test.ts @@ -263,7 +263,7 @@ describe('Integration | Scope', () => { expect(globalScope.getScopeData().tags).toEqual({ tag1: 'val1', tag2: 'val2' }); // Now when we call init, the global scope remains intact - Sentry.init({ dsn: 'https://username@domain/123', defaultIntegrations: false }); + Sentry.init({ traceLifecycle: 'static', dsn: 'https://username@domain/123', defaultIntegrations: false }); expect(globalScope.getClient()).toBeUndefined(); expect(Sentry.getGlobalScope()).toBe(globalScope); @@ -320,7 +320,7 @@ describe('Integration | Scope', () => { expect(isolationScope.getScopeData().tags).toEqual({ tag1: 'val1', tag2: 'val2' }); // Now when we call init, the isolation scope remains intact - Sentry.init({ dsn: 'https://username@domain/123', defaultIntegrations: false }); + Sentry.init({ traceLifecycle: 'static', dsn: 'https://username@domain/123', defaultIntegrations: false }); // client is only attached to global scope by default expect(isolationScope.getClient()).toBeUndefined(); @@ -471,7 +471,7 @@ describe('Integration | Scope', () => { expect(currentScope.getScopeData().tags).toEqual({ tag1: 'val1', tag2: 'val2' }); // Now when we call init, the current scope remains intact - Sentry.init({ dsn: 'https://username@domain/123', defaultIntegrations: false }); + Sentry.init({ traceLifecycle: 'static', dsn: 'https://username@domain/123', defaultIntegrations: false }); // client is attached to current scope expect(currentScope.getClient()).toBeDefined(); diff --git a/packages/vue/test/integration/VueIntegration.test.ts b/packages/vue/test/integration/VueIntegration.test.ts index 62ff990d1f43..6197beeb2d67 100644 --- a/packages/vue/test/integration/VueIntegration.test.ts +++ b/packages/vue/test/integration/VueIntegration.test.ts @@ -50,6 +50,7 @@ describe('Sentry.VueIntegration', () => { it('allows to initialize integration later', () => { Sentry.init({ + traceLifecycle: 'static', dsn: PUBLIC_DSN, defaultIntegrations: false, }); @@ -73,6 +74,7 @@ describe('Sentry.VueIntegration', () => { it('warns when mounting before SDK.VueIntegration', () => { Sentry.init({ + traceLifecycle: 'static', dsn: PUBLIC_DSN, defaultIntegrations: false, }); @@ -99,6 +101,7 @@ describe('Sentry.VueIntegration', () => { // where VNodes in console arguments would trigger recursive warning spam with captureConsoleIntegration Sentry.init({ + traceLifecycle: 'static', dsn: PUBLIC_DSN, defaultIntegrations: false, normalizeDepth: 10, // High depth that would cause the issue diff --git a/packages/vue/test/integration/init.test.ts b/packages/vue/test/integration/init.test.ts index ea9342c8da9c..6a596588335f 100644 --- a/packages/vue/test/integration/init.test.ts +++ b/packages/vue/test/integration/init.test.ts @@ -94,6 +94,7 @@ describe('Sentry.init', () => { }); Sentry.init({ + traceLifecycle: 'static', dsn: PUBLIC_DSN, defaultIntegrations: false, integrations: [], @@ -117,5 +118,6 @@ function runInit(options: Partial): Client | undefined { defaultIntegrations: false, integrations: [integration], ...options, + traceLifecycle: 'static', }); } diff --git a/packages/vue/test/integration/normalize.test.ts b/packages/vue/test/integration/normalize.test.ts index 8f0fe3c3438e..3fdedb5433a9 100644 --- a/packages/vue/test/integration/normalize.test.ts +++ b/packages/vue/test/integration/normalize.test.ts @@ -16,6 +16,7 @@ const PUBLIC_DSN = 'https://username@domain/123'; describe('@sentry/vue init() normalize stringifier', () => { beforeEach(() => { Sentry.init({ + traceLifecycle: 'static', dsn: PUBLIC_DSN, defaultIntegrations: false, integrations: [],