diff options
author | kennyballou <kballou@onyx.boisestate.edu> | 2013-01-10 11:11:24 -0700 |
---|---|---|
committer | kballou <kballou@onyx.boisestate.edu> | 2013-01-10 11:11:24 -0700 |
commit | 40986aed10b347c833e094df85b53539ed54144c (patch) | |
tree | a7a15252dfc0891596a644f97061fe9db9a361e6 /xnt | |
parent | 03550b0e9d8dbbe052557f909895f96fdda0c092 (diff) | |
download | xnt-40986aed10b347c833e094df85b53539ed54144c.tar.gz xnt-40986aed10b347c833e094df85b53539ed54144c.tar.xz |
Log "ignored" exceptions as warnings
Diffstat (limited to 'xnt')
-rw-r--r-- | xnt/tasks.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/xnt/tasks.py b/xnt/tasks.py index 119e2fd..22df254 100644 --- a/xnt/tasks.py +++ b/xnt/tasks.py @@ -59,8 +59,8 @@ def mkdir(dir,mode=0o777): logger.info("Making directory %s with mode %o", dir, mode) try: os.mkdir(dir,mode) - except IOError: - pass + except IOError as e: + log(e, logging.WARNING) except: raise @@ -75,8 +75,8 @@ def rm(*fileset): shutil.rmtree(f) else: os.remove(f) - except OSError: - pass + except OSError as e: + log(e, logging.WARNING) except: raise |