refactor: log swallowed exceptions across src/

Replace silent swallow-excepts (pass/return/continue) with
logger.warning recording the caught error, preserving behaviour.
This commit is contained in:
sankalp committed 2026-07-14 13:02:21 +05:45
1 parent c0a4b1b792
commit f72542a231
49 files changed
+1004 -363

No files matched your search

+8 -4
View File
@@ -535,8 +535,10 @@ class BluetoothConnections(Box):
self.other_devices_scrolled.height_animator.disconnect(
self._anim_finished_handler
)
except Exception:
pass
except Exception as e:
logger.warning(
f"[bluetooth] self.other_devices_scrolled.height_animator.disconnect( s... failed: {e}"
)
self._anim_finished_handler = None
def _refresh_after_animation(self):
@@ -558,8 +560,10 @@ class BluetoothConnections(Box):
spawn_detached(["blueman-manager"])
if self.parent and hasattr(self.parent, "hide_controlcenter"):
self.parent.hide_controlcenter()
except FileNotFoundError:
pass
except FileNotFoundError as e:
logger.warning(
f"[bluetooth] spawn_detached(['blueman-manager']) failed: {e}"
)
except Exception as e:
logger.error(f"[Bluetooth] Failed to open bluetooth settings: {e}")