@bitfab/sdk 0.64.15 → 0.64.17
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/cloudReplay.py +282 -24
- package/dist/{chunk-NYLVYTBO.js → chunk-G5BYSZLD.js} +30 -6
- package/dist/chunk-G5BYSZLD.js.map +1 -0
- package/dist/{chunk-Z4DIFZTO.js → chunk-I3LSDFMN.js} +2 -2
- package/dist/{chunk-Z4DIFZTO.js.map → chunk-I3LSDFMN.js.map} +1 -1
- package/dist/chunk-PQ6ABBRQ.js +1905 -0
- package/dist/chunk-PQ6ABBRQ.js.map +1 -0
- package/dist/{chunk-7ZJ7KXEV.js → chunk-QZFVHNQE.js} +2 -2
- package/dist/{chunk-2MHRNZH5.js → chunk-WLGH45CM.js} +204 -89
- package/dist/chunk-WLGH45CM.js.map +1 -0
- package/dist/{chunk-KVGRTCIE.js → chunk-YHKFC7XZ.js} +16 -2
- package/dist/{chunk-KVGRTCIE.js.map → chunk-YHKFC7XZ.js.map} +1 -1
- package/dist/{http-36VJ3FFM.js → http-AYZZNM2L.js} +2 -2
- package/dist/{http-IQ2AC36B.js → http-DAQLSTUN.js} +2 -2
- package/dist/index.cjs +25 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +99 -2
- package/dist/index.d.ts +99 -2
- package/dist/index.js +3 -3
- package/dist/node.cjs +25 -1
- package/dist/node.cjs.map +1 -1
- package/dist/node.d.cts +1 -1
- package/dist/node.d.ts +1 -1
- package/dist/node.js +3 -3
- package/dist/replay-ARKSPOVK.js +28 -0
- package/dist/{replay-2QFPGFS7.js → replay-FFNEMPGO.js} +3 -3
- package/dist/replay-FFNEMPGO.js.map +1 -0
- package/dist/replayCli.js +3 -2
- package/dist/replayCli.js.map +1 -1
- package/dist/seedCli.js +3 -2
- package/dist/seedCli.js.map +1 -1
- package/package.json +1 -1
- package/dist/chunk-2MHRNZH5.js.map +0 -1
- package/dist/chunk-NYLVYTBO.js.map +0 -1
- /package/dist/{chunk-7ZJ7KXEV.js.map → chunk-QZFVHNQE.js.map} +0 -0
- /package/dist/{http-36VJ3FFM.js.map → http-AYZZNM2L.js.map} +0 -0
- /package/dist/{http-IQ2AC36B.js.map → http-DAQLSTUN.js.map} +0 -0
- /package/dist/{replay-2QFPGFS7.js.map → replay-ARKSPOVK.js.map} +0 -0
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
flushTraces,
|
|
8
8
|
parseRetryAfterMs,
|
|
9
9
|
serializePayloadBody
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-YHKFC7XZ.js";
|
|
11
11
|
export {
|
|
12
12
|
BitfabError,
|
|
13
13
|
HttpClient,
|
|
@@ -18,4 +18,4 @@ export {
|
|
|
18
18
|
parseRetryAfterMs,
|
|
19
19
|
serializePayloadBody
|
|
20
20
|
};
|
|
21
|
-
//# sourceMappingURL=http-
|
|
21
|
+
//# sourceMappingURL=http-AYZZNM2L.js.map
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
flushTraces,
|
|
8
8
|
parseRetryAfterMs,
|
|
9
9
|
serializePayloadBody
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-I3LSDFMN.js";
|
|
11
11
|
import "./chunk-MT36GJMW.js";
|
|
12
12
|
export {
|
|
13
13
|
BitfabError,
|
|
@@ -19,4 +19,4 @@ export {
|
|
|
19
19
|
parseRetryAfterMs,
|
|
20
20
|
serializePayloadBody
|
|
21
21
|
};
|
|
22
|
-
//# sourceMappingURL=http-
|
|
22
|
+
//# sourceMappingURL=http-DAQLSTUN.js.map
|
package/dist/index.cjs
CHANGED
|
@@ -42,7 +42,7 @@ var __version__, __packageName__;
|
|
|
42
42
|
var init_version_generated = __esm({
|
|
43
43
|
"src/version.generated.ts"() {
|
|
44
44
|
"use strict";
|
|
45
|
-
__version__ = "0.64.
|
|
45
|
+
__version__ = "0.64.17";
|
|
46
46
|
__packageName__ = "@bitfab/sdk";
|
|
47
47
|
}
|
|
48
48
|
});
|
|
@@ -8929,6 +8929,9 @@ function draftsInGenerationOrder(assertions, assertionIds) {
|
|
|
8929
8929
|
function traceAssertionsPath(traceId, suffix = "") {
|
|
8930
8930
|
return `/api/sdk/traces/${encodeURIComponent(traceId)}/assertions${suffix}`;
|
|
8931
8931
|
}
|
|
8932
|
+
function traceScenarioPath(traceId) {
|
|
8933
|
+
return `/api/sdk/traces/${encodeURIComponent(traceId)}/scenario`;
|
|
8934
|
+
}
|
|
8932
8935
|
var TracesClient = class {
|
|
8933
8936
|
constructor(httpClient) {
|
|
8934
8937
|
this.httpClient = httpClient;
|
|
@@ -8992,6 +8995,22 @@ var TracesClient = class {
|
|
|
8992
8995
|
);
|
|
8993
8996
|
return response.archived;
|
|
8994
8997
|
}
|
|
8998
|
+
async getScenario(traceId) {
|
|
8999
|
+
const response = await this.httpClient.get(
|
|
9000
|
+
traceScenarioPath(traceId)
|
|
9001
|
+
);
|
|
9002
|
+
return response.scenario;
|
|
9003
|
+
}
|
|
9004
|
+
async saveScenario({
|
|
9005
|
+
traceId,
|
|
9006
|
+
...edit
|
|
9007
|
+
}) {
|
|
9008
|
+
const response = await this.httpClient.request(
|
|
9009
|
+
traceScenarioPath(traceId),
|
|
9010
|
+
edit
|
|
9011
|
+
);
|
|
9012
|
+
return response.scenario;
|
|
9013
|
+
}
|
|
8995
9014
|
};
|
|
8996
9015
|
|
|
8997
9016
|
// src/tracing.ts
|
|
@@ -9883,6 +9902,7 @@ function readEnv2(name) {
|
|
|
9883
9902
|
return void 0;
|
|
9884
9903
|
}
|
|
9885
9904
|
var CAPTURE_ENABLED_ENV = "BITFAB_CAPTURE_ENABLED";
|
|
9905
|
+
var REPLAY_API_KEY_ENV = "BITFAB_REPLAY_BITFAB_API_KEY";
|
|
9886
9906
|
var TRUE_ENV_VALUES = /* @__PURE__ */ new Set(["1", "true", "yes"]);
|
|
9887
9907
|
var FALSE_ENV_VALUES = /* @__PURE__ */ new Set(["0", "false", "no"]);
|
|
9888
9908
|
function readBooleanEnv(name) {
|
|
@@ -10397,6 +10417,10 @@ var Bitfab = class {
|
|
|
10397
10417
|
* early resolve that found nothing never poisons a later one.
|
|
10398
10418
|
*/
|
|
10399
10419
|
findApiKey(callsKeyFunction) {
|
|
10420
|
+
const replayKey = readEnv2(REPLAY_API_KEY_ENV);
|
|
10421
|
+
if (replayKey && replayKey.trim() !== "") {
|
|
10422
|
+
return replayKey;
|
|
10423
|
+
}
|
|
10400
10424
|
if (this.resolvedApiKey !== void 0) {
|
|
10401
10425
|
return this.resolvedApiKey;
|
|
10402
10426
|
}
|