-
Notifications
You must be signed in to change notification settings - Fork 3.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Many tests in /cookies/http-state consistently time out on Taskcluster but not on BuildBot #13204
Comments
Looks like the root cause is a Unicode error from wptserve when there are non-ASCII characters in headers (cookies in this case). To reproduce:
document.cookie="foo=你好"
Traceback:
|
Is there a spec/RFC that says what encoding HTTP headers should use? UTF-8? |
and
So, uh, not really. |
Okay... so, what do we do? I mean, hard crashing the server and indefinitely hanging the test are probably not we want in any case... Why does wptserve need to decode all header strings? |
I agree. 🙂
That would be my thought. Is there any reason not to just give a bunch of bytes to the handler? |
Looking at blame this is @FHorschig and @mikewest. |
@annevk this isn't about that specific test, it's about the wptserve behaviour |
@gsnedders yes. I can confirm reverting that change fixes the problem. |
Ah sorry, yes, either passing on bytes or applying https://infra.spec.whatwg.org/#isomorphic-encode. |
Not decoding stuff seems reasonable but it's going to need a full test run to find all the cases it breaks. Does someone have time to work on that? |
It's probably more reasonable to do isomorphic decoding since consumers likely want strings anyway as they're easier to operate on. |
@gsnedders we could, but I don't think it's needed (there's no information loss with isomorphic). If you really wanted to reinterpret you could, but for tests that's typically not what you ought to be doing (you want exact comparisons on the return values). |
Given that this is a regression and we don't run wptserve with Python3 in any critical places, shall we revert #11769 for now? |
The test sends a request to wptserve with non-ASCII characters in a header and sets up a simple handler to return the value of that header. The server shouldn't crash in either Python 2 or 3, and the response should not be garbled. The server crashes in Python 2 (#13204).
…1769)" This reverts commit 5bd512c. Fixes web-platform-tests#13204.
…1769)" This reverts commit 5bd512c. Fixes web-platform-tests#13204.
This regression is blocking https://chromium-review.googlesource.com/c/chromium/src/+/1249141. Gecko automatically imported the change in mozilla/gecko-dev@0ad26e7 although I don't know if also broke the tests. Per https://web-platform-tests.org/appendix/reverting.html I think reverting this back in #13204 (comment) would have been reasonable. Is #13246 the alternative fix? That's not a tiny change, can we revert first and combine the two commits for relanding? |
#13248 is a PR to revert it. |
OK, I've reopened and approved. @Ms2ger, can you take a look? |
The test sends a request to wptserve with non-ASCII characters in a header and sets up a simple handler to return the value of that header. The server shouldn't crash in either Python 2 or 3, and the response should not be garbled. The server crashes in Python 2 (#13204).
The test sends a request to wptserve with non-ASCII characters in a header and sets up a simple handler to return the value of that header. The server shouldn't crash in either Python 2 or 3, and the response should not be garbled. The server crashes in Python 2 (#13204).
The test sends a request to wptserve with non-ASCII characters in a header and sets up a simple handler to return the value of that header. The server shouldn't crash in either Python 2 or 3, and the response should not be garbled. The server crashes in Python 2 (#13204).
The test sends a request to wptserve with non-ASCII characters in a header and sets up a simple handler to return the value of that header. The server shouldn't crash in either Python 2 or 3, and the response should not be garbled. The server crashes in Python 2 (#13204).
The test sends a request to wptserve with non-ASCII characters in a header and sets up a simple handler to return the value of that header. The server shouldn't crash in either Python 2 or 3, and the response should not be garbled. The server crashes in Python 2 (#13204).
https://staging.wpt.fyi/results/cookies/http-state?sha=b040cb2a07&product=firefox[experimental,taskcluster]&product=firefox[buildbot,experimental]&diff=true
https://staging.wpt.fyi/results/cookies/http-state?sha=b040cb2a07&product=chrome[experimental,taskcluster]&product=chrome[buildbot,experimental]&diff=true
Presumably, the tests are a bit slow. I'll try to give them long timeout.
The text was updated successfully, but these errors were encountered: