[Sugar-devel] [PATCH 15/21 sugar-toolkit] pylint cleanup: disable warnings for reasonable catch-all exception handlers

Sascha Silbe sascha-pgp at silbe.org
Fri Oct 15 17:01:19 EDT 2010


Signed-off-by: Sascha Silbe <sascha-pgp at silbe.org>

diff --git a/src/sugar/activity/activity.py b/src/sugar/activity/activity.py
index 64bc840..7229096 100644
--- a/src/sugar/activity/activity.py
+++ b/src/sugar/activity/activity.py
@@ -823,6 +823,7 @@ class Activity(Window, gtk.Container):
             try:
                 self.save()
             except:
+                # pylint: disable=W0702
                 logging.exception('Error saving activity object to datastore')
                 self._show_keep_failed_dialog()
                 return False
diff --git a/src/sugar/util.py b/src/sugar/util.py
index e0a431b..df56946 100644
--- a/src/sugar/util.py
+++ b/src/sugar/util.py
@@ -335,6 +335,7 @@ def _cleanup_temp_files():
         try:
             os.unlink(path)
         except:
+            # pylint: disable=W0702
             logging.exception('Exception occured in _cleanup_temp_files')

 atexit.register(_cleanup_temp_files)
--
1.7.1



More information about the Sugar-devel mailing list