summaryrefslogtreecommitdiff
path: root/xnt
diff options
context:
space:
mode:
authorkennyballou <kballou@onyx.boisestate.edu>2013-01-10 11:11:24 -0700
committerkballou <kballou@onyx.boisestate.edu>2013-01-10 11:11:24 -0700
commit40986aed10b347c833e094df85b53539ed54144c (patch)
treea7a15252dfc0891596a644f97061fe9db9a361e6 /xnt
parent03550b0e9d8dbbe052557f909895f96fdda0c092 (diff)
downloadxnt-40986aed10b347c833e094df85b53539ed54144c.tar.gz
xnt-40986aed10b347c833e094df85b53539ed54144c.tar.xz
Log "ignored" exceptions as warnings
Diffstat (limited to 'xnt')
-rw-r--r--xnt/tasks.py8
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