@replit/river 0.200.4 → 0.201.0
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/{chunk-BBTXTDJ5.js → chunk-52DVJUVZ.js} +2 -2
- package/dist/{chunk-Q7DD2FLX.js → chunk-7IUEEQP7.js} +10 -10
- package/dist/chunk-7IUEEQP7.js.map +1 -0
- package/dist/{chunk-GKBNAMHM.js → chunk-OZ3ITXW5.js} +5 -7
- package/dist/chunk-OZ3ITXW5.js.map +1 -0
- package/dist/{chunk-LL4CB5UD.js → chunk-PJ4GJ5CU.js} +332 -3
- package/dist/chunk-PJ4GJ5CU.js.map +1 -0
- package/dist/{chunk-6EORIAZJ.js → chunk-UBUD2LMZ.js} +4 -6
- package/dist/chunk-UBUD2LMZ.js.map +1 -0
- package/dist/{client-ba6815ae.d.ts → client-a32692b0.d.ts} +2 -2
- package/dist/{connection-d217c989.d.ts → connection-48d021ca.d.ts} +2 -2
- package/dist/{context-8d1ed9a1.d.ts → context-8d263a7f.d.ts} +2 -2
- package/dist/logging/index.d.cts +1 -1
- package/dist/logging/index.d.ts +1 -1
- package/dist/{message-45658364.d.ts → message-3def9ded.d.ts} +1 -1
- package/dist/router/index.cjs +7 -8
- package/dist/router/index.cjs.map +1 -1
- package/dist/router/index.d.cts +8 -8
- package/dist/router/index.d.ts +8 -8
- package/dist/router/index.js +323 -46
- package/dist/router/index.js.map +1 -1
- package/dist/{server-eb7d2cfd.d.ts → server-48d90a77.d.ts} +2 -2
- package/dist/{services-94e0afc3.d.ts → services-e71ea921.d.ts} +4 -4
- package/dist/testUtil/index.cjs +2616 -0
- package/dist/testUtil/index.cjs.map +1 -0
- package/dist/{util/testHelpers.d.cts → testUtil/index.d.cts} +27 -18
- package/dist/{util/testHelpers.d.ts → testUtil/index.d.ts} +27 -18
- package/dist/testUtil/index.js +370 -0
- package/dist/testUtil/index.js.map +1 -0
- package/dist/transport/impls/ws/client.cjs +2 -2
- package/dist/transport/impls/ws/client.cjs.map +1 -1
- package/dist/transport/impls/ws/client.d.cts +4 -4
- package/dist/transport/impls/ws/client.d.ts +4 -4
- package/dist/transport/impls/ws/client.js +4 -5
- package/dist/transport/impls/ws/client.js.map +1 -1
- package/dist/transport/impls/ws/server.cjs +2 -2
- package/dist/transport/impls/ws/server.cjs.map +1 -1
- package/dist/transport/impls/ws/server.d.cts +4 -4
- package/dist/transport/impls/ws/server.d.ts +4 -4
- package/dist/transport/impls/ws/server.js +4 -5
- package/dist/transport/impls/ws/server.js.map +1 -1
- package/dist/transport/index.cjs +2 -2
- package/dist/transport/index.cjs.map +1 -1
- package/dist/transport/index.d.cts +4 -4
- package/dist/transport/index.d.ts +4 -4
- package/dist/transport/index.js +6 -8
- package/package.json +3 -3
- package/dist/chunk-6EORIAZJ.js.map +0 -1
- package/dist/chunk-GKBNAMHM.js.map +0 -1
- package/dist/chunk-LL4CB5UD.js.map +0 -1
- package/dist/chunk-Q7DD2FLX.js.map +0 -1
- package/dist/chunk-RWVZCH26.js +0 -340
- package/dist/chunk-RWVZCH26.js.map +0 -1
- package/dist/chunk-ZVWJN6V2.js +0 -307
- package/dist/chunk-ZVWJN6V2.js.map +0 -1
- package/dist/util/testHelpers.cjs +0 -1563
- package/dist/util/testHelpers.cjs.map +0 -1
- package/dist/util/testHelpers.js +0 -250
- package/dist/util/testHelpers.js.map +0 -1
- /package/dist/{chunk-BBTXTDJ5.js.map → chunk-52DVJUVZ.js.map} +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { C as ClientTransport } from '../../../client-
|
|
2
|
-
import { c as TransportClientId } from '../../../message-
|
|
3
|
-
import { b as ProvidedClientTransportOptions } from '../../../context-
|
|
4
|
-
import { W as WebSocketConnection } from '../../../connection-
|
|
1
|
+
import { C as ClientTransport } from '../../../client-a32692b0.js';
|
|
2
|
+
import { c as TransportClientId } from '../../../message-3def9ded.js';
|
|
3
|
+
import { b as ProvidedClientTransportOptions } from '../../../context-8d263a7f.js';
|
|
4
|
+
import { W as WebSocketConnection } from '../../../connection-48d021ca.js';
|
|
5
5
|
import { W as WsLike } from '../../../wslike-e0b32dd5.js';
|
|
6
6
|
import '@sinclair/typebox/value';
|
|
7
7
|
import '@sinclair/typebox';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { C as ClientTransport } from '../../../client-
|
|
2
|
-
import { c as TransportClientId } from '../../../message-
|
|
3
|
-
import { b as ProvidedClientTransportOptions } from '../../../context-
|
|
4
|
-
import { W as WebSocketConnection } from '../../../connection-
|
|
1
|
+
import { C as ClientTransport } from '../../../client-a32692b0.js';
|
|
2
|
+
import { c as TransportClientId } from '../../../message-3def9ded.js';
|
|
3
|
+
import { b as ProvidedClientTransportOptions } from '../../../context-8d263a7f.js';
|
|
4
|
+
import { W as WebSocketConnection } from '../../../connection-48d021ca.js';
|
|
5
5
|
import { W as WsLike } from '../../../wslike-e0b32dd5.js';
|
|
6
6
|
import '@sinclair/typebox/value';
|
|
7
7
|
import '@sinclair/typebox';
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import {
|
|
2
2
|
ClientTransport
|
|
3
|
-
} from "../../../chunk-
|
|
3
|
+
} from "../../../chunk-OZ3ITXW5.js";
|
|
4
4
|
import {
|
|
5
5
|
WebSocketConnection
|
|
6
|
-
} from "../../../chunk-
|
|
7
|
-
import "../../../chunk-
|
|
6
|
+
} from "../../../chunk-52DVJUVZ.js";
|
|
7
|
+
import "../../../chunk-PJ4GJ5CU.js";
|
|
8
|
+
import "../../../chunk-7IUEEQP7.js";
|
|
8
9
|
import "../../../chunk-LHH5LQ7C.js";
|
|
9
|
-
import "../../../chunk-LL4CB5UD.js";
|
|
10
|
-
import "../../../chunk-Q7DD2FLX.js";
|
|
11
10
|
import "../../../chunk-AJGIY2UB.js";
|
|
12
11
|
|
|
13
12
|
// transport/impls/ws/client.ts
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../transport/impls/ws/client.ts"],"sourcesContent":["import { ClientTransport } from '../../client';\nimport { TransportClientId } from '../../message';\nimport { ProvidedClientTransportOptions } from '../../options';\nimport { WebSocketConnection } from './connection';\nimport { WsLike } from './wslike';\n\n/**\n * A transport implementation that uses a WebSocket connection with automatic reconnection.\n * @class\n * @extends Transport\n */\nexport class WebSocketClientTransport extends ClientTransport<WebSocketConnection> {\n /**\n * A function that returns a Promise that resolves to a websocket URL.\n */\n wsGetter: (to: TransportClientId) => Promise<WsLike> | WsLike;\n\n /**\n * Creates a new WebSocketClientTransport instance.\n * @param wsGetter A function that returns a Promise that resolves to a WebSocket instance.\n * @param clientId The ID of the client using the transport. This should be unique per session.\n * @param serverId The ID of the server this transport is connecting to.\n * @param providedOptions An optional object containing configuration options for the transport.\n */\n constructor(\n wsGetter: (to: TransportClientId) => Promise<WsLike> | WsLike,\n clientId: TransportClientId,\n providedOptions?: ProvidedClientTransportOptions,\n ) {\n super(clientId, providedOptions);\n this.wsGetter = wsGetter;\n }\n\n async createNewOutgoingConnection(to: string) {\n this.log?.info(`establishing a new websocket to ${to}`, {\n clientId: this.clientId,\n connectedTo: to,\n });\n\n const ws = await this.wsGetter(to);\n\n await new Promise<void>((resolve, reject) => {\n if (ws.readyState === ws.OPEN) {\n resolve();\n\n return;\n }\n\n if (ws.readyState === ws.CLOSING || ws.readyState === ws.CLOSED) {\n reject(new Error('ws is closing or closed'));\n\n return;\n }\n\n ws.onopen = () => {\n resolve();\n };\n\n ws.onclose = (evt) => {\n reject(new Error(evt.reason));\n };\n\n ws.onerror = (err) => {\n reject(new Error(err.message));\n };\n });\n\n const conn = new WebSocketConnection(ws);\n this.log?.info(`raw websocket to ${to} ok`, {\n clientId: this.clientId,\n connectedTo: to,\n ...conn.loggingMetadata,\n });\n\n return conn;\n }\n}\n"],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../../../../transport/impls/ws/client.ts"],"sourcesContent":["import { ClientTransport } from '../../client';\nimport { TransportClientId } from '../../message';\nimport { ProvidedClientTransportOptions } from '../../options';\nimport { WebSocketConnection } from './connection';\nimport { WsLike } from './wslike';\n\n/**\n * A transport implementation that uses a WebSocket connection with automatic reconnection.\n * @class\n * @extends Transport\n */\nexport class WebSocketClientTransport extends ClientTransport<WebSocketConnection> {\n /**\n * A function that returns a Promise that resolves to a websocket URL.\n */\n wsGetter: (to: TransportClientId) => Promise<WsLike> | WsLike;\n\n /**\n * Creates a new WebSocketClientTransport instance.\n * @param wsGetter A function that returns a Promise that resolves to a WebSocket instance.\n * @param clientId The ID of the client using the transport. This should be unique per session.\n * @param serverId The ID of the server this transport is connecting to.\n * @param providedOptions An optional object containing configuration options for the transport.\n */\n constructor(\n wsGetter: (to: TransportClientId) => Promise<WsLike> | WsLike,\n clientId: TransportClientId,\n providedOptions?: ProvidedClientTransportOptions,\n ) {\n super(clientId, providedOptions);\n this.wsGetter = wsGetter;\n }\n\n async createNewOutgoingConnection(to: string) {\n this.log?.info(`establishing a new websocket to ${to}`, {\n clientId: this.clientId,\n connectedTo: to,\n });\n\n const ws = await this.wsGetter(to);\n\n await new Promise<void>((resolve, reject) => {\n if (ws.readyState === ws.OPEN) {\n resolve();\n\n return;\n }\n\n if (ws.readyState === ws.CLOSING || ws.readyState === ws.CLOSED) {\n reject(new Error('ws is closing or closed'));\n\n return;\n }\n\n ws.onopen = () => {\n resolve();\n };\n\n ws.onclose = (evt) => {\n reject(new Error(evt.reason));\n };\n\n ws.onerror = (err) => {\n reject(new Error(err.message));\n };\n });\n\n const conn = new WebSocketConnection(ws);\n this.log?.info(`raw websocket to ${to} ok`, {\n clientId: this.clientId,\n connectedTo: to,\n ...conn.loggingMetadata,\n });\n\n return conn;\n }\n}\n"],"mappings":";;;;;;;;;;;;AAWO,IAAM,2BAAN,cAAuC,gBAAqC;AAAA;AAAA;AAAA;AAAA,EAIjF;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,EASA,YACE,UACA,UACA,iBACA;AACA,UAAM,UAAU,eAAe;AAC/B,SAAK,WAAW;AAAA,EAClB;AAAA,EAEA,MAAM,4BAA4B,IAAY;AAC5C,SAAK,KAAK,KAAK,mCAAmC,EAAE,IAAI;AAAA,MACtD,UAAU,KAAK;AAAA,MACf,aAAa;AAAA,IACf,CAAC;AAED,UAAM,KAAK,MAAM,KAAK,SAAS,EAAE;AAEjC,UAAM,IAAI,QAAc,CAAC,SAAS,WAAW;AAC3C,UAAI,GAAG,eAAe,GAAG,MAAM;AAC7B,gBAAQ;AAER;AAAA,MACF;AAEA,UAAI,GAAG,eAAe,GAAG,WAAW,GAAG,eAAe,GAAG,QAAQ;AAC/D,eAAO,IAAI,MAAM,yBAAyB,CAAC;AAE3C;AAAA,MACF;AAEA,SAAG,SAAS,MAAM;AAChB,gBAAQ;AAAA,MACV;AAEA,SAAG,UAAU,CAAC,QAAQ;AACpB,eAAO,IAAI,MAAM,IAAI,MAAM,CAAC;AAAA,MAC9B;AAEA,SAAG,UAAU,CAAC,QAAQ;AACpB,eAAO,IAAI,MAAM,IAAI,OAAO,CAAC;AAAA,MAC/B;AAAA,IACF,CAAC;AAED,UAAM,OAAO,IAAI,oBAAoB,EAAE;AACvC,SAAK,KAAK,KAAK,oBAAoB,EAAE,OAAO;AAAA,MAC1C,UAAU,KAAK;AAAA,MACf,aAAa;AAAA,MACb,GAAG,KAAK;AAAA,IACV,CAAC;AAED,WAAO;AAAA,EACT;AACF;","names":[]}
|
|
@@ -685,7 +685,7 @@ var SessionNoConnection = class extends IdentifiedSessionWithGracePeriod {
|
|
|
685
685
|
var import_api = require("@opentelemetry/api");
|
|
686
686
|
|
|
687
687
|
// package.json
|
|
688
|
-
var version = "0.
|
|
688
|
+
var version = "0.201.0";
|
|
689
689
|
|
|
690
690
|
// tracing/index.ts
|
|
691
691
|
function createSessionTelemetryInfo(sessionId, to, from, propagationCtx) {
|
|
@@ -1485,7 +1485,7 @@ var Transport = class {
|
|
|
1485
1485
|
}
|
|
1486
1486
|
};
|
|
1487
1487
|
|
|
1488
|
-
//
|
|
1488
|
+
// transport/stringifyError.ts
|
|
1489
1489
|
function coerceErrorString(err) {
|
|
1490
1490
|
if (err instanceof Error) {
|
|
1491
1491
|
return err.message || "unknown reason";
|