ChainSafe / lodestar

🌟 TypeScript Implementation of Ethereum Consensus
https://lodestar.chainsafe.io
Apache License 2.0
1.15k stars 283 forks source link

bug: uncaughtException: Configured bind multiaddrs must have different ports #6531

Open barnabasbusa opened 6 months ago

barnabasbusa commented 6 months ago

Describe the bug

If I configure lodestar with:

lodestar_ports_p2p_tcp: 9000
lodestar_ports_p2p_udp: 9000
  - --port={{ lodestar_ports_p2p_tcp }}
  - --port6={{ lodestar_ports_p2p_tcp }}
  - --enr.ip={{ lodestar_announced_ip }}
  - --enr.ip6={{ lodestar_announced_ipv6 }}
  - --enr.tcp={{ lodestar_ports_p2p_tcp }}
  - --enr.tcp6={{ lodestar_ports_p2p_tcp }}
  - --enr.udp={{ lodestar_ports_p2p_udp }}
  - --enr.udp6={{ lodestar_ports_p2p_udp }}
  - --discoveryPort6={{ lodestar_ports_p2p_udp }}
Mar-12 13:50:11.814[network]         error: uncaughtException: Configured bind multiaddrs must have different ports
Error: Configured bind multiaddrs must have different ports
    at new UDPTransportService (file:///usr/app/node_modules/@chainsafe/discv5/lib/transport/udp.js:59:23)
    at Discv5.create (file:///usr/app/node_modules/@chainsafe/discv5/lib/service/service.js:126:97)
    at file:///usr/app/packages/beacon-node/lib/network/discv5/worker.js:43:23 - Configured bind multiaddrs must have different ports
Error: Configured bind multiaddrs must have different ports
    at new UDPTransportService (file:///usr/app/node_modules/@chainsafe/discv5/lib/transport/udp.js:59:23)
    at Discv5.create (file:///usr/app/node_modules/@chainsafe/discv5/lib/service/service.js:126:97)
    at file:///usr/app/packages/beacon-node/lib/network/discv5/worker.js:43:23
 ✖ Error: Configured bind multiaddrs must have different ports
    at new UDPTransportService (file:///usr/app/node_modules/@chainsafe/discv5/lib/transport/udp.js:59:23)
    at Discv5.create (file:///usr/app/node_modules/@chainsafe/discv5/lib/service/service.js:126:97)
    at file:///usr/app/packages/beacon-node/lib/network/discv5/worker.js:43:23

Expected behavior

I'd expect that ipv4 and ipv6 enr address ports wouldn't clash, and thus be able to come online without crashing.

Steps to reproduce

Additional context

No response

Operating system

Linux

Lodestar version or commit hash

v1.17.0

philknows commented 6 months ago

I would expect this to not clash either. Any ideas on what may be happening here @wemeetagain ?