bitfab 0.28.6 → 0.28.7
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/dist/{chunk-P4YXY7J4.js → chunk-TIMBGA3A.js} +12 -2
- package/dist/chunk-TIMBGA3A.js.map +1 -0
- package/dist/index.cjs +11 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +10 -1
- package/dist/index.d.ts +10 -1
- package/dist/index.js +1 -1
- package/dist/node.cjs +11 -1
- package/dist/node.cjs.map +1 -1
- package/dist/node.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-P4YXY7J4.js.map +0 -1
package/dist/index.d.cts
CHANGED
|
@@ -1014,6 +1014,15 @@ interface CurrentTrace {
|
|
|
1014
1014
|
* Context entries are stored in rawData.contexts as [{key, value}, ...].
|
|
1015
1015
|
*/
|
|
1016
1016
|
addContext(context: Record<string, unknown>): void;
|
|
1017
|
+
/**
|
|
1018
|
+
* Flag this trace to be dropped. When the trace completes, the server scrubs
|
|
1019
|
+
* its payloads (trace, external trace, and all spans) and marks it `dropped`
|
|
1020
|
+
* instead of `completed`, retaining only a skeleton audit record. Use this to
|
|
1021
|
+
* discard runs you never want stored (e.g. health checks, or a run you know
|
|
1022
|
+
* contains sensitive data). Takes effect at trace completion; a trace that is
|
|
1023
|
+
* flagged but never completes is not scrubbed.
|
|
1024
|
+
*/
|
|
1025
|
+
drop(): void;
|
|
1017
1026
|
}
|
|
1018
1027
|
/**
|
|
1019
1028
|
* Get a handle to the current active span.
|
|
@@ -1603,7 +1612,7 @@ declare class BitfabFunction {
|
|
|
1603
1612
|
/**
|
|
1604
1613
|
* SDK version from package.json (injected at build time)
|
|
1605
1614
|
*/
|
|
1606
|
-
declare const __version__ = "0.28.
|
|
1615
|
+
declare const __version__ = "0.28.7";
|
|
1607
1616
|
|
|
1608
1617
|
/**
|
|
1609
1618
|
* Constants for the Bitfab SDK.
|
package/dist/index.d.ts
CHANGED
|
@@ -1014,6 +1014,15 @@ interface CurrentTrace {
|
|
|
1014
1014
|
* Context entries are stored in rawData.contexts as [{key, value}, ...].
|
|
1015
1015
|
*/
|
|
1016
1016
|
addContext(context: Record<string, unknown>): void;
|
|
1017
|
+
/**
|
|
1018
|
+
* Flag this trace to be dropped. When the trace completes, the server scrubs
|
|
1019
|
+
* its payloads (trace, external trace, and all spans) and marks it `dropped`
|
|
1020
|
+
* instead of `completed`, retaining only a skeleton audit record. Use this to
|
|
1021
|
+
* discard runs you never want stored (e.g. health checks, or a run you know
|
|
1022
|
+
* contains sensitive data). Takes effect at trace completion; a trace that is
|
|
1023
|
+
* flagged but never completes is not scrubbed.
|
|
1024
|
+
*/
|
|
1025
|
+
drop(): void;
|
|
1017
1026
|
}
|
|
1018
1027
|
/**
|
|
1019
1028
|
* Get a handle to the current active span.
|
|
@@ -1603,7 +1612,7 @@ declare class BitfabFunction {
|
|
|
1603
1612
|
/**
|
|
1604
1613
|
* SDK version from package.json (injected at build time)
|
|
1605
1614
|
*/
|
|
1606
|
-
declare const __version__ = "0.28.
|
|
1615
|
+
declare const __version__ = "0.28.7";
|
|
1607
1616
|
|
|
1608
1617
|
/**
|
|
1609
1618
|
* Constants for the Bitfab SDK.
|
package/dist/index.js
CHANGED
package/dist/node.cjs
CHANGED
|
@@ -706,7 +706,7 @@ registerAsyncLocalStorageClass(
|
|
|
706
706
|
);
|
|
707
707
|
|
|
708
708
|
// src/version.generated.ts
|
|
709
|
-
var __version__ = "0.28.
|
|
709
|
+
var __version__ = "0.28.7";
|
|
710
710
|
|
|
711
711
|
// src/constants.ts
|
|
712
712
|
var DEFAULT_SERVICE_URL = "https://bitfab.ai";
|
|
@@ -3357,6 +3357,8 @@ var noOpTrace = {
|
|
|
3357
3357
|
setMetadata() {
|
|
3358
3358
|
},
|
|
3359
3359
|
addContext() {
|
|
3360
|
+
},
|
|
3361
|
+
drop() {
|
|
3360
3362
|
}
|
|
3361
3363
|
};
|
|
3362
3364
|
function getCurrentSpan() {
|
|
@@ -3433,6 +3435,12 @@ function getCurrentTrace() {
|
|
|
3433
3435
|
traceState.contexts.push(context);
|
|
3434
3436
|
} catch {
|
|
3435
3437
|
}
|
|
3438
|
+
},
|
|
3439
|
+
drop() {
|
|
3440
|
+
try {
|
|
3441
|
+
getOrCreateTraceState().dropped = true;
|
|
3442
|
+
} catch {
|
|
3443
|
+
}
|
|
3436
3444
|
}
|
|
3437
3445
|
};
|
|
3438
3446
|
}
|
|
@@ -4022,6 +4030,7 @@ var Bitfab = class {
|
|
|
4022
4030
|
testRunId: traceState?.testRunId,
|
|
4023
4031
|
inputSourceTraceId: traceState?.inputSourceTraceId,
|
|
4024
4032
|
dbSnapshotRef: traceState?.dbSnapshotRef,
|
|
4033
|
+
dropped: traceState?.dropped,
|
|
4025
4034
|
// Built AFTER the wrapped fn finished, so `accessed` reflects
|
|
4026
4035
|
// whether customer code obtained the branch URL during this
|
|
4027
4036
|
// item. Omitted entirely when no lease was attached, so the
|
|
@@ -4267,6 +4276,7 @@ var Bitfab = class {
|
|
|
4267
4276
|
traceFunctionKey: params.traceFunctionKey,
|
|
4268
4277
|
externalTrace: rawTrace,
|
|
4269
4278
|
completed: true,
|
|
4279
|
+
...params.dropped && { dropped: true },
|
|
4270
4280
|
...params.sessionId && { sessionId: params.sessionId },
|
|
4271
4281
|
...params.testRunId && { testRunId: params.testRunId }
|
|
4272
4282
|
});
|