From 1caae611ba2247d5a9c5c843d90638df020ae8b8 Mon Sep 17 00:00:00 2001 From: Jan Lindemann Date: Thu, 9 Apr 2026 08:05:07 +0200 Subject: [PATCH] App.os_release: Fix debug logging cat /etc/os-release sometimes fails over the wire, and the reason should be logged but isn't. Fix that. Signed-off-by: Jan Lindemann --- src/python/jw/pkg/App.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/python/jw/pkg/App.py b/src/python/jw/pkg/App.py index a80d4a49..8e2e629b 100644 --- a/src/python/jw/pkg/App.py +++ b/src/python/jw/pkg/App.py @@ -311,6 +311,7 @@ class App(Base): ) self.__os_release = result.decode().stdout.strip() except Exception as e: + log(INFO, f'Failed to read {release_file} ({str(e)}), falling back to uname') result = self.call_async( self.exec_context.run( ['uname', '-s'], @@ -321,7 +322,6 @@ class App(Base): if result.status != 0: log(ERR, f'/etc/os-release and uname both failed, the latter with exit status {result.status}') raise - log(INFO, f'Failed to read {release_file} ({str(e)}), falling back to uname') uname = result.decode().stdout.strip().lower() self.__os_release = f'ID={uname}\nVERSION_CODENAME=unknown'