@powersync/common 0.0.0-dev-20251201150812 → 0.0.0-dev-20251209082930

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/bundle.cjs CHANGED
@@ -12167,7 +12167,7 @@ The next upload iteration will be delayed.`);
12167
12167
  uploadError: ex
12168
12168
  }
12169
12169
  });
12170
- await this.delayRetry(controller.signal, this.options.crudUploadThrottleMs);
12170
+ await this.delayRetry(controller.signal);
12171
12171
  if (!this.isConnected) {
12172
12172
  // Exit the upload loop if the sync stream is no longer connected
12173
12173
  break;
@@ -12878,14 +12878,14 @@ The next upload iteration will be delayed.`);
12878
12878
  // trigger this for all updates
12879
12879
  this.iterateListeners((cb) => cb.statusUpdated?.(options));
12880
12880
  }
12881
- async delayRetry(signal, delayMs) {
12881
+ async delayRetry(signal) {
12882
12882
  return new Promise((resolve) => {
12883
12883
  if (signal?.aborted) {
12884
12884
  // If the signal is already aborted, resolve immediately
12885
12885
  resolve();
12886
12886
  return;
12887
12887
  }
12888
- const delay = delayMs ?? this.options.retryDelayMs;
12888
+ const { retryDelayMs } = this.options;
12889
12889
  let timeoutId;
12890
12890
  const endDelay = () => {
12891
12891
  resolve();
@@ -12896,7 +12896,7 @@ The next upload iteration will be delayed.`);
12896
12896
  signal?.removeEventListener('abort', endDelay);
12897
12897
  };
12898
12898
  signal?.addEventListener('abort', endDelay, { once: true });
12899
- timeoutId = setTimeout(endDelay, delay);
12899
+ timeoutId = setTimeout(endDelay, retryDelayMs);
12900
12900
  });
12901
12901
  }
12902
12902
  updateSubscriptions(subscriptions) {
@@ -13426,11 +13426,11 @@ class AbstractPowerSyncDatabase extends BaseObserver {
13426
13426
  .map((n) => parseInt(n));
13427
13427
  }
13428
13428
  catch (e) {
13429
- throw new Error(`Unsupported powersync extension version. Need >=0.4.5 <1.0.0, got: ${this.sdkVersion}. Details: ${e.message}`);
13429
+ throw new Error(`Unsupported powersync extension version. Need >=0.4.10 <1.0.0, got: ${this.sdkVersion}. Details: ${e.message}`);
13430
13430
  }
13431
- // Validate >=0.4.5 <1.0.0
13432
- if (versionInts[0] != 0 || versionInts[1] < 4 || (versionInts[1] == 4 && versionInts[2] < 5)) {
13433
- throw new Error(`Unsupported powersync extension version. Need >=0.4.5 <1.0.0, got: ${this.sdkVersion}`);
13431
+ // Validate >=0.4.10 <1.0.0
13432
+ if (versionInts[0] != 0 || versionInts[1] < 4 || (versionInts[1] == 4 && versionInts[2] < 10)) {
13433
+ throw new Error(`Unsupported powersync extension version. Need >=0.4.10 <1.0.0, got: ${this.sdkVersion}`);
13434
13434
  }
13435
13435
  }
13436
13436
  async resolveOfflineSyncStatus() {