On my localhost I get the following error every time I close a browser.
- ERRO err:read tcp 127.0.0.1:59516->127.0.0.1:59515: wsarecv: An existing connection was forcibly closed by the remote host. category=“Connection:handleIOError” elapsed=“0 ms” goroutine=47
Your ports may vary. (YPMV)
The tests seem to go through any way but the console is a red mess afterwards.
Page.close() does not generate any errors, only browser.close().
I am running on windows 10 towards localhost and I not running in docker.
Is there a way to fix this on my side?
Hi Joel, thanks for reporting this issue.
As you noticed, this error sometimes happens when the browser is closed, but otherwise doesn’t impact the test itself.
This is a similar error to the one in issue #232. I added a comment there to make sure we address this one as well. They’re both related to an improper way of handling the closing of the WebSocket connection, so we should definitely fix it. It’s now planned as part of the v0.4.0 release, and we’ll get to it in the upcoming weeks.
Just to confirm, which xk6-browser version are you using? The latest officially released binary (v0.2.0) or compiled by yourself from the
I am using v0.2.0 from binary.
I was also experiencing some issues with a Microsoft SignalR connection (which I assume also is websockets) but just turned that feature of for test purposes.