Bug 233224

Summary: [ Monterey ] TestWebKitAPI.WebSocket.PageWithAttributedBundleIdentifierDestroyed (API-test) is a constant timeout
Product: WebKit Reporter: Robert Jenner <jenner>
Component: WebKit APIAssignee: Alex Christensen <achristensen>
Status: RESOLVED FIXED    
Severity: Normal CC: achristensen, darin, webkit-bot-watchers-bugzilla, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: Other   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch darin: review+

Robert Jenner
Reported 2021-11-16 16:58:15 PST
TestWebKitAPI.WebSocket.PageWithAttributedBundleIdentifierDestroyed is a constant timeout on macOS Monterey. HISTORY: https://results.webkit.org/?suite=api-tests&test=TestWebKitAPI.WebSocket.PageWithAttributedBundleIdentifierDestroyed
Attachments
Patch (5.48 KB, patch)
2021-12-20 10:56 PST, Alex Christensen
no flags
Patch (3.47 KB, patch)
2021-12-20 12:47 PST, Alex Christensen
darin: review+
Radar WebKit Bug Importer
Comment 1 2021-11-16 16:58:52 PST
Robert Jenner
Comment 2 2021-11-19 11:50:17 PST
I was able to reproduce this timeout on a Release ToT build. Using the following test: Run-api-tests --release TestWebKitAPI.WebSocket.PageWithAttributedBundleIdentifierDestroyed I do want to note that I was not able to reproduce this with a Debug or a Production build. I had to specifically download a Release build, and that's where I was easily able to reproduce the timeout.
Alex Christensen
Comment 3 2021-12-20 10:44:11 PST
It seems that setting _attributedBundleIdentifier to a bundle id that doesn't exist causes it to be unable to make a network request.
Alex Christensen
Comment 4 2021-12-20 10:56:03 PST
Darin Adler
Comment 5 2021-12-20 12:19:12 PST
Comment on attachment 447611 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=447611&action=review > Source/WebKit/NetworkProcess/cocoa/NetworkSessionCocoa.mm:1767 > + if (!parameters.attributedBundleIdentifier().startsWith("com.apple.webkit.test.bundle.identifier")) Building the name of the test bundle right into the binary is usually something we try very hard to avoid. Isn’t there some other way the test could inject the evidence that it’s a test configuration?
Darin Adler
Comment 6 2021-12-20 12:19:46 PST
Comment on attachment 447611 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=447611&action=review >> Source/WebKit/NetworkProcess/cocoa/NetworkSessionCocoa.mm:1767 >> + if (!parameters.attributedBundleIdentifier().startsWith("com.apple.webkit.test.bundle.identifier")) > > Building the name of the test bundle right into the binary is usually something we try very hard to avoid. Isn’t there some other way the test could inject the evidence that it’s a test configuration? Like a separate boolean in the parameters.
Alex Christensen
Comment 7 2021-12-20 12:47:07 PST
Alex Christensen
Comment 8 2021-12-20 13:59:19 PST
Alex Christensen
Comment 9 2021-12-22 09:42:19 PST
r287359 enabled another test fixed by this.
Note You need to log in before you can comment on or make changes to this bug.