Last Comment Bug 712836 - Reloading live stream causes HTMLMediaElement.error.code to be copied to new clone of resource
: Reloading live stream causes HTMLMediaElement.error.code to be copied to new ...
Status: RESOLVED FIXED
[qa+]
:
Product: Core
Classification: Components
Component: Audio/Video (show other bugs)
: 11 Branch
: x86_64 Windows 7
: -- normal (vote)
: mozilla14
Assigned To: Robert O'Callahan (:roc) (Exited; email my personal email if necessary)
:
Mentors:
: 712856 730569 (view as bug list)
Depends on:
Blocks: 703379
  Show dependency treegraph
 
Reported: 2011-12-21 17:33 PST by Chris Pearce (:cpearce)
Modified: 2012-05-20 19:39 PDT (History)
12 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---
affected
fixed
verified


Attachments
Make MediaResources which have ended abnormally ineligible for cloning (14.84 KB, patch)
2012-03-19 03:34 PDT, Robert O'Callahan (:roc) (Exited; email my personal email if necessary)
cpearce: review+
jpr: approval‑mozilla‑aurora+
lukasblakk+bugs: approval‑mozilla‑beta+
Details | Diff | Splinter Review

Description Chris Pearce (:cpearce) 2011-12-21 17:33:56 PST
If you reload the page while watching a <video> with a live stream, the <video> in the reloaded page will have its error.code set to 1 (MEDIA_ERR_ABORTED). This causes the controls to display a message "Video stopped loading", and show the controls overlay (i.e. partially obscure the video).

This regressed in nightlies between 2011-11-20-03 and 2011-11-26, which is the period that bug 703379 was landing and stabilizing, so I'm assuming this is a regression from bug 703379.

I don't know the URL of a HTML5 live video stream, so I'm reproducing this problem locally with the following STR:

1. Download HttpMediaServer from:
https://github.com/cpearce/HttpMediaServer
2. Start HttpMediaServer.exe in some folder containing videos (like ~/Videos/).
2. Load the following data URI in Firefox:
data:text/html,<video src="http://localhost/video.webm?live" controls id="v" autoplay></video>
(Substitute video.webm with the name of some video in the same directory in which HttpMediaServer is running).
3. Reload page.
4. Observe "Video stopped loading" warning showing.
Comment 1 Robert O'Callahan (:roc) (Exited; email my personal email if necessary) 2011-12-21 18:02:45 PST
I guess we need to disconnect thing when we shutdown the decoder for the original page so that the load-aborted error code doesn't reach the media cache.
Comment 2 Jared Wein [:jaws] (please needinfo? me) 2011-12-21 19:23:51 PST
Alternatively, we could hide the error when we get a "timeupdate" event.
Comment 3 Jared Wein [:jaws] (please needinfo? me) 2011-12-25 01:59:21 PST
*** Bug 712856 has been marked as a duplicate of this bug. ***
Comment 4 Jared Wein [:jaws] (please needinfo? me) 2012-02-25 15:16:20 PST
*** Bug 730569 has been marked as a duplicate of this bug. ***
Comment 5 Markus Popp 2012-03-08 18:43:24 PST
Here is a simple example to test this with:

http://var.mpopp.net/video/

I found the problem beginning in Firefox Beta 11 (in Firefox 10 it seems to work). As Firefox 11 is to be released soon, and this bug appears to be quite significant, a soon fix would be much appreciated.
Comment 6 Robert O'Callahan (:roc) (Exited; email my personal email if necessary) 2012-03-19 03:34:08 PDT
Created attachment 607106 [details] [diff] [review]
Make MediaResources which have ended abnormally ineligible for cloning
Comment 7 Robert O'Callahan (:roc) (Exited; email my personal email if necessary) 2012-03-20 00:57:59 PDT
https://hg.mozilla.org/integration/mozilla-inbound/rev/b0e3b2c66abe
Comment 8 Matt Brubeck (:mbrubeck) 2012-03-20 10:40:33 PDT
https://hg.mozilla.org/mozilla-central/rev/b0e3b2c66abe
Comment 9 Robert O'Callahan (:roc) (Exited; email my personal email if necessary) 2012-03-20 11:51:47 PDT
Comment on attachment 607106 [details] [diff] [review]
Make MediaResources which have ended abnormally ineligible for cloning

Review of attachment 607106 [details] [diff] [review]:
-----------------------------------------------------------------

Fixes video regression.

Risk analysis: Simply makes us use the clone optimization in fewer cases, so shouldn't trigger any risky new behaviors.
Comment 10 Alex Keybl [:akeybl] 2012-03-20 15:11:23 PDT
JP is helping to find out if this affects any of our other initiatives (games, etc.), which we'd take into consideration for Beta approval.
Comment 11 JP Rosevear [:jpr] 2012-03-21 05:14:54 PDT
Comment on attachment 607106 [details] [diff] [review]
Make MediaResources which have ended abnormally ineligible for cloning

Discussed with roc, not a big deal for beta, so approving for aurora and skipping beta.
Comment 12 Robert O'Callahan (:roc) (Exited; email my personal email if necessary) 2012-03-21 18:49:41 PDT
https://hg.mozilla.org/releases/mozilla-aurora/rev/f11042d416a0
Comment 13 Krystian Kichewko 2012-03-29 06:55:22 PDT
Hey guys!

I think this is the main ticket for this issue. Is there a workaround for this? It is really hard html5 player when you need to restart firefox everytime you want to refresh the page.

Krystian Kichewko
Comment 14 Markus Popp 2012-03-29 07:05:38 PDT
(In reply to Krystian Kichewko from comment #13)
> I think this is the main ticket for this issue. Is there a workaround for
> this? It is really hard html5 player when you need to restart firefox
> everytime you want to refresh the page.

It is fixed in the Aurora & Nightly channels. I don't know why the bug fix doesn't go into Beta, as it is clearly a bug and not a new feature, or feature enhancement. IMHO it should go into Beta too (sounds bad to me to keep a bug alive although there is a fix), so the wide public (release channel users) get the fix on April 24th.

I hope the decision to not let this into Beta can be reconsidered.
Comment 15 Krystian Kichewko 2012-04-03 04:12:33 PDT
Hey Markus!

I agree, this is a major issue. I hope this gets moved into beta, and released to public asap. Maybe you know someone on Mozilla team who I can contact to ask them to reconsider moving this patch into Beta?

But I'm also searching for a workaround, youtube is doing it somehow because their videos are working on my firefox. Maybe you know how to prevent this error from happening? 

Krystian Kichewko
Comment 16 Markus Popp 2012-04-03 07:33:29 PDT
(In reply to Krystian Kichewko from comment #15)
> Maybe you know how to prevent this
> error from happening?

The only workaround that I know is to use Aurora builds for now.

http://www.mozilla.org/en-US/firefox/aurora/
Comment 17 Robert O'Callahan (:roc) (Exited; email my personal email if necessary) 2012-04-03 13:51:40 PDT
Comment on attachment 607106 [details] [diff] [review]
Make MediaResources which have ended abnormally ineligible for cloning

Review of attachment 607106 [details] [diff] [review]:
-----------------------------------------------------------------

Renominating based on above comments. Also, this has baked for a while and has no known regressions.
Comment 18 Lukas Blakk [:lsblakk] use ?needinfo 2012-04-03 14:28:59 PDT
Comment on attachment 607106 [details] [diff] [review]
Make MediaResources which have ended abnormally ineligible for cloning

Approved for beta since it's had lots of bake time on central, fixes a regression, and is causing user pain.  If possible please land immediately on beta branch so it can get into beta4 which will be going to build in a couple of hours.
Comment 19 Robert O'Callahan (:roc) (Exited; email my personal email if necessary) 2012-04-03 16:08:16 PDT
Thanks!

https://hg.mozilla.org/releases/mozilla-beta/rev/e4ed83ba6eb9
Comment 20 Krystian Kichewko 2012-04-04 03:48:37 PDT
Hey!

Thanks for the fast reaction! 

Krystian Kichewko
Comment 21 Ioana (away) 2012-05-11 04:58:43 PDT
Verified as fixed with the steps from comment 0 on:
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:13.0) Gecko/20100101 Firefox/13.0
BuildID: 20120425123149

Note You need to log in before you can comment on or make changes to this bug.