diff --git a/nipype/pipeline/plugins/pbs.py b/nipype/pipeline/plugins/pbs.py index 686f791263..f8a177dc69 100644 --- a/nipype/pipeline/plugins/pbs.py +++ b/nipype/pipeline/plugins/pbs.py @@ -36,7 +36,8 @@ def __init__(self, **kwargs): super(PBSPlugin, self).__init__(template, **kwargs) def _is_pending(self, taskid): - proc = subprocess.Popen(["qstat", taskid], + # subprocess.Popen requires taskid to be a string + proc = subprocess.Popen(["qstat", str(taskid)], stdout=subprocess.PIPE, stderr=subprocess.PIPE) _, e = proc.communicate() diff --git a/nipype/pipeline/plugins/sge.py b/nipype/pipeline/plugins/sge.py index 107151ad8e..af9a78620e 100644 --- a/nipype/pipeline/plugins/sge.py +++ b/nipype/pipeline/plugins/sge.py @@ -37,7 +37,8 @@ def __init__(self, **kwargs): super(SGEPlugin, self).__init__(template, **kwargs) def _is_pending(self, taskid): - proc = subprocess.Popen(["qstat", '-j', taskid], + # subprocess.Popen requires taskid to be a string + proc = subprocess.Popen(["qstat", '-j', str(taskid)], stdout=subprocess.PIPE, stderr=subprocess.PIPE) o, _ = proc.communicate()