New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 703588 link

Starred by 1 user

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows , Mac
Pri: 2
Type: Bug


Show other hotlists

Hotlists containing this issue:
Hotlist-1


Sign in to add a comment

Turn srcset parsing errors into a warning

Reported by andrea.g...@gmail.com, Mar 21 2017

Issue description

UserAgent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36

Steps to reproduce the problem:
1. type the following in console
2. (new Image).srcset = '<!-- this is a placeholder -->';
3. two red errors are thrown

What is the expected behavior?
Other browsers try to load the placeholder regardless, which I think is wrong. However, throwing 2 errors in console is also too much. Shouldn't these just be warnings instead?

What went wrong?
Specially when it comes to templates, having placeholders as attributes is quite common.

In this case Chromium is doing the right thing, ignoring the srcset without trying to load it from the network, but it throws 2 errors even if I instantly update the attribute.

If Chromium could just show a warning instead, that'd be awesome!

Did this work before? N/A 

Does this work in other browsers? Yes

Chrome version: 56.0.2924.87  Channel: n/a
OS Version: OS X 10.11.6
Flash Version: Shockwave Flash 25.0 r0

This is essential to keep mapped literal templates to DOM nodes as simple as possible, without having "scary" errors per srcset.

Thanks for considering some improvement, if possible.
 
Cc: y...@yoav.ws
Components: Blink>Image
Labels: OS-Windows
Status: Untriaged (was: Unconfirmed)
Summary: Turn srcset parsing errors into a warning (was: srcset is over-reacting)
While they look like errors, they are not exceptions (code that runs afterwards still runs). This is indeed deceiving and two are extraneous...

Comment 2 by phistuck@gmail.com, Mar 23 2017

One is here -
https://cs.chromium.org/chromium/src/third_party/WebKit/Source/core/html/parser/HTMLSrcsetParser.cpp?q=%22attribute+value+since%22&dr=C&l=198
Should probably just be changed from ErrorMessageLevel to WarningMessageLevel.

https://cs.chromium.org/chromium/src/third_party/WebKit/Source/core/html/parser/HTMLSrcsetParser.cpp?q=%22Dropped+srcset+candidate%22&dr=C&l=328
Same here, but perhaps the previous message (which comes from parseDescriptors calling srcsetError) should be prepended (shared via an out parameter or something) to this message.

Comment 3 by tkent@chromium.org, Mar 24 2017

Components: -Blink>DOM
Labels: -Pri-2 PaintTeamTriaged-20170324 BugSource-User Pri-3
Status: Available (was: Untriaged)
Project Member

Comment 5 by sheriffbot@chromium.org, Mar 28 2018

Labels: Hotlist-Recharge-Cold
Status: Untriaged (was: Available)
This issue has been Available for over a year. If it's no longer important or seems unlikely to be fixed, please consider closing it out. If it is important, please re-triage the issue.

Sorry for the inconvenience if the bug really should have been left as Available.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
the error is still there, but the fix looked simple enough.

why has this issue been abandoned?
Cc: phistuck@chromium.org
Labels: -Pri-3 Pri-2
Status: Available (was: Untriaged)
phistuck@, you have some greater powers now. Would you like to put the change up for review?

Sign in to add a comment