fix: lshw crashes due to duplicate logical name #227 #271

Merged
AlexDaichendt merged 1 commit from fix-227-lshw into master 2023-04-08 12:42:54 +02:00
AlexDaichendt commented 2023-04-08 11:19:21 +02:00 (Migrated from github.com)

Fixes #227

Newer versions of LSHW can return multiple logical names. This is parsed as an array. Netbox-agent assumes that the name is always a string, hence the failure.

This patch checks if the logical name output is a string or an array. If it is an array each logical name is added to the unknown interfaces list.

Fixes #227 Newer versions of LSHW can return multiple logical names. This is parsed as an array. Netbox-agent assumes that the name is always a string, hence the failure. This patch checks if the logical name output is a string or an array. If it is an array each logical name is added to the unknown interfaces list.
sinavir commented 2024-03-27 18:48:16 +01:00 (Migrated from github.com)

In which python version list.push method exist ? it is not list.append ?

In which python version `list.push` method exist ? it is not `list.append` ?
Sign in to join this conversation.
No description provided.