@sentry/core 10.50.0 → 10.51.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (188) hide show
  1. package/build/cjs/client.js +27 -3
  2. package/build/cjs/client.js.map +1 -1
  3. package/build/cjs/envelope.js +4 -1
  4. package/build/cjs/envelope.js.map +1 -1
  5. package/build/cjs/index.js +10 -5
  6. package/build/cjs/index.js.map +1 -1
  7. package/build/cjs/instrument/console.js +3 -1
  8. package/build/cjs/instrument/console.js.map +1 -1
  9. package/build/cjs/instrument/fetch.js +6 -2
  10. package/build/cjs/instrument/fetch.js.map +1 -1
  11. package/build/cjs/instrument/handlers.js +11 -1
  12. package/build/cjs/instrument/handlers.js.map +1 -1
  13. package/build/cjs/integrations/console.js +3 -1
  14. package/build/cjs/integrations/console.js.map +1 -1
  15. package/build/cjs/integrations/extraerrordata.js +2 -2
  16. package/build/cjs/integrations/extraerrordata.js.map +1 -1
  17. package/build/cjs/integrations/postgresjs.js +10 -1
  18. package/build/cjs/integrations/postgresjs.js.map +1 -1
  19. package/build/cjs/integrations/requestdata.js +9 -5
  20. package/build/cjs/integrations/requestdata.js.map +1 -1
  21. package/build/cjs/integrations/supabase.js +39 -12
  22. package/build/cjs/integrations/supabase.js.map +1 -1
  23. package/build/cjs/logs/console-integration.js +3 -1
  24. package/build/cjs/logs/console-integration.js.map +1 -1
  25. package/build/cjs/server-runtime-client.js +20 -2
  26. package/build/cjs/server-runtime-client.js.map +1 -1
  27. package/build/cjs/tracing/ai/gen-ai-attributes.js +6 -0
  28. package/build/cjs/tracing/ai/gen-ai-attributes.js.map +1 -1
  29. package/build/cjs/tracing/idleSpan.js +7 -1
  30. package/build/cjs/tracing/idleSpan.js.map +1 -1
  31. package/build/cjs/tracing/langchain/index.js +43 -8
  32. package/build/cjs/tracing/langchain/index.js.map +1 -1
  33. package/build/cjs/tracing/langchain/utils.js +44 -10
  34. package/build/cjs/tracing/langchain/utils.js.map +1 -1
  35. package/build/cjs/tracing/langgraph/index.js +105 -2
  36. package/build/cjs/tracing/langgraph/index.js.map +1 -1
  37. package/build/cjs/tracing/langgraph/utils.js +168 -0
  38. package/build/cjs/tracing/langgraph/utils.js.map +1 -1
  39. package/build/cjs/tracing/spans/captureSpan.js +125 -0
  40. package/build/cjs/tracing/spans/captureSpan.js.map +1 -1
  41. package/build/cjs/tracing/spans/envelope.js +13 -3
  42. package/build/cjs/tracing/spans/envelope.js.map +1 -1
  43. package/build/cjs/tracing/trace.js +1 -0
  44. package/build/cjs/tracing/trace.js.map +1 -1
  45. package/build/cjs/trpc.js +2 -3
  46. package/build/cjs/trpc.js.map +1 -1
  47. package/build/cjs/utils/isSentryRequestUrl.js +9 -1
  48. package/build/cjs/utils/isSentryRequestUrl.js.map +1 -1
  49. package/build/cjs/utils/normalizationHints.js +38 -0
  50. package/build/cjs/utils/normalizationHints.js.map +1 -0
  51. package/build/cjs/utils/normalize.js +7 -11
  52. package/build/cjs/utils/normalize.js.map +1 -1
  53. package/build/cjs/utils/object.js +1 -1
  54. package/build/cjs/utils/object.js.map +1 -1
  55. package/build/cjs/utils/request.js +63 -12
  56. package/build/cjs/utils/request.js.map +1 -1
  57. package/build/cjs/utils/should-ignore-span.js +27 -8
  58. package/build/cjs/utils/should-ignore-span.js.map +1 -1
  59. package/build/cjs/utils/version.js +1 -1
  60. package/build/esm/client.js +27 -3
  61. package/build/esm/client.js.map +1 -1
  62. package/build/esm/envelope.js +4 -1
  63. package/build/esm/envelope.js.map +1 -1
  64. package/build/esm/index.js +3 -2
  65. package/build/esm/index.js.map +1 -1
  66. package/build/esm/instrument/console.js +3 -1
  67. package/build/esm/instrument/console.js.map +1 -1
  68. package/build/esm/instrument/fetch.js +6 -2
  69. package/build/esm/instrument/fetch.js.map +1 -1
  70. package/build/esm/instrument/handlers.js +11 -1
  71. package/build/esm/instrument/handlers.js.map +1 -1
  72. package/build/esm/integrations/console.js +3 -1
  73. package/build/esm/integrations/console.js.map +1 -1
  74. package/build/esm/integrations/extraerrordata.js +2 -2
  75. package/build/esm/integrations/extraerrordata.js.map +1 -1
  76. package/build/esm/integrations/postgresjs.js +10 -1
  77. package/build/esm/integrations/postgresjs.js.map +1 -1
  78. package/build/esm/integrations/requestdata.js +9 -5
  79. package/build/esm/integrations/requestdata.js.map +1 -1
  80. package/build/esm/integrations/supabase.js +39 -12
  81. package/build/esm/integrations/supabase.js.map +1 -1
  82. package/build/esm/logs/console-integration.js +3 -1
  83. package/build/esm/logs/console-integration.js.map +1 -1
  84. package/build/esm/package.json +1 -1
  85. package/build/esm/server-runtime-client.js +20 -2
  86. package/build/esm/server-runtime-client.js.map +1 -1
  87. package/build/esm/tracing/ai/gen-ai-attributes.js +6 -1
  88. package/build/esm/tracing/ai/gen-ai-attributes.js.map +1 -1
  89. package/build/esm/tracing/idleSpan.js +7 -1
  90. package/build/esm/tracing/idleSpan.js.map +1 -1
  91. package/build/esm/tracing/langchain/index.js +45 -10
  92. package/build/esm/tracing/langchain/index.js.map +1 -1
  93. package/build/esm/tracing/langchain/utils.js +44 -12
  94. package/build/esm/tracing/langchain/utils.js.map +1 -1
  95. package/build/esm/tracing/langgraph/index.js +107 -5
  96. package/build/esm/tracing/langgraph/index.js.map +1 -1
  97. package/build/esm/tracing/langgraph/utils.js +166 -2
  98. package/build/esm/tracing/langgraph/utils.js.map +1 -1
  99. package/build/esm/tracing/spans/captureSpan.js +126 -2
  100. package/build/esm/tracing/spans/captureSpan.js.map +1 -1
  101. package/build/esm/tracing/spans/envelope.js +13 -3
  102. package/build/esm/tracing/spans/envelope.js.map +1 -1
  103. package/build/esm/tracing/trace.js +1 -0
  104. package/build/esm/tracing/trace.js.map +1 -1
  105. package/build/esm/trpc.js +2 -3
  106. package/build/esm/trpc.js.map +1 -1
  107. package/build/esm/utils/isSentryRequestUrl.js +9 -1
  108. package/build/esm/utils/isSentryRequestUrl.js.map +1 -1
  109. package/build/esm/utils/normalizationHints.js +33 -0
  110. package/build/esm/utils/normalizationHints.js.map +1 -0
  111. package/build/esm/utils/normalize.js +7 -11
  112. package/build/esm/utils/normalize.js.map +1 -1
  113. package/build/esm/utils/object.js +1 -1
  114. package/build/esm/utils/object.js.map +1 -1
  115. package/build/esm/utils/request.js +63 -12
  116. package/build/esm/utils/request.js.map +1 -1
  117. package/build/esm/utils/should-ignore-span.js +27 -8
  118. package/build/esm/utils/should-ignore-span.js.map +1 -1
  119. package/build/esm/utils/version.js +1 -1
  120. package/build/types/client.d.ts +12 -1
  121. package/build/types/client.d.ts.map +1 -1
  122. package/build/types/envelope.d.ts.map +1 -1
  123. package/build/types/index.d.ts +4 -2
  124. package/build/types/index.d.ts.map +1 -1
  125. package/build/types/instrument/console.d.ts +2 -1
  126. package/build/types/instrument/console.d.ts.map +1 -1
  127. package/build/types/instrument/fetch.d.ts +4 -2
  128. package/build/types/instrument/fetch.d.ts.map +1 -1
  129. package/build/types/instrument/handlers.d.ts +2 -2
  130. package/build/types/instrument/handlers.d.ts.map +1 -1
  131. package/build/types/integrations/console.d.ts.map +1 -1
  132. package/build/types/integrations/postgresjs.d.ts.map +1 -1
  133. package/build/types/integrations/supabase.d.ts.map +1 -1
  134. package/build/types/logs/console-integration.d.ts.map +1 -1
  135. package/build/types/server-runtime-client.d.ts +5 -0
  136. package/build/types/server-runtime-client.d.ts.map +1 -1
  137. package/build/types/tracing/idleSpan.d.ts.map +1 -1
  138. package/build/types/tracing/langchain/index.d.ts.map +1 -1
  139. package/build/types/tracing/langchain/types.d.ts +8 -0
  140. package/build/types/tracing/langchain/types.d.ts.map +1 -1
  141. package/build/types/tracing/langchain/utils.d.ts +2 -0
  142. package/build/types/tracing/langchain/utils.d.ts.map +1 -1
  143. package/build/types/tracing/langgraph/index.d.ts +4 -0
  144. package/build/types/tracing/langgraph/index.d.ts.map +1 -1
  145. package/build/types/tracing/langgraph/utils.d.ts +18 -2
  146. package/build/types/tracing/langgraph/utils.d.ts.map +1 -1
  147. package/build/types/tracing/spans/captureSpan.d.ts +10 -0
  148. package/build/types/tracing/spans/captureSpan.d.ts.map +1 -1
  149. package/build/types/tracing/spans/envelope.d.ts.map +1 -1
  150. package/build/types/trpc.d.ts.map +1 -1
  151. package/build/types/types-hoist/feedback/config.d.ts +20 -0
  152. package/build/types/types-hoist/feedback/config.d.ts.map +1 -1
  153. package/build/types/types-hoist/feedback/index.d.ts +2 -2
  154. package/build/types/types-hoist/feedback/index.d.ts.map +1 -1
  155. package/build/types/types-hoist/feedback/sendFeedback.d.ts +3 -0
  156. package/build/types/types-hoist/feedback/sendFeedback.d.ts.map +1 -1
  157. package/build/types/types-hoist/options.d.ts +37 -2
  158. package/build/types/types-hoist/options.d.ts.map +1 -1
  159. package/build/types/types-hoist/span.d.ts +5 -0
  160. package/build/types/types-hoist/span.d.ts.map +1 -1
  161. package/build/types/utils/normalizationHints.d.ts +9 -0
  162. package/build/types/utils/normalizationHints.d.ts.map +1 -0
  163. package/build/types/utils/normalize.d.ts.map +1 -1
  164. package/build/types/utils/object.d.ts +1 -1
  165. package/build/types/utils/object.d.ts.map +1 -1
  166. package/build/types/utils/request.d.ts.map +1 -1
  167. package/build/types/utils/should-ignore-span.d.ts +3 -1
  168. package/build/types/utils/should-ignore-span.d.ts.map +1 -1
  169. package/build/types-ts3.8/client.d.ts +12 -1
  170. package/build/types-ts3.8/index.d.ts +4 -2
  171. package/build/types-ts3.8/instrument/console.d.ts +2 -1
  172. package/build/types-ts3.8/instrument/fetch.d.ts +4 -2
  173. package/build/types-ts3.8/instrument/handlers.d.ts +2 -2
  174. package/build/types-ts3.8/server-runtime-client.d.ts +5 -0
  175. package/build/types-ts3.8/tracing/langchain/types.d.ts +8 -0
  176. package/build/types-ts3.8/tracing/langchain/utils.d.ts +2 -0
  177. package/build/types-ts3.8/tracing/langgraph/index.d.ts +4 -0
  178. package/build/types-ts3.8/tracing/langgraph/utils.d.ts +18 -2
  179. package/build/types-ts3.8/tracing/spans/captureSpan.d.ts +10 -0
  180. package/build/types-ts3.8/types-hoist/feedback/config.d.ts +20 -0
  181. package/build/types-ts3.8/types-hoist/feedback/index.d.ts +2 -2
  182. package/build/types-ts3.8/types-hoist/feedback/sendFeedback.d.ts +3 -0
  183. package/build/types-ts3.8/types-hoist/options.d.ts +37 -2
  184. package/build/types-ts3.8/types-hoist/span.d.ts +5 -0
  185. package/build/types-ts3.8/utils/normalizationHints.d.ts +9 -0
  186. package/build/types-ts3.8/utils/object.d.ts +1 -1
  187. package/build/types-ts3.8/utils/should-ignore-span.d.ts +3 -1
  188. package/package.json +1 -1
@@ -1,7 +1,7 @@
1
1
  export type InstrumentHandlerType = 'console' | 'dom' | 'fetch' | 'fetch-body-resolved' | 'history' | 'xhr' | 'error' | 'unhandledrejection';
2
2
  export type InstrumentHandlerCallback = (data: any) => void;
3
- /** Add a handler function. */
4
- export declare function addHandler(type: InstrumentHandlerType, handler: InstrumentHandlerCallback): void;
3
+ /** Add a handler function. Returns a function to remove the handler. */
4
+ export declare function addHandler(type: InstrumentHandlerType, handler: InstrumentHandlerCallback): () => void;
5
5
  /**
6
6
  * Reset all instrumentation handlers.
7
7
  * This can be used by tests to ensure we have a clean slate of instrumentation handlers.
@@ -18,6 +18,7 @@ export interface ServerRuntimeClientOptions extends ClientOptions<BaseTransportO
18
18
  * The Sentry Server Runtime Client SDK.
19
19
  */
20
20
  export declare class ServerRuntimeClient<O extends ClientOptions & ServerRuntimeClientOptions = ServerRuntimeClientOptions> extends Client<O> {
21
+ private _disposeCallbacks;
21
22
  /**
22
23
  * Creates a new Edge SDK instance.
23
24
  * @param options Configuration options for this SDK.
@@ -47,6 +48,10 @@ export declare class ServerRuntimeClient<O extends ClientOptions & ServerRuntime
47
48
  * to create a monitor automatically when sending a check in.
48
49
  */
49
50
  captureCheckIn(checkIn: CheckIn, monitorConfig?: MonitorConfig, scope?: Scope): string;
51
+ /**
52
+ * @inheritDoc
53
+ */
54
+ registerCleanup(callback: () => void): void;
50
55
  /**
51
56
  * Disposes of the client and releases all resources.
52
57
  *
@@ -32,6 +32,14 @@ export interface LangChainSerialized {
32
32
  graph?: Record<string, unknown>;
33
33
  kwargs?: Record<string, unknown>;
34
34
  }
35
+ /**
36
+ * Subset of the 'llm' param passed to createReactAgent
37
+ */
38
+ export interface BaseChatModel {
39
+ lc_namespace: string[];
40
+ modelName?: string;
41
+ model?: string;
42
+ }
35
43
  /**
36
44
  * LangChain message structure
37
45
  * Supports both regular messages and LangChain serialized format
@@ -57,4 +57,6 @@ export declare function extractChatModelRequestAttributes(llm: LangChainSerializ
57
57
  * `stop_reason` (for providers that use it).
58
58
  */
59
59
  export declare function extractLlmResponseAttributes(llmResult: LangChainLLMResult, recordOutputs: boolean): Record<string, SpanAttributeValue> | undefined;
60
+ export declare function getAgentNameFromMetadata(metadata?: Record<string, unknown>): Record<string, SpanAttributeValue>;
61
+ export declare function extractToolDefinitions(extraParams?: Record<string, unknown>): string | undefined;
60
62
  //# sourceMappingURL=utils.d.ts.map
@@ -8,6 +8,10 @@ import { CompiledGraph, LangGraphOptions } from './types';
8
8
  *
9
9
  */
10
10
  export declare function instrumentStateGraphCompile(originalCompile: (...args: unknown[]) => CompiledGraph, options: LangGraphOptions): (...args: unknown[]) => CompiledGraph;
11
+ /**
12
+ * Instruments createReactAgent to create invoke_agent and execute_tool spans.
13
+ */
14
+ export declare function instrumentCreateReactAgent(originalCreateReactAgent: (...args: unknown[]) => CompiledGraph, options?: LangGraphOptions): (...args: unknown[]) => CompiledGraph;
11
15
  /**
12
16
  * Directly instruments a StateGraph instance to add tracing spans
13
17
  *
@@ -1,6 +1,20 @@
1
1
  import { Span } from '../../types-hoist/span';
2
- import { LangChainMessage } from '../langchain/types';
3
- import { CompiledGraph } from './types';
2
+ import { BaseChatModel, LangChainMessage } from '../langchain/types';
3
+ import { CompiledGraph, LangGraphOptions } from './types';
4
+ /**
5
+ * Extract LLM model object from createReactAgent params
6
+ */
7
+ export declare function extractLLMFromParams(args: unknown[]): BaseChatModel | null;
8
+ /**
9
+ * Extract agent name from createReactAgent params
10
+ */
11
+ export declare function extractAgentNameFromParams(args: unknown[]): string | null;
12
+ /**
13
+ * Wraps an array of LangChain tools so each invocation creates a gen_ai.execute_tool span.
14
+ *
15
+ * Wraps each tool's invoke() method in place. A marker prevents double-wrapping.
16
+ */
17
+ export declare function wrapToolsWithSpans(tools: unknown[], options: LangGraphOptions, agentName?: string): unknown[];
4
18
  /**
5
19
  * Extract tool calls from messages
6
20
  */
@@ -28,4 +42,6 @@ export declare function extractToolsFromCompiledGraph(compiledGraph: CompiledGra
28
42
  * Set response attributes on the span
29
43
  */
30
44
  export declare function setResponseAttributes(span: Span, inputMessages: LangChainMessage[] | null, result: unknown): void;
45
+ /** Merge `sentryHandler` into a langchain `callbacks` value (`BaseCallbackHandler[]` or `BaseCallbackManager`). */
46
+ export declare function mergeSentryCallback(existing: unknown, sentryHandler: unknown): unknown;
31
47
  //# sourceMappingURL=utils.d.ts.map
@@ -23,4 +23,14 @@ export declare function applyBeforeSendSpanCallback(span: StreamedSpanJSON, befo
23
23
  * If an attribute already exists, it will not be overwritten.
24
24
  */
25
25
  export declare function safeSetSpanJSONAttributes(spanJSON: StreamedSpanJSON, newAttributes: RawAttributes<Record<string, unknown>>): void;
26
+ /**
27
+ * Infer and backfill span data from OTel semantic conventions.
28
+ * This mirrors what the `SentrySpanExporter` does for non-streamed spans via `getSpanData`/`inferSpanData`.
29
+ * Streamed spans skip the exporter, so we do the inference here during capture.
30
+ *
31
+ * Backfills: `sentry.op`, `sentry.source`, and `name` (description).
32
+ * Uses `safeSetSpanJSONAttributes` so explicitly set attributes are never overwritten.
33
+ */
34
+ /** Exported only for tests. */
35
+ export declare function inferSpanDataFromOtelAttributes(spanJSON: StreamedSpanJSON, spanKind?: number): void;
26
36
  //# sourceMappingURL=captureSpan.d.ts.map
@@ -159,6 +159,26 @@ export interface FeedbackTextConfiguration {
159
159
  * The label for the button that removed a highlight/hidden section of the screenshot.
160
160
  */
161
161
  removeHighlightText: string;
162
+ /**
163
+ * Error text shown when feedback submission is attempted with an empty message
164
+ */
165
+ errorEmptyMessageText: string;
166
+ /**
167
+ * Error text shown when the Sentry client is not set up
168
+ */
169
+ errorNoClientText: string;
170
+ /**
171
+ * Error text shown when the feedback submission times out (after 30s)
172
+ */
173
+ errorTimeoutText: string;
174
+ /**
175
+ * Error text shown when the feedback submission is blocked because the domain is not allowed (HTTP 403)
176
+ */
177
+ errorForbiddenText: string;
178
+ /**
179
+ * Error text shown when the feedback submission fails for any other reason (e.g. network error, ad-blocker)
180
+ */
181
+ errorGenericText: string;
162
182
  }
163
183
  /**
164
184
  * The public callbacks available for the feedback integration
@@ -1,9 +1,9 @@
1
1
  import { Attachment } from '../attachment';
2
2
  import { Integration } from '../integration';
3
3
  import { FeedbackCallbacks, FeedbackGeneralConfiguration, FeedbackTextConfiguration, FeedbackThemeConfiguration } from './config';
4
- import { FeedbackEvent, SendFeedback, SendFeedbackParams, UserFeedback } from './sendFeedback';
4
+ import { FeedbackErrorCode, FeedbackErrorMessages, FeedbackEvent, SendFeedback, SendFeedbackParams, UserFeedback } from './sendFeedback';
5
5
  export { FeedbackFormData } from './form';
6
- export { FeedbackEvent, UserFeedback, SendFeedback, SendFeedbackParams };
6
+ export { FeedbackErrorCode, FeedbackErrorMessages, FeedbackEvent, SendFeedback, SendFeedbackParams, UserFeedback };
7
7
  /**
8
8
  * The integration's internal `options` member where every value should be set
9
9
  */
@@ -43,8 +43,11 @@ export interface SendFeedbackParams {
43
43
  [key: string]: Primitive;
44
44
  };
45
45
  }
46
+ export type FeedbackErrorCode = 'ERROR_EMPTY_MESSAGE' | 'ERROR_NO_CLIENT' | 'ERROR_TIMEOUT' | 'ERROR_FORBIDDEN' | 'ERROR_GENERIC';
47
+ export type FeedbackErrorMessages = Partial<Record<FeedbackErrorCode, string>>;
46
48
  export type SendFeedback = (params: SendFeedbackParams, hint?: EventHint & {
47
49
  includeReplay?: boolean;
50
+ errorMessages?: FeedbackErrorMessages;
48
51
  }) => Promise<string>;
49
52
  export {};
50
53
  //# sourceMappingURL=sendFeedback.d.ts.map
@@ -90,9 +90,16 @@ export interface ServerRuntimeOptions {
90
90
  */
91
91
  onFatalError?(this: void, error: Error): void;
92
92
  }
93
+ /**
94
+ * Allowed attribute value matchers in `ignoreSpans` filters.
95
+ * String span attributes use pattern matching (substring or RegExp).
96
+ * Non-string attribute values match by strict equality (arrays element-wise).
97
+ */
98
+ export type IgnoreSpanAttributeValue = string | boolean | number | string[] | boolean[] | number[] | RegExp;
93
99
  /**
94
100
  * A filter object for ignoring spans.
95
- * At least one of the properties (`op` or `name`) must be set.
101
+ * At least one of the properties (`name`, `op`, or `attributes`) must be set.
102
+ * If multiple are set, all must match for the span to be ignored.
96
103
  */
97
104
  type IgnoreSpanFilter = {
98
105
  /**
@@ -103,6 +110,12 @@ type IgnoreSpanFilter = {
103
110
  * Spans with an op matching this pattern will be ignored.
104
111
  */
105
112
  op?: string | RegExp;
113
+ /**
114
+ * Spans whose attributes ALL match the corresponding entries will be ignored.
115
+ * String attribute values are matched as patterns (substring or RegExp).
116
+ * Non-string values match by strict equality (arrays element-wise).
117
+ */
118
+ attributes?: Record<string, IgnoreSpanAttributeValue>;
106
119
  } | {
107
120
  /**
108
121
  * Spans with a name matching this pattern will be ignored.
@@ -112,6 +125,27 @@ type IgnoreSpanFilter = {
112
125
  * Spans with an op matching this pattern will be ignored.
113
126
  */
114
127
  op: string | RegExp;
128
+ /**
129
+ * Spans whose attributes ALL match the corresponding entries will be ignored.
130
+ * String attribute values are matched as patterns (substring or RegExp).
131
+ * Non-string values match by strict equality (arrays element-wise).
132
+ */
133
+ attributes?: Record<string, IgnoreSpanAttributeValue>;
134
+ } | {
135
+ /**
136
+ * Spans with a name matching this pattern will be ignored.
137
+ */
138
+ name?: string | RegExp;
139
+ /**
140
+ * Spans with an op matching this pattern will be ignored.
141
+ */
142
+ op?: string | RegExp;
143
+ /**
144
+ * Spans whose attributes ALL match the corresponding entries will be ignored.
145
+ * String attribute values are matched as patterns (substring or RegExp).
146
+ * Non-string values match by strict equality (arrays element-wise).
147
+ */
148
+ attributes: Record<string, IgnoreSpanAttributeValue>;
115
149
  };
116
150
  export interface ClientOptions<TO extends BaseTransportOptions = BaseTransportOptions> {
117
151
  /**
@@ -291,7 +325,8 @@ export interface ClientOptions<TO extends BaseTransportOptions = BaseTransportOp
291
325
  * A list of span names or patterns to ignore.
292
326
  *
293
327
  * If you specify a pattern {@link IgnoreSpanFilter}, at least one
294
- * of the properties (`op` or `name`) must be set.
328
+ * of the properties (`name`, `op`, or `attributes`) must be set.
329
+ * When multiple properties are set, all must match for the span to be ignored.
295
330
  *
296
331
  * @default []
297
332
  */
@@ -50,6 +50,11 @@ export type SerializedStreamedSpan = Pick<StreamedSpanJSON, Exclude<keyof Stream
50
50
  * Envelope span item container.
51
51
  */
52
52
  export type SerializedStreamedSpanContainer = {
53
+ version?: number;
54
+ ingest_settings?: {
55
+ infer_ip?: 'auto' | 'never';
56
+ infer_user_agent?: 'auto' | 'never';
57
+ };
53
58
  items: Array<SerializedStreamedSpan>;
54
59
  };
55
60
  /** A JSON representation of a span. */
@@ -0,0 +1,9 @@
1
+ /** Marks an object so `normalize` returns it unchanged (already-normalized SDK data). */
2
+ export declare function setSkipNormalizationHint(obj: object): void;
3
+ /** Overrides remaining normalization depth from this object downward (e.g. Redux / Pinia state). */
4
+ export declare function setNormalizationDepthOverrideHint(obj: object, depth: number): void;
5
+ /** @internal */
6
+ export declare function hasSkipNormalizationHint(value: object): boolean;
7
+ /** @internal */
8
+ export declare function getNormalizationDepthOverrideHint(value: object): number | undefined;
9
+ //# sourceMappingURL=normalizationHints.d.ts.map
@@ -22,7 +22,7 @@ export declare function fill(source: {
22
22
  * @param name The name of the property to be set
23
23
  * @param value The value to which to set the property
24
24
  */
25
- export declare function addNonEnumerableProperty(obj: object, name: string, value: unknown): void;
25
+ export declare function addNonEnumerableProperty(obj: object, name: string | symbol, value: unknown): void;
26
26
  /**
27
27
  * Remembers the original function on the wrapped function and
28
28
  * patches up the prototype.
@@ -3,7 +3,9 @@ import { SpanJSON } from '../types-hoist/span';
3
3
  /**
4
4
  * Check if a span should be ignored based on the ignoreSpans configuration.
5
5
  */
6
- export declare function shouldIgnoreSpan(span: Pick<SpanJSON, 'description' | 'op'>, ignoreSpans: Required<ClientOptions>['ignoreSpans']): boolean;
6
+ export declare function shouldIgnoreSpan(span: Pick<SpanJSON, 'description' | 'op'> & {
7
+ attributes?: Record<string, unknown>;
8
+ }, ignoreSpans: Required<ClientOptions>['ignoreSpans']): boolean;
7
9
  /**
8
10
  * Takes a list of spans, and a span that was dropped, and re-parents the child spans of the dropped span to the parent of the dropped span, if possible.
9
11
  * This mutates the spans array in place!
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sentry/core",
3
- "version": "10.50.0",
3
+ "version": "10.51.0",
4
4
  "description": "Base implementation for all Sentry JavaScript SDKs",
5
5
  "repository": "git://github.com/getsentry/sentry-javascript.git",
6
6
  "homepage": "https://github.com/getsentry/sentry-javascript/tree/master/packages/core",