Skip non-upgradable apt list lines

This commit is contained in:
2026-02-07 23:16:27 +03:00
parent e3a977a2ec
commit e590b7e38f

View File

@@ -30,6 +30,8 @@ async def list_updates() -> tuple[str, list[str]]:
for line in out.splitlines(): for line in out.splitlines():
if not line or line.startswith("Listing..."): if not line or line.startswith("Listing..."):
continue continue
if "upgradable from:" not in line:
continue
# Format: name/repo new_ver arch [upgradable from: old] # Format: name/repo new_ver arch [upgradable from: old]
m = re.match(r"^(\S+)\s+(\S+)\s", line) m = re.match(r"^(\S+)\s+(\S+)\s", line)
if not m: if not m: