fixed the app_var.py.
Some checks are pending
Build-nightly / docker (push) Waiting to run

This commit is contained in:
Umiko 2025-05-13 20:33:57 +07:00
parent 43d71db74f
commit 2b5f9fc990

View File

@ -15,7 +15,7 @@ def get_system_info() -> str:
version = platform.version()
machine = platform.machine() or "unknown"
processor = platform.processor() or "unknown"
architecture = platform.architecture()[0]
architecture = platform.architecture()[0] # '64bit' or '32bit'
if system == "Windows":
try:
@ -28,6 +28,11 @@ def get_system_info() -> str:
system_str = f"Windows {release}"
elif system == "Linux":
try:
# Trying to get CPU info from /proc/cpuinfo
with open("/proc/cpuinfo") as f:
cpu_info = f.read()
# Get the processor information
processor = " ".join([line.split(":")[1].strip() for line in cpu_info.splitlines() if "model name" in line]) or processor
os_info = {}
with open("/etc/os-release") as f:
for line in f: