diff --git a/packages/node/src/integrations/http.ts b/packages/node/src/integrations/http.ts index ded111673387..1102c0301095 100644 --- a/packages/node/src/integrations/http.ts +++ b/packages/node/src/integrations/http.ts @@ -34,6 +34,8 @@ interface TracingOptions { * array, and only attach tracing headers if a match was found. * * @deprecated Use top level `tracePropagationTargets` option instead. + * This option will be removed in v8. + * * ``` * Sentry.init({ * tracePropagationTargets: ['api.site.com'], diff --git a/packages/sveltekit/test/client/sdk.test.ts b/packages/sveltekit/test/client/sdk.test.ts index a8353a73df3e..5ff3b9f9e846 100644 --- a/packages/sveltekit/test/client/sdk.test.ts +++ b/packages/sveltekit/test/client/sdk.test.ts @@ -109,9 +109,7 @@ describe('Sentry client SDK', () => { it('Merges a user-provided BrowserTracing integration with the automatically added one', () => { init({ dsn: 'https://public@dsn.ingest.sentry.io/1337', - integrations: [ - new BrowserTracing({ tracePropagationTargets: ['myDomain.com'], startTransactionOnLocationChange: false }), - ], + integrations: [new BrowserTracing({ finalTimeout: 10, startTransactionOnLocationChange: false })], enableTracing: true, }); @@ -126,8 +124,7 @@ describe('Sentry client SDK', () => { expect(browserTracing).toBeDefined(); // This shows that the user-configured options are still here - expect(options.tracePropagationTargets).toEqual(['myDomain.com']); - expect(options.startTransactionOnLocationChange).toBe(false); + expect(options.finalTimeout).toEqual(10); // But we force the routing instrumentation to be ours expect(options.routingInstrumentation).toEqual(svelteKitRoutingInstrumentation); diff --git a/packages/tracing-internal/src/browser/browsertracing.ts b/packages/tracing-internal/src/browser/browsertracing.ts index aae66bee3358..d01c837d26c2 100644 --- a/packages/tracing-internal/src/browser/browsertracing.ts +++ b/packages/tracing-internal/src/browser/browsertracing.ts @@ -248,6 +248,7 @@ export class BrowserTracing implements Integration { // This is done as it minimizes bundle size (we don't have to have undefined checks). // // If both 1 and either one of 2 or 3 are set (from above), we log out a warning. + // eslint-disable-next-line deprecation/deprecation const tracePropagationTargets = clientOptionsTracePropagationTargets || this.options.tracePropagationTargets; if (__DEBUG_BUILD__ && this._hasSetTracePropagationTargets && clientOptionsTracePropagationTargets) { logger.warn( diff --git a/packages/tracing-internal/src/browser/request.ts b/packages/tracing-internal/src/browser/request.ts index e24c726ada5f..3880abe90fd5 100644 --- a/packages/tracing-internal/src/browser/request.ts +++ b/packages/tracing-internal/src/browser/request.ts @@ -27,7 +27,10 @@ export interface RequestInstrumentationOptions { * List of strings and/or regexes used to determine which outgoing requests will have `sentry-trace` and `baggage` * headers attached. * - * Default: ['localhost', /^\//] {@see DEFAULT_TRACE_PROPAGATION_TARGETS} + * @deprecated Use the top-level `tracePropagationTargets` option in `Sentry.init` instead. + * This option will be removed in v8. + * + * Default: ['localhost', /^\//] @see {DEFAULT_TRACE_PROPAGATION_TARGETS} */ tracePropagationTargets: Array; @@ -125,6 +128,7 @@ export function instrumentOutgoingRequests(_options?: Partial