Skip to content

Crash on startup on wireguard net interface #134

@baryluk

Description

@baryluk

At commit aee8b9c

user@debian:~/SysMonTask$ sudo sysmontask
5.9.8
color prifile in the setting {'cpu': (0.384, 0.749, 1.0), 'memory': (0.627, 0.196, 0.788), 'disk': (0.109, 0.67, 0.0588), 'network': (0.709, 0.164, 0.164), 'gpu': (0.384, 0.749, 1.0)}
cpuInit
Memory Tab Initialising
sda
nvme1n1
nvme0n1
Traceback (most recent call last):
  File "/usr/local/bin/sysmontask", line 33, in <module>
    sys.exit(load_entry_point('sysmontask==1.0.0', 'console_scripts', 'sysmontask')())
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/dist-packages/sysmontask-1.0.0-py3.11.egg/sysmontask/sysmontask.py", line 1127, in start
    main=myclass()
         ^^^^^^^^^
  File "/usr/local/lib/python3.11/dist-packages/sysmontask-1.0.0-py3.11.egg/sysmontask/sysmontask.py", line 188, in __init__
    self.netinitialisation()
  File "/usr/local/lib/python3.11/dist-packages/sysmontask-1.0.0-py3.11.egg/sysmontask/net.py", line 281, in netinit
    for entry in nettemp[self.netNameList[i]]:
                 ~~~~~~~^^^^^^^^^^^^^^^^^^^^^
KeyError: 'wg0'
$ ip -json a | jq .
[
...
  {
    "ifindex": 22,
    "ifname": "wg0",
    "flags": [
      "POINTOPOINT",
      "NOARP",
      "UP",
      "LOWER_UP"
    ],
    "mtu": 1420,
    "qdisc": "noqueue",
    "operstate": "UNKNOWN",
    "group": "default",
    "txqlen": 1000,
    "link_type": "none",
    "addr_info": []
  }
]

Yes, there is no IPs assigned at the moment to this interface. There is no MAC address either.

Basically if link_type is not "ether", there likely will not be address / broadcast fields for example.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions