svelte-adapter-uws-extensions 0.5.10 → 0.6.0-next.2

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/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "svelte-adapter-uws-extensions",
3
- "version": "0.5.10",
3
+ "version": "0.6.0-next.2",
4
4
  "publishConfig": {
5
- "tag": "latest"
5
+ "tag": "next"
6
6
  },
7
7
  "description": "Redis and Postgres extensions for svelte-adapter-uws - distributed pub/sub, replay buffers, presence tracking, rate limiting, groups, and DB change notifications",
8
8
  "author": "Kevin Radziszewski",
@@ -154,7 +154,7 @@
154
154
  "node": ">=22.0.0"
155
155
  },
156
156
  "peerDependencies": {
157
- "svelte-adapter-uws": "^0.5.8"
157
+ "svelte-adapter-uws": "^0.6.0-next.5"
158
158
  },
159
159
  "dependencies": {
160
160
  "ioredis": "^5.0.0"
@@ -163,6 +163,7 @@
163
163
  "pg": "^8.0.0"
164
164
  },
165
165
  "devDependencies": {
166
+ "svelte-adapter-uws": "^0.6.0-next.5",
166
167
  "vitest": "^4.0.18",
167
168
  "ws": "^8.0.0"
168
169
  },
@@ -123,9 +123,13 @@ export function createIdempotencyStore(client, options = {}) {
123
123
  // callers that need the table to exist before they start polling can
124
124
  // `await idempotency.ready()`. Subsequent ensureTable() calls are
125
125
  // no-ops via the migrated flag.
126
- const readyPromise = autoMigrate
127
- ? ensureTable().catch((err) => { throw err; })
128
- : Promise.resolve();
126
+ const readyPromise = autoMigrate ? ensureTable() : Promise.resolve();
127
+ // A caller that never awaits ready() must not crash the process if this
128
+ // eager migration rejects (e.g. the table is dropped concurrently): the
129
+ // failure is non-fatal because acquire() / clear() / purge() each re-run
130
+ // ensureTable() and surface the error on first real use. An explicit
131
+ // ready() awaiter still observes the rejection - it receives readyPromise.
132
+ readyPromise.catch(() => {});
129
133
 
130
134
  function validateKey(idempotencyKey) {
131
135
  if (typeof idempotencyKey !== 'string' || idempotencyKey.length === 0) {