Conversation
✅ Deploy Preview for vjs10-site ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
📦 Bundle Size Report🎨 @videojs/html
Presets (7)
Media (7)
Players (3)
Skins (17)
UI Components (22)
Sizes are marginal over the root entry point. ⚛️ @videojs/react
Presets (7)
Media (6)
Skins (14)
UI Components (19)
Sizes are marginal over the root entry point. 🧩 @videojs/core
Entries (8)
🏷️ @videojs/element — no changesEntries (2)
📦 @videojs/store — no changesEntries (3)
🔧 @videojs/utils — no changesEntries (10)
📦 @videojs/spf — no changesEntries (3)
ℹ️ How to interpretAll sizes are standalone totals (minified + brotli).
Run |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Autofix Details
Bugbot Autofix prepared a fix for the issue found in the latest run.
- ✅ Fixed: Stale error state after source change in native path
- Added 'emptied' event listener to clear #error field on source changes, matching browser behavior and hls.js pattern.
Or push these changes by commenting:
@cursor push 3077e33124
Preview (3077e33124)
diff --git a/packages/core/src/dom/media/native-hls/errors.ts b/packages/core/src/dom/media/native-hls/errors.ts
--- a/packages/core/src/dom/media/native-hls/errors.ts
+++ b/packages/core/src/dom/media/native-hls/errors.ts
@@ -54,6 +54,15 @@
},
{ signal: this.#disconnect.signal }
);
+
+ listen(
+ target,
+ 'emptied',
+ () => {
+ this.#error = null;
+ },
+ { signal: this.#disconnect.signal }
+ );
}
#destroy(): void {
diff --git a/packages/core/src/dom/media/native-hls/tests/errors.test.ts b/packages/core/src/dom/media/native-hls/tests/errors.test.ts
--- a/packages/core/src/dom/media/native-hls/tests/errors.test.ts
+++ b/packages/core/src/dom/media/native-hls/tests/errors.test.ts
@@ -181,4 +181,17 @@
const event = handler.mock.calls[0]![0] as ErrorEvent;
expect(event.error.code).toBe(MediaError.MEDIA_ERR_NETWORK);
});
+
+ it('clears error on emptied event (source change)', () => {
+ const { host, video } = setup();
+
+ fireNativeError(video, MediaError.MEDIA_ERR_NETWORK, 'network failure');
+
+ expect(host.error).not.toBeNull();
+ expect(host.error!.code).toBe(MediaError.MEDIA_ERR_NETWORK);
+
+ video.dispatchEvent(new Event('emptied'));
+
+ expect(host.error).toBeNull();
+ });
});This Bugbot Autofix run was free. To enable autofix for future PRs, go to the Cursor dashboard.
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.


fix #982
Note
Medium Risk
Touches core media event forwarding (
ProxyMixin,DelegateMixin,CustomMediaMixin) and error propagation for both hls.js and native playback, which could subtly change how consumers receive/stop events. Coverage is improved with new unit tests, but the behavioral shift is cross-cutting.Overview
Adds native HLS error enrichment by introducing
NativeHlsMediaErrorsMixin, which intercepts native<video>errorevents, stops their propagation, and re-dispatches an enrichedErrorEventcarrying aMediaError(cleared onemptied/detach/destroy).Refactors event bridging/proxying: extracts
bridgeEventsintocore/utils, updatesDelegateMixinattach ordering, reworksProxyMixinto forward target events onto the proxy’s ownEventTargetlisteners, and changesCustomMediaMixinto defer forwarding captured non-bubbling media events so consumerstopPropagationsemantics still work.Renames HLS mixins to
HlsJs*variants and adjusts hls.js fatal error message handling (data.error?.message), adds extensive new tests forProxyMixin, delegate/proxy attach ordering, and native HLS error behavior, and adds new sandbox templates to demonative-hls-videoin both HTML and React.Written by Cursor Bugbot for commit bb37e45. This will update automatically on new commits. Configure here.