From 4e5f7b9db1bbb1614d783f86ab27b16b570daa20 Mon Sep 17 00:00:00 2001 From: Robin Aggleton Date: Wed, 4 May 2016 10:53:21 +0100 Subject: [PATCH] Add error for dag filename if on /users --- htcondenser/core/dagman.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/htcondenser/core/dagman.py b/htcondenser/core/dagman.py index a069e8e..1ba2269 100644 --- a/htcondenser/core/dagman.py +++ b/htcondenser/core/dagman.py @@ -21,7 +21,8 @@ class DAGMan(object): Parameters ---------- filename : str - Filename to write DAG jobs. + Filename to write DAG jobs. This cannot be on /users, + must be on NFS drive, e.g. /storage. status_file : str, optional Filename for DAG status file. See @@ -55,6 +56,8 @@ def __init__(self, other_args=None): super(DAGMan, self).__init__() self.dag_filename = filename + if os.path.abspath(self.dag_filename).startswith('/users'): + raise IOError('You cannot put DAG filename on /users - must be on NFS (e.g.. /storage') self.status_file = status_file self.status_update_period = str(status_update_period) self.dot = dot