setting media source during user gesture event removes permission to play
Reported by
kevin.br...@sendtonews.com,
Oct 18 2017
|
||||||||
Issue descriptionSteps to reproduce the problem: 1. As the result of a user gesture, modify the source of a video player that has not been authorized to play, and register an event callback to play once canplay fires. 2. As the result of canplay event, play 3. get not authorized error What is the expected behavior? As the event chain was initiated by a user gesture, the play should be allowed. What went wrong? The play was not allowed, console emits a user gesture not allowed error. Did this work before? N/A Does this work in other browsers? N/A Chrome version: 61.0.3163.98 Channel: stable OS Version: 7.0.0 Flash Version: There should be a 'gestureLockReleased' property of some kind that can be queried by javascript to see if a media element has been authorized to play
,
Oct 23 2017
Device is LG G5 rs988. I don't have screencast software installed and am not intending to. The example file I included should be more than enough.
,
Oct 23 2017
Thank you for providing more feedback. Adding requester "msrchandra@chromium.org" to the cc list and removing "Needs-Feedback" label. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Oct 25 2017
,
Oct 26 2017
,
Oct 26 2017
I couldn't repro in Chrome 62.0.3202.62 in Linux. Is there any Android specific gesture handling during media playback?
,
Oct 26 2017
This issue will be fixed by bug 715049 . However, your problem will still exists on Safari iOS and other browsers. The recommended way to resolve your problem is explained in this article: https://developers.google.com/web/updates/2017/06/play-request-was-interrupted Hope this helps :)
,
Oct 26 2017
The issue here is that the permission to play is being lost even though the play command is the result of a gesture. This is happening on the android version of chrome. bug 715049 is the copying of autoplay functionality to desktop, from android. You're saying that copying a feature from android to desktop will fix the bug on the source platform, android. I don't see how that logically makes sense. If anything, you will copy the errant behavior onto desktop. Can you confirm what you meant?
,
Oct 27 2017
According to your original issue, you do not call play on the user gesture: """ 1. As the result of a user gesture, modify the source of a video player that has not been authorized to play, and register an event callback to play once canplay fires. """ What I read is that you set the `src` when the user gesture happens and you later, asynchronously call `play()`. The link I provided above should give you directions to help. The bug I linked will also make this behaviour work.
,
Oct 27 2017
You are correct I call it asynchronously, however current expected behavior is that the permission to play carries through asynchronous events is it not? Or is is that the only asynchronous event allowed is the message event, through a post message call? If it is intended that post message is the only way to carry the permission than can you consider this a feature request to align asyncrounous behevior across all linked events? I can call the load function as stated in your linked blog post, and I've confirmed that this works, but it still leaves me rather stranded when forced to deal with 3rd party libraries that don't do this.
,
Oct 30 2017
`postMessage()` and `setTimeout()` will carry the gesture token. Not all async calls will. It's a bit of a mess and we are working on making things simpler on that side. We are also changing the autoplay policy to no longer rely on all this, thus the dependency. It should help with your problems, see https://blog.chromium.org/2017/09/unified-autoplay.html
,
May 11 2018
This should be fixed in M66 |
||||||||
►
Sign in to add a comment |
||||||||
Comment 1 by msrchandra@chromium.org
, Oct 23 2017Labels: Needs-triage-Mobile Triaged-Mobile Needs-Feedback