Skip to content
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

[BUG] Frames crashes everything #5111

Closed
shirshak55 opened this issue Jan 22, 2021 · 7 comments
Closed

[BUG] Frames crashes everything #5111

shirshak55 opened this issue Jan 22, 2021 · 7 comments
Assignees

Comments

@shirshak55
Copy link

shirshak55 commented Jan 22, 2021

Context

Version: ^1.8 (I have issue with above 1.7 too)
OS: Windows / MacOS (Not tested on LINUX)

Logs

 pw:api   selector resolved to visible <td>…</td> +12ms
  pw:api <= page.waitForSelector succeeded +4ms
  pw:api => page.evaluate started +1ms
  pw:api <= page.evaluate succeeded +5ms
  pw:api => page.evaluate started +0ms
  pw:api <= page.evaluate succeeded +2ms
[TEST] TESTING CHAT
  pw:api   "networkidle" event fired +478ms
  pw:api => page.reload started +5s
  pw:api waiting for navigation until "load" +1ms
Error: net::ERR_ABORTED; maybe frame was detached?
    at FrameManager.frameAbortedNavigation (C:\Users\shirshak\Desktop\new-chat-app\node_modules\playwright\lib\server\frames.js:177:20)
    at FrameManager.requestFailed (C:\Users\shirshak\Desktop\new-chat-app\node_modules\playwright\lib\server\frames.js:225:18)
    at CRNetworkManager._onLoadingFailed (C:\Users\shirshak\Desktop\new-chat-app\node_modules\playwright\lib\server\chromium\crNetworkManager.js:330:34)
    at CRSession.emit (node:events:327:20)
    at C:\Users\shirshak\Desktop\new-chat-app\node_modules\playwright\lib\server\chromium\crConnection.js:155:22
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

And its always frames I don't know why. Its a normal code with page.goto.

Is there anyway at least just to ignore this error? Currently it stops whole node process and kills every contexts .

Global Error catcher are also not working:

I have even wrote following silly code:

process.on("uncaughtException", () => {
    console.log("uncaught exception")
})

process.on("unhandledRejection", () => {
    console.log("uncaught exception")
})

But it still doesn't obey this and crashes everything.

When does it happens?

  • In headful mode lets say page is going to reload and if i submit "submit" button etc then if playwright reload the page it will crash.

Thanks.

@dgozman
Copy link
Contributor

dgozman commented Jan 22, 2021

@shirshak55 Could you please answer some questions for us to better understand the issue?

  • Is it possible to provide the url/script to repro this?
  • Does this only happen in headful mode?
  • Does this only happen after you click "submit" button and then reload? Could you please check whether form submit is a GET or a POST (open DevTools manually before submitting, and look for the new request in the network tab)?
  • If it is possible to run with DEBUG=pw:protocol,pw:api and send the log file, that would be awesome.

@shirshak55
Copy link
Author

shirshak55 commented Jan 22, 2021

@dgozman

  1. I can't provide but I am sure I saw it in nytimes newspaper website. I will check if I can reproduce the part of code.

  2. For me its on headful mode. In Headless mode I cannot interact so there is no way for me to know if there is bug or not.

  3. LOL after opening devtools there is no such bug. It comes only when devtool is turned off. And it happens only if I submit and at same time I reload page on playwright. Looks like its some sort of race condition?

  4. Here are logs.

 pw:api   "networkidle" event fired +404ms
  pw:protocol ◀ RECV {"method":"Page.lifecycleEvent","params":{"frameId":"37CD3451B53E2F466F0A9BF2EACC3F26","loaderId":"36A60C0AD92C601D63D19B36CA76C70E","name":"networkIdle","timestamp":273205.68016},"sessionId":"FB51CFF8688884A2ADEFDF753F8F4262"} +896ms
  pw:protocol ◀ RECV {"method":"Page.frameScheduledNavigation","params":{"frameId":"37CD3451B53E2F466F0A9BF2EACC3F26","delay":0,"reason":"formSubmissionPost","url":"https://secret.chat.app/secret?s=B"},"sessionId":"FB51CFF8688884A2ADEFDF753F8F4262"} +4s
  pw:protocol ◀ RECV {"method":"Page.frameRequestedNavigation","params":{"frameId":"37CD3451B53E2F466F0A9BF2EACC3F26","reason":"formSubmissionPost","url":"https://secret.chat.app/secret?s=B","disposition":"currentTab"},"sessionId":"FB51CFF8688884A2ADEFDF753F8F4262"} +1ms
  pw:protocol ◀ RECV {"method":"Page.frameStartedLoading","params":{"frameId":"37CD3451B53E2F466F0A9BF2EACC3F26"},"sessionId":"FB51CFF8688884A2ADEFDF753F8F4262"} +0ms
  pw:protocol ◀ RECV {"method":"Network.requestWillBeSent","params":{"requestId":"202F84FF7469DF75F393A0A4A68ED0C7","loaderId":"202F84FF7469DF75F393A0A4A68ED0C7","documentURL":"https://secret.chat.app/secret?s=B","request":{"url":"https://secret.chat.app/secret?s=B","method":"POST","headers":{"sec-ch-ua":"\" Not A;Brand\";v=\"99\", \"Chromium\";v=\"90\"","sec-ch-ua-mobile":"?0","Upgrade-Insecure-Requests":"1","Origin":"https://secret.chat.app","Content-Type":"application/x-www-form-urlencoded","User-Agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4392.0 Safari/537.36","Referer":"https://secret.chat.app/secret?s=B"},"postData":"__EVENTTARGET=&__EVENTARGUMENT=&__LASTFOCUS=&__VIEWSTATE=%2FwEPDwULLTE3NjQ0MzIxMTYPZBYCZg9kFg5mDxBkEBUDCUZhbGwgMjAyMAtXaW50ZXIgMjAyMQtTcHJpbmcgMjAyMRUDBDEyMDQEMTIwNwQxMjExFCsDA2dnZxYBAgJkAgEPEGQQFQoHLS1BTEwtLRhSZWd1bGFyIEFjYWRlbWljIFNlc3Npb24QQi1TcHJpbmcgUmVndWxhch5CLVNwcmluZyBGaXJzdCBXZWVrZW5kIFNlc3Npb24dQi1TcHJpbmcgU2Vjb25kIFdrZW5kIFNlc3Npb24eQi1TcHJpbmcgRnJzdCBTZXZlbiBXayBTZXNzaW9uHUItU3ByaW5nIFNuZCBTZXZlbiBXayBTZXNzaW9uG0ItU3ByaW5nIEZpcnN0IDUgV2sgU2Vzc2lvbhxCLVNwcmluZyBTbmQgRml2ZSBXayBTZXNzaW9uHkItU3ByaW5nIFRoaXJkIEZpdmUgV0sgU2Vzc2lvbhUKAi0xATEDQjIwA0IyMQNCMjIDQjIzA0IyNANCMjUDQjI2A0IyNxQrAwpnZ2dnZ2dnZ2dnFgFmZAICDxBkEBUvBy0tQUxMLS0aQXRobGV0aWMgVHJuIEhsdGgmRXhjciBTY2kMQmlvY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QZkUwVDVxY0FkTURySzhVSVdRS0V2TGpKSiUyQmkzekxXeCUyQkRWWTlJQlNyNGR3d2NxdjhKekdMZWFNSDM3TkJkdG1LTHBlJTJGQ2hmV0xsb0tyNlNCRG56ZkRoaFE1SkZCQlVPdEg5dFYwY1clMkJ1OE5MWHV6UnVubzBXM3FjZE5tdTNGejBvWGNFUk04aSUyRiUyQngycEM1bnpKUmIyaXZadnFLRldCWnZrWDkyVkxYUllTZUhzWVlWMG16RDlqNkNXQk9uZ3JZczROOVRSNlUlMkJNdnU1MkpaWGg5bmZPRWc2Q3JreDAzWWRkZTdvSWNWJTJCM2Ztb2FzMEtFRjJkWkI5UTBRSk9PUjh5d0k1Nml0SiUyQkdKS0w2bTNrQnJteVp3MjJVY25LVkI1RzdLOSUyQlFFb1hURCUyRmZBRkhITnpJNXBTenFHR0lKajJVZms5b3UlMkZsNGV3Vk0yY1gzSU1lcTZSclY5WXEzWVl5MDRpYmFmTmI5SWdoaUFSRHc2V0tVUWlSZFFmRzElMkJFQVdKdTFHdHM4ekxFJTJCeTZTMERsV2FaTkJsYnNWelljSUJZYmhoSXd3TWRXWEZxRWZOUzJpNVJCc1Y2Zlc2Z1piY3RudGQxJTJCeTlVd2NxWE1LWjVKeFE0TWlXcHo1S0dUcnglMkZ2cFBQSHl4M0M0TlJQckomU2VtZXN0ZXJfWXI9MTIxMSZUZXJtU2Vzc2lvbj0tMSZTY2hvb2w9QlBIQVJNQUNZJkRlcGFydG1lbnQ9LTEmQ291cnNlTGV2ZWw9LTEmdGJDb3Vyc2U9MzEwJlNlYXJjaD1TZWFyY2g="}],"mixedContentType":"none","initialPriority":"VeryHigh","referrerPolicy":"strict-origin-when-cross-origin"},"timestamp":273210.787467,"wallTime":1611343249.49175,"initiator":{"type":"other"},"type":"Document","frameId":"37CD3451B53E2F466F0A9BF2EACC3F26","hasUserGesture":true},"sessionId":"FB51CFF8688884A2ADEFDF753F8F4262"} +2ms
  pw:protocol ◀ RECV {"method":"Page.frameClearedScheduledNavigation","params":{"frameId":"37CD3451B53E2F466F0A9BF2EACC3F26"},"sessionId":"FB51CFF8688884A2ADEFDF753F8F4262"} +5ms
  pw:protocol ◀ RECV {"method":"Network.requestWillBeSentExtraInfo","params":{"requestId":"202F84FF7469DF75F393A0A4A68ED0C7","associatedCookies":[{"blockedReasons":[],"cookie":{"name":"ASP.NET_SessionId","value":"o531zfkqb05rztswvwr5s50h","domain":"secret.chat.app","path":"/","expires":-1,"size":41,"httpOnly":true,"secure":false,"session":true,"priority":"Medium","sameParty":false}}],"headers":{"Host":"secret.chat.app","Connection":"keep-alive","Content-Length":"6503","Cache-Control":"max-age=0","sec-ch-ua":"\" Not A;Brand\";v=\"99\", \"Chromium\";v=\"90\"","sec-ch-ua-mobile":"?0","Upgrade-Insecure-Requests":"1","Origin":"https://secret.chat.app","Content-Type":"application/x-www-form-urlencoded","User-Agent":"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/90.0.4392.0 Safari/537.36","Accept":"text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9","Sec-Fetch-Site":"same-origin","Sec-Fetch-Mode":"navigate","Sec-Fetch-User":"?1","Sec-Fetch-Dest":"document","Referer":"https://secret.chat.app/secret?s=B","Accept-Encoding":"gzip, deflate, br","Accept-Language":"en-US,en;q=0.9","Cookie":"ASP.NET_SessionId=o531zfkqb05rztswvwr5s50h"}},"sessionId":"FB51CFF8688884A2ADEFDF753F8F4262"} +0ms
  pw:api => page.reload started +5s
  pw:api waiting for navigation until "load" +0ms
  pw:protocol SEND ► {"id":171,"method":"Page.reload","sessionId":"FB51CFF8688884A2ADEFDF753F8F4262"} +1ms
  pw:protocol ◀ RECV {"method":"Network.loadingFailed","params":{"requestId":"202F84FF7469DF75F393A0A4A68ED0C7","timestamp":273210.79604,"type":"Document","errorText":"net::ERR_ABORTED","canceled":true},"sessionId":"FB51CFF8688884A2ADEFDF753F8F4262"} +2ms
Error: net::ERR_ABORTED; maybe frame was detached?
    at FrameManager.frameAbortedNavigation (C:\Users\shirshak\Desktop\new-liu\node_modules\playwright\lib\server\frames.js:177:20)
    at FrameManager.requestFailed (C:\Users\shirshak\Desktop\new-liu\node_modules\playwright\lib\server\frames.js:225:18)
    at CRNetworkManager._onLoadingFailed (C:\Users\shirshak\Desktop\new-liu\node_modules\playwright\lib\server\chromium\crNetworkManager.js:330:34)
    at CRSession.emit (node:events:327:20)
    at C:\Users\shirshak\Desktop\new-liu\node_modules\playwright\lib\server\chromium\crConnection.js:155:22
    at processTicksAndRejections (node:internal/process/task_queues:93:5)
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.

Thanks.

@dgozman
Copy link
Contributor

dgozman commented Jan 22, 2021

@shirshak55 Thanks, I can repro now. I'd like to better understand your scenario though. So, you are manually submitting a form and at the same time doing page.reload() in Playwright script? This sounds like a recipe for getting race issues. Perhaps it would be better to finish submitting the form, and then reload? What are you trying to achieve or test here?

Now, what's happening. Playwright issues page.reload() but since there is already a navigation in progress (the form submit), it gets the net::ERR_ABORTED error because that navigation is aborted, and decides that reload did not succeed. I will look into how we can make this better.

@shirshak55
Copy link
Author

shirshak55 commented Jan 22, 2021

@dgozman Sometime we manually adjust filters in chat section (Like changing color, theme etc) (doing that from playwright is abit complicated as we are in testing phase) that reloads the page. But we monitor the chat for Machine learning purpose which needs reloading like 30 second.

I think in any case browser/node process shouldn't stop. At least it should be caught by extension. May be if script is reloading the page it should stop manual reload and reload normally? I don't know whats the best way to solve this issue :)

And the problem is not just manual imagine page refresh itself and playwright also tries to refresh it may crash right?

Thank You 👍

@dgozman
Copy link
Contributor

dgozman commented Jan 22, 2021

I'd suggest you to just catch the reload in this case, because it seems totally fine in your usecase that reload does not work, and instead the form submit happens. Does that sound right?

await page.reload().catch(console.log);

However, this particular race scenario seems to be broken currently, and page.reload() would still throw from inside, even if you catch it. I'll work on the fix.

@shirshak55
Copy link
Author

shirshak55 commented Jan 22, 2021

@dgozman that doesn't work.

I have already done similar to this

await page.reload().catch(e=>undefined)

Yea I think this issue will be fixed if that race condition is fixed.

@dgozman
Copy link
Contributor

dgozman commented Jan 27, 2021

page.reload().catch(e => undefined) should work with playwright@next. Thank you for the issue!

@dgozman dgozman closed this as completed Jan 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants