Bug 156604

Summary: ASSERT when loading github.com
Product: WebKit Reporter: Myles C. Maxfield <mmaxfield>
Component: New BugsAssignee: Myles C. Maxfield <mmaxfield>
Status: RESOLVED FIXED    
Severity: Normal CC: dbates, dino, jonlee, rhodovan.u-szeged, simon.fraser, thorton, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch darin: review+

Description Myles C. Maxfield 2016-04-14 15:20:11 PDT
ASSERT when loading github.com
Comment 1 Myles C. Maxfield 2016-04-14 15:22:25 PDT
Created attachment 276438 [details]
Patch
Comment 2 Myles C. Maxfield 2016-04-14 15:27:19 PDT
Created attachment 276439 [details]
Patch
Comment 3 Myles C. Maxfield 2016-04-14 15:27:42 PDT
<rdar://problem/19890634>
Comment 4 Myles C. Maxfield 2016-04-14 16:13:36 PDT
*** Bug 155748 has been marked as a duplicate of this bug. ***
Comment 5 Daniel Bates 2016-04-14 16:37:08 PDT
Comment on attachment 276439 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=276439&action=review

> Source/WebCore/html/HTMLInputElement.cpp:924
> +    updateValidity();

Although this is sufficient to fix this bug. I suspect that this validity issue also affects other form controls, including <textarea> and <select>.

> LayoutTests/fast/forms/checkValidity-cloneNode-crash-expected.txt:5
> +TEST COMPLETE
> +This test makes sure that calling checkValidity() on a cloned node does not crash a Debug build. The test passes if there is no crash (and if you don't see any "FAIL"s).

It is weird that we print the test description after "TEST COMPLETE". We should make use of description() (defined in js-test-pre.js) to add a test description. This function will ensure that we print the test description along with a message on how to interpret the test results before the PASS messages and the "TEST COMPLETE" message.

> LayoutTests/fast/forms/checkValidity-cloneNode-crash.html:7
> +This test makes sure that calling checkValidity() on a cloned node does not crash a Debug build. The test passes if there is no crash (and if you don't see any "FAIL"s).

Please use description() to record the this test description, taking care to encode HTML entities. One example of a test that makes use of description() is <http://trac.webkit.org/browser/trunk/LayoutTests/fast/box-decoration-break/box-decoration-break-parsing.html?rev=199567>.
Comment 6 Daniel Bates 2016-04-14 16:40:36 PDT
For completeness, Blink addressed the <textarea> and <select> variants of this bug in <https://bugs.chromium.org/p/chromium/issues/detail?id=461414> and <https://bugs.chromium.org/p/chromium/issues/detail?id=461412>, respectively.
Comment 7 Renata Hodovan 2016-04-15 00:24:08 PDT
(In reply to comment #4)
> *** Bug 155748 has been marked as a duplicate of this bug. ***

(Btw the "duplicate" was also a reduced version of the github assert. Reported 3 weeks ago :))
Comment 8 Darin Adler 2016-04-15 08:55:10 PDT
Comment on attachment 276439 [details]
Patch

Looks OK.

We have a lot of other problems with the validity code, tracked by other bugs. Sam Weinig has questioned the value of the form validation features, although they are in the HTML standard; if we do keep them we need a much more extensive test suite and an improved implementation. At the moment the cost of trying to make these features work certainly greatly outweighs their usefulness.
Comment 9 Myles C. Maxfield 2016-04-15 12:59:11 PDT
Committed r199607: <http://trac.webkit.org/changeset/199607>