You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
testing on the same machine, and 2 machines over LAN
two nodes connect as expected
// pc aconstswarm=hyperswarm()swarm.join(hash,{lookup:true,announce: true})swarm.on("connection",()=>{console.log("yuppie")})// pc bconstswarm=hyperswarm()swarm.join(hash,{lookup:true,announce: true})swarm.on("connection",()=>{console.log("yuppie")})
two nodes does not connect
// pc aconstswarm=hyperswarm()setTimeout(()=>swarm.join(hash,{lookup:true,announce: true}),5000)swarm.on("connection",()=>{console.log("never happens")})// pc bconstswarm=hyperswarm()setTimeout(()=>swarm.join(hash,{lookup:true,announce: true}),10000)swarm.on("connection",()=>{console.log("never happens")})
workaround (the nodes connect)
// pc aconstswarm=hyperswarm()swarm.network.bind()setTimeout(()=>swarm.join(hash,{lookup:true,announce: true}),5000)swarm.on("connection",()=>{console.log("yuppie")})// pc bconstswarm=hyperswarm()swarm.network.bind()setTimeout(()=>swarm.join(hash,{lookup:true,announce: true}),10000)swarm.on("connection",()=>{console.log("yuppie")})
Maybe i am missing something in the docs?
Maybe it has something to do with how discovery cycle works?
The text was updated successfully, but these errors were encountered:
repo https://github.com/freddi301/p2p-network-tools/tree/master/desktop
If i join a common topic right after initializing the swarm, the two nodes do connect.
If i join a common topic some time after initializing swarm the two nodes do not connect.
If i call swarm.network.bind() right after swarm initialization and join a common topic some time after, the two nodes do connect.
I updated the description
testing on the same machine, and 2 machines over LAN
two nodes connect as expected
two nodes does not connect
workaround (the nodes connect)
Maybe i am missing something in the docs?
Maybe it has something to do with how discovery cycle works?
The text was updated successfully, but these errors were encountered: