sentry-vir 0.0.0 → 0.0.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/LICENSE-CC0 +121 -0
- package/LICENSE-MIT +21 -0
- package/README.md +92 -0
- package/dist/cjs/env/execution-env.d.ts +181 -0
- package/dist/cjs/env/execution-env.js +47 -0
- package/dist/cjs/env/release-env.d.ts +8 -0
- package/dist/cjs/env/release-env.js +13 -0
- package/dist/cjs/event-context/event-context.d.ts +16 -0
- package/dist/cjs/event-context/event-context.js +11 -0
- package/dist/cjs/event-context/event-severity.d.ts +21 -0
- package/dist/cjs/event-context/event-severity.js +37 -0
- package/dist/cjs/event-context/extra-context.error.d.ts +24 -0
- package/dist/cjs/event-context/extra-context.error.js +35 -0
- package/dist/cjs/event-context/extra-event-context.d.ts +17 -0
- package/dist/cjs/event-context/extra-event-context.js +27 -0
- package/dist/cjs/index.d.ts +11 -0
- package/dist/cjs/index.js +27 -0
- package/dist/cjs/init-sentry/event-processor.d.ts +10 -0
- package/dist/cjs/init-sentry/event-processor.js +28 -0
- package/dist/cjs/init-sentry/handle-sentry-send.d.ts +16 -0
- package/dist/cjs/init-sentry/handle-sentry-send.js +48 -0
- package/dist/cjs/init-sentry/init-sentry.d.ts +194 -0
- package/dist/cjs/init-sentry/init-sentry.js +24 -0
- package/dist/cjs/init-sentry/sentry-config.d.ts +9 -0
- package/dist/cjs/init-sentry/sentry-config.js +51 -0
- package/dist/cjs/init-sentry/sentry-logger.d.ts +40 -0
- package/dist/cjs/init-sentry/sentry-logger.js +96 -0
- package/dist/esm/env/execution-env.js +20 -0
- package/dist/esm/env/release-env.js +10 -0
- package/dist/esm/event-context/event-context.js +7 -0
- package/dist/esm/event-context/event-severity.js +32 -0
- package/dist/esm/event-context/extra-context.error.js +30 -0
- package/dist/esm/event-context/extra-event-context.js +22 -0
- package/dist/esm/index.js +11 -0
- package/dist/esm/init-sentry/event-processor.js +24 -0
- package/dist/esm/init-sentry/handle-sentry-send.js +43 -0
- package/dist/esm/init-sentry/init-sentry.js +20 -0
- package/dist/esm/init-sentry/sentry-config.js +47 -0
- package/dist/esm/init-sentry/sentry-logger.js +91 -0
- package/dist/types/env/execution-env.d.ts +181 -0
- package/dist/types/env/release-env.d.ts +8 -0
- package/dist/types/event-context/event-context.d.ts +16 -0
- package/dist/types/event-context/event-severity.d.ts +21 -0
- package/dist/types/event-context/extra-context.error.d.ts +24 -0
- package/dist/types/event-context/extra-event-context.d.ts +17 -0
- package/dist/types/index.d.ts +11 -0
- package/dist/types/init-sentry/event-processor.d.ts +10 -0
- package/dist/types/init-sentry/handle-sentry-send.d.ts +16 -0
- package/dist/types/init-sentry/init-sentry.d.ts +194 -0
- package/dist/types/init-sentry/sentry-config.d.ts +9 -0
- package/dist/types/init-sentry/sentry-logger.d.ts +40 -0
- package/package.json +68 -10
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { EventExtraContext } from './event-context';
|
|
2
|
+
/**
|
|
3
|
+
* Symbol used to attach extra event context to events. This is particularly useful for errors so
|
|
4
|
+
* they can be thrown while attaching this extra context to them.
|
|
5
|
+
*/
|
|
6
|
+
export declare const extraEventContextSymbol: unique symbol;
|
|
7
|
+
/** Simply describes an object that has extra event context. */
|
|
8
|
+
export type HasExtraContext = {
|
|
9
|
+
[extraEventContextSymbol]: EventExtraContext;
|
|
10
|
+
};
|
|
11
|
+
/** Type guard for whether any given input has extra event context. */
|
|
12
|
+
export declare function hasExtraEventContext(input: unknown): input is HasExtraContext;
|
|
13
|
+
/**
|
|
14
|
+
* Tries to extract extra event context via extraEventContextSymbol. Returns undefined if there is
|
|
15
|
+
* no extra event context.
|
|
16
|
+
*/
|
|
17
|
+
export declare function extractExtraEventContext(event: unknown): EventExtraContext | undefined;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.extractExtraEventContext = exports.hasExtraEventContext = exports.extraEventContextSymbol = void 0;
|
|
4
|
+
const common_1 = require("@augment-vir/common");
|
|
5
|
+
/**
|
|
6
|
+
* Symbol used to attach extra event context to events. This is particularly useful for errors so
|
|
7
|
+
* they can be thrown while attaching this extra context to them.
|
|
8
|
+
*/
|
|
9
|
+
exports.extraEventContextSymbol = Symbol('extra-event-context');
|
|
10
|
+
/** Type guard for whether any given input has extra event context. */
|
|
11
|
+
function hasExtraEventContext(input) {
|
|
12
|
+
return (0, common_1.typedHasProperty)(input, exports.extraEventContextSymbol);
|
|
13
|
+
}
|
|
14
|
+
exports.hasExtraEventContext = hasExtraEventContext;
|
|
15
|
+
/**
|
|
16
|
+
* Tries to extract extra event context via extraEventContextSymbol. Returns undefined if there is
|
|
17
|
+
* no extra event context.
|
|
18
|
+
*/
|
|
19
|
+
function extractExtraEventContext(event) {
|
|
20
|
+
if (hasExtraEventContext(event)) {
|
|
21
|
+
return event[exports.extraEventContextSymbol];
|
|
22
|
+
}
|
|
23
|
+
else {
|
|
24
|
+
return undefined;
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
exports.extractExtraEventContext = extractExtraEventContext;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export * from './env/execution-env';
|
|
2
|
+
export * from './env/release-env';
|
|
3
|
+
export * from './event-context/event-context';
|
|
4
|
+
export * from './event-context/event-severity';
|
|
5
|
+
export * from './event-context/extra-context.error';
|
|
6
|
+
export * from './event-context/extra-event-context';
|
|
7
|
+
export * from './init-sentry/event-processor';
|
|
8
|
+
export * from './init-sentry/handle-sentry-send';
|
|
9
|
+
export * from './init-sentry/init-sentry';
|
|
10
|
+
export * from './init-sentry/sentry-config';
|
|
11
|
+
export * from './init-sentry/sentry-logger';
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./env/execution-env"), exports);
|
|
18
|
+
__exportStar(require("./env/release-env"), exports);
|
|
19
|
+
__exportStar(require("./event-context/event-context"), exports);
|
|
20
|
+
__exportStar(require("./event-context/event-severity"), exports);
|
|
21
|
+
__exportStar(require("./event-context/extra-context.error"), exports);
|
|
22
|
+
__exportStar(require("./event-context/extra-event-context"), exports);
|
|
23
|
+
__exportStar(require("./init-sentry/event-processor"), exports);
|
|
24
|
+
__exportStar(require("./init-sentry/handle-sentry-send"), exports);
|
|
25
|
+
__exportStar(require("./init-sentry/init-sentry"), exports);
|
|
26
|
+
__exportStar(require("./init-sentry/sentry-config"), exports);
|
|
27
|
+
__exportStar(require("./init-sentry/sentry-logger"), exports);
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { EventHint, Event as SentryEvent } from '@sentry/types';
|
|
2
|
+
import { EventExtraContextCreator } from '../event-context/event-context';
|
|
3
|
+
/** Attach extra event data for a sentry event. */
|
|
4
|
+
export declare function processSentryEvent(
|
|
5
|
+
/** Event from Sentry. */
|
|
6
|
+
event: SentryEvent,
|
|
7
|
+
/** EventHint generated by Sentry. */
|
|
8
|
+
hint: EventHint,
|
|
9
|
+
/** Optional callback for creating extra event context. */
|
|
10
|
+
createUniversalContext?: EventExtraContextCreator | undefined): SentryEvent;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.processSentryEvent = void 0;
|
|
4
|
+
const common_1 = require("@augment-vir/common");
|
|
5
|
+
const event_context_1 = require("../event-context/event-context");
|
|
6
|
+
const event_severity_1 = require("../event-context/event-severity");
|
|
7
|
+
const extra_event_context_1 = require("../event-context/extra-event-context");
|
|
8
|
+
/** Attach extra event data for a sentry event. */
|
|
9
|
+
function processSentryEvent(
|
|
10
|
+
/** Event from Sentry. */
|
|
11
|
+
event,
|
|
12
|
+
/** EventHint generated by Sentry. */
|
|
13
|
+
hint,
|
|
14
|
+
/** Optional callback for creating extra event context. */
|
|
15
|
+
createUniversalContext) {
|
|
16
|
+
const extraContext = {
|
|
17
|
+
...(0, extra_event_context_1.extractExtraEventContext)(hint.originalException),
|
|
18
|
+
...createUniversalContext?.(),
|
|
19
|
+
originalFullMessage: event.message || (0, common_1.extractErrorMessage)(hint.originalException),
|
|
20
|
+
};
|
|
21
|
+
const sentryContext = (0, event_context_1.convertEventDetailsToSentryContext)({
|
|
22
|
+
severity: (0, event_severity_1.extractEventSeverity)(event),
|
|
23
|
+
extraContext,
|
|
24
|
+
});
|
|
25
|
+
Object.assign(event, sentryContext);
|
|
26
|
+
return event;
|
|
27
|
+
}
|
|
28
|
+
exports.processSentryEvent = processSentryEvent;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { EventHint } from '@sentry/browser';
|
|
2
|
+
import type { ErrorEvent, TransactionEvent } from '@sentry/types';
|
|
3
|
+
import { SentryReleaseEnvEnum } from '../env/release-env';
|
|
4
|
+
/** Creates a handler for Sentry events based on the given env. */
|
|
5
|
+
export declare function createSentryHandler(
|
|
6
|
+
/**
|
|
7
|
+
* The release environment (dev vs prod). Determines whether events should be sent to sentry or
|
|
8
|
+
* not.
|
|
9
|
+
*/
|
|
10
|
+
releaseEnv: SentryReleaseEnvEnum): (event: TransactionEvent | ErrorEvent, hint: EventHint) => TransactionEvent | ErrorEvent | null;
|
|
11
|
+
/** Tries to extract the original event message from different possible Sentry types. */
|
|
12
|
+
export declare function extractOriginalMessage(
|
|
13
|
+
/** Event from Sentry. */
|
|
14
|
+
event: TransactionEvent | ErrorEvent,
|
|
15
|
+
/** EventHint generated by Sentry. */
|
|
16
|
+
hint: EventHint): string;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.extractOriginalMessage = exports.createSentryHandler = void 0;
|
|
4
|
+
const common_1 = require("@augment-vir/common");
|
|
5
|
+
const release_env_1 = require("../env/release-env");
|
|
6
|
+
const event_severity_1 = require("../event-context/event-severity");
|
|
7
|
+
/** Creates a handler for Sentry events based on the given env. */
|
|
8
|
+
function createSentryHandler(
|
|
9
|
+
/**
|
|
10
|
+
* The release environment (dev vs prod). Determines whether events should be sent to sentry or
|
|
11
|
+
* not.
|
|
12
|
+
*/
|
|
13
|
+
releaseEnv) {
|
|
14
|
+
/** The actual function that gets called when handling Sentry events. */
|
|
15
|
+
function handleSentrySend(
|
|
16
|
+
/** The event from Sentry. */
|
|
17
|
+
event,
|
|
18
|
+
/** The EventHint generated by Sentry. */
|
|
19
|
+
hint) {
|
|
20
|
+
const consoleMethod = (0, event_severity_1.getConsoleMethodForSeverity)(event);
|
|
21
|
+
const message = extractOriginalMessage(event, hint);
|
|
22
|
+
const logArgs = [
|
|
23
|
+
message,
|
|
24
|
+
event.extra,
|
|
25
|
+
{ event, hint },
|
|
26
|
+
];
|
|
27
|
+
if (releaseEnv === release_env_1.SentryReleaseEnvEnum.Dev) {
|
|
28
|
+
consoleMethod('Would have sent to Sentry:', ...logArgs);
|
|
29
|
+
return null;
|
|
30
|
+
}
|
|
31
|
+
else {
|
|
32
|
+
consoleMethod('Sending to Sentry:', ...logArgs);
|
|
33
|
+
return event;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
return handleSentrySend;
|
|
37
|
+
}
|
|
38
|
+
exports.createSentryHandler = createSentryHandler;
|
|
39
|
+
/** Tries to extract the original event message from different possible Sentry types. */
|
|
40
|
+
function extractOriginalMessage(
|
|
41
|
+
/** Event from Sentry. */
|
|
42
|
+
event,
|
|
43
|
+
/** EventHint generated by Sentry. */
|
|
44
|
+
hint) {
|
|
45
|
+
const message = event.message || (0, common_1.extractErrorMessage)(hint.originalException);
|
|
46
|
+
return message;
|
|
47
|
+
}
|
|
48
|
+
exports.extractOriginalMessage = extractOriginalMessage;
|
|
@@ -0,0 +1,194 @@
|
|
|
1
|
+
import type { Options } from '@sentry/types';
|
|
2
|
+
import { SentryExecutionEnvEnum } from '../env/execution-env';
|
|
3
|
+
import { SentryReleaseEnvEnum } from '../env/release-env';
|
|
4
|
+
import { EventExtraContextCreator } from '../event-context/event-context';
|
|
5
|
+
import { UserOverrides } from './sentry-config';
|
|
6
|
+
/** Configuration for initializing Sentry. */
|
|
7
|
+
export type InitSentryInput = {
|
|
8
|
+
/**
|
|
9
|
+
* The environment wherein the Sentry client will execute. Used to determine which Sentry client
|
|
10
|
+
* to load: browser or node.
|
|
11
|
+
*/
|
|
12
|
+
executionEnv: SentryExecutionEnvEnum;
|
|
13
|
+
/**
|
|
14
|
+
* The release environment, prod vs dev rather than browser vs node. In dev, events won't be
|
|
15
|
+
* sent to sentry. In both options, all events will be logged to the local console.
|
|
16
|
+
*/
|
|
17
|
+
releaseEnv: SentryReleaseEnvEnum;
|
|
18
|
+
/** Name for the current release. */
|
|
19
|
+
releaseName: Required<Options>['release'];
|
|
20
|
+
/** DSN needed for Sentry to hook up to your sentry project. */
|
|
21
|
+
dsn: Required<Options>['dsn'];
|
|
22
|
+
/**
|
|
23
|
+
* Optionally create extra context to be included in all Sentry events. This will execute for
|
|
24
|
+
* each event that is processed.
|
|
25
|
+
*/
|
|
26
|
+
createUniversalContext?: EventExtraContextCreator | undefined;
|
|
27
|
+
/** Optionally override any Sentry config properties that this package sets. */
|
|
28
|
+
sentryConfigOverrides?: UserOverrides;
|
|
29
|
+
};
|
|
30
|
+
/**
|
|
31
|
+
* Setup a sentry client with all the default sentry-vir integrations and configs.
|
|
32
|
+
*
|
|
33
|
+
* To override any default sentry-vir settings, include them in the userConfig input.
|
|
34
|
+
*/
|
|
35
|
+
export declare function initSentry({ executionEnv, dsn, releaseEnv, releaseName, sentryConfigOverrides, createUniversalContext, }: InitSentryInput): Promise<{
|
|
36
|
+
default: typeof import("@sentry/browser");
|
|
37
|
+
Integrations: {
|
|
38
|
+
GlobalHandlers: typeof import("@sentry/browser").GlobalHandlers;
|
|
39
|
+
TryCatch: typeof import("@sentry/browser").TryCatch;
|
|
40
|
+
Breadcrumbs: typeof import("@sentry/browser").Breadcrumbs;
|
|
41
|
+
LinkedErrors: typeof import("@sentry/browser").LinkedErrors;
|
|
42
|
+
HttpContext: typeof import("@sentry/browser").HttpContext;
|
|
43
|
+
Dedupe: typeof import("@sentry/browser").Dedupe;
|
|
44
|
+
FunctionToString: typeof import("@sentry/core").FunctionToString;
|
|
45
|
+
InboundFilters: typeof import("@sentry/core").InboundFilters;
|
|
46
|
+
};
|
|
47
|
+
Replay: typeof import("@sentry/replay").Replay;
|
|
48
|
+
BrowserTracing: typeof import("@sentry-internal/tracing").BrowserTracing;
|
|
49
|
+
defaultRequestInstrumentationOptions: import("@sentry-internal/tracing").RequestInstrumentationOptions;
|
|
50
|
+
instrumentOutgoingRequests: typeof import("@sentry-internal/tracing").instrumentOutgoingRequests;
|
|
51
|
+
addTracingExtensions: typeof import("@sentry/core").addTracingExtensions;
|
|
52
|
+
setMeasurement: typeof import("@sentry/core").setMeasurement;
|
|
53
|
+
extractTraceparentData: typeof import("@sentry/utils").extractTraceparentData;
|
|
54
|
+
getActiveTransaction: typeof import("@sentry/core").getActiveTransaction;
|
|
55
|
+
spanStatusfromHttpCode: typeof import("@sentry/core").spanStatusfromHttpCode;
|
|
56
|
+
trace: typeof import("@sentry/core").trace;
|
|
57
|
+
makeMultiplexedTransport: typeof import("@sentry/core").makeMultiplexedTransport;
|
|
58
|
+
ModuleMetadata: typeof import("@sentry/core").ModuleMetadata;
|
|
59
|
+
makeBrowserOfflineTransport: typeof import("@sentry/browser").makeBrowserOfflineTransport;
|
|
60
|
+
onProfilingStartRouteTransaction: typeof import("@sentry/browser").onProfilingStartRouteTransaction;
|
|
61
|
+
BrowserProfilingIntegration: typeof import("@sentry/browser").BrowserProfilingIntegration;
|
|
62
|
+
addGlobalEventProcessor: typeof import("@sentry/core").addGlobalEventProcessor;
|
|
63
|
+
addBreadcrumb: typeof import("@sentry/core").addBreadcrumb;
|
|
64
|
+
captureException: typeof import("@sentry/core").captureException;
|
|
65
|
+
captureEvent: typeof import("@sentry/core").captureEvent;
|
|
66
|
+
captureMessage: typeof import("@sentry/core").captureMessage;
|
|
67
|
+
close: typeof import("@sentry/core").close;
|
|
68
|
+
configureScope: typeof import("@sentry/core").configureScope;
|
|
69
|
+
createTransport: typeof import("@sentry/core").createTransport;
|
|
70
|
+
flush: typeof import("@sentry/core").flush;
|
|
71
|
+
getHubFromCarrier: typeof import("@sentry/core").getHubFromCarrier;
|
|
72
|
+
getCurrentHub: typeof import("@sentry/core").getCurrentHub;
|
|
73
|
+
Hub: typeof import("@sentry/core").Hub;
|
|
74
|
+
lastEventId: typeof import("@sentry/core").lastEventId;
|
|
75
|
+
makeMain: typeof import("@sentry/core").makeMain;
|
|
76
|
+
Scope: typeof import("@sentry/core").Scope;
|
|
77
|
+
startTransaction: typeof import("@sentry/core").startTransaction;
|
|
78
|
+
getActiveSpan: typeof import("@sentry/core").getActiveSpan;
|
|
79
|
+
startSpan: typeof import("@sentry/core").startSpan;
|
|
80
|
+
startInactiveSpan: typeof import("@sentry/core").startInactiveSpan;
|
|
81
|
+
startSpanManual: typeof import("@sentry/core").startSpanManual;
|
|
82
|
+
SDK_VERSION: "7.73.0";
|
|
83
|
+
setContext: typeof import("@sentry/core").setContext;
|
|
84
|
+
setExtra: typeof import("@sentry/core").setExtra;
|
|
85
|
+
setExtras: typeof import("@sentry/core").setExtras;
|
|
86
|
+
setTag: typeof import("@sentry/core").setTag;
|
|
87
|
+
setTags: typeof import("@sentry/core").setTags;
|
|
88
|
+
setUser: typeof import("@sentry/core").setUser;
|
|
89
|
+
withScope: typeof import("@sentry/core").withScope;
|
|
90
|
+
FunctionToString: typeof import("@sentry/core").FunctionToString;
|
|
91
|
+
InboundFilters: typeof import("@sentry/core").InboundFilters;
|
|
92
|
+
WINDOW: import("@sentry/utils").InternalGlobal & Window;
|
|
93
|
+
BrowserClient: typeof import("@sentry/browser").BrowserClient;
|
|
94
|
+
makeFetchTransport: typeof import("@sentry/browser").makeFetchTransport;
|
|
95
|
+
makeXHRTransport: typeof import("@sentry/browser").makeXHRTransport;
|
|
96
|
+
defaultStackParser: import("@sentry/types").StackParser;
|
|
97
|
+
defaultStackLineParsers: import("@sentry/types").StackLineParser[];
|
|
98
|
+
chromeStackLineParser: import("@sentry/types").StackLineParser;
|
|
99
|
+
geckoStackLineParser: import("@sentry/types").StackLineParser;
|
|
100
|
+
opera10StackLineParser: import("@sentry/types").StackLineParser;
|
|
101
|
+
opera11StackLineParser: import("@sentry/types").StackLineParser;
|
|
102
|
+
winjsStackLineParser: import("@sentry/types").StackLineParser;
|
|
103
|
+
eventFromException: typeof import("@sentry/browser").eventFromException;
|
|
104
|
+
eventFromMessage: typeof import("@sentry/browser").eventFromMessage;
|
|
105
|
+
exceptionFromError: typeof import("@sentry/browser").exceptionFromError;
|
|
106
|
+
createUserFeedbackEnvelope: typeof import("@sentry/browser").createUserFeedbackEnvelope;
|
|
107
|
+
defaultIntegrations: (import("@sentry/browser").HttpContext | import("@sentry/browser").Dedupe | import("@sentry/core").InboundFilters | import("@sentry/core").FunctionToString | import("@sentry/browser").GlobalHandlers | import("@sentry/browser").TryCatch | import("@sentry/browser").Breadcrumbs | import("@sentry/browser").LinkedErrors)[];
|
|
108
|
+
forceLoad: typeof import("@sentry/browser").forceLoad;
|
|
109
|
+
init: typeof import("@sentry/browser").init;
|
|
110
|
+
onLoad: typeof import("@sentry/browser").onLoad;
|
|
111
|
+
showReportDialog: typeof import("@sentry/browser").showReportDialog;
|
|
112
|
+
captureUserFeedback: typeof import("@sentry/browser").captureUserFeedback;
|
|
113
|
+
wrap: typeof import("@sentry/browser").wrap;
|
|
114
|
+
GlobalHandlers: typeof import("@sentry/browser").GlobalHandlers;
|
|
115
|
+
TryCatch: typeof import("@sentry/browser").TryCatch;
|
|
116
|
+
Breadcrumbs: typeof import("@sentry/browser").Breadcrumbs;
|
|
117
|
+
LinkedErrors: typeof import("@sentry/browser").LinkedErrors;
|
|
118
|
+
HttpContext: typeof import("@sentry/browser").HttpContext;
|
|
119
|
+
Dedupe: typeof import("@sentry/browser").Dedupe;
|
|
120
|
+
} | {
|
|
121
|
+
default: typeof import("@sentry/node");
|
|
122
|
+
addGlobalEventProcessor: typeof import("@sentry/core").addGlobalEventProcessor;
|
|
123
|
+
addBreadcrumb: typeof import("@sentry/core").addBreadcrumb;
|
|
124
|
+
captureException: typeof import("@sentry/core").captureException;
|
|
125
|
+
captureEvent: typeof import("@sentry/core").captureEvent;
|
|
126
|
+
captureMessage: typeof import("@sentry/core").captureMessage;
|
|
127
|
+
close: typeof import("@sentry/core").close;
|
|
128
|
+
configureScope: typeof import("@sentry/core").configureScope;
|
|
129
|
+
createTransport: typeof import("@sentry/core").createTransport;
|
|
130
|
+
extractTraceparentData: typeof import("@sentry/utils").extractTraceparentData;
|
|
131
|
+
flush: typeof import("@sentry/core").flush;
|
|
132
|
+
getActiveTransaction: typeof import("@sentry/core").getActiveTransaction;
|
|
133
|
+
getHubFromCarrier: typeof import("@sentry/core").getHubFromCarrier;
|
|
134
|
+
getCurrentHub: typeof import("@sentry/core").getCurrentHub;
|
|
135
|
+
Hub: typeof import("@sentry/core").Hub;
|
|
136
|
+
lastEventId: typeof import("@sentry/core").lastEventId;
|
|
137
|
+
makeMain: typeof import("@sentry/core").makeMain;
|
|
138
|
+
runWithAsyncContext: typeof import("@sentry/core").runWithAsyncContext;
|
|
139
|
+
Scope: typeof import("@sentry/core").Scope;
|
|
140
|
+
startTransaction: typeof import("@sentry/core").startTransaction;
|
|
141
|
+
SDK_VERSION: "7.73.0";
|
|
142
|
+
setContext: typeof import("@sentry/core").setContext;
|
|
143
|
+
setExtra: typeof import("@sentry/core").setExtra;
|
|
144
|
+
setExtras: typeof import("@sentry/core").setExtras;
|
|
145
|
+
setTag: typeof import("@sentry/core").setTag;
|
|
146
|
+
setTags: typeof import("@sentry/core").setTags;
|
|
147
|
+
setUser: typeof import("@sentry/core").setUser;
|
|
148
|
+
spanStatusfromHttpCode: typeof import("@sentry/core").spanStatusfromHttpCode;
|
|
149
|
+
trace: typeof import("@sentry/core").trace;
|
|
150
|
+
withScope: typeof import("@sentry/core").withScope;
|
|
151
|
+
captureCheckIn: typeof import("@sentry/core").captureCheckIn;
|
|
152
|
+
setMeasurement: typeof import("@sentry/core").setMeasurement;
|
|
153
|
+
getActiveSpan: typeof import("@sentry/core").getActiveSpan;
|
|
154
|
+
startSpan: typeof import("@sentry/core").startSpan;
|
|
155
|
+
startActiveSpan: typeof import("@sentry/core").startSpan;
|
|
156
|
+
startInactiveSpan: typeof import("@sentry/core").startInactiveSpan;
|
|
157
|
+
startSpanManual: typeof import("@sentry/core").startSpanManual;
|
|
158
|
+
autoDiscoverNodePerformanceMonitoringIntegrations: typeof import("@sentry/node").autoDiscoverNodePerformanceMonitoringIntegrations;
|
|
159
|
+
NodeClient: typeof import("@sentry/node").NodeClient;
|
|
160
|
+
makeNodeTransport: typeof import("@sentry/node").makeNodeTransport;
|
|
161
|
+
defaultIntegrations: (import("@sentry/core").InboundFilters | import("@sentry/core").FunctionToString | import("@sentry/node/types/integrations").OnUncaughtException | import("@sentry/node/types/integrations").OnUnhandledRejection | import("@sentry/node/types/integrations").ContextLines | import("@sentry/node/types/integrations").Context | import("@sentry/node/types/integrations").Console | import("@sentry/node/types/integrations").Http | import("@sentry/node/types/integrations").LinkedErrors | import("@sentry/node/types/integrations").Modules | import("@sentry/node/types/integrations").RequestData | import("@sentry/node/types/integrations").LocalVariables | import("@sentry/node/types/integrations").Undici)[];
|
|
162
|
+
init: typeof import("@sentry/node").init;
|
|
163
|
+
defaultStackParser: import("@sentry/types").StackParser;
|
|
164
|
+
getSentryRelease: typeof import("@sentry/node").getSentryRelease;
|
|
165
|
+
addRequestDataToEvent: typeof import("@sentry/node").addRequestDataToEvent;
|
|
166
|
+
DEFAULT_USER_INCLUDES: string[];
|
|
167
|
+
extractRequestData: typeof import("@sentry/node").extractRequestData;
|
|
168
|
+
deepReadDirSync: typeof import("@sentry/node").deepReadDirSync;
|
|
169
|
+
getModuleFromFilename: typeof import("@sentry/node").getModuleFromFilename;
|
|
170
|
+
enableAnrDetection: typeof import("@sentry/node").enableAnrDetection;
|
|
171
|
+
Integrations: {
|
|
172
|
+
Apollo: typeof import("@sentry-internal/tracing").Apollo;
|
|
173
|
+
Express: typeof import("@sentry-internal/tracing").Express;
|
|
174
|
+
GraphQL: typeof import("@sentry-internal/tracing").GraphQL;
|
|
175
|
+
Mongo: typeof import("@sentry-internal/tracing").Mongo;
|
|
176
|
+
Mysql: typeof import("@sentry-internal/tracing").Mysql;
|
|
177
|
+
Postgres: typeof import("@sentry-internal/tracing").Postgres;
|
|
178
|
+
Prisma: typeof import("@sentry-internal/tracing").Prisma;
|
|
179
|
+
Console: typeof import("@sentry/node/types/integrations").Console;
|
|
180
|
+
Http: typeof import("@sentry/node/types/integrations").Http;
|
|
181
|
+
OnUncaughtException: typeof import("@sentry/node/types/integrations").OnUncaughtException;
|
|
182
|
+
OnUnhandledRejection: typeof import("@sentry/node/types/integrations").OnUnhandledRejection;
|
|
183
|
+
LinkedErrors: typeof import("@sentry/node/types/integrations").LinkedErrors;
|
|
184
|
+
Modules: typeof import("@sentry/node/types/integrations").Modules;
|
|
185
|
+
ContextLines: typeof import("@sentry/node/types/integrations").ContextLines;
|
|
186
|
+
Context: typeof import("@sentry/node/types/integrations").Context;
|
|
187
|
+
RequestData: typeof import("@sentry/node/types/integrations").RequestData;
|
|
188
|
+
LocalVariables: typeof import("@sentry/node/types/integrations").LocalVariables;
|
|
189
|
+
Undici: typeof import("@sentry/node/types/integrations").Undici;
|
|
190
|
+
FunctionToString: typeof import("@sentry/core").FunctionToString;
|
|
191
|
+
InboundFilters: typeof import("@sentry/core").InboundFilters;
|
|
192
|
+
};
|
|
193
|
+
Handlers: typeof import("@sentry/node/types/handlers");
|
|
194
|
+
}>;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.initSentry = void 0;
|
|
4
|
+
const execution_env_1 = require("../env/execution-env");
|
|
5
|
+
const event_processor_1 = require("./event-processor");
|
|
6
|
+
const sentry_config_1 = require("./sentry-config");
|
|
7
|
+
/**
|
|
8
|
+
* Setup a sentry client with all the default sentry-vir integrations and configs.
|
|
9
|
+
*
|
|
10
|
+
* To override any default sentry-vir settings, include them in the userConfig input.
|
|
11
|
+
*/
|
|
12
|
+
/* c8 ignore next */
|
|
13
|
+
async function initSentry({ executionEnv, dsn, releaseEnv, releaseName, sentryConfigOverrides, createUniversalContext, }) {
|
|
14
|
+
const sentryDep = await (0, execution_env_1.getSentryByEnv)(executionEnv);
|
|
15
|
+
const finalSentryConfig = await (0, sentry_config_1.createSentryConfig)(executionEnv, sentryDep, {
|
|
16
|
+
dsn,
|
|
17
|
+
environment: releaseEnv,
|
|
18
|
+
release: releaseName,
|
|
19
|
+
}, sentryConfigOverrides, releaseEnv);
|
|
20
|
+
sentryDep.init(finalSentryConfig);
|
|
21
|
+
sentryDep.addGlobalEventProcessor((event, hint) => (0, event_processor_1.processSentryEvent)(event, hint, createUniversalContext));
|
|
22
|
+
return sentryDep;
|
|
23
|
+
}
|
|
24
|
+
exports.initSentry = initSentry;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { Options } from '@sentry/types';
|
|
2
|
+
import { SentryBrowserDep, SentryDepByEnv, SentryExecutionEnvEnum, SentryNodeDep } from '../env/execution-env';
|
|
3
|
+
import { SentryReleaseEnvEnum } from '../env/release-env';
|
|
4
|
+
/** Optional UserOverrides of Sentry config values. */
|
|
5
|
+
export type UserOverrides = Omit<Partial<Options>, keyof RequiredSentryOptions> | undefined;
|
|
6
|
+
/** Sentry config options that are required. */
|
|
7
|
+
export type RequiredSentryOptions = Pick<Required<Options>, 'dsn' | 'environment' | 'release'>;
|
|
8
|
+
/** Creates the sentry config used internally by sentry-vir. */
|
|
9
|
+
export declare function createSentryConfig<const Env extends SentryExecutionEnvEnum>(env: Env, sentryDep: SentryDepByEnv<Env>, requiredSentryOptions: RequiredSentryOptions, userOverrides: UserOverrides, releaseEnv: SentryReleaseEnvEnum): Promise<SentryBrowserDep | SentryNodeDep>;
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.createSentryConfig = void 0;
|
|
4
|
+
const common_1 = require("@augment-vir/common");
|
|
5
|
+
const execution_env_1 = require("../env/execution-env");
|
|
6
|
+
const handle_sentry_send_1 = require("./handle-sentry-send");
|
|
7
|
+
/** Creates the sentry config used internally by sentry-vir. */
|
|
8
|
+
async function createSentryConfig(env, sentryDep, requiredSentryOptions, userOverrides, releaseEnv) {
|
|
9
|
+
const sharedSentryConfig = {
|
|
10
|
+
beforeSend: (0, handle_sentry_send_1.createSentryHandler)(releaseEnv),
|
|
11
|
+
beforeSendTransaction: (0, handle_sentry_send_1.createSentryHandler)(releaseEnv),
|
|
12
|
+
defaultIntegrations: false,
|
|
13
|
+
enabled: true,
|
|
14
|
+
};
|
|
15
|
+
const envSentryConfig = sentryConfigByEnv[env](
|
|
16
|
+
/**
|
|
17
|
+
* As cast needed because env and sentryDep are tightly coupled and there's not a good way
|
|
18
|
+
* to check that they match with a type guard. This is okay, however, because the types of
|
|
19
|
+
* this functions parameters already imposes the requirement that they are coupled.
|
|
20
|
+
*/
|
|
21
|
+
sentryDep);
|
|
22
|
+
const combinedConfig = (0, common_1.mergeDeep)(sharedSentryConfig, envSentryConfig, requiredSentryOptions, userOverrides);
|
|
23
|
+
return combinedConfig;
|
|
24
|
+
}
|
|
25
|
+
exports.createSentryConfig = createSentryConfig;
|
|
26
|
+
const sentryConfigByEnv = {
|
|
27
|
+
[execution_env_1.SentryExecutionEnvEnum.Browser](BrowserSentry) {
|
|
28
|
+
const options = {
|
|
29
|
+
integrations: [
|
|
30
|
+
new BrowserSentry.HttpContext(),
|
|
31
|
+
new BrowserSentry.Dedupe(),
|
|
32
|
+
new BrowserSentry.InboundFilters(),
|
|
33
|
+
new BrowserSentry.FunctionToString(),
|
|
34
|
+
new BrowserSentry.GlobalHandlers(),
|
|
35
|
+
],
|
|
36
|
+
};
|
|
37
|
+
return options;
|
|
38
|
+
},
|
|
39
|
+
[execution_env_1.SentryExecutionEnvEnum.Node](NodeSentry) {
|
|
40
|
+
const options = {
|
|
41
|
+
integrations: [
|
|
42
|
+
new NodeSentry.Integrations.OnUncaughtException(),
|
|
43
|
+
new NodeSentry.Integrations.OnUnhandledRejection(),
|
|
44
|
+
new NodeSentry.Integrations.ContextLines(),
|
|
45
|
+
new NodeSentry.Integrations.Context(),
|
|
46
|
+
new NodeSentry.Integrations.FunctionToString(),
|
|
47
|
+
],
|
|
48
|
+
};
|
|
49
|
+
return options;
|
|
50
|
+
},
|
|
51
|
+
};
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { AnyFunction, MaybePromise } from '@augment-vir/common';
|
|
2
|
+
import type { Event as SentryEvent } from '@sentry/types';
|
|
3
|
+
import type { SentryDep } from '../env/execution-env';
|
|
4
|
+
import { EventDetails, EventExtraContext } from '../event-context/event-context';
|
|
5
|
+
/** The bare minimum Sentry client needed for logging events. */
|
|
6
|
+
export type SentryClientForLogging = Pick<SentryDep, 'captureMessage' | 'captureException' | 'captureEvent'>;
|
|
7
|
+
/** An event that was triggered before setSentryClientForLogging was called. */
|
|
8
|
+
export type PrematureEvent<EntryPointFunction extends AnyFunction> = {
|
|
9
|
+
entryPoint: EntryPointFunction;
|
|
10
|
+
inputs: Parameters<EntryPointFunction>;
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* Used to store events before the Sentry client is setup. This is exported for testing purposes
|
|
14
|
+
* only, you don't need to do anything with this.
|
|
15
|
+
*/
|
|
16
|
+
export declare const prematureSentryEvents: PrematureEvent<any>[];
|
|
17
|
+
/**
|
|
18
|
+
* Asynchronously set the Sentry client for logging. When this is called, any events that were
|
|
19
|
+
* triggered beforehand are handled. Thus, this set can be done at any time, allowing for
|
|
20
|
+
* asynchronous Sentry client setup but synchronous log and error handling.
|
|
21
|
+
*
|
|
22
|
+
* This should be called as soon as possible after you have a return value from initSentry.
|
|
23
|
+
*
|
|
24
|
+
* This can be safely called multiple times (to overwrite the previously set Sentry client) because
|
|
25
|
+
* previous events won't be handled multiple times.
|
|
26
|
+
*/
|
|
27
|
+
export declare function setSentryClientForLogging(client: MaybePromise<SentryClientForLogging>): Promise<void>;
|
|
28
|
+
/** Record an error to Sentry without throwing it. */
|
|
29
|
+
export declare function handleError(error: unknown, extraContext?: EventExtraContext): string | undefined;
|
|
30
|
+
/** Send non-error events to Sentry. */
|
|
31
|
+
export declare const sendLog: {
|
|
32
|
+
/** Sends an even to Sentry with debug severity. */
|
|
33
|
+
readonly debug: (info: Parameters<typeof sendLogToSentry>[0], extraContext?: EventExtraContext) => string | undefined;
|
|
34
|
+
/** Sends an even to Sentry with info severity. */
|
|
35
|
+
readonly info: (info: Parameters<typeof sendLogToSentry>[0], extraContext?: EventExtraContext) => string | undefined;
|
|
36
|
+
/** Sends an even to Sentry with warning severity. */
|
|
37
|
+
readonly warning: (info: Parameters<typeof sendLogToSentry>[0], extraContext?: EventExtraContext) => string | undefined;
|
|
38
|
+
};
|
|
39
|
+
declare function sendLogToSentry(logInfo: string | Omit<SentryEvent, 'extra' | 'level'>, eventDetails: EventDetails): string | undefined;
|
|
40
|
+
export {};
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.sendLog = exports.handleError = exports.setSentryClientForLogging = exports.prematureSentryEvents = void 0;
|
|
4
|
+
const common_1 = require("@augment-vir/common");
|
|
5
|
+
const event_context_1 = require("../event-context/event-context");
|
|
6
|
+
const event_severity_1 = require("../event-context/event-severity");
|
|
7
|
+
let sentryClientForLogging;
|
|
8
|
+
/**
|
|
9
|
+
* Used to store events before the Sentry client is setup. This is exported for testing purposes
|
|
10
|
+
* only, you don't need to do anything with this.
|
|
11
|
+
*/
|
|
12
|
+
exports.prematureSentryEvents = [];
|
|
13
|
+
/**
|
|
14
|
+
* Asynchronously set the Sentry client for logging. When this is called, any events that were
|
|
15
|
+
* triggered beforehand are handled. Thus, this set can be done at any time, allowing for
|
|
16
|
+
* asynchronous Sentry client setup but synchronous log and error handling.
|
|
17
|
+
*
|
|
18
|
+
* This should be called as soon as possible after you have a return value from initSentry.
|
|
19
|
+
*
|
|
20
|
+
* This can be safely called multiple times (to overwrite the previously set Sentry client) because
|
|
21
|
+
* previous events won't be handled multiple times.
|
|
22
|
+
*/
|
|
23
|
+
async function setSentryClientForLogging(client) {
|
|
24
|
+
const hadClientBefore = !!sentryClientForLogging;
|
|
25
|
+
sentryClientForLogging = await client;
|
|
26
|
+
if (!hadClientBefore) {
|
|
27
|
+
sendPrematureEvents();
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
exports.setSentryClientForLogging = setSentryClientForLogging;
|
|
31
|
+
function sendPrematureEvents() {
|
|
32
|
+
while (exports.prematureSentryEvents.length) {
|
|
33
|
+
const prematureLog = exports.prematureSentryEvents.pop();
|
|
34
|
+
if (!prematureLog) {
|
|
35
|
+
return;
|
|
36
|
+
}
|
|
37
|
+
prematureLog.entryPoint(...prematureLog.inputs);
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
/** Record an error to Sentry without throwing it. */
|
|
41
|
+
function handleError(error, extraContext) {
|
|
42
|
+
if (!sentryClientForLogging) {
|
|
43
|
+
exports.prematureSentryEvents.push({
|
|
44
|
+
entryPoint: handleError,
|
|
45
|
+
inputs: [
|
|
46
|
+
error,
|
|
47
|
+
extraContext,
|
|
48
|
+
],
|
|
49
|
+
});
|
|
50
|
+
return undefined;
|
|
51
|
+
}
|
|
52
|
+
const scopeContext = (0, event_context_1.convertEventDetailsToSentryContext)({
|
|
53
|
+
extraContext,
|
|
54
|
+
severity: event_severity_1.EventSeverityEnum.Error,
|
|
55
|
+
});
|
|
56
|
+
const eventId = sentryClientForLogging.captureException(error, scopeContext);
|
|
57
|
+
return eventId;
|
|
58
|
+
}
|
|
59
|
+
exports.handleError = handleError;
|
|
60
|
+
/** Send non-error events to Sentry. */
|
|
61
|
+
exports.sendLog = {
|
|
62
|
+
/** Sends an even to Sentry with debug severity. */
|
|
63
|
+
[event_severity_1.EventSeverityEnum.Debug]: wrapLogWithSeverity(event_severity_1.EventSeverityEnum.Debug),
|
|
64
|
+
/** Sends an even to Sentry with info severity. */
|
|
65
|
+
[event_severity_1.EventSeverityEnum.Info]: wrapLogWithSeverity(event_severity_1.EventSeverityEnum.Info),
|
|
66
|
+
/** Sends an even to Sentry with warning severity. */
|
|
67
|
+
[event_severity_1.EventSeverityEnum.Warning]: wrapLogWithSeverity(event_severity_1.EventSeverityEnum.Warning),
|
|
68
|
+
};
|
|
69
|
+
function wrapLogWithSeverity(severity) {
|
|
70
|
+
return (info, extraContext) => {
|
|
71
|
+
return sendLogToSentry(info, {
|
|
72
|
+
extraContext,
|
|
73
|
+
severity,
|
|
74
|
+
});
|
|
75
|
+
};
|
|
76
|
+
}
|
|
77
|
+
function sendLogToSentry(logInfo, eventDetails) {
|
|
78
|
+
if (!sentryClientForLogging) {
|
|
79
|
+
exports.prematureSentryEvents.push({
|
|
80
|
+
entryPoint: 'sendLog',
|
|
81
|
+
inputs: [
|
|
82
|
+
logInfo,
|
|
83
|
+
eventDetails,
|
|
84
|
+
],
|
|
85
|
+
});
|
|
86
|
+
return undefined;
|
|
87
|
+
}
|
|
88
|
+
const scopeContext = (0, event_context_1.convertEventDetailsToSentryContext)(eventDetails);
|
|
89
|
+
const eventId = (0, common_1.isRuntimeTypeOf)(logInfo, 'string')
|
|
90
|
+
? sentryClientForLogging.captureMessage(logInfo, scopeContext)
|
|
91
|
+
: sentryClientForLogging.captureEvent({
|
|
92
|
+
...logInfo,
|
|
93
|
+
...scopeContext,
|
|
94
|
+
});
|
|
95
|
+
return eventId;
|
|
96
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/** Used to determine which Sentry client dependency to import. */
|
|
2
|
+
/* c8 ignore next */
|
|
3
|
+
export var SentryExecutionEnvEnum;
|
|
4
|
+
(function (SentryExecutionEnvEnum) {
|
|
5
|
+
SentryExecutionEnvEnum["Browser"] = "browser";
|
|
6
|
+
SentryExecutionEnvEnum["Node"] = "node";
|
|
7
|
+
})(SentryExecutionEnvEnum || (SentryExecutionEnvEnum = {}));
|
|
8
|
+
/** The sentry dep import for each execution env. */
|
|
9
|
+
/* c8 ignore next 6 */
|
|
10
|
+
export const sentryDepByEnv = {
|
|
11
|
+
/** Sentry client for the browser. */
|
|
12
|
+
[SentryExecutionEnvEnum.Browser]: () => import('@sentry/browser'),
|
|
13
|
+
/** Sentry client for the Node.js. */
|
|
14
|
+
[SentryExecutionEnvEnum.Node]: () => import('@sentry/node'),
|
|
15
|
+
};
|
|
16
|
+
/* c8 ignore next 6 */
|
|
17
|
+
/** Determine which Sentry client dependency to use and then import it. */
|
|
18
|
+
export async function getSentryByEnv(env) {
|
|
19
|
+
return (await sentryDepByEnv[env]());
|
|
20
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Used to determine logging behavior (dev does not send events to Sentry but still logs them
|
|
3
|
+
* locally).
|
|
4
|
+
*/
|
|
5
|
+
/* c8 ignore next */
|
|
6
|
+
export var SentryReleaseEnvEnum;
|
|
7
|
+
(function (SentryReleaseEnvEnum) {
|
|
8
|
+
SentryReleaseEnvEnum["Prod"] = "prod";
|
|
9
|
+
SentryReleaseEnvEnum["Dev"] = "dev";
|
|
10
|
+
})(SentryReleaseEnvEnum || (SentryReleaseEnvEnum = {}));
|