@replit/river 0.26.6 → 0.26.8
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-3NZ73HXL.js → chunk-CATCCJAL.js} +4 -4
- package/dist/{chunk-MZM234IB.js → chunk-KTS4HBYE.js} +1 -1
- package/dist/chunk-KTS4HBYE.js.map +1 -0
- package/dist/{chunk-H677UET6.js → chunk-NHXIQELK.js} +2 -2
- package/dist/{chunk-5INVLQT5.js → chunk-QEVXZ3I7.js} +14 -4
- package/dist/chunk-QEVXZ3I7.js.map +1 -0
- package/dist/{chunk-APGOIQC4.js → chunk-QXQG6ZFZ.js} +2 -2
- package/dist/{chunk-J7AQMYUQ.js → chunk-SIRVFV3D.js} +4 -4
- package/dist/{chunk-CER7XNCN.js → chunk-XMXSGTU2.js} +4 -4
- package/dist/{chunk-H2RVJ32Z.js → chunk-ZFSQNWYX.js} +2 -2
- package/dist/{chunk-H2RVJ32Z.js.map → chunk-ZFSQNWYX.js.map} +1 -1
- package/dist/{client-96810511.d.ts → client-1229b53d.d.ts} +2 -2
- package/dist/connection-c5ffd44e.d.ts +32 -0
- package/dist/{handshake-65e0e848.d.ts → handshake-02a61755.d.ts} +3 -1
- package/dist/logging/index.cjs.map +1 -1
- package/dist/logging/index.d.cts +1 -1
- package/dist/logging/index.d.ts +1 -1
- package/dist/logging/index.js +1 -1
- package/dist/{message-e917ee98.d.ts → message-3edb8fac.d.ts} +1 -0
- package/dist/router/index.cjs +1 -1
- 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 +2 -2
- package/dist/{server-b8aaf116.d.ts → server-89076d9a.d.ts} +3 -2
- package/dist/{services-40e7c5cf.d.ts → services-4478e99b.d.ts} +3 -3
- package/dist/transport/impls/ws/client.cjs +13 -3
- 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 +6 -6
- package/dist/transport/impls/ws/server.cjs +27 -5
- package/dist/transport/impls/ws/server.cjs.map +1 -1
- package/dist/transport/impls/ws/server.d.cts +6 -5
- package/dist/transport/impls/ws/server.d.ts +6 -5
- package/dist/transport/impls/ws/server.js +20 -8
- package/dist/transport/impls/ws/server.js.map +1 -1
- package/dist/transport/index.cjs +1 -1
- 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 -6
- package/dist/util/testHelpers.cjs +1 -1
- package/dist/util/testHelpers.cjs.map +1 -1
- package/dist/util/testHelpers.d.cts +4 -4
- package/dist/util/testHelpers.d.ts +4 -4
- package/dist/util/testHelpers.js +3 -3
- package/package.json +1 -1
- package/dist/chunk-5INVLQT5.js.map +0 -1
- package/dist/chunk-MZM234IB.js.map +0 -1
- package/dist/connection-48133ec3.d.ts +0 -11
- /package/dist/{chunk-3NZ73HXL.js.map → chunk-CATCCJAL.js.map} +0 -0
- /package/dist/{chunk-H677UET6.js.map → chunk-NHXIQELK.js.map} +0 -0
- /package/dist/{chunk-APGOIQC4.js.map → chunk-QXQG6ZFZ.js.map} +0 -0
- /package/dist/{chunk-J7AQMYUQ.js.map → chunk-SIRVFV3D.js.map} +0 -0
- /package/dist/{chunk-CER7XNCN.js.map → chunk-XMXSGTU2.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 '../../../handshake-
|
|
4
|
-
import { W as WebSocketConnection } from '../../../connection-
|
|
1
|
+
import { C as ClientTransport } from '../../../client-1229b53d.js';
|
|
2
|
+
import { c as TransportClientId } from '../../../message-3edb8fac.js';
|
|
3
|
+
import { b as ProvidedClientTransportOptions } from '../../../handshake-02a61755.js';
|
|
4
|
+
import { W as WebSocketConnection } from '../../../connection-c5ffd44e.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 '../../../handshake-
|
|
4
|
-
import { W as WebSocketConnection } from '../../../connection-
|
|
1
|
+
import { C as ClientTransport } from '../../../client-1229b53d.js';
|
|
2
|
+
import { c as TransportClientId } from '../../../message-3edb8fac.js';
|
|
3
|
+
import { b as ProvidedClientTransportOptions } from '../../../handshake-02a61755.js';
|
|
4
|
+
import { W as WebSocketConnection } from '../../../connection-c5ffd44e.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,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
ClientTransport
|
|
3
|
-
} from "../../../chunk-
|
|
3
|
+
} from "../../../chunk-XMXSGTU2.js";
|
|
4
4
|
import {
|
|
5
5
|
WebSocketConnection
|
|
6
|
-
} from "../../../chunk-
|
|
7
|
-
import "../../../chunk-
|
|
8
|
-
import "../../../chunk-
|
|
9
|
-
import "../../../chunk-
|
|
10
|
-
import "../../../chunk-
|
|
6
|
+
} from "../../../chunk-QEVXZ3I7.js";
|
|
7
|
+
import "../../../chunk-CATCCJAL.js";
|
|
8
|
+
import "../../../chunk-KTS4HBYE.js";
|
|
9
|
+
import "../../../chunk-NHXIQELK.js";
|
|
10
|
+
import "../../../chunk-ZFSQNWYX.js";
|
|
11
11
|
import "../../../chunk-4PVU7J25.js";
|
|
12
12
|
|
|
13
13
|
// transport/impls/ws/client.ts
|
|
@@ -103,11 +103,21 @@ var Connection = class {
|
|
|
103
103
|
};
|
|
104
104
|
|
|
105
105
|
// transport/impls/ws/connection.ts
|
|
106
|
+
var WS_HEALTHY_CLOSE_CODE = 1e3;
|
|
106
107
|
var WebSocketConnection = class extends Connection {
|
|
107
108
|
ws;
|
|
108
|
-
|
|
109
|
+
extras;
|
|
110
|
+
get loggingMetadata() {
|
|
111
|
+
const metadata = super.loggingMetadata;
|
|
112
|
+
if (this.extras) {
|
|
113
|
+
metadata.extras = this.extras;
|
|
114
|
+
}
|
|
115
|
+
return metadata;
|
|
116
|
+
}
|
|
117
|
+
constructor(ws, extras) {
|
|
109
118
|
super();
|
|
110
119
|
this.ws = ws;
|
|
120
|
+
this.extras = extras;
|
|
111
121
|
this.ws.binaryType = "arraybuffer";
|
|
112
122
|
let didError = false;
|
|
113
123
|
this.ws.onerror = () => {
|
|
@@ -140,7 +150,7 @@ var WebSocketConnection = class extends Connection {
|
|
|
140
150
|
return true;
|
|
141
151
|
}
|
|
142
152
|
close() {
|
|
143
|
-
this.ws.close();
|
|
153
|
+
this.ws.close(WS_HEALTHY_CLOSE_CODE);
|
|
144
154
|
}
|
|
145
155
|
};
|
|
146
156
|
|
|
@@ -669,7 +679,7 @@ var SessionNoConnection = class extends IdentifiedSessionWithGracePeriod {
|
|
|
669
679
|
var import_api = require("@opentelemetry/api");
|
|
670
680
|
|
|
671
681
|
// package.json
|
|
672
|
-
var version = "0.26.
|
|
682
|
+
var version = "0.26.8";
|
|
673
683
|
|
|
674
684
|
// tracing/index.ts
|
|
675
685
|
function createSessionTelemetryInfo(sessionId, to, from, propagationCtx) {
|
|
@@ -1786,6 +1796,16 @@ var ServerTransport = class extends Transport {
|
|
|
1786
1796
|
};
|
|
1787
1797
|
|
|
1788
1798
|
// transport/impls/ws/server.ts
|
|
1799
|
+
function cleanHeaders(headers) {
|
|
1800
|
+
const cleanedHeaders = {};
|
|
1801
|
+
for (const [key, value] of Object.entries(headers)) {
|
|
1802
|
+
if (!key.startsWith("sec-") && value) {
|
|
1803
|
+
const cleanedValue = Array.isArray(value) ? value[0] : value;
|
|
1804
|
+
cleanedHeaders[key] = cleanedValue;
|
|
1805
|
+
}
|
|
1806
|
+
}
|
|
1807
|
+
return cleanedHeaders;
|
|
1808
|
+
}
|
|
1789
1809
|
var WebSocketServerTransport = class extends ServerTransport {
|
|
1790
1810
|
wss;
|
|
1791
1811
|
constructor(wss, clientId, providedOptions) {
|
|
@@ -1793,8 +1813,10 @@ var WebSocketServerTransport = class extends ServerTransport {
|
|
|
1793
1813
|
this.wss = wss;
|
|
1794
1814
|
this.wss.on("connection", this.connectionHandler);
|
|
1795
1815
|
}
|
|
1796
|
-
connectionHandler = (ws) => {
|
|
1797
|
-
const conn = new WebSocketConnection(ws
|
|
1816
|
+
connectionHandler = (ws, req) => {
|
|
1817
|
+
const conn = new WebSocketConnection(ws, {
|
|
1818
|
+
headers: cleanHeaders(req.headersDistinct)
|
|
1819
|
+
});
|
|
1798
1820
|
this.handleConnection(conn);
|
|
1799
1821
|
};
|
|
1800
1822
|
close() {
|