@milaboratories/pframes-rs-node 1.1.18 → 1.1.24

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.
@@ -1,549 +1,492 @@
1
- 'use strict';
2
-
3
- var ulid = require('ulid');
4
- var plModelCommon = require('@milaboratories/pl-model-common');
5
- var helpers = require('@milaboratories/helpers');
6
- var addon = require('./addon.cjs');
7
- var dump = require('./dump.cjs');
8
-
1
+ require("./_virtual/_rolldown/runtime.cjs");
2
+ const require_addon = require("./addon.cjs");
3
+ const require_dump = require("./dump.cjs");
4
+ let ulid = require("ulid");
5
+ let _milaboratories_pl_model_common = require("@milaboratories/pl-model-common");
6
+ let _milaboratories_helpers = require("@milaboratories/helpers");
7
+ //#region export/wrapper.ts
9
8
  async function pprofDump() {
10
- try {
11
- return await addon.AddonSymbol.pprofDump();
12
- }
13
- catch (err) {
14
- const error = new plModelCommon.PFrameError(`PFrame pprofDump failed`);
15
- error.cause = plModelCommon.ensureError(err);
16
- throw error;
17
- }
18
- }
19
- class PFrame {
20
- #frame;
21
- #id;
22
- get id() {
23
- return this.#id;
24
- }
25
- #logger;
26
- constructor(options) {
27
- this.#id = options.frameId;
28
- this.#logger = options.logger ?? (() => { });
29
- dump.dump([`${this.id}`, `${this.id}.json`], {
30
- timeStamp: Date.now(),
31
- requestType: "create",
32
- }, this.#logger);
33
- try {
34
- this.#frame = addon.AddonSymbol.pFrameCreate(options.spillPath, options.logger);
35
- this.#logger("info", `PFrame ${this.id} created`);
36
- }
37
- catch (err) {
38
- const error = new plModelCommon.PFrameError(`PFrame creation failed`);
39
- error.cause = new Error(`PFrame ${this.id} creation failed, ` +
40
- `logger: ${this.#logger?.toString()}, ` +
41
- `error:\n` +
42
- `${plModelCommon.ensureError(err)}`);
43
- throw error;
44
- }
45
- }
46
- addColumnSpec(columnId, columnSpec) {
47
- const requestId = ulid.ulid();
48
- dump.dump([`${this.id}`, `${requestId}.json`], {
49
- timeStamp: Date.now(),
50
- requestType: "addColumnSpec",
51
- requestData: {
52
- columnId: dump.hashColumnId(columnId),
53
- columnSpec,
54
- },
55
- }, this.#logger);
56
- dump.dump([`${this.id}`, `data`, `${dump.hashColumnId(columnId)}.spec`], {
57
- ...columnSpec,
58
- }, this.#logger);
59
- try {
60
- return addon.AddonSymbol.pFrameAddColumnSpec(this.#frame, columnId, columnSpec);
61
- }
62
- catch (err) {
63
- const error = new plModelCommon.PFrameError(`PFrame addColumnSpec request failed`);
64
- error.cause = new Error(`PFrame ${this.id} addColumnSpec request ${requestId} failed, ` +
65
- `columnId: ${JSON.stringify(columnId)}, ` +
66
- `columnSpec: ${JSON.stringify(columnSpec)}, ` +
67
- `error:\n` +
68
- `${plModelCommon.ensureError(err)}`);
69
- throw error;
70
- }
71
- }
72
- setDataSource(dataSource) {
73
- const requestId = ulid.ulid();
74
- dump.dump([`${this.id}`, `${requestId}.json`], {
75
- timeStamp: Date.now(),
76
- requestType: "setDataSource",
77
- }, this.#logger);
78
- const wrappedDataSource = {
79
- preloadBlob: async (blobIds) => {
80
- const requestId = ulid.ulid();
81
- dump.dump([`${this.id}`, `${requestId}.json`], {
82
- timeStamp: Date.now(),
83
- requestType: "preloadBlob",
84
- requestData: {
85
- blobIds,
86
- },
87
- }, this.#logger);
88
- this.#logger("info", `PFrame ${this.id} preloadBlob started, blobIds: ${JSON.stringify(blobIds)}`);
89
- const timer = helpers.PerfTimer.start();
90
- try {
91
- return await dataSource.preloadBlob(blobIds);
92
- }
93
- finally {
94
- this.#logger("info", `PFrame ${this.id} preloadBlob finished, took ${timer.elapsed()} (${blobIds.length} blobs)`);
95
- }
96
- },
97
- resolveBlobContent: async (blobId) => {
98
- const requestId = ulid.ulid();
99
- dump.dump([`${this.id}`, `${requestId}.json`], {
100
- timeStamp: Date.now(),
101
- requestType: "resolveBlobContent",
102
- requestData: {
103
- blobId,
104
- },
105
- }, this.#logger);
106
- const blob = await dataSource.resolveBlobContent(blobId);
107
- this.#logger("info", `PFrame ${this.id} resolved blob ${blobId}`);
108
- dump.dump([`${this.id}`, `data`, `${blobId}`], blob, this.#logger);
109
- return blob;
110
- },
111
- parquetServer: dataSource.parquetServer,
112
- };
113
- try {
114
- return addon.AddonSymbol.pFrameSetDataSource(this.#frame, wrappedDataSource);
115
- }
116
- catch (err) {
117
- const error = new plModelCommon.PFrameError(`PFrame setDataSource request failed`);
118
- error.cause = new Error(`PFrame ${this.id} setDataSource request ${requestId} failed, ` +
119
- `dataSource: ${dataSource.toString()}, ` +
120
- `error:\n` +
121
- `${plModelCommon.ensureError(err)}`);
122
- throw error;
123
- }
124
- }
125
- setColumnData(columnId, dataInfo, ops) {
126
- const requestId = ulid.ulid();
127
- dump.dump([`${this.id}`, `${requestId}.json`], {
128
- timeStamp: Date.now(),
129
- requestType: "setColumnData",
130
- requestData: {
131
- columnId: dump.hashColumnId(columnId),
132
- dataInfo,
133
- },
134
- }, this.#logger);
135
- dump.dump([`${this.id}`, `data`, `${dump.hashColumnId(columnId)}.datainfo`], {
136
- ...dataInfo,
137
- }, this.#logger);
138
- try {
139
- ops?.signal?.throwIfAborted();
140
- return addon.AddonSymbol.pFrameSetColumnData(this.#frame, columnId, dataInfo, ops?.signal);
141
- }
142
- catch (err) {
143
- const error = new plModelCommon.PFrameError(`PFrame setColumnData request failed`);
144
- error.cause = new Error(`PFrame ${this.id} setColumnData request ${requestId} failed, ` +
145
- `columnId: ${JSON.stringify(columnId)}, ` +
146
- `dataInfo: ${JSON.stringify(dataInfo)}, ` +
147
- `error:\n` +
148
- `${plModelCommon.ensureError(err)}`);
149
- throw error;
150
- }
151
- }
152
- dispose() {
153
- const requestId = ulid.ulid();
154
- dump.dump([`${this.id}`, `${requestId}.json`], {
155
- timeStamp: Date.now(),
156
- requestType: "dispose",
157
- }, this.#logger);
158
- try {
159
- addon.AddonSymbol.pFrameDispose(this.#frame);
160
- this.#logger("info", `PFrame ${this.id} disposed`);
161
- }
162
- catch (err) {
163
- const error = new plModelCommon.PFrameError(`PFrame dispose request failed`);
164
- error.cause = new Error(`PFrame ${this.id} dispose request ${requestId} failed, ` +
165
- `error:\n` +
166
- `${plModelCommon.ensureError(err)}`);
167
- throw error;
168
- }
169
- }
170
- [Symbol.dispose]() {
171
- this.dispose();
172
- }
173
- async findColumns(request) {
174
- const requestId = ulid.ulid();
175
- dump.dump([`${this.id}`, `${requestId}.json`], {
176
- timeStamp: Date.now(),
177
- requestType: "findColumns",
178
- requestData: request,
179
- }, this.#logger);
180
- const timer = helpers.PerfTimer.start();
181
- try {
182
- return await addon.AddonSymbol.pFrameFindColumns(this.#frame, request);
183
- }
184
- catch (err) {
185
- const error = new plModelCommon.PFrameError(`PFrame findColumns request failed`);
186
- error.cause = new Error(`PFrame ${this.id} findColumns request ${requestId} failed, ` +
187
- `request: ${JSON.stringify(request)}, ` +
188
- `error:\n` +
189
- `${plModelCommon.ensureError(err)}`);
190
- throw error;
191
- }
192
- finally {
193
- this.#logger("info", `PFrame ${this.id} findColumns request ${requestId} took ${timer.elapsed()}`);
194
- }
195
- }
196
- async deleteColumn(request) {
197
- const requestId = ulid.ulid();
198
- dump.dump([`${this.id}`, `${requestId}.json`], {
199
- timeStamp: Date.now(),
200
- requestType: "deleteColumn",
201
- requestData: request,
202
- }, this.#logger);
203
- const timer = helpers.PerfTimer.start();
204
- try {
205
- return await addon.AddonSymbol.pFrameDeleteColumn(this.#frame, request);
206
- }
207
- catch (err) {
208
- const error = new plModelCommon.PFrameError(`PFrame deleteColumn request failed`);
209
- error.cause = new Error(`PFrame ${this.id} deleteColumn request ${requestId} failed, ` +
210
- `request: ${JSON.stringify(request)}, ` +
211
- `error:\n` +
212
- `${plModelCommon.ensureError(err)}`);
213
- throw error;
214
- }
215
- finally {
216
- this.#logger("info", `PFrame ${this.id} deleteColumn request ${requestId} took ${timer.elapsed()}`);
217
- }
218
- }
219
- async getColumnSpec(columnId) {
220
- const requestId = ulid.ulid();
221
- dump.dump([`${this.id}`, `${requestId}.json`], {
222
- timeStamp: Date.now(),
223
- requestType: "getColumnSpec",
224
- requestData: {
225
- columnId: dump.hashColumnId(columnId),
226
- },
227
- }, this.#logger);
228
- try {
229
- return await addon.AddonSymbol.pFrameGetColumnSpec(this.#frame, columnId);
230
- }
231
- catch (err) {
232
- const error = new plModelCommon.PFrameError(`PFrame getColumnSpec request failed`);
233
- error.cause = new Error(`PFrame ${this.id} getColumnSpec request ${requestId} failed, ` +
234
- `columnId: ${JSON.stringify(columnId)}, ` +
235
- `error:\n` +
236
- `${plModelCommon.ensureError(err)}`);
237
- throw error;
238
- }
239
- }
240
- async listColumns() {
241
- const requestId = ulid.ulid();
242
- dump.dump([`${this.id}`, `${requestId}.json`], {
243
- timeStamp: Date.now(),
244
- requestType: "listColumns",
245
- }, this.#logger);
246
- try {
247
- return await addon.AddonSymbol.pFrameListColumns(this.#frame);
248
- }
249
- catch (err) {
250
- const error = new plModelCommon.PFrameError(`PFrame listColumns request failed`);
251
- error.cause = new Error(`PFrame ${this.id} listColumns request ${requestId} failed, ` +
252
- `error:\n` +
253
- `${plModelCommon.ensureError(err)}`);
254
- throw error;
255
- }
256
- }
257
- createTable(requestId, request) {
258
- const dumpData = {
259
- timeStamp: Date.now(),
260
- requestType: "createTable",
261
- requestData: dump.hashCreateTableRequestColumnId(request),
262
- };
263
- dump.dump([`${this.id}`, `${requestId}.json`], dumpData, this.#logger);
264
- dump.dump([`${this.id}`, `${requestId}`, `${requestId}.json`], dumpData, this.#logger);
265
- const timer = helpers.PerfTimer.start();
266
- try {
267
- const boxed = addon.AddonSymbol.pFrameCreateTable(this.#frame, requestId, request);
268
- return new PTable(this, requestId, boxed, this.#logger);
269
- }
270
- catch (err) {
271
- const error = new plModelCommon.PFrameError(`PFrame createTable request failed`);
272
- error.cause = new Error(`PFrame ${this.id} createTable request ${requestId} failed, ` +
273
- `request: ${JSON.stringify(request)}, ` +
274
- `error:\n` +
275
- `${plModelCommon.ensureError(err)}`);
276
- throw error;
277
- }
278
- finally {
279
- this.#logger("info", `PFrame ${this.id} createTable request ${requestId} took ${timer.elapsed()}`);
280
- }
281
- }
282
- createTableV2(requestId, request) {
283
- const timer = helpers.PerfTimer.start();
284
- const dumpData = {
285
- timeStamp: Date.now(),
286
- requestType: "createTableV2",
287
- requestData: dump.hashCreateTableV2RequestColumnId(request),
288
- };
289
- dump.dump([`${this.id}`, `${requestId}.json`], dumpData, this.#logger);
290
- dump.dump([`${this.id}`, `${requestId}`, `${requestId}.json`], dumpData, this.#logger);
291
- try {
292
- const boxed = addon.AddonSymbol.pFrameCreateTableV2(this.#frame, requestId, request);
293
- return new PTable(this, requestId, boxed, this.#logger);
294
- }
295
- catch (err) {
296
- const error = new plModelCommon.PFrameError(`PFrame createTableV2 request failed`);
297
- error.cause = new Error(`PFrame ${this.id} createTableV2 request ${requestId} failed, ` +
298
- `error:\n` +
299
- `${plModelCommon.ensureError(err)}`);
300
- throw error;
301
- }
302
- finally {
303
- this.#logger("info", `PFrame ${this.id} createTableV2 request ${requestId} took ${timer.elapsed()}`);
304
- }
305
- }
306
- async getUniqueValues(request, ops) {
307
- const requestId = ulid.ulid();
308
- dump.dump([`${this.id}`, `${requestId}.json`], {
309
- timeStamp: Date.now(),
310
- requestType: "getUniqueValues",
311
- requestData: dump.hashUniqueValuesRequestColumnId(request),
312
- }, this.#logger);
313
- this.#logger("info", `PFrame ${this.id} getUniqueValues request ${requestId} started`);
314
- const timer = helpers.PerfTimer.start();
315
- try {
316
- ops?.signal?.throwIfAborted();
317
- return await addon.AddonSymbol.pFrameGetUniqueValues(this.#frame, requestId, request, ops?.signal);
318
- }
319
- catch (err) {
320
- if (plModelCommon.isAbortError(err)) {
321
- throw new plModelCommon.AbortError(`PFrame ${this.id} getUniqueValues request ${requestId} cancelled`);
322
- }
323
- const error = new plModelCommon.PFrameError(`PFrame getUniqueValues request failed`);
324
- error.cause = new Error(`PFrame ${this.id} getUniqueValues request ${requestId} failed, ` +
325
- `request: ${JSON.stringify(request)}, ` +
326
- `error:\n` +
327
- `${plModelCommon.ensureError(err)}`);
328
- throw error;
329
- }
330
- finally {
331
- this.#logger("info", `PFrame ${this.id} getUniqueValues request ${requestId} finished, took ${timer.elapsed()}`);
332
- }
333
- }
9
+ try {
10
+ return await require_addon.AddonSymbol.pprofDump();
11
+ } catch (err) {
12
+ const error = new _milaboratories_pl_model_common.PFrameError(`PFrame pprofDump failed`);
13
+ error.cause = (0, _milaboratories_pl_model_common.ensureError)(err);
14
+ throw error;
15
+ }
334
16
  }
335
- class PTable {
336
- #frame;
337
- #table;
338
- #id;
339
- get id() {
340
- return this.#id;
341
- }
342
- #logger;
343
- constructor(frame, id, table, logger) {
344
- this.#frame = frame;
345
- this.#table = table;
346
- this.#id = id;
347
- this.#logger = logger;
348
- this.#logger("info", `PTable ${this.id} created`);
349
- }
350
- getSpec() {
351
- const requestId = ulid.ulid();
352
- dump.dump([`${this.#frame.id}`, `${this.id}`, `${requestId}.json`], {
353
- timeStamp: Date.now(),
354
- requestType: "getSpec",
355
- }, this.#logger);
356
- try {
357
- return addon.AddonSymbol.pTableGetSpec(this.#table);
358
- }
359
- catch (err) {
360
- const error = new plModelCommon.PFrameError(`PTable getSpec request failed`);
361
- error.cause = new Error(`PTable ${this.id} getSpec request ${requestId} failed, ` +
362
- `error:\n` +
363
- `${plModelCommon.ensureError(err)}`);
364
- throw error;
365
- }
366
- }
367
- getColumnIndices(columnIds) {
368
- const requestId = ulid.ulid();
369
- dump.dump([`${this.#frame.id}`, `${this.id}`, `${requestId}.json`], {
370
- timeStamp: Date.now(),
371
- requestType: "getColumnIndices",
372
- requestData: {
373
- columnIds: columnIds.map(dump.hashTableColumnId),
374
- },
375
- }, this.#logger);
376
- try {
377
- return addon.AddonSymbol.pTableGetColumnIndices(this.#table, columnIds);
378
- }
379
- catch (err) {
380
- const error = new plModelCommon.PFrameError(`PTable getColumnIndices request failed`);
381
- error.cause = new Error(`PTable ${this.id} getColumnIndices request ${requestId} failed, ` +
382
- `columnIds: ${JSON.stringify(columnIds)}, ` +
383
- `error:\n` +
384
- `${plModelCommon.ensureError(err)}`);
385
- throw error;
386
- }
387
- }
388
- async getFootprint(ops) {
389
- const requestId = ulid.ulid();
390
- dump.dump([`${this.#frame.id}`, `${this.id}`, `${requestId}.json`], {
391
- timeStamp: Date.now(),
392
- requestType: "getFootprint",
393
- }, this.#logger);
394
- try {
395
- ops?.signal?.throwIfAborted();
396
- return await addon.AddonSymbol.pTableGetFootprint(this.#table, ops?.signal);
397
- }
398
- catch (err) {
399
- if (plModelCommon.isAbortError(err)) {
400
- throw new plModelCommon.AbortError(`PTable ${this.id} getFootprint request ${requestId} cancelled`);
401
- }
402
- const error = new plModelCommon.PFrameError(`PTable getFootprint request failed`);
403
- error.cause = new Error(`PTable ${this.id} getFootprint request ${requestId} failed, ` +
404
- `error:\n` +
405
- `${plModelCommon.ensureError(err)}`);
406
- throw error;
407
- }
408
- }
409
- async getShape(ops) {
410
- const requestId = ulid.ulid();
411
- dump.dump([`${this.#frame.id}`, `${this.id}`, `${requestId}.json`], {
412
- timeStamp: Date.now(),
413
- requestType: "getShape",
414
- }, this.#logger);
415
- this.#logger("info", `PTable ${this.id} getShape request ${requestId} started`);
416
- const timer = helpers.PerfTimer.start();
417
- try {
418
- ops?.signal?.throwIfAborted();
419
- return await addon.AddonSymbol.pTableGetShape(this.#table, ops?.signal);
420
- }
421
- catch (err) {
422
- if (plModelCommon.isAbortError(err)) {
423
- throw new plModelCommon.AbortError(`PTable ${this.id} getShape request ${requestId} cancelled`);
424
- }
425
- const error = new plModelCommon.PFrameError(`PTable getShape request failed`);
426
- error.cause = new Error(`PTable ${this.id} getShape request ${requestId} failed, ` +
427
- `error:\n` +
428
- `${plModelCommon.ensureError(err)}`);
429
- throw error;
430
- }
431
- finally {
432
- this.#logger("info", `PTable ${this.id} getShape request ${requestId} finished, took ${timer.elapsed()}`);
433
- }
434
- }
435
- async getData(columnIndices, ops) {
436
- const requestId = ulid.ulid();
437
- dump.dump([`${this.#frame.id}`, `${this.id}`, `${requestId}.json`], {
438
- timeStamp: Date.now(),
439
- requestType: "getData",
440
- requestData: {
441
- columnIndices,
442
- range: ops?.range ?? null,
443
- },
444
- }, this.#logger);
445
- this.#logger("info", `PTable ${this.id} getData request ${requestId} started`);
446
- let rowCount = 0;
447
- const timer = helpers.PerfTimer.start();
448
- try {
449
- ops?.signal?.throwIfAborted();
450
- const result = await addon.AddonSymbol.pTableGetData(this.#table, requestId, columnIndices, ops?.range, ops?.signal);
451
- rowCount = result[0].data.length;
452
- return result;
453
- }
454
- catch (err) {
455
- if (plModelCommon.isAbortError(err)) {
456
- throw new plModelCommon.AbortError(`PTable ${this.id} getData request ${requestId} cancelled`);
457
- }
458
- const error = new plModelCommon.PFrameError(`PTable getData request failed`);
459
- error.cause = new Error(`PTable ${this.id} getData request ${requestId} failed, ` +
460
- `columnIndices: ${JSON.stringify(columnIndices)}, ` +
461
- `range: ${ops?.range ? JSON.stringify(ops.range) : undefined}, ` +
462
- `error:\n` +
463
- `${plModelCommon.ensureError(err)}`);
464
- throw error;
465
- }
466
- finally {
467
- this.#logger("info", `PTable ${this.id} getData request ${requestId} finished, took ${timer.elapsed()} (${rowCount} rows)`);
468
- }
469
- }
470
- filter(requestId, request) {
471
- const dumpData = {
472
- timeStamp: Date.now(),
473
- table: this.id,
474
- requestType: "filter",
475
- requestData: {
476
- filters: request.map(dump.hashFilterColumnId),
477
- },
478
- };
479
- dump.dump([`${this.#frame.id}`, `${requestId}.json`], dumpData, this.#logger);
480
- dump.dump([`${this.#frame.id}`, `${requestId}`, `${requestId}.json`], dumpData, this.#logger);
481
- const timer = helpers.PerfTimer.start();
482
- try {
483
- const boxed = addon.AddonSymbol.pTableFilter(this.#table, requestId, request);
484
- return new PTable(this.#frame, requestId, boxed, this.#logger);
485
- }
486
- catch (err) {
487
- const error = new plModelCommon.PFrameError(`PTable filter request failed`);
488
- error.cause = new Error(`PTable ${this.id} filter request ${requestId} failed, ` +
489
- `request: ${JSON.stringify(request)}, ` +
490
- `error:\n` +
491
- `${plModelCommon.ensureError(err)}`);
492
- throw error;
493
- }
494
- finally {
495
- this.#logger("info", `PTable ${this.id} filter request ${requestId} took ${timer.elapsed()}`);
496
- }
497
- }
498
- sort(requestId, request) {
499
- const dumpData = {
500
- timeStamp: Date.now(),
501
- table: this.id,
502
- requestType: "sort",
503
- requestData: request.map(dump.hashSortingColumnId),
504
- };
505
- dump.dump([`${this.#frame.id}`, `${requestId}.json`], dumpData, this.#logger);
506
- dump.dump([`${this.#frame.id}`, `${requestId}`, `${requestId}.json`], dumpData, this.#logger);
507
- const timer = helpers.PerfTimer.start();
508
- try {
509
- const boxed = addon.AddonSymbol.pTableSort(this.#table, requestId, request);
510
- return new PTable(this.#frame, requestId, boxed, this.#logger);
511
- }
512
- catch (err) {
513
- const error = new plModelCommon.PFrameError(`PTable sort request failed`);
514
- error.cause = new Error(`PTable ${this.id} sort request ${requestId} failed, ` +
515
- `request: ${JSON.stringify(request)}, ` +
516
- `error:\n` +
517
- `${plModelCommon.ensureError(err)}`);
518
- throw error;
519
- }
520
- finally {
521
- this.#logger("info", `PTable ${this.id} sort request ${requestId} took ${timer.elapsed()}`);
522
- }
523
- }
524
- dispose() {
525
- const requestId = ulid.ulid();
526
- dump.dump([`${this.#frame.id}`, `${this.id}`, `${requestId}.json`], {
527
- timeStamp: Date.now(),
528
- requestType: "dispose",
529
- }, this.#logger);
530
- try {
531
- addon.AddonSymbol.pTableDispose(this.#table);
532
- this.#logger("info", `PTable ${this.id} disposed`);
533
- }
534
- catch (err) {
535
- const error = new plModelCommon.PFrameError(`PTable dispose request failed`);
536
- error.cause = new Error(`PTable ${this.id} dispose request ${requestId} failed, ` +
537
- `error:\n` +
538
- `${plModelCommon.ensureError(err)}`);
539
- throw error;
540
- }
541
- }
542
- [Symbol.dispose]() {
543
- this.dispose();
544
- }
545
- }
546
-
17
+ var PFrame = class {
18
+ #frame;
19
+ #id;
20
+ get id() {
21
+ return this.#id;
22
+ }
23
+ #logger;
24
+ constructor(options) {
25
+ this.#id = options.frameId;
26
+ this.#logger = options.logger ?? (() => {});
27
+ require_dump.dump([`${this.id}`, `${this.id}.json`], {
28
+ timeStamp: Date.now(),
29
+ requestType: "create"
30
+ }, this.#logger);
31
+ try {
32
+ this.#frame = require_addon.AddonSymbol.pFrameCreate(options.spillPath, options.logger);
33
+ this.#logger("info", `PFrame ${this.id} created`);
34
+ } catch (err) {
35
+ const error = new _milaboratories_pl_model_common.PFrameError(`PFrame creation failed`);
36
+ error.cause = /* @__PURE__ */ new Error(`PFrame ${this.id} creation failed, logger: ${this.#logger?.toString()}, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
37
+ throw error;
38
+ }
39
+ }
40
+ addColumnSpec(columnId, columnSpec) {
41
+ const requestId = (0, ulid.ulid)();
42
+ require_dump.dump([`${this.id}`, `${requestId}.json`], {
43
+ timeStamp: Date.now(),
44
+ requestType: "addColumnSpec",
45
+ requestData: {
46
+ columnId: require_dump.hashColumnId(columnId),
47
+ columnSpec
48
+ }
49
+ }, this.#logger);
50
+ require_dump.dump([
51
+ `${this.id}`,
52
+ `data`,
53
+ `${require_dump.hashColumnId(columnId)}.spec`
54
+ ], { ...columnSpec }, this.#logger);
55
+ try {
56
+ return require_addon.AddonSymbol.pFrameAddColumnSpec(this.#frame, columnId, columnSpec);
57
+ } catch (err) {
58
+ const error = new _milaboratories_pl_model_common.PFrameError(`PFrame addColumnSpec request failed`);
59
+ error.cause = /* @__PURE__ */ new Error(`PFrame ${this.id} addColumnSpec request ${requestId} failed, columnId: ${JSON.stringify(columnId)}, columnSpec: ${JSON.stringify(columnSpec)}, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
60
+ throw error;
61
+ }
62
+ }
63
+ setDataSource(dataSource) {
64
+ const requestId = (0, ulid.ulid)();
65
+ require_dump.dump([`${this.id}`, `${requestId}.json`], {
66
+ timeStamp: Date.now(),
67
+ requestType: "setDataSource"
68
+ }, this.#logger);
69
+ const wrappedDataSource = {
70
+ preloadBlob: async (blobIds) => {
71
+ const requestId = (0, ulid.ulid)();
72
+ require_dump.dump([`${this.id}`, `${requestId}.json`], {
73
+ timeStamp: Date.now(),
74
+ requestType: "preloadBlob",
75
+ requestData: { blobIds }
76
+ }, this.#logger);
77
+ this.#logger("info", `PFrame ${this.id} preloadBlob started, blobIds: ${JSON.stringify(blobIds)}`);
78
+ const timer = _milaboratories_helpers.PerfTimer.start();
79
+ try {
80
+ return await dataSource.preloadBlob(blobIds);
81
+ } finally {
82
+ this.#logger("info", `PFrame ${this.id} preloadBlob finished, took ${timer.elapsed()} (${blobIds.length} blobs)`);
83
+ }
84
+ },
85
+ resolveBlobContent: async (blobId) => {
86
+ const requestId = (0, ulid.ulid)();
87
+ require_dump.dump([`${this.id}`, `${requestId}.json`], {
88
+ timeStamp: Date.now(),
89
+ requestType: "resolveBlobContent",
90
+ requestData: { blobId }
91
+ }, this.#logger);
92
+ const blob = await dataSource.resolveBlobContent(blobId);
93
+ this.#logger("info", `PFrame ${this.id} resolved blob ${blobId}`);
94
+ require_dump.dump([
95
+ `${this.id}`,
96
+ `data`,
97
+ `${blobId}`
98
+ ], blob, this.#logger);
99
+ return blob;
100
+ },
101
+ parquetServer: dataSource.parquetServer
102
+ };
103
+ try {
104
+ return require_addon.AddonSymbol.pFrameSetDataSource(this.#frame, wrappedDataSource);
105
+ } catch (err) {
106
+ const error = new _milaboratories_pl_model_common.PFrameError(`PFrame setDataSource request failed`);
107
+ error.cause = /* @__PURE__ */ new Error(`PFrame ${this.id} setDataSource request ${requestId} failed, dataSource: ${dataSource.toString()}, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
108
+ throw error;
109
+ }
110
+ }
111
+ setColumnData(columnId, dataInfo, ops) {
112
+ const requestId = (0, ulid.ulid)();
113
+ require_dump.dump([`${this.id}`, `${requestId}.json`], {
114
+ timeStamp: Date.now(),
115
+ requestType: "setColumnData",
116
+ requestData: {
117
+ columnId: require_dump.hashColumnId(columnId),
118
+ dataInfo
119
+ }
120
+ }, this.#logger);
121
+ require_dump.dump([
122
+ `${this.id}`,
123
+ `data`,
124
+ `${require_dump.hashColumnId(columnId)}.datainfo`
125
+ ], { ...dataInfo }, this.#logger);
126
+ try {
127
+ ops?.signal?.throwIfAborted();
128
+ return require_addon.AddonSymbol.pFrameSetColumnData(this.#frame, columnId, dataInfo, ops?.signal);
129
+ } catch (err) {
130
+ const error = new _milaboratories_pl_model_common.PFrameError(`PFrame setColumnData request failed`);
131
+ error.cause = /* @__PURE__ */ new Error(`PFrame ${this.id} setColumnData request ${requestId} failed, columnId: ${JSON.stringify(columnId)}, dataInfo: ${JSON.stringify(dataInfo)}, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
132
+ throw error;
133
+ }
134
+ }
135
+ dispose() {
136
+ const requestId = (0, ulid.ulid)();
137
+ require_dump.dump([`${this.id}`, `${requestId}.json`], {
138
+ timeStamp: Date.now(),
139
+ requestType: "dispose"
140
+ }, this.#logger);
141
+ try {
142
+ require_addon.AddonSymbol.pFrameDispose(this.#frame);
143
+ this.#logger("info", `PFrame ${this.id} disposed`);
144
+ } catch (err) {
145
+ const error = new _milaboratories_pl_model_common.PFrameError(`PFrame dispose request failed`);
146
+ error.cause = /* @__PURE__ */ new Error(`PFrame ${this.id} dispose request ${requestId} failed, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
147
+ throw error;
148
+ }
149
+ }
150
+ [Symbol.dispose]() {
151
+ this.dispose();
152
+ }
153
+ async findColumns(request) {
154
+ const requestId = (0, ulid.ulid)();
155
+ require_dump.dump([`${this.id}`, `${requestId}.json`], {
156
+ timeStamp: Date.now(),
157
+ requestType: "findColumns",
158
+ requestData: request
159
+ }, this.#logger);
160
+ const timer = _milaboratories_helpers.PerfTimer.start();
161
+ try {
162
+ return await require_addon.AddonSymbol.pFrameFindColumns(this.#frame, request);
163
+ } catch (err) {
164
+ const error = new _milaboratories_pl_model_common.PFrameError(`PFrame findColumns request failed`);
165
+ error.cause = /* @__PURE__ */ new Error(`PFrame ${this.id} findColumns request ${requestId} failed, request: ${JSON.stringify(request)}, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
166
+ throw error;
167
+ } finally {
168
+ this.#logger("info", `PFrame ${this.id} findColumns request ${requestId} took ${timer.elapsed()}`);
169
+ }
170
+ }
171
+ async deleteColumn(request) {
172
+ const requestId = (0, ulid.ulid)();
173
+ require_dump.dump([`${this.id}`, `${requestId}.json`], {
174
+ timeStamp: Date.now(),
175
+ requestType: "deleteColumn",
176
+ requestData: request
177
+ }, this.#logger);
178
+ const timer = _milaboratories_helpers.PerfTimer.start();
179
+ try {
180
+ return await require_addon.AddonSymbol.pFrameDeleteColumn(this.#frame, request);
181
+ } catch (err) {
182
+ const error = new _milaboratories_pl_model_common.PFrameError(`PFrame deleteColumn request failed`);
183
+ error.cause = /* @__PURE__ */ new Error(`PFrame ${this.id} deleteColumn request ${requestId} failed, request: ${JSON.stringify(request)}, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
184
+ throw error;
185
+ } finally {
186
+ this.#logger("info", `PFrame ${this.id} deleteColumn request ${requestId} took ${timer.elapsed()}`);
187
+ }
188
+ }
189
+ async getColumnSpec(columnId) {
190
+ const requestId = (0, ulid.ulid)();
191
+ require_dump.dump([`${this.id}`, `${requestId}.json`], {
192
+ timeStamp: Date.now(),
193
+ requestType: "getColumnSpec",
194
+ requestData: { columnId: require_dump.hashColumnId(columnId) }
195
+ }, this.#logger);
196
+ try {
197
+ return await require_addon.AddonSymbol.pFrameGetColumnSpec(this.#frame, columnId);
198
+ } catch (err) {
199
+ const error = new _milaboratories_pl_model_common.PFrameError(`PFrame getColumnSpec request failed`);
200
+ error.cause = /* @__PURE__ */ new Error(`PFrame ${this.id} getColumnSpec request ${requestId} failed, columnId: ${JSON.stringify(columnId)}, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
201
+ throw error;
202
+ }
203
+ }
204
+ async listColumns() {
205
+ const requestId = (0, ulid.ulid)();
206
+ require_dump.dump([`${this.id}`, `${requestId}.json`], {
207
+ timeStamp: Date.now(),
208
+ requestType: "listColumns"
209
+ }, this.#logger);
210
+ try {
211
+ return await require_addon.AddonSymbol.pFrameListColumns(this.#frame);
212
+ } catch (err) {
213
+ const error = new _milaboratories_pl_model_common.PFrameError(`PFrame listColumns request failed`);
214
+ error.cause = /* @__PURE__ */ new Error(`PFrame ${this.id} listColumns request ${requestId} failed, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
215
+ throw error;
216
+ }
217
+ }
218
+ createTable(requestId, request) {
219
+ const dumpData = {
220
+ timeStamp: Date.now(),
221
+ requestType: "createTable",
222
+ requestData: require_dump.hashCreateTableRequestColumnId(request)
223
+ };
224
+ require_dump.dump([`${this.id}`, `${requestId}.json`], dumpData, this.#logger);
225
+ require_dump.dump([
226
+ `${this.id}`,
227
+ `${requestId}`,
228
+ `${requestId}.json`
229
+ ], dumpData, this.#logger);
230
+ const timer = _milaboratories_helpers.PerfTimer.start();
231
+ try {
232
+ const boxed = require_addon.AddonSymbol.pFrameCreateTable(this.#frame, requestId, request);
233
+ return new PTable(this, requestId, boxed, this.#logger);
234
+ } catch (err) {
235
+ const error = new _milaboratories_pl_model_common.PFrameError(`PFrame createTable request failed`);
236
+ error.cause = /* @__PURE__ */ new Error(`PFrame ${this.id} createTable request ${requestId} failed, request: ${JSON.stringify(request)}, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
237
+ throw error;
238
+ } finally {
239
+ this.#logger("info", `PFrame ${this.id} createTable request ${requestId} took ${timer.elapsed()}`);
240
+ }
241
+ }
242
+ createTableV2(requestId, request) {
243
+ const timer = _milaboratories_helpers.PerfTimer.start();
244
+ const dumpData = {
245
+ timeStamp: Date.now(),
246
+ requestType: "createTableV2",
247
+ requestData: require_dump.hashCreateTableV2RequestColumnId(request)
248
+ };
249
+ require_dump.dump([`${this.id}`, `${requestId}.json`], dumpData, this.#logger);
250
+ require_dump.dump([
251
+ `${this.id}`,
252
+ `${requestId}`,
253
+ `${requestId}.json`
254
+ ], dumpData, this.#logger);
255
+ try {
256
+ const boxed = require_addon.AddonSymbol.pFrameCreateTableV2(this.#frame, requestId, request);
257
+ return new PTable(this, requestId, boxed, this.#logger);
258
+ } catch (err) {
259
+ const error = new _milaboratories_pl_model_common.PFrameError(`PFrame createTableV2 request failed`);
260
+ error.cause = /* @__PURE__ */ new Error(`PFrame ${this.id} createTableV2 request ${requestId} failed, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
261
+ throw error;
262
+ } finally {
263
+ this.#logger("info", `PFrame ${this.id} createTableV2 request ${requestId} took ${timer.elapsed()}`);
264
+ }
265
+ }
266
+ async getUniqueValues(request, ops) {
267
+ const requestId = (0, ulid.ulid)();
268
+ require_dump.dump([`${this.id}`, `${requestId}.json`], {
269
+ timeStamp: Date.now(),
270
+ requestType: "getUniqueValues",
271
+ requestData: require_dump.hashUniqueValuesRequestColumnId(request)
272
+ }, this.#logger);
273
+ this.#logger("info", `PFrame ${this.id} getUniqueValues request ${requestId} started`);
274
+ const timer = _milaboratories_helpers.PerfTimer.start();
275
+ try {
276
+ ops?.signal?.throwIfAborted();
277
+ return await require_addon.AddonSymbol.pFrameGetUniqueValues(this.#frame, requestId, request, ops?.signal);
278
+ } catch (err) {
279
+ if ((0, _milaboratories_pl_model_common.isAbortError)(err)) throw new _milaboratories_pl_model_common.AbortError(`PFrame ${this.id} getUniqueValues request ${requestId} cancelled`);
280
+ const error = new _milaboratories_pl_model_common.PFrameError(`PFrame getUniqueValues request failed`);
281
+ error.cause = /* @__PURE__ */ new Error(`PFrame ${this.id} getUniqueValues request ${requestId} failed, request: ${JSON.stringify(request)}, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
282
+ throw error;
283
+ } finally {
284
+ this.#logger("info", `PFrame ${this.id} getUniqueValues request ${requestId} finished, took ${timer.elapsed()}`);
285
+ }
286
+ }
287
+ };
288
+ var PTable = class PTable {
289
+ #frame;
290
+ #table;
291
+ #id;
292
+ get id() {
293
+ return this.#id;
294
+ }
295
+ #logger;
296
+ constructor(frame, id, table, logger) {
297
+ this.#frame = frame;
298
+ this.#table = table;
299
+ this.#id = id;
300
+ this.#logger = logger;
301
+ this.#logger("info", `PTable ${this.id} created`);
302
+ }
303
+ getSpec() {
304
+ const requestId = (0, ulid.ulid)();
305
+ require_dump.dump([
306
+ `${this.#frame.id}`,
307
+ `${this.id}`,
308
+ `${requestId}.json`
309
+ ], {
310
+ timeStamp: Date.now(),
311
+ requestType: "getSpec"
312
+ }, this.#logger);
313
+ try {
314
+ return require_addon.AddonSymbol.pTableGetSpec(this.#table);
315
+ } catch (err) {
316
+ const error = new _milaboratories_pl_model_common.PFrameError(`PTable getSpec request failed`);
317
+ error.cause = /* @__PURE__ */ new Error(`PTable ${this.id} getSpec request ${requestId} failed, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
318
+ throw error;
319
+ }
320
+ }
321
+ getColumnIndices(columnIds) {
322
+ const requestId = (0, ulid.ulid)();
323
+ require_dump.dump([
324
+ `${this.#frame.id}`,
325
+ `${this.id}`,
326
+ `${requestId}.json`
327
+ ], {
328
+ timeStamp: Date.now(),
329
+ requestType: "getColumnIndices",
330
+ requestData: { columnIds: columnIds.map(require_dump.hashTableColumnId) }
331
+ }, this.#logger);
332
+ try {
333
+ return require_addon.AddonSymbol.pTableGetColumnIndices(this.#table, columnIds);
334
+ } catch (err) {
335
+ const error = new _milaboratories_pl_model_common.PFrameError(`PTable getColumnIndices request failed`);
336
+ error.cause = /* @__PURE__ */ new Error(`PTable ${this.id} getColumnIndices request ${requestId} failed, columnIds: ${JSON.stringify(columnIds)}, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
337
+ throw error;
338
+ }
339
+ }
340
+ async getFootprint(ops) {
341
+ const requestId = (0, ulid.ulid)();
342
+ require_dump.dump([
343
+ `${this.#frame.id}`,
344
+ `${this.id}`,
345
+ `${requestId}.json`
346
+ ], {
347
+ timeStamp: Date.now(),
348
+ requestType: "getFootprint"
349
+ }, this.#logger);
350
+ try {
351
+ ops?.signal?.throwIfAborted();
352
+ return await require_addon.AddonSymbol.pTableGetFootprint(this.#table, ops?.signal);
353
+ } catch (err) {
354
+ if ((0, _milaboratories_pl_model_common.isAbortError)(err)) throw new _milaboratories_pl_model_common.AbortError(`PTable ${this.id} getFootprint request ${requestId} cancelled`);
355
+ const error = new _milaboratories_pl_model_common.PFrameError(`PTable getFootprint request failed`);
356
+ error.cause = /* @__PURE__ */ new Error(`PTable ${this.id} getFootprint request ${requestId} failed, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
357
+ throw error;
358
+ }
359
+ }
360
+ async getShape(ops) {
361
+ const requestId = (0, ulid.ulid)();
362
+ require_dump.dump([
363
+ `${this.#frame.id}`,
364
+ `${this.id}`,
365
+ `${requestId}.json`
366
+ ], {
367
+ timeStamp: Date.now(),
368
+ requestType: "getShape"
369
+ }, this.#logger);
370
+ this.#logger("info", `PTable ${this.id} getShape request ${requestId} started`);
371
+ const timer = _milaboratories_helpers.PerfTimer.start();
372
+ try {
373
+ ops?.signal?.throwIfAborted();
374
+ return await require_addon.AddonSymbol.pTableGetShape(this.#table, ops?.signal);
375
+ } catch (err) {
376
+ if ((0, _milaboratories_pl_model_common.isAbortError)(err)) throw new _milaboratories_pl_model_common.AbortError(`PTable ${this.id} getShape request ${requestId} cancelled`);
377
+ const error = new _milaboratories_pl_model_common.PFrameError(`PTable getShape request failed`);
378
+ error.cause = /* @__PURE__ */ new Error(`PTable ${this.id} getShape request ${requestId} failed, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
379
+ throw error;
380
+ } finally {
381
+ this.#logger("info", `PTable ${this.id} getShape request ${requestId} finished, took ${timer.elapsed()}`);
382
+ }
383
+ }
384
+ async getData(columnIndices, ops) {
385
+ const requestId = (0, ulid.ulid)();
386
+ require_dump.dump([
387
+ `${this.#frame.id}`,
388
+ `${this.id}`,
389
+ `${requestId}.json`
390
+ ], {
391
+ timeStamp: Date.now(),
392
+ requestType: "getData",
393
+ requestData: {
394
+ columnIndices,
395
+ range: ops?.range ?? null
396
+ }
397
+ }, this.#logger);
398
+ this.#logger("info", `PTable ${this.id} getData request ${requestId} started`);
399
+ let rowCount = 0;
400
+ const timer = _milaboratories_helpers.PerfTimer.start();
401
+ try {
402
+ ops?.signal?.throwIfAborted();
403
+ const result = await require_addon.AddonSymbol.pTableGetData(this.#table, requestId, columnIndices, ops?.range, ops?.signal);
404
+ rowCount = result[0].data.length;
405
+ return result;
406
+ } catch (err) {
407
+ if ((0, _milaboratories_pl_model_common.isAbortError)(err)) throw new _milaboratories_pl_model_common.AbortError(`PTable ${this.id} getData request ${requestId} cancelled`);
408
+ const error = new _milaboratories_pl_model_common.PFrameError(`PTable getData request failed`);
409
+ error.cause = /* @__PURE__ */ new Error(`PTable ${this.id} getData request ${requestId} failed, columnIndices: ${JSON.stringify(columnIndices)}, range: ${ops?.range ? JSON.stringify(ops.range) : void 0}, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
410
+ throw error;
411
+ } finally {
412
+ this.#logger("info", `PTable ${this.id} getData request ${requestId} finished, took ${timer.elapsed()} (${rowCount} rows)`);
413
+ }
414
+ }
415
+ filter(requestId, request) {
416
+ const dumpData = {
417
+ timeStamp: Date.now(),
418
+ table: this.id,
419
+ requestType: "filter",
420
+ requestData: { filters: request.map(require_dump.hashFilterColumnId) }
421
+ };
422
+ require_dump.dump([`${this.#frame.id}`, `${requestId}.json`], dumpData, this.#logger);
423
+ require_dump.dump([
424
+ `${this.#frame.id}`,
425
+ `${requestId}`,
426
+ `${requestId}.json`
427
+ ], dumpData, this.#logger);
428
+ const timer = _milaboratories_helpers.PerfTimer.start();
429
+ try {
430
+ const boxed = require_addon.AddonSymbol.pTableFilter(this.#table, requestId, request);
431
+ return new PTable(this.#frame, requestId, boxed, this.#logger);
432
+ } catch (err) {
433
+ const error = new _milaboratories_pl_model_common.PFrameError(`PTable filter request failed`);
434
+ error.cause = /* @__PURE__ */ new Error(`PTable ${this.id} filter request ${requestId} failed, request: ${JSON.stringify(request)}, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
435
+ throw error;
436
+ } finally {
437
+ this.#logger("info", `PTable ${this.id} filter request ${requestId} took ${timer.elapsed()}`);
438
+ }
439
+ }
440
+ sort(requestId, request) {
441
+ const dumpData = {
442
+ timeStamp: Date.now(),
443
+ table: this.id,
444
+ requestType: "sort",
445
+ requestData: request.map(require_dump.hashSortingColumnId)
446
+ };
447
+ require_dump.dump([`${this.#frame.id}`, `${requestId}.json`], dumpData, this.#logger);
448
+ require_dump.dump([
449
+ `${this.#frame.id}`,
450
+ `${requestId}`,
451
+ `${requestId}.json`
452
+ ], dumpData, this.#logger);
453
+ const timer = _milaboratories_helpers.PerfTimer.start();
454
+ try {
455
+ const boxed = require_addon.AddonSymbol.pTableSort(this.#table, requestId, request);
456
+ return new PTable(this.#frame, requestId, boxed, this.#logger);
457
+ } catch (err) {
458
+ const error = new _milaboratories_pl_model_common.PFrameError(`PTable sort request failed`);
459
+ error.cause = /* @__PURE__ */ new Error(`PTable ${this.id} sort request ${requestId} failed, request: ${JSON.stringify(request)}, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
460
+ throw error;
461
+ } finally {
462
+ this.#logger("info", `PTable ${this.id} sort request ${requestId} took ${timer.elapsed()}`);
463
+ }
464
+ }
465
+ dispose() {
466
+ const requestId = (0, ulid.ulid)();
467
+ require_dump.dump([
468
+ `${this.#frame.id}`,
469
+ `${this.id}`,
470
+ `${requestId}.json`
471
+ ], {
472
+ timeStamp: Date.now(),
473
+ requestType: "dispose"
474
+ }, this.#logger);
475
+ try {
476
+ require_addon.AddonSymbol.pTableDispose(this.#table);
477
+ this.#logger("info", `PTable ${this.id} disposed`);
478
+ } catch (err) {
479
+ const error = new _milaboratories_pl_model_common.PFrameError(`PTable dispose request failed`);
480
+ error.cause = /* @__PURE__ */ new Error(`PTable ${this.id} dispose request ${requestId} failed, error:\n${(0, _milaboratories_pl_model_common.ensureError)(err)}`);
481
+ throw error;
482
+ }
483
+ }
484
+ [Symbol.dispose]() {
485
+ this.dispose();
486
+ }
487
+ };
488
+ //#endregion
547
489
  exports.PFrame = PFrame;
548
490
  exports.pprofDump = pprofDump;
549
- //# sourceMappingURL=wrapper.cjs.map
491
+
492
+ //# sourceMappingURL=wrapper.cjs.map