@mdbase-dev/sdk 0.1.0-beta.157 → 0.1.0-beta.158

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,11 +1,11 @@
1
1
  {
2
2
  "runtime": {
3
- "sha256": "d375ce16a48dec718801704f56ffb6a545247a2793912c2c8e68ceb171ff2537",
4
- "bytes": 3797530,
5
- "maxBytes": 3797530,
3
+ "sha256": "7d5cf20f69ef22db5eee56fa28a71a5cadab1d4014aedfc3ee5a12ccf21fff6b",
4
+ "bytes": 3798410,
5
+ "maxBytes": 3798410,
6
6
  "source": {
7
7
  "repository": "mdbase-dev/mdbase-connect",
8
- "commit": "3e433313e0a234513478789686a4f4274e4dd76c"
8
+ "commit": "056880a91db3971c10ff80cd5b5ed4a81a6b28db"
9
9
  }
10
10
  },
11
11
  "sqlite": {
@@ -15308,12 +15308,12 @@ function appReleaseTrust() {
15308
15308
  // src/application/asset-pins.json
15309
15309
  var asset_pins_default = {
15310
15310
  runtime: {
15311
- sha256: "d375ce16a48dec718801704f56ffb6a545247a2793912c2c8e68ceb171ff2537",
15312
- bytes: 3797530,
15313
- maxBytes: 3797530,
15311
+ sha256: "7d5cf20f69ef22db5eee56fa28a71a5cadab1d4014aedfc3ee5a12ccf21fff6b",
15312
+ bytes: 3798410,
15313
+ maxBytes: 3798410,
15314
15314
  source: {
15315
15315
  repository: "mdbase-dev/mdbase-connect",
15316
- commit: "3e433313e0a234513478789686a4f4274e4dd76c"
15316
+ commit: "056880a91db3971c10ff80cd5b5ed4a81a6b28db"
15317
15317
  }
15318
15318
  },
15319
15319
  sqlite: {
@@ -21417,9 +21417,8 @@ var FilesApi = class {
21417
21417
  if (o.onProgress) this.progress.set(transfer, o.onProgress);
21418
21418
  const busyUntil = Date.now() + REGION_BUSY_WAIT_MS;
21419
21419
  for (; ; ) {
21420
- const phase = { committing: false };
21421
21420
  try {
21422
- return await this.uploadOnce(source, size2, open2, o, phase);
21421
+ return await this.uploadOnce(source, size2, open2, o);
21423
21422
  } catch (e) {
21424
21423
  if (isMdbaseError(e, "unavailable") && this.client.link === "reconnecting") continue;
21425
21424
  if (regionBusy(e, busyUntil)) {
@@ -21427,13 +21426,13 @@ var FilesApi = class {
21427
21426
  continue;
21428
21427
  }
21429
21428
  this.progress.delete(transfer);
21430
- if (!phase.committing) await this.abortUpload(transfer).catch(() => {
21429
+ await this.abortUpload(transfer).catch(() => {
21431
21430
  });
21432
21431
  throw withMutation(e, "upload", { mutationId: open2.mutationId });
21433
21432
  }
21434
21433
  }
21435
21434
  }
21436
- async uploadOnce(source, size2, open2, o, phase) {
21435
+ async uploadOnce(source, size2, open2, o) {
21437
21436
  const s = await this.session(o.signal);
21438
21437
  const sig = o.signal ? { signal: o.signal } : {};
21439
21438
  const opened = await s.request("open_upload", openUploadParams.enc(open2), { codec: openUploadResult, ...sig });
@@ -21466,7 +21465,6 @@ var FilesApi = class {
21466
21465
  if (inflight.size >= 4) await Promise.race(inflight);
21467
21466
  }
21468
21467
  await Promise.all(inflight);
21469
- phase.committing = true;
21470
21468
  const r = await s.request("commit_upload", m([[0, uuid2.enc(open2.transfer)]]), {
21471
21469
  codec: receipt,
21472
21470
  ...sig
@@ -21480,7 +21478,7 @@ var FilesApi = class {
21480
21478
  }
21481
21479
  return w;
21482
21480
  }
21483
- /** Abort an upload; the replica discards its chunks. */
21481
+ /** Release the upload lane. An already captured write remains durable; use its receipt to resolve the outcome. */
21484
21482
  abortUpload(transferId) {
21485
21483
  return this.client.call("abort_upload", m([[0, uuid2.enc(transferId)]])).then(() => {
21486
21484
  });
@@ -3764,9 +3764,8 @@ var MdbaseSDK = (() => {
3764
3764
  if (o.onProgress) this.progress.set(transfer, o.onProgress);
3765
3765
  const busyUntil = Date.now() + REGION_BUSY_WAIT_MS;
3766
3766
  for (; ; ) {
3767
- const phase = { committing: false };
3768
3767
  try {
3769
- return await this.uploadOnce(source, size2, open2, o, phase);
3768
+ return await this.uploadOnce(source, size2, open2, o);
3770
3769
  } catch (e) {
3771
3770
  if (isMdbaseError(e, "unavailable") && this.client.link === "reconnecting") continue;
3772
3771
  if (regionBusy(e, busyUntil)) {
@@ -3774,13 +3773,13 @@ var MdbaseSDK = (() => {
3774
3773
  continue;
3775
3774
  }
3776
3775
  this.progress.delete(transfer);
3777
- if (!phase.committing) await this.abortUpload(transfer).catch(() => {
3776
+ await this.abortUpload(transfer).catch(() => {
3778
3777
  });
3779
3778
  throw withMutation(e, "upload", { mutationId: open2.mutationId });
3780
3779
  }
3781
3780
  }
3782
3781
  }
3783
- async uploadOnce(source, size2, open2, o, phase) {
3782
+ async uploadOnce(source, size2, open2, o) {
3784
3783
  const s = await this.session(o.signal);
3785
3784
  const sig = o.signal ? { signal: o.signal } : {};
3786
3785
  const opened = await s.request("open_upload", openUploadParams.enc(open2), { codec: openUploadResult, ...sig });
@@ -3813,7 +3812,6 @@ var MdbaseSDK = (() => {
3813
3812
  if (inflight.size >= 4) await Promise.race(inflight);
3814
3813
  }
3815
3814
  await Promise.all(inflight);
3816
- phase.committing = true;
3817
3815
  const r = await s.request("commit_upload", m([[0, uuid.enc(open2.transfer)]]), {
3818
3816
  codec: receipt,
3819
3817
  ...sig
@@ -3827,7 +3825,7 @@ var MdbaseSDK = (() => {
3827
3825
  }
3828
3826
  return w;
3829
3827
  }
3830
- /** Abort an upload; the replica discards its chunks. */
3828
+ /** Release the upload lane. An already captured write remains durable; use its receipt to resolve the outcome. */
3831
3829
  abortUpload(transferId) {
3832
3830
  return this.client.call("abort_upload", m([[0, uuid.enc(transferId)]])).then(() => {
3833
3831
  });
@@ -40969,12 +40967,12 @@ ${end.comment}` : end.comment;
40969
40967
  // src/application/asset-pins.json
40970
40968
  var asset_pins_default = {
40971
40969
  runtime: {
40972
- sha256: "d375ce16a48dec718801704f56ffb6a545247a2793912c2c8e68ceb171ff2537",
40973
- bytes: 3797530,
40974
- maxBytes: 3797530,
40970
+ sha256: "7d5cf20f69ef22db5eee56fa28a71a5cadab1d4014aedfc3ee5a12ccf21fff6b",
40971
+ bytes: 3798410,
40972
+ maxBytes: 3798410,
40975
40973
  source: {
40976
40974
  repository: "mdbase-dev/mdbase-connect",
40977
- commit: "3e433313e0a234513478789686a4f4274e4dd76c"
40975
+ commit: "056880a91db3971c10ff80cd5b5ed4a81a6b28db"
40978
40976
  }
40979
40977
  },
40980
40978
  sqlite: {