Page MenuHomeVyOS Platform

'show hardware cpu' issue on arm64
Closed, ResolvedPublic

Description

Traceback (most recent call last):
  File "/usr/libexec/vyos/op_mode/cpu.py", line 76, in <module>
    res = vyos.opmode.run(sys.modules[__name__])
  File "/usr/lib/python3/dist-packages/vyos/opmode.py", line 200, in run
    res = func(**args)
  File "/usr/libexec/vyos/op_mode/cpu.py", line 58, in show
    cpu_data = _get_raw_data()
  File "/usr/libexec/vyos/op_mode/cpu.py", line 40, in _get_raw_data
    return vyos.cpu.get_cpus()
  File "/usr/lib/python3/dist-packages/vyos/cpu.py", line 83, in get_cpus
    cpus_dict = _find_physical_cpus()
  File "/usr/lib/python3/dist-packages/vyos/cpu.py", line 76, in _find_physical_cpus
    phys_cpus[num] = cpu[num]
NameError: name 'cpu' is not defined

Mathew McBride originally created a fix for this here: https://github.com/mcbridematt/vyos-1x/commit/b54463e47c126ff76fc35105737b29dc73932df7
However, a Phabricator task was never created, or at least I did not find it.
As its been a while I am submitting this relatively trivial change now.

Details

Difficulty level
Unknown (require assessment)
Version
-
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Perfectly compatible
Issue type
Bug (incorrect behavior)

Revisions and Commits

Event Timeline

MartB created this object in space S1 VyOS Public.
MartB added a commit: Restricted Diffusion Commit.Jan 26 2023, 1:54 AM
Viacheslav changed the task status from Open to Needs testing.Jan 26 2023, 8:46 AM