@stream-io/video-client 1.61.0 → 1.61.1
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/CHANGELOG.md +6 -0
- package/dist/index.browser.es.js +14 -5
- package/dist/index.browser.es.js.map +1 -1
- package/dist/index.cjs.js +14 -5
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.es.js +14 -5
- package/dist/index.es.js.map +1 -1
- package/package.json +1 -1
- package/src/reporting/ClientEventReporter.ts +7 -2
- package/src/reporting/__tests__/ClientEventReporter.test.ts +2 -2
- package/src/rtc/BasePeerConnection.ts +6 -1
- package/src/rtc/__tests__/Publisher.test.ts +50 -0
package/dist/index.es.js
CHANGED
|
@@ -5082,7 +5082,7 @@ const toIceCandidate = (iceTrickle) => {
|
|
|
5082
5082
|
}
|
|
5083
5083
|
};
|
|
5084
5084
|
|
|
5085
|
-
const version = "1.61.
|
|
5085
|
+
const version = "1.61.1";
|
|
5086
5086
|
const [major, minor, patch] = version.split('.');
|
|
5087
5087
|
let sdkInfo = {
|
|
5088
5088
|
type: SdkType.PLAIN_JAVASCRIPT,
|
|
@@ -8755,7 +8755,12 @@ class BasePeerConnection {
|
|
|
8755
8755
|
}
|
|
8756
8756
|
// we can't recover from a failed connection state (contrary to ICE)
|
|
8757
8757
|
if (state === 'failed') {
|
|
8758
|
-
|
|
8758
|
+
const reason = this.iceHasEverConnected
|
|
8759
|
+
? ReconnectReason.CONNECTION_FAILED
|
|
8760
|
+
: ReconnectReason.ICE_NEVER_CONNECTED;
|
|
8761
|
+
clearTimeout(this.preConnectStuckTimeout);
|
|
8762
|
+
this.preConnectStuckTimeout = undefined;
|
|
8763
|
+
this.onReconnectionNeeded?.(WebsocketReconnectStrategy.REJOIN, reason, this.peerType);
|
|
8759
8764
|
return;
|
|
8760
8765
|
}
|
|
8761
8766
|
this.handleConnectionStateUpdate(state);
|
|
@@ -19632,11 +19637,11 @@ class StreamClient {
|
|
|
19632
19637
|
return await this.wsConnection.connect(this.defaultWSTimeout);
|
|
19633
19638
|
};
|
|
19634
19639
|
getSdkVersion = () => this.options.clientAppIdentifier?.sdkVersion ||
|
|
19635
|
-
"1.61.
|
|
19640
|
+
"1.61.1";
|
|
19636
19641
|
getUserAgent = () => {
|
|
19637
19642
|
if (!this.cachedUserAgent) {
|
|
19638
19643
|
const { clientAppIdentifier = {} } = this.options;
|
|
19639
|
-
const { sdkName = 'js', sdkVersion = "1.61.
|
|
19644
|
+
const { sdkName = 'js', sdkVersion = "1.61.1", ...extras } = clientAppIdentifier;
|
|
19640
19645
|
this.cachedUserAgent = [
|
|
19641
19646
|
`stream-video-${sdkName}-v${sdkVersion}`,
|
|
19642
19647
|
...Object.entries(extras).map(([key, value]) => `${key}=${value}`),
|
|
@@ -20171,7 +20176,11 @@ class ClientEventReporter {
|
|
|
20171
20176
|
return;
|
|
20172
20177
|
}
|
|
20173
20178
|
if (event.state === 'failed') {
|
|
20174
|
-
|
|
20179
|
+
const iceConnected = event.iceConnectionState === 'connected' ||
|
|
20180
|
+
event.iceConnectionState === 'completed';
|
|
20181
|
+
this.emitPeerConnectionFailure(cid, role, iceConnected ? 'DTLS_CONNECTIVITY_FAILED' : 'ICE_CONNECTIVITY_FAILED', iceConnected
|
|
20182
|
+
? 'DTLS connectivity checks failed'
|
|
20183
|
+
: 'ICE connectivity checks failed');
|
|
20175
20184
|
return;
|
|
20176
20185
|
}
|
|
20177
20186
|
switch (event.state) {
|