@bitfab/sdk 0.53.4 → 0.53.5
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-KTBWJLIN.js → chunk-BOXLWX73.js} +2 -2
- package/dist/{chunk-KTBWJLIN.js.map → chunk-BOXLWX73.js.map} +1 -1
- package/dist/{chunk-4GMZN76Y.js → chunk-IDQBDBNS.js} +3 -3
- package/dist/{chunk-BZML7OQD.js → chunk-PAL7VIWM.js} +2 -2
- package/dist/{chunk-WQOA3SFF.js → chunk-Q7IB5VFZ.js} +33 -16
- package/dist/chunk-Q7IB5VFZ.js.map +1 -0
- package/dist/{chunk-OWZF23WR.js → chunk-RMATODGT.js} +2 -2
- package/dist/{chunk-OWZF23WR.js.map → chunk-RMATODGT.js.map} +1 -1
- package/dist/{http-6NM3JD5W.js → http-3WOABXYN.js} +2 -2
- package/dist/{http-HSCOLYYK.js → http-6F3OLGWX.js} +2 -2
- package/dist/index.cjs +28 -11
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.js +3 -3
- package/dist/node.cjs +28 -11
- package/dist/node.cjs.map +1 -1
- package/dist/node.js +3 -3
- package/dist/{replay-V3AN37XH.js → replay-HVLPMPVQ.js} +3 -3
- package/dist/replayCli.js +2 -2
- package/dist/seedCli.js +2 -2
- package/package.json +1 -1
- package/dist/chunk-WQOA3SFF.js.map +0 -1
- /package/dist/{chunk-4GMZN76Y.js.map → chunk-IDQBDBNS.js.map} +0 -0
- /package/dist/{chunk-BZML7OQD.js.map → chunk-PAL7VIWM.js.map} +0 -0
- /package/dist/{http-6NM3JD5W.js.map → http-3WOABXYN.js.map} +0 -0
- /package/dist/{http-HSCOLYYK.js.map → http-6F3OLGWX.js.map} +0 -0
- /package/dist/{replay-V3AN37XH.js.map → replay-HVLPMPVQ.js.map} +0 -0
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
flushTraces,
|
|
7
7
|
parseRetryAfterMs,
|
|
8
8
|
serializePayloadBody
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-BOXLWX73.js";
|
|
10
10
|
import "./chunk-VCRFFCLY.js";
|
|
11
11
|
export {
|
|
12
12
|
BitfabError,
|
|
@@ -17,4 +17,4 @@ export {
|
|
|
17
17
|
parseRetryAfterMs,
|
|
18
18
|
serializePayloadBody
|
|
19
19
|
};
|
|
20
|
-
//# sourceMappingURL=http-
|
|
20
|
+
//# sourceMappingURL=http-3WOABXYN.js.map
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
flushTraces,
|
|
7
7
|
parseRetryAfterMs,
|
|
8
8
|
serializePayloadBody
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-RMATODGT.js";
|
|
10
10
|
export {
|
|
11
11
|
BitfabError,
|
|
12
12
|
HttpClient,
|
|
@@ -16,4 +16,4 @@ export {
|
|
|
16
16
|
parseRetryAfterMs,
|
|
17
17
|
serializePayloadBody
|
|
18
18
|
};
|
|
19
|
-
//# sourceMappingURL=http-
|
|
19
|
+
//# sourceMappingURL=http-6F3OLGWX.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.53.
|
|
45
|
+
__version__ = "0.53.5";
|
|
46
46
|
__packageName__ = "@bitfab/sdk";
|
|
47
47
|
}
|
|
48
48
|
});
|
|
@@ -5525,14 +5525,24 @@ var DatasetsClient = class {
|
|
|
5525
5525
|
}
|
|
5526
5526
|
/**
|
|
5527
5527
|
* List datasets, scoped to one trace function when `traceFunctionKey` is
|
|
5528
|
-
* given and organization-wide otherwise.
|
|
5528
|
+
* given and organization-wide otherwise. Fetches all pages automatically.
|
|
5529
5529
|
*/
|
|
5530
5530
|
async list(params = {}) {
|
|
5531
|
-
const
|
|
5532
|
-
|
|
5533
|
-
|
|
5534
|
-
|
|
5535
|
-
|
|
5531
|
+
const datasets = [];
|
|
5532
|
+
let cursor;
|
|
5533
|
+
do {
|
|
5534
|
+
const query = new URLSearchParams({ limit: "100" });
|
|
5535
|
+
if (params.traceFunctionKey !== void 0) {
|
|
5536
|
+
query.set("traceFunctionKey", params.traceFunctionKey);
|
|
5537
|
+
}
|
|
5538
|
+
if (cursor !== void 0) {
|
|
5539
|
+
query.set("cursor", cursor);
|
|
5540
|
+
}
|
|
5541
|
+
const response = await this.httpClient.get(`/api/sdk/datasets?${query}`);
|
|
5542
|
+
datasets.push(...response.datasets);
|
|
5543
|
+
cursor = response.nextCursor ?? void 0;
|
|
5544
|
+
} while (cursor !== void 0);
|
|
5545
|
+
return datasets;
|
|
5536
5546
|
}
|
|
5537
5547
|
/** Fetch one dataset by id. Rejects with a 404 `BitfabError` when it is not in this organization. */
|
|
5538
5548
|
async get(datasetId) {
|
|
@@ -5541,11 +5551,18 @@ var DatasetsClient = class {
|
|
|
5541
5551
|
);
|
|
5542
5552
|
return response.dataset;
|
|
5543
5553
|
}
|
|
5544
|
-
/**
|
|
5554
|
+
/** Fetches all trace-ID pages, the same membership a replay with `datasetId` selects. */
|
|
5545
5555
|
async listTraces(datasetId) {
|
|
5546
|
-
|
|
5547
|
-
|
|
5548
|
-
)
|
|
5556
|
+
const traceIds = [];
|
|
5557
|
+
const query = new URLSearchParams({ limit: "100" });
|
|
5558
|
+
for (; ; ) {
|
|
5559
|
+
const page = await this.httpClient.get(`${datasetPath(datasetId, "/traces")}?${query}`);
|
|
5560
|
+
traceIds.push(...page.traceIds);
|
|
5561
|
+
if (page.nextCursor === void 0 || page.nextCursor === null) {
|
|
5562
|
+
return { datasetId: page.datasetId, traceIds };
|
|
5563
|
+
}
|
|
5564
|
+
query.set("cursor", page.nextCursor);
|
|
5565
|
+
}
|
|
5549
5566
|
}
|
|
5550
5567
|
/**
|
|
5551
5568
|
* Add traces to the dataset (1 to 100 ids per call). Traces outside the
|