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

Socket error ECONNRESET when targeting webkit browser with Playwright #473

Open
fpaul-1A opened this issue Mar 6, 2023 · 1 comment
Open

Comments

@fpaul-1A
Copy link

fpaul-1A commented Mar 6, 2023

Hello,

I've started to look into Kassette to provide mocks for our E2E tests using Playwright.
I managed to make it work quite easily and it fits perfectly our needs, thank you for that :)

I've noticed some issues when running in local on Webkit browser only (on windows, node18), working as expected of Chromium and Firefox.
I see the following error when it tries to intercept an https request

Socket error
Error: read ECONNRESET
    at TCP.onStreamRead (node:internal/stream_base_commons:217:20)

and then the proxy fails to respond to the call

I am not sure if the issue is caused by Kassette directly, however I don't see the error when not using a proxy-server
I've created a repository to reproduce this issue with a basic web page https://github.com/fpaul-1A/kassette-playground

Also, the error doesn't seem to happen on the CI with Ubuntu (I have other issues on Windows and Mac-OS though)
https://github.com/fpaul-1A/kassette-playground/actions/runs/4325102305

Thank you for your help

@divdavem
Copy link
Member

Hello @fpaul-1A

Thank you for reporting this issue and sorry for the delay to answer.
This looks like an issue in Playwright.

With the latest version of Playwright (1.32.3), the issue does not seem to happen anymore on Windows (there may be some ECONNRESET error in the console, but the browser apparently retries the connection and the test passes).
The problem still happens on MacOS.

I forked your repository and fixed the other issues you were mentioning. Here are the results of tests in GitHub CI (click on the icons to see the corresponding logs):

Playwright version Ubuntu Windows MacOS
1.31.0 ✔️
1.32.3 ✔️ ✔️

I have opened this issue on Playwright to fix the issue on MacOS.

Best regards

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants