Closed Bug 1830625 Opened 1 year ago Closed 1 year ago

On the Interbrand website, with `media.autoplay.blocking_policy = 1` , videos cannot be played even when directly clicking their play buttons

Categories

(Core :: DOM: Core & HTML, defect)

Firefox 112
x86_64
Linux
defect

Tracking

()

RESOLVED WONTFIX

People

(Reporter: nekohayo, Unassigned)

References

Details

User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/112.0

Steps to reproduce:

  1. Either through the GUI preferences, or through about:config, set Firefox to fully block autoplaying videos (even silent ones), that is media.autoplay.default = 5
  2. Set media.autoplay.blocking_policy = 1 (or media.autoplay.blocking_policy = 2)
  3. Visit https://interbrand.com , wait for it to load
  4. Click the "pause" button on the black hero banner/header background, where a looped autoplaying video was supposed to be.
  5. Scroll down to the middle of the height of the page, and notice there is also a non-autoplaying click-to-play video embedded there. Press its play button (or click in the middle of the video).

Actual results:

In both cases, the video do not play, no matter how many times you click their play buttons.

Expected results:

Is there a way Firefox could handle these, without needing to enable autoplay in the settings?

I think I've also seen this problem on other sites such as Radio Canada, for example this page that has a video: https://ici.radio-canada.ca/info/videos/1-8764467/epopee-baie-james (but that one works with media.autoplay.blocking_policy = 1 , just not media.autoplay.blocking_policy = 2 but this one is reportedly less surprising)

Component: Untriaged → Audio/Video: Playback
OS: Unspecified → Linux
Product: Firefox → Core
Hardware: Unspecified → x86_64
Flags: needinfo?(alwu)

Sorry, this one should be a WONFIX issue for media.autoplay.blocking_policy = 2 due to the tech constraint, see the click-to-play part. However, for media.autoplay.blocking_policy = 1, it should work once the player calls video.play() within the certain time frame (default time is 5000ms).

Here is the profile I captured when using media.autoplay.blocking_policy = 1. The interesting part is that, those videos are controlled by Vimeo player, which was isolated into another process. From the log showed in the profiled result (click interbrand.com process, and go to Marker Table, set filter with log), the transient activation result is always zero, even if I adjust dom.user_activation.transient.timeout to a super big value. It seems that we didn't propagate that transient flag correctly among different processes. Edgar, could you help me take a look on this?

Thanks!

Component: Audio/Video: Playback → DOM: Core & HTML
Flags: needinfo?(alwu) → needinfo?(echen)

Clicking on parent frame won't propagate the user transient activation to the cross-origin child frame, which is defined in the spec (https://html.spec.whatwg.org/#user-activation-processing-model), so it is expected behavior.

Flags: needinfo?(echen)

Alastor, is this a WONTFIX....?

Flags: needinfo?(alwu)

Per Edgar's reply, if the transient activation shouldn't be propagated into cross-origin frames, then yes, it should be WONFIX for media.autoplay.blocking_policy = 1. Sorry.

Status: UNCONFIRMED → RESOLVED
Closed: 1 year ago
Flags: needinfo?(alwu)
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.