Skip to content
This repository was archived by the owner on Dec 11, 2025. It is now read-only.

Commit 92486ce

Browse files
mmlbofaurax
authored andcommitted
Ensure lshw output is always listified
lshw changed the output of -xml between B.02.19 and B.02.20, in commit 2b1c730b493d647bbab4854713571458e82a81e7 (https://ezix.org/src/pkg/lshw/commit/2b1c730b493d647bbab4854713571458e82a81e7). This commit seems to try to fix the JSON output but in doing so sets `disable("output:list")` in main. This was feature/setting was being used by the code in hwNode::asXML. It seems that options are default enabled and thus we were getting the xml data listified. When the output:list was disabled in that commit we stopped getting listified xml. I have verified that we can enable the option by passing it in the cli args as `-enable output:list`. Signed-off-by: Manuel Mendez <github@i.m.mmlb.dev>
1 parent fa16da4 commit 92486ce

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packethardware/utils.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,9 @@ def get_megaraid_prop(prop):
296296

297297
def lshw():
298298
# Workaround for x.large.arm: Skip framebuffer test ("-disable fb")
299-
return cmd_output("lshw", "-xml", "-quiet", "-disable", "fb")
299+
return cmd_output(
300+
"lshw", "-xml", "-quiet", "-disable", "fb", "-enable", "output:list"
301+
)
300302

301303

302304
def lspci(pci_id):

0 commit comments

Comments
 (0)