yggdrasil-network / yggdrasil-go

An experiment in scalable routing as an encrypted IPv6 overlay network

Home Page:https://yggdrasil-network.github.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

panic: this should never happen

0x1a8510f2 opened this issue · comments

Looks like you were wrong! :P

panic: this should never happen
goroutine 958 [running]:
github.com/Arceliar/ironwood/network.(*bloom).encode(0xc000288020, {0xc0004600a0, 0x3, 0x4e})
	/go/pkg/mod/github.com/!arceliar/ironwood@v0.0.0-20231104025256-ec84c695fc44/network/bloomfilter.go:78 +0x338
github.com/Arceliar/ironwood/network.wireEncode({0xc0004600a0?, 0x171eea6e5e0b?, 0x0?}, 0x48?, {0x946ff8?, 0xc000288020?})
	/go/pkg/mod/github.com/!arceliar/ironwood@v0.0.0-20231104025256-ec84c695fc44/network/wire.go:65 +0x6f
github.com/Arceliar/ironwood/network.(*peerWriter).sendPacket.func1()
	/go/pkg/mod/github.com/!arceliar/ironwood@v0.0.0-20231104025256-ec84c695fc44/network/peers.go:207 +0x186
github.com/Arceliar/phony.(*Inbox).run(0xc0004701f8)
	/go/pkg/mod/github.com/!arceliar/phony@v0.0.0-20220903101357-530938a4b13d/actor.go:98 +0x2d
created by github.com/Arceliar/phony.(*Inbox).restart in goroutine 957
	/go/pkg/mod/github.com/!arceliar/phony@v0.0.0-20220903101357-530938a4b13d/actor.go:132 +0x4f

I'm not sure what the conditions are to reproduce this, but it has been happening to my instance constantly as of late. My instance runs in Docker using the official Dockerfile. The config is as follows:

{
  # List of connection strings for outbound peer connections in URI format,
  # e.g. tls://a.b.c.d:e or socks://a.b.c.d:e/f.g.h.i:j. These connections
  # will obey the operating system routing table, therefore you should
  # use this section when you may connect via different interfaces.
  Peers: [
    # Poland
    "tls://pl1.servers.devices.cwinfo.net:11129",
    "tls://54.37.137.221:11129",
    #"tls://[2001:41d0:601:1100::cf2]:11129",

    # United Kingdom
    "tcp://curiosity.tdjs.tech:30003",
    "tls://uk1.servers.devices.cwinfo.net:28395",
    "tls://51.38.64.12:28395",
    #"tls://[2a10:4740:40:0:2222:3f9c:b7cf:1]:43006"
  ]

  # List of connection strings for outbound peer connections in URI format,
  # arranged by source interface, e.g. { "eth0": [ "tls://a.b.c.d:e" ] }.
  # Note that SOCKS peerings will NOT be affected by this option and should
  # go in the "Peers" section instead.
  InterfacePeers: {}

  # Listen addresses for incoming connections. You will need to add
  # listeners in order to accept incoming peerings from non-local nodes.
  # Multicast peer discovery will work regardless of any listeners set
  # here. Each listener should be specified in URI format as above, e.g.
  # tls://0.0.0.0:0 or tls://[::]:0 to listen on all interfaces.
  Listen: [
    "tcp://0.0.0.0:11100",
    "tcp://[::]:11100",
    "tls://0.0.0.0:11101",
    "tls://[::]:11101",
    "quic://0.0.0.0:11102",
    "quic://[::]:11102",
  ]

  # Listen address for admin connections. Default is to listen for local
  # connections either on TCP/9001 or a UNIX socket depending on your
  # platform. Use this value for yggdrasilctl -endpoint=X. To disable
  # the admin socket, use the value "none" instead.
  AdminListen: none

  # Configuration for which interfaces multicast peer discovery should be
  # enabled on. Each entry in the list should be a json object which may
  # contain Regex, Beacon, Listen, and Port. Regex is a regular expression
  # which is matched against an interface name, and interfaces use the
  # first configuration that they match gainst. Beacon configures whether
  # or not the node should send link-local multicast beacons to advertise
  # their presence, while listening for incoming connections on Port.
  # Listen controls whether or not the node listens for multicast beacons
  # and opens outgoing connections.
  MulticastInterfaces: []

  # List of peer public keys to allow incoming peering connections
  # from. If left empty/undefined then all connections will be allowed
  # by default. This does not affect outgoing peerings, nor does it
  # affect link-local peers discovered via multicast.
  AllowedPublicKeys: []

  # Your private key. DO NOT share this with anyone!
  PrivateKey: <REDACTED>
  
  # Local network interface name for TUN adapter, or "auto" to select
  # an interface automatically, or "none" to run without TUN.
  IfName: none
  
  # Maximum Transmission Unit (MTU) size for your local TUN interface.
  # Default is the largest supported size for your platform. The lowest
  # possible value is 1280.
  IfMTU: 65535

  # By default, nodeinfo contains some defaults including the platform,
  # architecture and Yggdrasil version. These can help when surveying
  # the network and diagnosing network routing problems. Enabling
  # nodeinfo privacy prevents this, so that only items specified in
  # "NodeInfo" are sent back if specified.
  NodeInfoPrivacy: true

  # Optional node info. This must be a { "key": "value", ... } map
  # or set as null. This is entirely optional but, if set, is visible
  # to the whole network on request.
  NodeInfo: {
    "node": "l1qu1d ygg0",
    "name": "l1qu1d ygg0",
    "operator": "l1qu1d",
    "location": "Opole Vivodeship, Poland"
  } 
}   

please show yggdrasil version
Seems you have version lowest that 0.5.4

Hmm, you may be onto something.

image

Might be that something got borked in the build process. I've rebuilt the container, it now shows Build version: 0.5.4-2-g3dfa6d0, and the issue doesn't seem to show up anymore, at least for the moment.

I'll close the issue, and reopen should it show up again.