@dxos/network-manager 0.1.58-main.f5feb2a → 0.1.58-main.fa022ee
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/lib/browser/{chunk-CNQ55TFQ.mjs → chunk-66HPNABI.mjs} +19 -9
- package/dist/lib/browser/{chunk-CNQ55TFQ.mjs.map → chunk-66HPNABI.mjs.map} +3 -3
- package/dist/lib/browser/index.mjs +1 -1
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/testing/index.mjs +1 -1
- package/dist/lib/node/index.cjs +18 -8
- package/dist/lib/node/index.cjs.map +3 -3
- package/dist/lib/node/meta.json +1 -1
- package/dist/lib/node/testing/index.cjs +18 -8
- package/dist/lib/node/testing/index.cjs.map +3 -3
- package/dist/types/src/transport/simplepeer-transport.d.ts.map +1 -1
- package/package.json +17 -17
- package/src/transport/simplepeer-transport.ts +3 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"simplepeer-transport.d.ts","sourceRoot":"","sources":["../../../../src/transport/simplepeer-transport.ts"],"names":[],"mappings":";AAQA,OAAO,EAAE,KAAK,EAAE,MAAM,aAAa,CAAC;AACpC,OAAO,EAAE,WAAW,EAAS,MAAM,aAAa,CAAC;AAIjD,OAAO,EAAE,MAAM,EAAE,MAAM,uCAAuC,CAAC;AAE/D,OAAO,EAAE,SAAS,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAG1D,MAAM,MAAM,yBAAyB,GAAG;IACtC,SAAS,EAAE,OAAO,CAAC;IACnB,MAAM,EAAE,MAAM,CAAC,eAAe,CAAC;IAC/B,YAAY,CAAC,EAAE,GAAG,CAAC;IACnB,UAAU,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;CAC/C,CAAC;AAEF;;GAEG;AACH,qBAAa,mBAAoB,YAAW,SAAS;IAUvC,OAAO,CAAC,QAAQ,CAAC,MAAM;IATnC,OAAO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AC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dxos/network-manager",
|
|
3
|
-
"version": "0.1.58-main.
|
|
3
|
+
"version": "0.1.58-main.fa022ee",
|
|
4
4
|
"description": "Network Manager",
|
|
5
5
|
"homepage": "https://dxos.org",
|
|
6
6
|
"bugs": "https://github.com/dxos/dxos/issues",
|
|
@@ -30,21 +30,21 @@
|
|
|
30
30
|
"tiny-invariant": "^1.3.1",
|
|
31
31
|
"ws": "^7.4.4",
|
|
32
32
|
"xor-distance": "^2.0.0",
|
|
33
|
-
"@dxos/async": "0.1.58-main.
|
|
34
|
-
"@dxos/codec-protobuf": "0.1.58-main.
|
|
35
|
-
"@dxos/context": "0.1.58-main.
|
|
36
|
-
"@dxos/credentials": "0.1.58-main.
|
|
37
|
-
"@dxos/crypto": "0.1.58-main.
|
|
38
|
-
"@dxos/debug": "0.1.58-main.
|
|
39
|
-
"@dxos/invariant": "0.1.58-main.
|
|
40
|
-
"@dxos/keys": "0.1.58-main.
|
|
41
|
-
"@dxos/log": "0.1.58-main.
|
|
42
|
-
"@dxos/messaging": "0.1.58-main.
|
|
43
|
-
"@dxos/node-std": "0.1.58-main.
|
|
44
|
-
"@dxos/protocols": "0.1.58-main.
|
|
45
|
-
"@dxos/rpc": "0.1.58-main.
|
|
46
|
-
"@dxos/teleport": "0.1.58-main.
|
|
47
|
-
"@dxos/util": "0.1.58-main.
|
|
33
|
+
"@dxos/async": "0.1.58-main.fa022ee",
|
|
34
|
+
"@dxos/codec-protobuf": "0.1.58-main.fa022ee",
|
|
35
|
+
"@dxos/context": "0.1.58-main.fa022ee",
|
|
36
|
+
"@dxos/credentials": "0.1.58-main.fa022ee",
|
|
37
|
+
"@dxos/crypto": "0.1.58-main.fa022ee",
|
|
38
|
+
"@dxos/debug": "0.1.58-main.fa022ee",
|
|
39
|
+
"@dxos/invariant": "0.1.58-main.fa022ee",
|
|
40
|
+
"@dxos/keys": "0.1.58-main.fa022ee",
|
|
41
|
+
"@dxos/log": "0.1.58-main.fa022ee",
|
|
42
|
+
"@dxos/messaging": "0.1.58-main.fa022ee",
|
|
43
|
+
"@dxos/node-std": "0.1.58-main.fa022ee",
|
|
44
|
+
"@dxos/protocols": "0.1.58-main.fa022ee",
|
|
45
|
+
"@dxos/rpc": "0.1.58-main.fa022ee",
|
|
46
|
+
"@dxos/teleport": "0.1.58-main.fa022ee",
|
|
47
|
+
"@dxos/util": "0.1.58-main.fa022ee"
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|
|
50
50
|
"@swc-node/register": "1.5.4",
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
"earljs": "~0.1.10",
|
|
55
55
|
"fast-check": "~3.3.0",
|
|
56
56
|
"typescript": "^5.2.2",
|
|
57
|
-
"@dxos/signal": "0.1.58-main.
|
|
57
|
+
"@dxos/signal": "0.1.58-main.fa022ee"
|
|
58
58
|
},
|
|
59
59
|
"publishConfig": {
|
|
60
60
|
"access": "public"
|
|
@@ -72,12 +72,9 @@ export class SimplePeerTransport implements Transport {
|
|
|
72
72
|
} else {
|
|
73
73
|
this.errors.raise(new UnknownProtocolError('unknown RTCError', err));
|
|
74
74
|
}
|
|
75
|
-
|
|
76
|
-
// Safari specific? are all errors of code: "DATA_CHANNEL_ERROR" connection aborts?
|
|
77
|
-
} else if (err.name === 'InvalidStateError') {
|
|
78
|
-
this.errors.raise(new ConnectionResetError('safari WebRTC error', err));
|
|
79
75
|
// catch more generic simple-peer errors: https://github.com/feross/simple-peer/blob/master/README.md#error-codes
|
|
80
76
|
} else if ('code' in err) {
|
|
77
|
+
log.info('simple-peer error', err);
|
|
81
78
|
switch (err.code) {
|
|
82
79
|
case 'ERR_WEBRTC_SUPPORT':
|
|
83
80
|
this.errors.raise(new ProtocolError('WebRTC not supported', err));
|
|
@@ -96,12 +93,13 @@ export class SimplePeerTransport implements Transport {
|
|
|
96
93
|
this.errors.raise(new Error('unknown simple-peer error'));
|
|
97
94
|
}
|
|
98
95
|
} else {
|
|
96
|
+
log.info('unknown peer connection error', err);
|
|
99
97
|
this.errors.raise(err);
|
|
100
98
|
}
|
|
101
99
|
|
|
102
100
|
// Try to gather additional information about the connection.
|
|
103
101
|
try {
|
|
104
|
-
if (typeof (this._peer as any)?._pc
|
|
102
|
+
if (typeof (this._peer as any)?._pc?.getStats === 'function') {
|
|
105
103
|
(this._peer as any)._pc.getStats().then((stats: any) => {
|
|
106
104
|
log.warn('report after webrtc error', {
|
|
107
105
|
config: this.params.webrtcConfig,
|