-
Notifications
You must be signed in to change notification settings - Fork 9.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
feat(chromium)!: roll to Chromium 97.0.4692.0 (r938248) #7764
Conversation
22e6234
to
5e5745c
Compare
@@ -68,13 +69,17 @@ export class HTTPResponse { | |||
ip: responsePayload.remoteIPAddress, | |||
port: responsePayload.remotePort, | |||
}; | |||
this._status = responsePayload.status; | |||
// TODO extract statusText from extraInfo.headersText instead if present |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For my own understanding, is this a TODO you expect to wrap up before landing this patch, or a follow-up? (In case of the latter, let's file a tracking bug?)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I copied it from Joey's PR #7640 so I plan to add him as a reviewer here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I tried to do this but ran into an issue. I'll try again and update with more context
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, I just pushed a commit to my PR which takes care of this.
@josepharhar I am trying to roll Chromium now that your CLs have landed. I have copied the fixes from your PR #7640 but there is still one test failing (https://github.com/puppeteer/puppeteer/runs/4176540107?check_suite_focus=true) Do you think it could be related to your CLs too? Also, please review the changes. |
821b3d1
to
728d7f5
Compare
It looks like the status of the response after the redirect is sometimes wrong (302 instead of 200) https://github.com/puppeteer/puppeteer/runs/4177611057?check_suite_focus=true |
b8db156
to
71663a1
Compare
Sorry I didn’t look at this today, hopefully I’ll have a chance tomorrow |
I checked out this PR on my glinux machine, and I wasn't able to reproduce the failure when running the tests. Wouldn't it make sense to do this roll and let me merge my PR separately? You could mark any network tests as failing if needed. |
No, I cannot reproduce locally as well :( I am going to try to reproduce it again next week.
Usually we fix everything before or with the roll PR. I think it does not make much sense to roll with the broken functionality. Feel free to make changes to this branch if you need to! Or you can take over other changes to your PR and include the roll there. |
I believe it's flaky. Sometimes there are completely different network test failing but all seem to be failing on assertions for the network response attributes. |
I think that |
I don't have permission to push to this branch, but I added commits to my PR to try to try to wait for ExtraInfo events. Unfortunately the tests still fail, and I don't know if my changes actually made it better or not because I can't reproduce the failure locally and I can't even push a commit that uses |
@josepharhar is the eslint complaining about .only? usually you can push |
I have merged the changes from the other branch here and cleaned up some debugging stuff. Let's see if it passes now. |
f5064ae
to
9221e28
Compare
@josepharhar I was able to reproduce the flake with the CDP log on the bot. Here is the relevant part https://gist.github.com/OrKoN/369323d11b1106c525f23a4ad9ec5a5b So the test fails because the response code is 302 instead of 200. I can see the extra info events with 302 and 200 status codes so I suspect that we might be calling _emitResponseEvent with the wrong extraInfo event. |
9221e28
to
2b1c596
Compare
@josepharhar I came to a conclusion that there is an extra extraInfo event sent for empty.html URL sometimes that cause the wrong HTTP status for the entire redirection chain. I have captured that in a reproducible new (true) unit test. Could you please take a look? |
); | ||
this._forgetRequest(request, false); | ||
if (extraInfos.length) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@josepharhar in particular, I have added this check here: is my understanding correct that there should be no unprocessed extraInfo events if we emit _emitResponseEvent?
For each redirect, chromium should emit one requestWillBeSentExtraInfo and one responseReceivedExtraInfo.
Is the issue that the order of events as I listed is wrong? Or is the issue that there are more or less ExtraInfo events than I listed? |
I'm reading the log you shared to try to answer that question |
@josepharhar thanks a lot for fixing it! I am not very familiar with the backend implementation for these events but it'd be great to expand the unit tests if you know what are the possible/supported (or also unsupported) orders in which events could arrive. |
2d8a490
to
32f5c4c
Compare
Sounds good, I can add more coverage to |
Thanks, I think that we don't need to block on that too. I have just removed some awaits that I have added previously to see if they are redundant with the fixes. For the unit tests, I think we need to make some changes in types and TS configuration so that we could define test cases without defining the entire event payloads that are not used by the network manager directly. |
We could just move the |
Let's keep the test for coverage and refactor later. I think this is ready to land: do you want me to land your PR or is it okay to land this one? |
Issues: #7458