Websocket connection failed | The helia-webpack throws an Websocket error
harmanpunn opened this issue · 3 comments
The webpack example that uses react throws the following error on the console
WebSocket connection to ‘wss://ny5.bootstrap.libp2p.io/p2p/QmQCU2EcMqAqQPR2i9bChDtGNJchTbq5TbXJJ16u19uLTa’ failed:
Failed to establish a connection to https://141.136.36.230:4001/.well-known/libp2p-webtransport?type=noise: net::ERR_CONNECTION_REFUSED.
Failed to establish a connection to https://[2a02:4780:f:f81b::1]:4001/.well-known/libp2p-webtransport?type=noise: net::ERR_ADDRESS_UNREACHABLE.
The above error keeps printing on the console
And then the app crashes.
Also getting multiple instances of the following warning:
WebTransport session establishment failed. Too many pending WebTransport sessions (64)
Hello guys
Im a bit late here, but I also received the same error. I tried a lot of things but, the issue is still there.
Any update on this?
This is expected behaviour.
In a distributed application, we discover network peers based on the peer records they leave with other peers, but when we come to connect to them, there's no guarantee they are actually still online so a lot of these connection attempts will fail.
Unfortunately browsers tend to log error messages like this, even though the application has handled the failure - there's not much we can do, except open issues against the browsers asking them not to log error messages when the error has been caught.
WebTransport session establishment failed. Too many pending WebTransport sessions (64)
This is a browser limitation that is documented here - a fix is in progress for Chromium, Firefox does not have this problem.