Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upSpeedometer 2.0 fails at backbone test #18442
Comments
|
I'm having deja vu about this one. Is this related to needing to bump the mozjs/sm version? |
|
Here's the surrounding context of the error: new BenchmarkTestStep('CompletingAllItems', function (newTodo, contentWindow, contentDocument) {
var checkboxes = contentDocument.querySelectorAll('.toggle');
for (var i = 0; i < numberOfItemsToAdd; i++)
checkboxes[i].click();
}),I'm suspecting that |
|
Can I take this bug? It seems like the test is creating the checkboxes by simulating typing and pressing Enter on an input element. Servo is not handling the Enter keypress correctly for some reason (the event does not reach jQuery, and so it also doesn't reach the TodoMVC JS code), and I would like to investigate a bit. |
|
Ooh, please do! Glad to hear you have a theory. |
|
You may want to look at .https://github.com/servo/servo/blob/master/components/script/textinput.rs |
|
So, https://github.com/servo/servo/blob/master/components/script/dom/document.rs#L1393 also seems relevant. It seems we only trigger keypress events when they correspond to a printable key, which (naively) means we would only get keyup and keydown events for pressing Enter, but never keypress. Does this seem plausible, or is it the kind of thing which would manifest itself in popular websites? Relevant: https://bugzilla.mozilla.org/show_bug.cgi?id=968056. Apparently Servo follows the DOM 3 Events standard, and so does Blink. I will try to figure out why this works on Chrome. |
|
Easy test: <script>addEventListener('keypress', function(e) { console.log("press: " + e.key); })</script>I only see output when pressing keys like 'a', 'f', '5'. Enter does not trigger it. |
|
I believe the
(https://w3c.github.io/uievents/#event-type-keypress) |
|
Apologies, I made a mistake! There are two issues related to TodoMVC:
I will investigate why this is the case tomorrow. [0] http://swannodette.github.io/todomvc/architecture-examples/backbone/index.html |
|
Oh, that will be fixed by #17896. However, we need to release a new version of html5ever before that can merge (which is waiting on servo/html5ever#304). |
|
Good to know, thanks! So I guess the bug @jonathandturner found is already fixed :) I'll look at the other one (item 1) as soon as possible. |
|
We can now progress beyond this test. |
If you run the Speedometer 2.0 test on AWFY, with the latest Servo you can get through the 20 or so tests but then it will stop on the Backbone test at
BackboneJS-TodoMVC(22 / 480):Terminal:
(will try to dig in a bit further, but just wanted to post this before I did)