[Webkit-unassigned] [Bug 252465] In PWA, HTML Video Element may be unable to play stream from 'getUserMedia()'

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sat Mar 18 12:52:00 PDT 2023


https://bugs.webkit.org/show_bug.cgi?id=252465

--- Comment #13 from Chris <chrissyg at protonmail.com> ---
(In reply to thompsoncwt from comment #12)
> I wrestled with this bug for many months but I think I finally discovered
> what triggers it. It seems (to me) that it is triggered when you close the
> app while a portion of the video is off-screen, or after it has been sent
> off-screen. 
> 
> Two ways that seem to reliably reproduce the bug:
> 1. Have the video element/recording be bigger than the screen and part of
> the video is clipped or off-screen, then close the app.
> 2. Have no part of the video element be off screen, but send it off screen
> for example by using a text input that brings up the keyboard, then close
> the app.
> 
> After either of those 2 things happen, the app will no longer be able to
> play the stream from getUserMedia(), even after closing and reopening the
> app. #2 is especially frustrating for my situation because I prompt users to
> input a title for their recording, which can trigger the bug if users close
> the app while on that page. This only happens while the app is in PWA mode
> on iOS, never while using the Safari browser on iOS, and never on a Mac or
> other PC with either Safari or Chrome.
> 
> The only way I've found to recover functionality is to either restart the
> device like mentioned by Chris, or what has worked for me is closing the app
> while the prompt that asks the users to Allow the app to access microphone
> and camera is visible on screen.

Amazing work!

This explanation fits perfectly with my application use case- my app is basically a wizard interface that flips through multiple panels, showing and hiding div elements- one of those div elements is the 'picture taking' stage which contains the canvas and video elements that have the stream attached.. to improve the UX I basically call getUserMedia() before the 'picture taking' stage appears and leave it running when the user proceeds to the next step.

This has to be why the bug is so common for me!

What I will do is test my app by calling getUserMedia() only while the picture taking stage is on screen, I'll then have it stop the stream before the div is hidden- just to see if I can ever trigger the bug.

I would really love to see this fixed so hopefully the more we can keep this thread alive the greater our chances will be...

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20230318/1cb1c12e/attachment.htm>


More information about the webkit-unassigned mailing list