Skip to content
This repository has been archived by the owner on Feb 12, 2024. It is now read-only.

Uncaught Error: underlying socket has been closed #883

Closed
pgte opened this issue Jun 19, 2017 · 2 comments
Closed

Uncaught Error: underlying socket has been closed #883

pgte opened this issue Jun 19, 2017 · 2 comments
Labels
kind/bug A bug in existing code (including security flaws)

Comments

@pgte
Copy link
Contributor

pgte commented Jun 19, 2017

When using the Webrtc transport and disconnecting the network, this error is logged.

index.js:477 Uncaught Error: underlying socket has been closed
    at index.js:477
    at Array.forEach (<anonymous>)
    at Multiplex.destroy (index.js:475)
    at index.js:43
    at call (index.js:50)
    at Array.forEach (<anonymous>)
    at index.js:70
    at f (once.js:25)
    at Stream.<anonymous> (index.js:29)
    at Stream.f (once.js:25)

The error does not seam to be handled, since the peer connection keeps existing, never leaving.

ipfs-shipyard/y-ipfs-connector#1 depends on this.

@pgte
Copy link
Contributor Author

pgte commented Jun 19, 2017

After some seconds, I witnessed another couple of possibly related errors:

index.js:27 Error: Stream ended prematurely
    at series (index.js:21)
    at parallel.js:39
    at once.js:12
    at iterateeCallback (eachOfLimit.js:44)
    at onlyOnce.js:12
    at parallel.js:36
    at fail (finish.js:43)
    at Object.shake.handshake.read [as cb] (finish.js:46)
    at drain (index.js:42)
    at index.js:59

(this one emanates from node_modules/libp2p-secio/src/handshake/index.js:21)

and:

index.js:95 Uncaught Error: Multiplexer is destroyed
    at Multiplex.createStream (index.js:95)
    at MultiplexMuxer.newStream (muxer.js:34)
    at openConnInMuxedConn (dial.js:180)
    at gotMuxer (dial.js:74)
    at Swarm.dial (dial.js:42)
    at _getPeerInfo (index.js:251)
    at setImmediate (index.js:310)
    at setImmediate.js:27
    at onNextTick (main.js:64)
    at Item.run (browser.js:153)

(this last one emanates from node_modules/multiplex/src/index.js:95)

@daviddias daviddias added the kind/bug A bug in existing code (including security flaws) label Jun 28, 2017
@pgte
Copy link
Contributor Author

pgte commented Jun 30, 2017

Found that this was not the fault of js-ipfs directly, but rather from a lib I was using.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
kind/bug A bug in existing code (including security flaws)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants