@@ -16,6 +16,7 @@ import type {
16
16
import type { RequestEventData , Span , TransactionSource , WrappedFunction } from '@sentry/core' ;
17
17
import {
18
18
continueTrace ,
19
+ debug ,
19
20
fill ,
20
21
getActiveSpan ,
21
22
getClient ,
@@ -24,7 +25,6 @@ import {
24
25
hasSpansEnabled ,
25
26
isNodeEnv ,
26
27
loadModule ,
27
- logger ,
28
28
SEMANTIC_ATTRIBUTE_SENTRY_OP ,
29
29
SEMANTIC_ATTRIBUTE_SENTRY_ORIGIN ,
30
30
SEMANTIC_ATTRIBUTE_SENTRY_SOURCE ,
@@ -73,7 +73,7 @@ export function sentryHandleError(err: unknown, { request }: DataFunctionArgs):
73
73
}
74
74
75
75
captureRemixServerException ( err , 'remix.server.handleError' , request ) . then ( null , e => {
76
- DEBUG_BUILD && logger . warn ( 'Failed to capture Remix Server exception.' , e ) ;
76
+ DEBUG_BUILD && debug . warn ( 'Failed to capture Remix Server exception.' , e ) ;
77
77
} ) ;
78
78
}
79
79
@@ -220,7 +220,7 @@ function makeWrappedRootLoader() {
220
220
// We skip injection of trace and baggage in those cases.
221
221
// For `redirect`, a valid internal redirection target will have the trace and baggage injected.
222
222
if ( isRedirectResponse ( res ) || isCatchResponse ( res ) ) {
223
- DEBUG_BUILD && logger . warn ( 'Skipping injection of trace and baggage as the response does not have a body' ) ;
223
+ DEBUG_BUILD && debug . warn ( 'Skipping injection of trace and baggage as the response does not have a body' ) ;
224
224
return res ;
225
225
} else {
226
226
const data = await extractData ( res ) ;
@@ -235,7 +235,7 @@ function makeWrappedRootLoader() {
235
235
} ,
236
236
) ;
237
237
} else {
238
- DEBUG_BUILD && logger . warn ( 'Skipping injection of trace and baggage as the response body is not an object' ) ;
238
+ DEBUG_BUILD && debug . warn ( 'Skipping injection of trace and baggage as the response body is not an object' ) ;
239
239
return res ;
240
240
}
241
241
}
@@ -289,7 +289,7 @@ function wrapRequestHandler<T extends ServerBuild | (() => ServerBuild | Promise
289
289
try {
290
290
normalizedRequest = winterCGRequestToRequestData ( request ) ;
291
291
} catch ( e ) {
292
- DEBUG_BUILD && logger . warn ( 'Failed to normalize Remix request' ) ;
292
+ DEBUG_BUILD && debug . warn ( 'Failed to normalize Remix request' ) ;
293
293
}
294
294
295
295
if ( options ?. instrumentTracing && resolvedRoutes ) {
@@ -447,7 +447,7 @@ export function instrumentServer(options?: { instrumentTracing?: boolean }): voi
447
447
} > ( '@remix-run/server-runtime' , module ) ;
448
448
449
449
if ( ! pkg ) {
450
- DEBUG_BUILD && logger . warn ( 'Remix SDK was unable to require `@remix-run/server-runtime` package.' ) ;
450
+ DEBUG_BUILD && debug . warn ( 'Remix SDK was unable to require `@remix-run/server-runtime` package.' ) ;
451
451
452
452
return ;
453
453
}
0 commit comments