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

Dialer.connectToPeer fails badly if no addrs #672

Closed
dthorpe opened this issue Jun 16, 2020 · 1 comment
Closed

Dialer.connectToPeer fails badly if no addrs #672

dthorpe opened this issue Jun 16, 2020 · 1 comment
Labels
kind/bug A bug in existing code (including security flaws) status/ready Ready to be worked

Comments

@dthorpe
Copy link

dthorpe commented Jun 16, 2020

Version: package.json version or the commit you have installed.
Platform: output of uname -a (UNIX), or version and 32 or 64-bit (Windows). If using in a Browser, please share the browser version as well.
Subsystem: if known, please specify affected core module name (e.g Transports, SECIO, etc).

If possible, please provide code that demonstrates the problem, keeping it as
simple and free of external dependencies as you are able.
-->

  • Version: 0.28.2
  • Platform: Darwin Kernel Version 17.7.0: Wed May 27 17:00:02 PDT 2020; root:xnu-4570.71.80.1~1/RELEASE_X86_64 x86_64
  • Subsystem: libp2p/dialer

Type: Bug

Severity: Medium

Description:

calling Dialer.connectToPeer with a peer that has no addresses fails with

Unhandled Rejection (TypeError): Cannot read property 'length' of undefined

Steps to reproduce the error:

const peer = new PeerId(Buffer.from("QmfEa1LrSt2R7KiZ31yPo3TT8ipfyDfrMRkaQix3rcXXXX"))
await dialer.connectToPeer(peer)
@vasco-santos vasco-santos added kind/bug A bug in existing code (including security flaws) status/ready Ready to be worked labels Jun 17, 2020
@jacobheun
Copy link
Contributor

Fixed by #715

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

Successfully merging a pull request may close this issue.

3 participants