@vindral/web-sdk 4.2.0-24-g5a70e2f5 → 4.2.0-26-g0fa621b5
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/{D3Z2pdQb.js → B4Y3kCsd.js} +66 -18
- package/{BYPrwk75.js → DEr08j58.js} +1 -1
- package/core.js +1 -1
- package/legacy.es.js +66 -18
- package/legacy.umd.js +3 -3
- package/package.json +1 -1
- package/player.js +2 -2
- package/vindral-player-component.js +2 -2
|
@@ -3774,7 +3774,7 @@ var tc = class {
|
|
|
3774
3774
|
}
|
|
3775
3775
|
};
|
|
3776
3776
|
} catch (t) {
|
|
3777
|
-
return b($s, e).
|
|
3777
|
+
return b($s, e).warn("Error reading object", { error: t }), {
|
|
3778
3778
|
done: !0,
|
|
3779
3779
|
value: void 0
|
|
3780
3780
|
};
|
|
@@ -5251,13 +5251,13 @@ var Od = /* @__PURE__ */ new WeakMap(), kd = /* @__PURE__ */ new WeakMap(), Ad =
|
|
|
5251
5251
|
case J.AnnounceOk:
|
|
5252
5252
|
{
|
|
5253
5253
|
let t = b(Md, n).current().get(e.namespace.join("/"));
|
|
5254
|
-
t || b(jd, n).
|
|
5254
|
+
t || b(jd, n).warn("No announcement found", e), t == null || t.state.onOk(e);
|
|
5255
5255
|
}
|
|
5256
5256
|
break;
|
|
5257
5257
|
case J.AnnounceError:
|
|
5258
5258
|
{
|
|
5259
5259
|
let t = b(Md, n).current().get(e.namespace.join("/"));
|
|
5260
|
-
t || b(jd, n).
|
|
5260
|
+
t || b(jd, n).warn("No announcement found", e), t == null || t.state.onError(e);
|
|
5261
5261
|
}
|
|
5262
5262
|
break;
|
|
5263
5263
|
default: break;
|
|
@@ -5521,7 +5521,7 @@ var Yd = 2e3, Xd = /* @__PURE__ */ new WeakMap(), Zd = /* @__PURE__ */ new WeakM
|
|
|
5521
5521
|
case J.SubscribeError:
|
|
5522
5522
|
{
|
|
5523
5523
|
let t = b(Zd, n).current().get(e.id);
|
|
5524
|
-
t || b($d, n).
|
|
5524
|
+
t || b($d, n).warn("No subscription found", e), t == null || t.onError(e), y(ef, n, rf).call(n, e.id);
|
|
5525
5525
|
}
|
|
5526
5526
|
break;
|
|
5527
5527
|
case J.SubscribeDone:
|
|
@@ -5620,7 +5620,9 @@ function mf(e) {
|
|
|
5620
5620
|
return t(function* () {
|
|
5621
5621
|
var t, r;
|
|
5622
5622
|
switch (b(uf, n).debug("received message", e), yield (t = n.subscriber) == null ? void 0 : t.onMessage(e), yield (r = n.publisher) == null ? void 0 : r.onMessage(e), e.type) {
|
|
5623
|
-
case J.Goaway:
|
|
5623
|
+
case J.Goaway:
|
|
5624
|
+
b(uf, n).info("received GoAway", e);
|
|
5625
|
+
break;
|
|
5624
5626
|
default: break;
|
|
5625
5627
|
}
|
|
5626
5628
|
})();
|
|
@@ -5835,7 +5837,7 @@ function zf(e) {
|
|
|
5835
5837
|
var Bf = /* @__PURE__ */ new WeakMap(), Vf = /* @__PURE__ */ new WeakMap(), Hf = /* @__PURE__ */ new WeakMap(), Uf = /* @__PURE__ */ new WeakMap(), Wf = /* @__PURE__ */ new WeakMap(), Gf = /* @__PURE__ */ new WeakMap(), Kf = /* @__PURE__ */ new WeakSet(), qf = class {
|
|
5836
5838
|
constructor(e, t, n) {
|
|
5837
5839
|
S(this, Kf), v(this, Bf, void 0), v(this, Vf, void 0), v(this, Hf, new ke(100)), v(this, Uf, void 0), v(this, Wf, 0), v(this, Gf, O.get().createContext("WebTransportConnection")), x(Uf, this, n), x(Bf, this, e), x(Vf, this, t), y(Kf, this, Jf).call(this).catch((e) => {
|
|
5838
|
-
b(Gf, this).
|
|
5840
|
+
b(Gf, this).warn("Incoming streams handling ended with error", e), b(Vf, this).markPostHandshake(), b(Hf, this).close();
|
|
5839
5841
|
}), b(Bf, this).closed.then(() => {
|
|
5840
5842
|
b(Vf, this).markPostHandshake(), b(Hf, this).close();
|
|
5841
5843
|
});
|
|
@@ -5914,7 +5916,12 @@ function Zf() {
|
|
|
5914
5916
|
let n = Iu.wrapWebsocket(t), r = zu(n, e.role).catch((e) => {
|
|
5915
5917
|
throw Yf.warn("MoQ handshake failed, closing WebSocket", { error: e }), t.close(), e;
|
|
5916
5918
|
});
|
|
5917
|
-
|
|
5919
|
+
e.handshakePipelining || (yield r);
|
|
5920
|
+
let i = new pf(new Rf(t, n), e.authToken);
|
|
5921
|
+
return Yf.info("connected", {
|
|
5922
|
+
url: e.wsUrl || e.url,
|
|
5923
|
+
transport: "websocket"
|
|
5924
|
+
}), i;
|
|
5918
5925
|
}), Zf.apply(this, arguments);
|
|
5919
5926
|
}
|
|
5920
5927
|
function Qf(e) {
|
|
@@ -5929,7 +5936,12 @@ function $f() {
|
|
|
5929
5936
|
let r = yield n.createBidirectionalStream(), i = Iu.wrapWebTransport(r), a = zu(i, e.role).catch(() => {
|
|
5930
5937
|
n.close();
|
|
5931
5938
|
});
|
|
5932
|
-
|
|
5939
|
+
e.handshakePipelining || (yield a);
|
|
5940
|
+
let o = new pf(new qf(n, i, e.url.toString()), e.authToken);
|
|
5941
|
+
return Yf.info("connected", {
|
|
5942
|
+
url: e.url,
|
|
5943
|
+
transport: "webtransport"
|
|
5944
|
+
}), o;
|
|
5933
5945
|
}), $f.apply(this, arguments);
|
|
5934
5946
|
}
|
|
5935
5947
|
function ep(e) {
|
|
@@ -6367,7 +6379,7 @@ var rm = class {
|
|
|
6367
6379
|
}
|
|
6368
6380
|
onFragment(e, t, n, r, i) {
|
|
6369
6381
|
var a;
|
|
6370
|
-
b(Xp, this) === void 0 && (x(Xp, this, e), x(Zp, this, t), x(Qp, this, n), x($p, this, r), b(Jp, this).
|
|
6382
|
+
b(Xp, this) === void 0 && (x(Xp, this, e), x(Zp, this, t), x(Qp, this, n), x($p, this, r), b(Jp, this).debug("group start", {
|
|
6371
6383
|
name: b(Yp, this).name,
|
|
6372
6384
|
groupId: e,
|
|
6373
6385
|
startTimeMs: r,
|
|
@@ -6385,7 +6397,7 @@ var rm = class {
|
|
|
6385
6397
|
}
|
|
6386
6398
|
};
|
|
6387
6399
|
function im() {
|
|
6388
|
-
b(Xp, this) !== void 0 && b($p, this) !== void 0 && b(em, this) !== void 0 && b(Jp, this).
|
|
6400
|
+
b(Xp, this) !== void 0 && b($p, this) !== void 0 && b(em, this) !== void 0 && b(Jp, this).debug("group end", {
|
|
6389
6401
|
name: b(Yp, this).name,
|
|
6390
6402
|
groupId: b(Xp, this),
|
|
6391
6403
|
startTimeMs: b($p, this),
|
|
@@ -6422,7 +6434,7 @@ var um = class {
|
|
|
6422
6434
|
n.updateBaseMediaDecodeTime(n.baseMediaDecodeTime() - o);
|
|
6423
6435
|
let l = e.track.timestampRange();
|
|
6424
6436
|
if (l && i >= l[1]) break;
|
|
6425
|
-
b(cm, e).
|
|
6437
|
+
b(cm, e).trace("fragment", C(C({}, s), {}, {
|
|
6426
6438
|
startTime: i,
|
|
6427
6439
|
endTime: a,
|
|
6428
6440
|
subscribeId: t.subscribeId,
|
|
@@ -6652,6 +6664,10 @@ function km(e) {
|
|
|
6652
6664
|
return t(function* () {
|
|
6653
6665
|
let t = e - T(1), r = n.timeline(), i = r[0], a = r[r.length - 1];
|
|
6654
6666
|
if (!i || !a || a.wallclock - i.wallclock > vm) return;
|
|
6667
|
+
b(bm, n).debug("backfilling timeline", {
|
|
6668
|
+
currentGroupId: e,
|
|
6669
|
+
backfillGroupId: t
|
|
6670
|
+
});
|
|
6655
6671
|
let o = w.fromPromise(kp.subscribe(b(Cm, n), new rp().name(b(wm, n)).groupOrder("ascending").range(t, t).build()));
|
|
6656
6672
|
return y(Em, n, Om).call(n, o);
|
|
6657
6673
|
})();
|
|
@@ -7599,7 +7615,7 @@ var pg = (e, t) => {
|
|
|
7599
7615
|
}), e(this, "onMessage", (e, t) => {
|
|
7600
7616
|
this.websockets.length !== 0 && this.options.onMessage(e, t.data);
|
|
7601
7617
|
}), e(this, "onError", () => {
|
|
7602
|
-
this.logger.
|
|
7618
|
+
this.logger.warn("On error", C({}, this.options)), this.close("one websocket had an error"), this.emit("error", new g("WebSocket error", {
|
|
7603
7619
|
code: "websocket_error",
|
|
7604
7620
|
isFatal: !1
|
|
7605
7621
|
}));
|
|
@@ -7917,9 +7933,9 @@ function zg() {
|
|
|
7917
7933
|
}), b(Dg, e)) : (de(typeof i == "string", "Edge URL is expected to be a string"), e.connectionImpl = yield xg.start(e.emitter, e.logger, C(C({}, e.config), {}, {
|
|
7918
7934
|
connectInfo: n,
|
|
7919
7935
|
edgeUrl: i
|
|
7920
|
-
}), b(Dg, e))), t.reset(), x(Mg, e, (a = b(Mg, e), a++, a)), x(Ag, e, 0), x(Pg, e, Date.now()), b(Ng, e) || x(Ng, e, b(Pg, e)), yield e.connectionImpl.closed();
|
|
7936
|
+
}), b(Dg, e))), t.reset(), x(Mg, e, (a = b(Mg, e), a++, a)), x(Ag, e, 0), x(Pg, e, Date.now()), b(Ng, e) || x(Ng, e, b(Pg, e)), yield e.connectionImpl.closed(), e.logger.info("Connection closed");
|
|
7921
7937
|
} catch (n) {
|
|
7922
|
-
e.logger.
|
|
7938
|
+
e.logger.warn("Failed to connect", n);
|
|
7923
7939
|
let r = t.shiftedEdge();
|
|
7924
7940
|
r && e.emitter.emit("telemetry event", {
|
|
7925
7941
|
code: "shifted_edge",
|
|
@@ -10429,15 +10445,47 @@ var uv = class {
|
|
|
10429
10445
|
if (!hn(e) || !i.isSupportedVideoCodecProfile(e.codec, e.codecString)) return !1;
|
|
10430
10446
|
if (!i.willUseMediaSource()) return i.isWebCodecsVideoAvailable(i.channelId) ? i.webCodecsRenditionSupport.checkVideoSupport(e) : !0;
|
|
10431
10447
|
let n = yield ns(e);
|
|
10432
|
-
if (!n.supported
|
|
10448
|
+
if (!n.supported) return !1;
|
|
10449
|
+
if (e.codec === "av1" && !n.smooth && !n.powerEfficient) return i.logger.debug("discarding av1 rendition, neither smooth nor power efficient", {
|
|
10450
|
+
codecString: e.codecString,
|
|
10451
|
+
width: e.width,
|
|
10452
|
+
height: e.height,
|
|
10453
|
+
bitRate: e.bitRate,
|
|
10454
|
+
capabilities: n
|
|
10455
|
+
}), !1;
|
|
10433
10456
|
let r = i.options.getOverride("maxVideoBitRate", i.channelId);
|
|
10434
10457
|
return r ? r >= e.bitRate : !0;
|
|
10435
10458
|
});
|
|
10436
10459
|
return function(t) {
|
|
10437
10460
|
return e.apply(this, arguments);
|
|
10438
10461
|
};
|
|
10439
|
-
}())), r = e.filter((e, t) => n[t]), a =
|
|
10440
|
-
|
|
10462
|
+
}())), r = e.filter((e, t) => n[t]), a = e.filter((e, t) => !n[t]);
|
|
10463
|
+
a.length > 0 && i.logger.debug("unsupported renditions filtered out", { renditions: a.map((e) => C(C({
|
|
10464
|
+
codec: e.codec,
|
|
10465
|
+
codecString: e.codecString
|
|
10466
|
+
}, hn(e) ? {
|
|
10467
|
+
width: e.width,
|
|
10468
|
+
height: e.height
|
|
10469
|
+
} : {}), {}, { bitRate: e.bitRate })) });
|
|
10470
|
+
let o = r.filter((e) => e.codec === "h264").reverse()[0], s = r.filter((e) => e.codec === "av1").reverse()[0];
|
|
10471
|
+
return o && s && o.width > s.width && o.height > s.height && (i.logger.debug("discarding av1 renditions, h264 ladder has higher resolution", {
|
|
10472
|
+
bestH264: {
|
|
10473
|
+
width: o.width,
|
|
10474
|
+
height: o.height,
|
|
10475
|
+
bitRate: o.bitRate
|
|
10476
|
+
},
|
|
10477
|
+
bestAV1: {
|
|
10478
|
+
width: s.width,
|
|
10479
|
+
height: s.height,
|
|
10480
|
+
bitRate: s.bitRate
|
|
10481
|
+
}
|
|
10482
|
+
}), r = r.filter((e) => e.codec !== "av1")), i.logger.debug("supported renditions", { renditions: r.map((e) => C(C({
|
|
10483
|
+
codec: e.codec,
|
|
10484
|
+
codecString: e.codecString
|
|
10485
|
+
}, hn(e) ? {
|
|
10486
|
+
width: e.width,
|
|
10487
|
+
height: e.height
|
|
10488
|
+
} : {}), {}, { bitRate: e.bitRate })) }), r;
|
|
10441
10489
|
});
|
|
10442
10490
|
return function(t) {
|
|
10443
10491
|
return e.apply(this, arguments);
|
|
@@ -10573,7 +10621,7 @@ var uv = class {
|
|
|
10573
10621
|
let e = this.modules.canvasModule instanceof v_ ? !0 : void 0;
|
|
10574
10622
|
return C({
|
|
10575
10623
|
uptime: Date.now() - this.createdAt,
|
|
10576
|
-
version: "4.2.0-
|
|
10624
|
+
version: "4.2.0-26-g0fa621b5",
|
|
10577
10625
|
clientId: this.clientId,
|
|
10578
10626
|
sessionId: this.sessionId,
|
|
10579
10627
|
channelId: this.channelId,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as e, t } from "./BsfwXDui.js";
|
|
2
|
-
import { _ as n, a as r, c as i, d as a, f as o, g as s, h as c, i as ee, l, m as te, n as u, o as ne, p as re, r as ie, s as ae, t as oe, u as se, v as ce } from "./
|
|
2
|
+
import { _ as n, a as r, c as i, d as a, f as o, g as s, h as c, i as ee, l, m as te, n as u, o as ne, p as re, r as ie, s as ae, t as oe, u as se, v as ce } from "./B4Y3kCsd.js";
|
|
3
3
|
import { M as le } from "./C01DcfYu.js";
|
|
4
4
|
import { a as d, i as f, n as p, r as m, t as h } from "./B7hT-BKr.js";
|
|
5
5
|
import { n as ue, t as de } from "./B5bZayjf.js";
|
package/core.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { t as e } from "./
|
|
1
|
+
import { t as e } from "./B4Y3kCsd.js";
|
|
2
2
|
import { a as t, c as n, i as r, l as i, n as a, o, r as s, s as c, u as l } from "./C01DcfYu.js";
|
|
3
3
|
export { a as AUTHENTICATION_EXPIRED_CODE, s as AUTHENTICATION_FAILED_CODE, r as CHANNEL_NOT_FOUND_CODE, t as CONNECTION_FAILED_AFTER_RETRIES_CODE, o as CONNECTION_FAILED_CODE, c as DISCONNECTED_BY_EDGE, n as INACTIVITY_CODE, i as NO_INCOMING_DATA, e as Vindral, l as VindralError };
|
package/legacy.es.js
CHANGED
|
@@ -4672,7 +4672,7 @@ var su = class {
|
|
|
4672
4672
|
}
|
|
4673
4673
|
};
|
|
4674
4674
|
} catch (t) {
|
|
4675
|
-
return j(au, e).
|
|
4675
|
+
return j(au, e).warn("Error reading object", { error: t }), {
|
|
4676
4676
|
done: !0,
|
|
4677
4677
|
value: void 0
|
|
4678
4678
|
};
|
|
@@ -6162,13 +6162,13 @@ var zp = /* @__PURE__ */ new WeakMap(), Bp = /* @__PURE__ */ new WeakMap(), Vp =
|
|
|
6162
6162
|
case $.AnnounceOk:
|
|
6163
6163
|
{
|
|
6164
6164
|
let n = j(Up, t).current().get(e.namespace.join("/"));
|
|
6165
|
-
n || j(Hp, t).
|
|
6165
|
+
n || j(Hp, t).warn("No announcement found", e), n == null || n.state.onOk(e);
|
|
6166
6166
|
}
|
|
6167
6167
|
break;
|
|
6168
6168
|
case $.AnnounceError:
|
|
6169
6169
|
{
|
|
6170
6170
|
let n = j(Up, t).current().get(e.namespace.join("/"));
|
|
6171
|
-
n || j(Hp, t).
|
|
6171
|
+
n || j(Hp, t).warn("No announcement found", e), n == null || n.state.onError(e);
|
|
6172
6172
|
}
|
|
6173
6173
|
break;
|
|
6174
6174
|
default: break;
|
|
@@ -6433,7 +6433,7 @@ var sm = 2e3, cm = /* @__PURE__ */ new WeakMap(), lm = /* @__PURE__ */ new WeakM
|
|
|
6433
6433
|
case $.SubscribeError:
|
|
6434
6434
|
{
|
|
6435
6435
|
let n = j(lm, t).current().get(e.id);
|
|
6436
|
-
n || j(dm, t).
|
|
6436
|
+
n || j(dm, t).warn("No subscription found", e), n == null || n.onError(e), D(fm, t, hm).call(t, e.id);
|
|
6437
6437
|
}
|
|
6438
6438
|
break;
|
|
6439
6439
|
case $.SubscribeDone:
|
|
@@ -6531,7 +6531,9 @@ function Tm(e) {
|
|
|
6531
6531
|
return N(function* () {
|
|
6532
6532
|
var n, r;
|
|
6533
6533
|
switch (j(xm, t).debug("received message", e), yield (n = t.subscriber) == null ? void 0 : n.onMessage(e), yield (r = t.publisher) == null ? void 0 : r.onMessage(e), e.type) {
|
|
6534
|
-
case $.Goaway:
|
|
6534
|
+
case $.Goaway:
|
|
6535
|
+
j(xm, t).info("received GoAway", e);
|
|
6536
|
+
break;
|
|
6535
6537
|
default: break;
|
|
6536
6538
|
}
|
|
6537
6539
|
})();
|
|
@@ -6743,7 +6745,7 @@ H(), R(), E(), A(), O(), M(), P();
|
|
|
6743
6745
|
var Zm = /* @__PURE__ */ new WeakMap(), Qm = /* @__PURE__ */ new WeakMap(), $m = /* @__PURE__ */ new WeakMap(), eh = /* @__PURE__ */ new WeakMap(), th = /* @__PURE__ */ new WeakMap(), nh = /* @__PURE__ */ new WeakMap(), rh = /* @__PURE__ */ new WeakSet(), ih = class {
|
|
6744
6746
|
constructor(e, t, n) {
|
|
6745
6747
|
L(this, rh), T(this, Zm, void 0), T(this, Qm, void 0), T(this, $m, new _e(100)), T(this, eh, void 0), T(this, th, 0), T(this, nh, rn.get().createContext("WebTransportConnection")), k(eh, this, n), k(Zm, this, e), k(Qm, this, t), D(rh, this, ah).call(this).catch((e) => {
|
|
6746
|
-
j(nh, this).
|
|
6748
|
+
j(nh, this).warn("Incoming streams handling ended with error", e), j(Qm, this).markPostHandshake(), j($m, this).close();
|
|
6747
6749
|
}), j(Zm, this).closed.then(() => {
|
|
6748
6750
|
j(Qm, this).markPostHandshake(), j($m, this).close();
|
|
6749
6751
|
});
|
|
@@ -6821,7 +6823,12 @@ function ch() {
|
|
|
6821
6823
|
let n = qf.wrapWebsocket(t), r = Xf(n, e.role).catch((e) => {
|
|
6822
6824
|
throw oh.warn("MoQ handshake failed, closing WebSocket", { error: e }), t.close(), e;
|
|
6823
6825
|
});
|
|
6824
|
-
|
|
6826
|
+
e.handshakePipelining || (yield r);
|
|
6827
|
+
let i = new wm(new Ym(t, n), e.authToken);
|
|
6828
|
+
return oh.info("connected", {
|
|
6829
|
+
url: e.wsUrl || e.url,
|
|
6830
|
+
transport: "websocket"
|
|
6831
|
+
}), i;
|
|
6825
6832
|
}), ch.apply(this, arguments);
|
|
6826
6833
|
}
|
|
6827
6834
|
function lh(e) {
|
|
@@ -6836,7 +6843,12 @@ function uh() {
|
|
|
6836
6843
|
let r = yield n.createBidirectionalStream(), i = qf.wrapWebTransport(r), a = Xf(i, e.role).catch(() => {
|
|
6837
6844
|
n.close();
|
|
6838
6845
|
});
|
|
6839
|
-
|
|
6846
|
+
e.handshakePipelining || (yield a);
|
|
6847
|
+
let o = new wm(new ih(n, i, e.url.toString()), e.authToken);
|
|
6848
|
+
return oh.info("connected", {
|
|
6849
|
+
url: e.url,
|
|
6850
|
+
transport: "webtransport"
|
|
6851
|
+
}), o;
|
|
6840
6852
|
}), uh.apply(this, arguments);
|
|
6841
6853
|
}
|
|
6842
6854
|
function dh(e) {
|
|
@@ -7272,7 +7284,7 @@ var mg = class {
|
|
|
7272
7284
|
}
|
|
7273
7285
|
onFragment(e, t, n, r, i) {
|
|
7274
7286
|
var a;
|
|
7275
|
-
j(sg, this) === void 0 && (k(sg, this, e), k(cg, this, t), k(lg, this, n), k(ug, this, r), j(ag, this).
|
|
7287
|
+
j(sg, this) === void 0 && (k(sg, this, e), k(cg, this, t), k(lg, this, n), k(ug, this, r), j(ag, this).debug("group start", {
|
|
7276
7288
|
name: j(og, this).name,
|
|
7277
7289
|
groupId: e,
|
|
7278
7290
|
startTimeMs: r,
|
|
@@ -7290,7 +7302,7 @@ var mg = class {
|
|
|
7290
7302
|
}
|
|
7291
7303
|
};
|
|
7292
7304
|
function hg() {
|
|
7293
|
-
j(sg, this) !== void 0 && j(ug, this) !== void 0 && j(dg, this) !== void 0 && j(ag, this).
|
|
7305
|
+
j(sg, this) !== void 0 && j(ug, this) !== void 0 && j(dg, this) !== void 0 && j(ag, this).debug("group end", {
|
|
7294
7306
|
name: j(og, this).name,
|
|
7295
7307
|
groupId: j(sg, this),
|
|
7296
7308
|
startTimeMs: j(ug, this),
|
|
@@ -7327,7 +7339,7 @@ var xg = class {
|
|
|
7327
7339
|
n.updateBaseMediaDecodeTime(n.baseMediaDecodeTime() - o);
|
|
7328
7340
|
let l = e.track.timestampRange();
|
|
7329
7341
|
if (l && i >= l[1]) break;
|
|
7330
|
-
j(yg, e).
|
|
7342
|
+
j(yg, e).trace("fragment", z(z({}, s), {}, {
|
|
7331
7343
|
startTime: i,
|
|
7332
7344
|
endTime: a,
|
|
7333
7345
|
subscribeId: t.subscribeId,
|
|
@@ -7556,6 +7568,10 @@ function Bg(e) {
|
|
|
7556
7568
|
return N(function* () {
|
|
7557
7569
|
let n = e - F(1), r = t.timeline(), i = r[0], a = r[r.length - 1];
|
|
7558
7570
|
if (!i || !a || a.wallclock - i.wallclock > kg) return;
|
|
7571
|
+
j(jg, t).debug("backfilling timeline", {
|
|
7572
|
+
currentGroupId: e,
|
|
7573
|
+
backfillGroupId: n
|
|
7574
|
+
});
|
|
7559
7575
|
let o = C.fromPromise(Bh.subscribe(j(Pg, t), new mh().name(j(Fg, t)).groupOrder("ascending").range(n, n).build()));
|
|
7560
7576
|
return D(Lg, t, zg).call(t, o);
|
|
7561
7577
|
})();
|
|
@@ -8507,7 +8523,7 @@ var Ov = /* @__PURE__ */ function(e) {
|
|
|
8507
8523
|
}), p(this, "onMessage", (e, t) => {
|
|
8508
8524
|
this.websockets.length !== 0 && this.options.onMessage(e, t.data);
|
|
8509
8525
|
}), p(this, "onError", () => {
|
|
8510
|
-
this.logger.
|
|
8526
|
+
this.logger.warn("On error", z({}, this.options)), this.close("one websocket had an error"), this.emit("error", new U("WebSocket error", {
|
|
8511
8527
|
code: "websocket_error",
|
|
8512
8528
|
isFatal: !1
|
|
8513
8529
|
}));
|
|
@@ -8827,9 +8843,9 @@ function $v() {
|
|
|
8827
8843
|
}), j(Vv, e)) : (ye(typeof i == "string", "Edge URL is expected to be a string"), e.connectionImpl = yield Fv.start(e.emitter, e.logger, z(z({}, e.config), {}, {
|
|
8828
8844
|
connectInfo: n,
|
|
8829
8845
|
edgeUrl: i
|
|
8830
|
-
}), j(Vv, e))), t.reset(), k(Kv, e, (a = j(Kv, e), a++, a)), k(Wv, e, 0), k(Jv, e, Date.now()), j(qv, e) || k(qv, e, j(Jv, e)), yield e.connectionImpl.closed();
|
|
8846
|
+
}), j(Vv, e))), t.reset(), k(Kv, e, (a = j(Kv, e), a++, a)), k(Wv, e, 0), k(Jv, e, Date.now()), j(qv, e) || k(qv, e, j(Jv, e)), yield e.connectionImpl.closed(), e.logger.info("Connection closed");
|
|
8831
8847
|
} catch (n) {
|
|
8832
|
-
e.logger.
|
|
8848
|
+
e.logger.warn("Failed to connect", n);
|
|
8833
8849
|
let r = t.shiftedEdge();
|
|
8834
8850
|
r && e.emitter.emit("telemetry event", {
|
|
8835
8851
|
code: "shifted_edge",
|
|
@@ -11920,15 +11936,47 @@ var dx = /* @__PURE__ */ new WeakMap(), fx = /* @__PURE__ */ new WeakMap(), px =
|
|
|
11920
11936
|
if (!lr(e) || !n.isSupportedVideoCodecProfile(e.codec, e.codecString)) return !1;
|
|
11921
11937
|
if (!n.willUseMediaSource()) return n.isWebCodecsVideoAvailable(n.channelId) ? n.webCodecsRenditionSupport.checkVideoSupport(e) : !0;
|
|
11922
11938
|
let r = yield qc(e);
|
|
11923
|
-
if (!r.supported
|
|
11939
|
+
if (!r.supported) return !1;
|
|
11940
|
+
if (e.codec === "av1" && !r.smooth && !r.powerEfficient) return n.logger.debug("discarding av1 rendition, neither smooth nor power efficient", {
|
|
11941
|
+
codecString: e.codecString,
|
|
11942
|
+
width: e.width,
|
|
11943
|
+
height: e.height,
|
|
11944
|
+
bitRate: e.bitRate,
|
|
11945
|
+
capabilities: r
|
|
11946
|
+
}), !1;
|
|
11924
11947
|
let i = n.options.getOverride("maxVideoBitRate", n.channelId);
|
|
11925
11948
|
return i ? i >= e.bitRate : !0;
|
|
11926
11949
|
});
|
|
11927
11950
|
return function(t) {
|
|
11928
11951
|
return e.apply(this, arguments);
|
|
11929
11952
|
};
|
|
11930
|
-
}())), r = e.filter((e, n) => t[n]), i =
|
|
11931
|
-
|
|
11953
|
+
}())), r = e.filter((e, n) => t[n]), i = e.filter((e, n) => !t[n]);
|
|
11954
|
+
i.length > 0 && n.logger.debug("unsupported renditions filtered out", { renditions: i.map((e) => z(z({
|
|
11955
|
+
codec: e.codec,
|
|
11956
|
+
codecString: e.codecString
|
|
11957
|
+
}, lr(e) ? {
|
|
11958
|
+
width: e.width,
|
|
11959
|
+
height: e.height
|
|
11960
|
+
} : {}), {}, { bitRate: e.bitRate })) });
|
|
11961
|
+
let a = r.filter((e) => e.codec === "h264").reverse()[0], o = r.filter((e) => e.codec === "av1").reverse()[0];
|
|
11962
|
+
return a && o && a.width > o.width && a.height > o.height && (n.logger.debug("discarding av1 renditions, h264 ladder has higher resolution", {
|
|
11963
|
+
bestH264: {
|
|
11964
|
+
width: a.width,
|
|
11965
|
+
height: a.height,
|
|
11966
|
+
bitRate: a.bitRate
|
|
11967
|
+
},
|
|
11968
|
+
bestAV1: {
|
|
11969
|
+
width: o.width,
|
|
11970
|
+
height: o.height,
|
|
11971
|
+
bitRate: o.bitRate
|
|
11972
|
+
}
|
|
11973
|
+
}), r = r.filter((e) => e.codec !== "av1")), n.logger.debug("supported renditions", { renditions: r.map((e) => z(z({
|
|
11974
|
+
codec: e.codec,
|
|
11975
|
+
codecString: e.codecString
|
|
11976
|
+
}, lr(e) ? {
|
|
11977
|
+
width: e.width,
|
|
11978
|
+
height: e.height
|
|
11979
|
+
} : {}), {}, { bitRate: e.bitRate })) }), r;
|
|
11932
11980
|
});
|
|
11933
11981
|
return function(t) {
|
|
11934
11982
|
return e.apply(this, arguments);
|
|
@@ -12064,7 +12112,7 @@ var dx = /* @__PURE__ */ new WeakMap(), fx = /* @__PURE__ */ new WeakMap(), px =
|
|
|
12064
12112
|
let e = this.modules.canvasModule instanceof ob ? !0 : void 0;
|
|
12065
12113
|
return z({
|
|
12066
12114
|
uptime: Date.now() - this.createdAt,
|
|
12067
|
-
version: "4.2.0-
|
|
12115
|
+
version: "4.2.0-26-g0fa621b5",
|
|
12068
12116
|
clientId: this.clientId,
|
|
12069
12117
|
sessionId: this.sessionId,
|
|
12070
12118
|
channelId: this.channelId,
|