From 5c8d9007f62277d37cdb470623c335ff718a9dfd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gina=20H=C3=A4u=C3=9Fge?= Date: Thu, 22 Oct 2015 12:35:23 +0200 Subject: [PATCH] Fixed some missing exception capturing (cherry picked from commit 2f86a6a) --- src/octoprint/printer/profile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/octoprint/printer/profile.py b/src/octoprint/printer/profile.py index 7ef630a0..700aef07 100644 --- a/src/octoprint/printer/profile.py +++ b/src/octoprint/printer/profile.py @@ -408,7 +408,7 @@ class PrinterProfileManager(object): for path in (("volume", "width"), ("volume", "depth"), ("volume", "height"), ("extruder", "nozzleDiameter")): try: convert_value(profile, path, float) - except: + except Exception as e: self._logger.warn("Profile has invalid value for path {path!r}: {msg}".format(path=".".join(path), msg=str(e))) return False @@ -416,7 +416,7 @@ class PrinterProfileManager(object): for path in (("axes", "x", "inverted"), ("axes", "y", "inverted"), ("axes", "z", "inverted")): try: convert_value(profile, path, bool) - except: + except Exception as e: self._logger.warn("Profile has invalid value for path {path!r}: {msg}".format(path=".".join(path), msg=str(e))) return False