diff options
author | Martin Robinson <mrobinson@igalia.com> | 2023-04-20 12:06:05 +0200 |
---|---|---|
committer | Martin Robinson <mrobinson@igalia.com> | 2023-04-20 12:06:05 +0200 |
commit | ef8359df4b78d606aa32634a8d4f21cbd960f095 (patch) | |
tree | 8ee426cc282e9bef64d9983b86085bf2c5852044 /python | |
parent | 9acb9cc5cf21d14709355a3c75af7202e9301bd5 (diff) | |
download | servo-ef8359df4b78d606aa32634a8d4f21cbd960f095.tar.gz servo-ef8359df4b78d606aa32634a8d4f21cbd960f095.zip |
Catch more exceptions when delivering build notifications
It seems that catching ImportError isn't enough, so we must catch any
type of exception when trying to deliver a build notification.
Fixes #29645.
Diffstat (limited to 'python')
-rw-r--r-- | python/servo/build_commands.py | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/python/servo/build_commands.py b/python/servo/build_commands.py index 2b0624d3a1d..135a48ef7ed 100644 --- a/python/servo/build_commands.py +++ b/python/servo/build_commands.py @@ -743,9 +743,8 @@ class MachCommands(CommandBase): {"transient": True}, # hints -1 # timeout ) - except ImportError: - print("[Warning] Could not generate notification: " - "Optional Python module 'dbus' is not installed.", + except Exception as exception: + print(f"[Warning] Could not generate notification: {exception}", file=sys.stderr) return True |