Closed
Bug 1376004
Opened 8 years ago
Closed 8 years ago
Show proper error on UI when getting 404
Categories
(Core :: Audio/Video: Playback, enhancement, P3)
Core
Audio/Video: Playback
Tracking
()
RESOLVED
FIXED
mozilla56
Tracking | Status | |
---|---|---|
firefox56 | --- | fixed |
People
(Reporter: bwu, Assigned: jwwang)
References
Details
Attachments
(2 files)
Per bug 1374510 comment 3, we should show the proper error message for 404.
Updated•8 years ago
|
Priority: -- → P3
Assignee | ||
Comment 1•8 years ago
|
||
This test case set 'src' to a resource that doesn't exist. Our video control shows "Video format or MIME type is not supported" while Chrome shows an empty UI.
Our UI is confusing which looks we don't support the format instead of 404 file not found.
Assignee | ||
Comment 2•8 years ago
|
||
This should be a bug of video control.
Assignee | ||
Updated•8 years ago
|
Component: Audio/Video: Playback → Video/Audio Controls
Product: Core → Toolkit
Comment 3•8 years ago
|
||
Hi JW,
If the error msg is "Video format or MIME type is not supported", that means we received "MEDIA_ERR_SRC_NOT_SUPPORTED" in the video controls. Do we have any additional information can help us indicate 404 error instead of a generic "MEDIA_ERR_SRC_NOT_SUPPORTED" error? otherwise we might need to change message to a more neutral wording for both cases.
Flags: needinfo?(jwwang)
Assignee | ||
Comment 4•8 years ago
|
||
The spec. doesn't talk about any specific error like 404.
https://html.spec.whatwg.org/multipage/media.html#dom-mediaerror-media_err_src_not_supported
"The media resource indicated by the src attribute or assigned media provider object was not suitable."
Can we assume "not suitable" means "doesn't exist"? Or at least we can show an empty UI as Chrome does that is less misleading.
Flags: needinfo?(jwwang) → needinfo?(cpearce)
Comment 5•8 years ago
|
||
We cannot assume that "not suitable" means "doesn't exist". "not suitable" includes not having a codec that can decode the media for example.
We could certainly feed back more details on the HTMLMediaElement.error.message field; we have the capability now to have that contain an arbitrary string, so we could set it to a known value which conveys 404 which the videocontrols could look out for.
Flags: needinfo?(cpearce)
Comment hidden (mozreview-request) |
Assignee | ||
Updated•8 years ago
|
Attachment #8886496 -
Flags: review?(cpearce)
Comment 7•8 years ago
|
||
mozreview-review |
Comment on attachment 8886496 [details]
Bug 1376004. P1 - include http response code in the error.message field so the UI has more details to display a proper error message.
https://reviewboard.mozilla.org/r/157300/#review162730
Great, thanks.
Attachment #8886496 -
Flags: review?(cpearce) → review+
Assignee | ||
Updated•8 years ago
|
Component: Video/Audio Controls → Audio/Video: Playback
Product: Toolkit → Core
Pushed by jwwang@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/974788a46fa3
P1 - include http response code in the error.message field so the UI has more details to display a proper error message. r=cpearce
Assignee | ||
Comment 10•8 years ago
|
||
Hi Ray,
We include response code in the error.message field. You can now parse the string to get more details about the error.
The format is: xxx: yyy. xxx is the http response code and yyy is a string that describes the code.
E.g. 404: Not Found.
I think 404 is the only code we care about for now.
Comment 11•8 years ago
|
||
(In reply to JW Wang [:jwwang] [:jw_wang] from comment #10)
> Hi Ray,
> We include response code in the error.message field. You can now parse the
> string to get more details about the error.
>
> The format is: xxx: yyy. xxx is the http response code and yyy is a string
> that describes the code.
> E.g. 404: Not Found.
>
> I think 404 is the only code we care about for now.
Sure, is bug 1380232 the right place to carry on the UI part?
Assignee | ||
Comment 12•8 years ago
|
||
No. Please open a new bug for UI changes.
![]() |
||
Comment 13•8 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 8 years ago
status-firefox56:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla56
You need to log in
before you can comment on or make changes to this bug.
Description
•