@tracelog/lib 2.7.1 → 2.7.2-rc.97.2
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.
- package/README.md +8 -3
- package/dist/browser/tracelog.esm.js +430 -397
- package/dist/browser/tracelog.esm.js.map +1 -1
- package/dist/browser/tracelog.js +2 -1
- package/dist/browser/tracelog.js.map +1 -1
- package/dist/public-api.cjs +2 -2
- package/dist/public-api.cjs.map +1 -1
- package/dist/public-api.d.mts +15 -2
- package/dist/public-api.d.ts +15 -2
- package/dist/public-api.js +2 -2
- package/dist/public-api.js.map +1 -1
- package/package.json +1 -1
package/dist/public-api.d.mts
CHANGED
|
@@ -324,6 +324,8 @@ interface ErrorData {
|
|
|
324
324
|
line?: number;
|
|
325
325
|
/** Column number in source file */
|
|
326
326
|
column?: number;
|
|
327
|
+
/** Error stack trace (truncated to 2000 chars) */
|
|
328
|
+
stack?: string;
|
|
327
329
|
}
|
|
328
330
|
/**
|
|
329
331
|
* UTM campaign tracking parameters
|
|
@@ -636,6 +638,14 @@ declare class PermanentError extends Error {
|
|
|
636
638
|
readonly statusCode?: number | undefined;
|
|
637
639
|
constructor(message: string, statusCode?: number | undefined);
|
|
638
640
|
}
|
|
641
|
+
/**
|
|
642
|
+
* Represents a rate limit error (429) that should not be retried in the
|
|
643
|
+
* inner send loop. Events are persisted for periodic retry via EventManager
|
|
644
|
+
* backoff, where server-side idempotency cache will resolve them.
|
|
645
|
+
*/
|
|
646
|
+
declare class RateLimitError extends Error {
|
|
647
|
+
constructor(message: string);
|
|
648
|
+
}
|
|
639
649
|
/**
|
|
640
650
|
* Represents a timeout error where the server likely received the request
|
|
641
651
|
* but the response took too long. Events should NOT be persisted for retry
|
|
@@ -1878,7 +1888,10 @@ declare class ErrorHandler extends StateManager {
|
|
|
1878
1888
|
private readonly handleRejection;
|
|
1879
1889
|
private extractRejectionMessage;
|
|
1880
1890
|
private sanitize;
|
|
1891
|
+
private sanitizePii;
|
|
1881
1892
|
private shouldSuppressError;
|
|
1893
|
+
private static readonly TRUNCATION_SUFFIX;
|
|
1894
|
+
private truncateStack;
|
|
1882
1895
|
private pruneOldErrors;
|
|
1883
1896
|
}
|
|
1884
1897
|
|
|
@@ -2500,7 +2513,7 @@ declare const MAX_ARRAY_LENGTH = 1000;
|
|
|
2500
2513
|
* Regular expressions for detecting and sanitizing Personally Identifiable Information (PII)
|
|
2501
2514
|
* These patterns are used to replace sensitive information with [REDACTED] in error messages
|
|
2502
2515
|
*/
|
|
2503
|
-
declare const PII_PATTERNS: readonly [RegExp, RegExp, RegExp, RegExp, RegExp, RegExp, RegExp];
|
|
2516
|
+
declare const PII_PATTERNS: readonly [RegExp, RegExp, RegExp, RegExp, RegExp, RegExp, RegExp, RegExp];
|
|
2504
2517
|
|
|
2505
2518
|
/**
|
|
2506
2519
|
* Performance monitoring and web vitals constants for TraceLog
|
|
@@ -2555,4 +2568,4 @@ declare const tracelog: {
|
|
|
2555
2568
|
resetIdentity: () => Promise<void>;
|
|
2556
2569
|
};
|
|
2557
2570
|
|
|
2558
|
-
export { AppConfigValidationError, type BeforeBatchTransformer, type BeforeSendTransformer, type ClickCoordinates, type ClickData, type ClickTrackingElementData, type Config, type CustomEventData, type CustomHeadersProvider, DEFAULT_SESSION_TIMEOUT, DEFAULT_WEB_VITALS_MODE, type DeviceInfo, DeviceType, type EmitterCallback, EmitterEvent, type EmitterMap, type ErrorData, ErrorType, type EventData, EventType, type EventTypeName, type EventsQueue, type IdentifyData, type InitResult, InitializationTimeoutError, IntegrationValidationError, MAX_ARRAY_LENGTH, MAX_CUSTOM_EVENT_ARRAY_SIZE, MAX_CUSTOM_EVENT_KEYS, MAX_CUSTOM_EVENT_NAME_LENGTH, MAX_CUSTOM_EVENT_STRING_SIZE, MAX_NESTED_OBJECT_KEYS, MAX_STRING_LENGTH, MAX_STRING_LENGTH_IN_ARRAY, type MetadataType, Mode, PII_PATTERNS, type PageViewData, PermanentError, type PersistedEventsQueue, type PrimaryScrollEvent, SamplingRateValidationError, type ScrollData, ScrollDirection, type SecondaryScrollEvent, type SessionEventCounts, SessionTimeoutValidationError, SpecialApiUrl, type State, TimeoutError, type TraceLogTestBridge, TraceLogValidationError, type TransformerHook, type TransformerMap, type UTM, type ViewportConfig, type ViewportElement, type ViewportEventData, WEB_VITALS_GOOD_THRESHOLDS, WEB_VITALS_NEEDS_IMPROVEMENT_THRESHOLDS, WEB_VITALS_POOR_THRESHOLDS, type WebVitalType, type WebVitalsData, type WebVitalsMode, getWebVitalsThresholds, isPrimaryScrollEvent, isSecondaryScrollEvent, tracelog };
|
|
2571
|
+
export { AppConfigValidationError, type BeforeBatchTransformer, type BeforeSendTransformer, type ClickCoordinates, type ClickData, type ClickTrackingElementData, type Config, type CustomEventData, type CustomHeadersProvider, DEFAULT_SESSION_TIMEOUT, DEFAULT_WEB_VITALS_MODE, type DeviceInfo, DeviceType, type EmitterCallback, EmitterEvent, type EmitterMap, type ErrorData, ErrorType, type EventData, EventType, type EventTypeName, type EventsQueue, type IdentifyData, type InitResult, InitializationTimeoutError, IntegrationValidationError, MAX_ARRAY_LENGTH, MAX_CUSTOM_EVENT_ARRAY_SIZE, MAX_CUSTOM_EVENT_KEYS, MAX_CUSTOM_EVENT_NAME_LENGTH, MAX_CUSTOM_EVENT_STRING_SIZE, MAX_NESTED_OBJECT_KEYS, MAX_STRING_LENGTH, MAX_STRING_LENGTH_IN_ARRAY, type MetadataType, Mode, PII_PATTERNS, type PageViewData, PermanentError, type PersistedEventsQueue, type PrimaryScrollEvent, RateLimitError, SamplingRateValidationError, type ScrollData, ScrollDirection, type SecondaryScrollEvent, type SessionEventCounts, SessionTimeoutValidationError, SpecialApiUrl, type State, TimeoutError, type TraceLogTestBridge, TraceLogValidationError, type TransformerHook, type TransformerMap, type UTM, type ViewportConfig, type ViewportElement, type ViewportEventData, WEB_VITALS_GOOD_THRESHOLDS, WEB_VITALS_NEEDS_IMPROVEMENT_THRESHOLDS, WEB_VITALS_POOR_THRESHOLDS, type WebVitalType, type WebVitalsData, type WebVitalsMode, getWebVitalsThresholds, isPrimaryScrollEvent, isSecondaryScrollEvent, tracelog };
|
package/dist/public-api.d.ts
CHANGED
|
@@ -324,6 +324,8 @@ interface ErrorData {
|
|
|
324
324
|
line?: number;
|
|
325
325
|
/** Column number in source file */
|
|
326
326
|
column?: number;
|
|
327
|
+
/** Error stack trace (truncated to 2000 chars) */
|
|
328
|
+
stack?: string;
|
|
327
329
|
}
|
|
328
330
|
/**
|
|
329
331
|
* UTM campaign tracking parameters
|
|
@@ -636,6 +638,14 @@ declare class PermanentError extends Error {
|
|
|
636
638
|
readonly statusCode?: number | undefined;
|
|
637
639
|
constructor(message: string, statusCode?: number | undefined);
|
|
638
640
|
}
|
|
641
|
+
/**
|
|
642
|
+
* Represents a rate limit error (429) that should not be retried in the
|
|
643
|
+
* inner send loop. Events are persisted for periodic retry via EventManager
|
|
644
|
+
* backoff, where server-side idempotency cache will resolve them.
|
|
645
|
+
*/
|
|
646
|
+
declare class RateLimitError extends Error {
|
|
647
|
+
constructor(message: string);
|
|
648
|
+
}
|
|
639
649
|
/**
|
|
640
650
|
* Represents a timeout error where the server likely received the request
|
|
641
651
|
* but the response took too long. Events should NOT be persisted for retry
|
|
@@ -1878,7 +1888,10 @@ declare class ErrorHandler extends StateManager {
|
|
|
1878
1888
|
private readonly handleRejection;
|
|
1879
1889
|
private extractRejectionMessage;
|
|
1880
1890
|
private sanitize;
|
|
1891
|
+
private sanitizePii;
|
|
1881
1892
|
private shouldSuppressError;
|
|
1893
|
+
private static readonly TRUNCATION_SUFFIX;
|
|
1894
|
+
private truncateStack;
|
|
1882
1895
|
private pruneOldErrors;
|
|
1883
1896
|
}
|
|
1884
1897
|
|
|
@@ -2500,7 +2513,7 @@ declare const MAX_ARRAY_LENGTH = 1000;
|
|
|
2500
2513
|
* Regular expressions for detecting and sanitizing Personally Identifiable Information (PII)
|
|
2501
2514
|
* These patterns are used to replace sensitive information with [REDACTED] in error messages
|
|
2502
2515
|
*/
|
|
2503
|
-
declare const PII_PATTERNS: readonly [RegExp, RegExp, RegExp, RegExp, RegExp, RegExp, RegExp];
|
|
2516
|
+
declare const PII_PATTERNS: readonly [RegExp, RegExp, RegExp, RegExp, RegExp, RegExp, RegExp, RegExp];
|
|
2504
2517
|
|
|
2505
2518
|
/**
|
|
2506
2519
|
* Performance monitoring and web vitals constants for TraceLog
|
|
@@ -2555,4 +2568,4 @@ declare const tracelog: {
|
|
|
2555
2568
|
resetIdentity: () => Promise<void>;
|
|
2556
2569
|
};
|
|
2557
2570
|
|
|
2558
|
-
export { AppConfigValidationError, type BeforeBatchTransformer, type BeforeSendTransformer, type ClickCoordinates, type ClickData, type ClickTrackingElementData, type Config, type CustomEventData, type CustomHeadersProvider, DEFAULT_SESSION_TIMEOUT, DEFAULT_WEB_VITALS_MODE, type DeviceInfo, DeviceType, type EmitterCallback, EmitterEvent, type EmitterMap, type ErrorData, ErrorType, type EventData, EventType, type EventTypeName, type EventsQueue, type IdentifyData, type InitResult, InitializationTimeoutError, IntegrationValidationError, MAX_ARRAY_LENGTH, MAX_CUSTOM_EVENT_ARRAY_SIZE, MAX_CUSTOM_EVENT_KEYS, MAX_CUSTOM_EVENT_NAME_LENGTH, MAX_CUSTOM_EVENT_STRING_SIZE, MAX_NESTED_OBJECT_KEYS, MAX_STRING_LENGTH, MAX_STRING_LENGTH_IN_ARRAY, type MetadataType, Mode, PII_PATTERNS, type PageViewData, PermanentError, type PersistedEventsQueue, type PrimaryScrollEvent, SamplingRateValidationError, type ScrollData, ScrollDirection, type SecondaryScrollEvent, type SessionEventCounts, SessionTimeoutValidationError, SpecialApiUrl, type State, TimeoutError, type TraceLogTestBridge, TraceLogValidationError, type TransformerHook, type TransformerMap, type UTM, type ViewportConfig, type ViewportElement, type ViewportEventData, WEB_VITALS_GOOD_THRESHOLDS, WEB_VITALS_NEEDS_IMPROVEMENT_THRESHOLDS, WEB_VITALS_POOR_THRESHOLDS, type WebVitalType, type WebVitalsData, type WebVitalsMode, getWebVitalsThresholds, isPrimaryScrollEvent, isSecondaryScrollEvent, tracelog };
|
|
2571
|
+
export { AppConfigValidationError, type BeforeBatchTransformer, type BeforeSendTransformer, type ClickCoordinates, type ClickData, type ClickTrackingElementData, type Config, type CustomEventData, type CustomHeadersProvider, DEFAULT_SESSION_TIMEOUT, DEFAULT_WEB_VITALS_MODE, type DeviceInfo, DeviceType, type EmitterCallback, EmitterEvent, type EmitterMap, type ErrorData, ErrorType, type EventData, EventType, type EventTypeName, type EventsQueue, type IdentifyData, type InitResult, InitializationTimeoutError, IntegrationValidationError, MAX_ARRAY_LENGTH, MAX_CUSTOM_EVENT_ARRAY_SIZE, MAX_CUSTOM_EVENT_KEYS, MAX_CUSTOM_EVENT_NAME_LENGTH, MAX_CUSTOM_EVENT_STRING_SIZE, MAX_NESTED_OBJECT_KEYS, MAX_STRING_LENGTH, MAX_STRING_LENGTH_IN_ARRAY, type MetadataType, Mode, PII_PATTERNS, type PageViewData, PermanentError, type PersistedEventsQueue, type PrimaryScrollEvent, RateLimitError, SamplingRateValidationError, type ScrollData, ScrollDirection, type SecondaryScrollEvent, type SessionEventCounts, SessionTimeoutValidationError, SpecialApiUrl, type State, TimeoutError, type TraceLogTestBridge, TraceLogValidationError, type TransformerHook, type TransformerMap, type UTM, type ViewportConfig, type ViewportElement, type ViewportEventData, WEB_VITALS_GOOD_THRESHOLDS, WEB_VITALS_NEEDS_IMPROVEMENT_THRESHOLDS, WEB_VITALS_POOR_THRESHOLDS, type WebVitalType, type WebVitalsData, type WebVitalsMode, getWebVitalsThresholds, isPrimaryScrollEvent, isSecondaryScrollEvent, tracelog };
|