field-manual icon indicating copy to clipboard operation
field-manual copied to clipboard

In `04_P2P_Part_1`, `NPP.connectToPeer` got `Error: Circuit relay dial failed as addresses did not have peer id`

Open zhiquan911 opened this issue 2 years ago • 6 comments

When I was studying the chapter of 04_P2P_Part_1, I opened two browsers, and the node of one browser called NPP.connectToPeer("QmUExv5GFBqqMWq9PQcur4UmnEGiY99gmqZQoMgCd2C8rd") to connect to the node of the other browser. I got Error: Circuit dial relay failed as addresses did not have peer id.

zhiquan911 avatar Jul 08 '21 08:07 zhiquan911

did you solve your problem ? same thing for me

lilian131 avatar Dec 05 '21 08:12 lilian131

Now how is the situation, I also have this problem, which makes it can't learn later.

Gezi-lzq avatar Feb 10 '22 09:02 Gezi-lzq

I had the same problem. I ended up having to implement a Webrtc-star server (https://suda.pl/free-webrtc-star-heroku/) to fix connection issues. Let me know if I can help further!

julienmalard avatar Feb 22 '22 06:02 julienmalard

Hi @julienmalard, thanks so much for pointing to this. Do you have any example code you could share for how you implemented this in regards to the orbit-db tutorial?

phonofidelic avatar Feb 25 '22 22:02 phonofidelic

No problem! Here's my code: https://github.com/reseau-constellation/ipa/blob/main/src/ipfs.ts I added a line for my specific Webrtc-star server.

julienmalard avatar Feb 26 '22 03:02 julienmalard

No problem! Here's my code: https://github.com/reseau-constellation/ipa/blob/main/src/ipfs.ts I added a line for my specific Webrtc-star server. You would then simply pass this ipfs instance into the orbit-db instance when you create it, and all should then work.

julienmalard avatar Feb 26 '22 03:02 julienmalard