Describe the bug
When running the UXTU4Unix.py main program, the dmidecode not installed message was displayed.
"\nError: 'dmidecode' is not installed.\n"
"Install it with your package manager, for example:\n"
" Debian/Ubuntu : sudo apt install dmidecode\n"
" Fedora/RHEL : sudo dnf install dmidecode\n"
" Arch : sudo pacman -S dmidecode\n"
To Reproduce
Steps to reproduce the behavior:
System - Tumbleweed SUSE - Latest kernel and rolling release.
Confirm dmidecode is installed and working.
But when UXTU4Unix.py is ran as a regular user, dmidecode is not found.
the shutil.which call looking for the dmidecode path returns None and the program exits.
Expected behavior
The dmidecode path should be found and return a path which would allow the program to continue.
Screenshots
no screenshots.
Desktop (please complete the following information):
- OS: Tumbleweed latest rolling release and kernel as of 4/29 (kernel 7.0.1-1)
- Browser: chrome, unrelated
- Version: 0.5.2
Additional context
Resolved by adding possible paths to the hardware.py file in Assets -> Modules
Changed:
if shutil.which("dmidecode") is None:
To:
if shutil.which("dmidecode", path='/usr/sbin:/sbin:/usr/bin:none') is None:
This allowed the file path to be found and should still return None if dmidecode is not found.
This may be a path problem with my system only but if it does impact others, the possible paths for searching seem to resolve the problem.
Describe the bug
When running the UXTU4Unix.py main program, the dmidecode not installed message was displayed.
"\nError: 'dmidecode' is not installed.\n"
"Install it with your package manager, for example:\n"
" Debian/Ubuntu : sudo apt install dmidecode\n"
" Fedora/RHEL : sudo dnf install dmidecode\n"
" Arch : sudo pacman -S dmidecode\n"
To Reproduce
Steps to reproduce the behavior:
System - Tumbleweed SUSE - Latest kernel and rolling release.
Confirm dmidecode is installed and working.
But when UXTU4Unix.py is ran as a regular user, dmidecode is not found.
the shutil.which call looking for the dmidecode path returns None and the program exits.
Expected behavior
The dmidecode path should be found and return a path which would allow the program to continue.
Screenshots
no screenshots.
Desktop (please complete the following information):
Additional context
Resolved by adding possible paths to the hardware.py file in Assets -> Modules
Changed:
if shutil.which("dmidecode") is None:
To:
if shutil.which("dmidecode", path='/usr/sbin:/sbin:/usr/bin:none') is None:
This allowed the file path to be found and should still return None if dmidecode is not found.
This may be a path problem with my system only but if it does impact others, the possible paths for searching seem to resolve the problem.