rivetkit 0.0.0-pr.4860.b5fe23b → 0.0.0-pr.4860.f43cf47
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/browser/client.d.ts +34 -4
- package/dist/browser/client.js +14 -7
- package/dist/browser/client.js.map +1 -1
- package/dist/browser/inspector/client.js +2 -1
- package/dist/browser/inspector/client.js.map +1 -1
- package/dist/tsup/agent-os/index.cjs +2 -1
- package/dist/tsup/agent-os/index.cjs.map +1 -1
- package/dist/tsup/agent-os/index.d.cts +26 -4
- package/dist/tsup/agent-os/index.d.ts +26 -4
- package/dist/tsup/agent-os/index.js +2 -1
- package/dist/tsup/agent-os/index.js.map +1 -1
- package/dist/tsup/{chunk-TPY4ULGZ.cjs → chunk-3ME5SAJL.cjs} +3 -3
- package/dist/tsup/{chunk-TPY4ULGZ.cjs.map → chunk-3ME5SAJL.cjs.map} +1 -1
- package/dist/tsup/{chunk-26BTODC3.js → chunk-4VCLZDED.js} +15 -8
- package/dist/tsup/chunk-4VCLZDED.js.map +1 -0
- package/dist/tsup/{chunk-HTUDFT54.js → chunk-5F5CEFYI.js} +4 -4
- package/dist/tsup/{chunk-2J6HEKC3.js → chunk-EFIWXUJK.js} +4 -4
- package/dist/tsup/{chunk-SOABA7VS.cjs → chunk-KVSWU6BL.cjs} +10 -10
- package/dist/tsup/{chunk-SOABA7VS.cjs.map → chunk-KVSWU6BL.cjs.map} +1 -1
- package/dist/tsup/{chunk-XIOH4YFR.cjs → chunk-LIBPBWW3.cjs} +5 -5
- package/dist/tsup/{chunk-XIOH4YFR.cjs.map → chunk-LIBPBWW3.cjs.map} +1 -1
- package/dist/tsup/{chunk-73XXSOF2.cjs → chunk-LQ4LKEUC.cjs} +4 -4
- package/dist/tsup/{chunk-73XXSOF2.cjs.map → chunk-LQ4LKEUC.cjs.map} +1 -1
- package/dist/tsup/{chunk-7ZMTRP5L.js → chunk-NMGBT4I3.js} +3 -3
- package/dist/tsup/{chunk-L2MPIIMW.js → chunk-R2LBGJ56.js} +2 -2
- package/dist/tsup/{chunk-IGKWYUSX.cjs → chunk-R7SAONUZ.cjs} +137 -137
- package/dist/tsup/{chunk-IGKWYUSX.cjs.map → chunk-R7SAONUZ.cjs.map} +1 -1
- package/dist/tsup/{chunk-I43HZXBU.js → chunk-VVIXQQEW.js} +2 -2
- package/dist/tsup/{chunk-CPN4XHBW.cjs → chunk-XBBC4GFA.cjs} +16 -9
- package/dist/tsup/chunk-XBBC4GFA.cjs.map +1 -0
- package/dist/tsup/{chunk-SIWAIBZN.cjs → chunk-XTP5DZQN.cjs} +8 -8
- package/dist/tsup/{chunk-SIWAIBZN.cjs.map → chunk-XTP5DZQN.cjs.map} +1 -1
- package/dist/tsup/{chunk-YKFKSOT2.js → chunk-YNL557CO.js} +2 -2
- package/dist/tsup/client/mod.cjs +6 -6
- package/dist/tsup/client/mod.d.cts +3 -2
- package/dist/tsup/client/mod.d.ts +3 -2
- package/dist/tsup/client/mod.js +5 -5
- package/dist/tsup/common/log.cjs +2 -2
- package/dist/tsup/common/log.js +1 -1
- package/dist/tsup/common/websocket.cjs +3 -3
- package/dist/tsup/common/websocket.js +2 -2
- package/dist/tsup/{config-BfBykp2S.d.ts → config-Ditotsl8.d.ts} +62 -6
- package/dist/tsup/{config-CyyirxT4.d.cts → config-ctKnLh95.d.cts} +62 -6
- package/dist/tsup/{context-dXtQFcf_.d.ts → context-BQAsyraR.d.ts} +1 -1
- package/dist/tsup/{context-C9d-GRgx.d.cts → context-BpqKT1X1.d.cts} +1 -1
- package/dist/tsup/inspector/mod.cjs +5 -5
- package/dist/tsup/inspector/mod.js +4 -4
- package/dist/tsup/mod.cjs +396 -253
- package/dist/tsup/mod.cjs.map +1 -1
- package/dist/tsup/mod.d.cts +4 -3
- package/dist/tsup/mod.d.ts +4 -3
- package/dist/tsup/mod.js +356 -213
- package/dist/tsup/mod.js.map +1 -1
- package/dist/tsup/test/mod.cjs +9 -9
- package/dist/tsup/test/mod.d.cts +2 -1
- package/dist/tsup/test/mod.d.ts +2 -1
- package/dist/tsup/test/mod.js +5 -5
- package/dist/tsup/utils.cjs +2 -2
- package/dist/tsup/utils.js +1 -1
- package/dist/tsup/workflow/mod.cjs +7 -7
- package/dist/tsup/workflow/mod.d.cts +4 -3
- package/dist/tsup/workflow/mod.d.ts +4 -3
- package/dist/tsup/workflow/mod.js +4 -4
- package/package.json +9 -8
- package/src/common/database/native-database.test.ts +36 -0
- package/src/common/utils.ts +8 -2
- package/src/registry/config/index.ts +115 -54
- package/src/registry/index.ts +26 -17
- package/src/registry/napi-runtime.ts +192 -68
- package/src/registry/native.ts +140 -105
- package/src/registry/runtime.ts +105 -57
- package/src/registry/wasm-runtime.ts +96 -67
- package/dist/tsup/chunk-26BTODC3.js.map +0 -1
- package/dist/tsup/chunk-CPN4XHBW.cjs.map +0 -1
- /package/dist/tsup/{chunk-HTUDFT54.js.map → chunk-5F5CEFYI.js.map} +0 -0
- /package/dist/tsup/{chunk-2J6HEKC3.js.map → chunk-EFIWXUJK.js.map} +0 -0
- /package/dist/tsup/{chunk-7ZMTRP5L.js.map → chunk-NMGBT4I3.js.map} +0 -0
- /package/dist/tsup/{chunk-L2MPIIMW.js.map → chunk-R2LBGJ56.js.map} +0 -0
- /package/dist/tsup/{chunk-I43HZXBU.js.map → chunk-VVIXQQEW.js.map} +0 -0
- /package/dist/tsup/{chunk-YKFKSOT2.js.map → chunk-YNL557CO.js.map} +0 -0
package/dist/browser/client.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import * as _rivetkit_rivetkit_wasm from '@rivetkit/rivetkit-wasm';
|
|
1
2
|
import { z as z$2 } from 'zod';
|
|
2
3
|
import z$1, { z } from 'zod/v4';
|
|
3
4
|
import { UniversalWebSocket } from '@rivetkit/virtual-websocket';
|
|
@@ -1335,7 +1336,6 @@ declare class ActorDefinition<S, CP, CS, V, I, DB extends AnyDatabaseProvider, E
|
|
|
1335
1336
|
|
|
1336
1337
|
declare const ActorsSchema: z$2.ZodRecord<z$2.ZodString, z$2.ZodCustom<BaseActorDefinition<any, any, any, any, any, any, any, any, any>, BaseActorDefinition<any, any, any, any, any, any, any, any, any>>>;
|
|
1337
1338
|
type RegistryActors = z$2.infer<typeof ActorsSchema>;
|
|
1338
|
-
type WasmRuntimeInitInput = WebAssembly.Module | ArrayBuffer | ArrayBufferView | URL | Response;
|
|
1339
1339
|
declare const RegistryConfigSchema: z$2.ZodPipe<z$2.ZodObject<{
|
|
1340
1340
|
use: z$2.ZodRecord<z$2.ZodString, z$2.ZodCustom<AnyActorDefinition, AnyActorDefinition>>;
|
|
1341
1341
|
test: z$2.ZodDefault<z$2.ZodOptional<z$2.ZodObject<{
|
|
@@ -1353,8 +1353,26 @@ declare const RegistryConfigSchema: z$2.ZodPipe<z$2.ZodObject<{
|
|
|
1353
1353
|
wasm: "wasm";
|
|
1354
1354
|
}>>, z$2.ZodTransform<"auto" | "native" | "wasm", "auto" | "native" | "wasm" | undefined>>;
|
|
1355
1355
|
wasm: z$2.ZodDefault<z$2.ZodOptional<z$2.ZodObject<{
|
|
1356
|
-
|
|
1356
|
+
bindings: z$2.ZodOptional<z$2.ZodCustom<typeof _rivetkit_rivetkit_wasm, typeof _rivetkit_rivetkit_wasm>>;
|
|
1357
|
+
initInput: z$2.ZodOptional<z$2.ZodCustom<{
|
|
1358
|
+
module_or_path: _rivetkit_rivetkit_wasm.InitInput | Promise<_rivetkit_rivetkit_wasm.InitInput>;
|
|
1359
|
+
} | _rivetkit_rivetkit_wasm.InitInput | Promise<_rivetkit_rivetkit_wasm.InitInput> | undefined, {
|
|
1360
|
+
module_or_path: _rivetkit_rivetkit_wasm.InitInput | Promise<_rivetkit_rivetkit_wasm.InitInput>;
|
|
1361
|
+
} | _rivetkit_rivetkit_wasm.InitInput | Promise<_rivetkit_rivetkit_wasm.InitInput> | undefined>>;
|
|
1357
1362
|
}, z$2.core.$strip>>>;
|
|
1363
|
+
sqlite: z$2.ZodPipe<z$2.ZodOptional<z$2.ZodUnion<readonly [z$2.ZodEnum<{
|
|
1364
|
+
local: "local";
|
|
1365
|
+
remote: "remote";
|
|
1366
|
+
}>, z$2.ZodObject<{
|
|
1367
|
+
backend: z$2.ZodEnum<{
|
|
1368
|
+
local: "local";
|
|
1369
|
+
remote: "remote";
|
|
1370
|
+
}>;
|
|
1371
|
+
}, z$2.core.$strip>]>>, z$2.ZodTransform<{
|
|
1372
|
+
backend: "local" | "remote";
|
|
1373
|
+
} | undefined, "local" | "remote" | {
|
|
1374
|
+
backend: "local" | "remote";
|
|
1375
|
+
} | undefined>>;
|
|
1358
1376
|
noWelcome: z$2.ZodDefault<z$2.ZodOptional<z$2.ZodBoolean>>;
|
|
1359
1377
|
logging: z$2.ZodDefault<z$2.ZodOptional<z$2.ZodObject<{
|
|
1360
1378
|
baseLogger: z$2.ZodOptional<z$2.ZodCustom<Logger, Logger>>;
|
|
@@ -1405,6 +1423,9 @@ declare const RegistryConfigSchema: z$2.ZodPipe<z$2.ZodObject<{
|
|
|
1405
1423
|
disableSignalHandlers: z$2.ZodDefault<z$2.ZodOptional<z$2.ZodBoolean>>;
|
|
1406
1424
|
}, z$2.core.$strip>>>;
|
|
1407
1425
|
}, z$2.core.$strip>, z$2.ZodTransform<{
|
|
1426
|
+
sqlite: {
|
|
1427
|
+
backend: "local" | "remote";
|
|
1428
|
+
} | undefined;
|
|
1408
1429
|
endpoint: string | undefined;
|
|
1409
1430
|
namespace: string;
|
|
1410
1431
|
token: string | undefined;
|
|
@@ -1427,7 +1448,10 @@ declare const RegistryConfigSchema: z$2.ZodPipe<z$2.ZodObject<{
|
|
|
1427
1448
|
maxOutgoingMessageSize: number;
|
|
1428
1449
|
runtime: "auto" | "native" | "wasm";
|
|
1429
1450
|
wasm: {
|
|
1430
|
-
|
|
1451
|
+
bindings?: typeof _rivetkit_rivetkit_wasm | undefined;
|
|
1452
|
+
initInput?: {
|
|
1453
|
+
module_or_path: _rivetkit_rivetkit_wasm.InitInput | Promise<_rivetkit_rivetkit_wasm.InitInput>;
|
|
1454
|
+
} | _rivetkit_rivetkit_wasm.InitInput | Promise<_rivetkit_rivetkit_wasm.InitInput> | undefined;
|
|
1431
1455
|
};
|
|
1432
1456
|
noWelcome: boolean;
|
|
1433
1457
|
logging: {
|
|
@@ -1471,8 +1495,14 @@ declare const RegistryConfigSchema: z$2.ZodPipe<z$2.ZodObject<{
|
|
|
1471
1495
|
maxOutgoingMessageSize: number;
|
|
1472
1496
|
runtime: "auto" | "native" | "wasm";
|
|
1473
1497
|
wasm: {
|
|
1474
|
-
|
|
1498
|
+
bindings?: typeof _rivetkit_rivetkit_wasm | undefined;
|
|
1499
|
+
initInput?: {
|
|
1500
|
+
module_or_path: _rivetkit_rivetkit_wasm.InitInput | Promise<_rivetkit_rivetkit_wasm.InitInput>;
|
|
1501
|
+
} | _rivetkit_rivetkit_wasm.InitInput | Promise<_rivetkit_rivetkit_wasm.InitInput> | undefined;
|
|
1475
1502
|
};
|
|
1503
|
+
sqlite: {
|
|
1504
|
+
backend: "local" | "remote";
|
|
1505
|
+
} | undefined;
|
|
1476
1506
|
noWelcome: boolean;
|
|
1477
1507
|
logging: {
|
|
1478
1508
|
baseLogger?: Logger | undefined;
|
package/dist/browser/client.js
CHANGED
|
@@ -193,8 +193,14 @@ function deconstructError(error, logger4, extraLog, exposeInternalError = false)
|
|
|
193
193
|
function stringifyError(error) {
|
|
194
194
|
if (error instanceof Error) {
|
|
195
195
|
if (typeof process !== "undefined" && getLogErrorStack()) {
|
|
196
|
-
|
|
197
|
-
|
|
196
|
+
let stack;
|
|
197
|
+
try {
|
|
198
|
+
stack = error.stack;
|
|
199
|
+
} catch {
|
|
200
|
+
stack = void 0;
|
|
201
|
+
}
|
|
202
|
+
return `${error.name}: ${error.message}${stack ? `
|
|
203
|
+
${stack}` : ""}`;
|
|
198
204
|
} else {
|
|
199
205
|
return `${error.name}: ${error.message}`;
|
|
200
206
|
}
|
|
@@ -225,7 +231,7 @@ function noopNext() {
|
|
|
225
231
|
// package.json
|
|
226
232
|
var package_default = {
|
|
227
233
|
name: "rivetkit",
|
|
228
|
-
version: "0.0.0-pr.4860.
|
|
234
|
+
version: "0.0.0-pr.4860.f43cf47",
|
|
229
235
|
description: "Lightweight libraries for building stateful actors on edge platforms",
|
|
230
236
|
license: "Apache-2.0",
|
|
231
237
|
keywords: [
|
|
@@ -386,6 +392,7 @@ var package_default = {
|
|
|
386
392
|
format: "biome format .",
|
|
387
393
|
"format:write": "biome format --write .",
|
|
388
394
|
test: "vitest run",
|
|
395
|
+
"test:platforms": "pnpm run build && RIVETKIT_INCLUDE_PLATFORM_TESTS=1 vitest run tests/platforms --passWithNoTests",
|
|
389
396
|
"test:watch": "vitest",
|
|
390
397
|
"dump-asyncapi": "tsx scripts/dump-asyncapi.ts",
|
|
391
398
|
"registry-config-schema-gen": "tsx scripts/registry-config-schema-gen.ts",
|
|
@@ -522,13 +529,13 @@ function getLogger(name = "default") {
|
|
|
522
529
|
}
|
|
523
530
|
|
|
524
531
|
// src/utils.ts
|
|
525
|
-
var
|
|
532
|
+
var VERSION = package_default.version;
|
|
526
533
|
var _userAgent;
|
|
527
534
|
function httpUserAgent() {
|
|
528
535
|
if (_userAgent !== void 0) {
|
|
529
536
|
return _userAgent;
|
|
530
537
|
}
|
|
531
|
-
let userAgent = `RivetKit/${
|
|
538
|
+
let userAgent = `RivetKit/${VERSION}`;
|
|
532
539
|
const navigatorObj = typeof navigator !== "undefined" ? navigator : void 0;
|
|
533
540
|
if (navigatorObj?.userAgent) userAgent += ` ${navigatorObj.userAgent}`;
|
|
534
541
|
_userAgent = userAgent;
|
|
@@ -584,7 +591,7 @@ function combineUrlPath(endpoint, path, queryParams) {
|
|
|
584
591
|
var EXTRA_ERROR_LOG = {
|
|
585
592
|
issues: "https://github.com/rivet-dev/rivet/issues",
|
|
586
593
|
support: "https://rivet.dev/discord",
|
|
587
|
-
version:
|
|
594
|
+
version: VERSION
|
|
588
595
|
};
|
|
589
596
|
|
|
590
597
|
// src/devtools-loader/log.ts
|
|
@@ -593,7 +600,7 @@ function logger() {
|
|
|
593
600
|
}
|
|
594
601
|
|
|
595
602
|
// src/devtools-loader/index.ts
|
|
596
|
-
var DEFAULT_DEVTOOLS_URL = (version =
|
|
603
|
+
var DEFAULT_DEVTOOLS_URL = (version = VERSION) => `https://releases.rivet.dev/rivet/latest/devtools/mod.js?v=${version}`;
|
|
597
604
|
var scriptId = "rivetkit-devtools-script";
|
|
598
605
|
function injectDevtools(config) {
|
|
599
606
|
if (!window) {
|