From 12752fb3a4dc25da512632fa907403760aef2589 Mon Sep 17 00:00:00 2001 From: Thomas Kluyver <thomas@kluyver.me.uk> Date: Tue, 5 Oct 2021 12:09:37 +0100 Subject: [PATCH] check_output() takes an input kwarg, check_call() doesn't --- src/xfel_calibrate/calibrate.py | 2 +- src/xfel_calibrate/finalize.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/xfel_calibrate/calibrate.py b/src/xfel_calibrate/calibrate.py index 7e9fbd58f..e83c60a41 100755 --- a/src/xfel_calibrate/calibrate.py +++ b/src/xfel_calibrate/calibrate.py @@ -644,7 +644,7 @@ def run_finalize(fmt_args, temp_path, job_list, sequential=False): finalize_script, ] - output = check_output(cmd).decode('utf8') + output = check_output(cmd, input=b'').decode('utf8') jobid = None if not sequential: jobid = output.partition(';')[0].strip() diff --git a/src/xfel_calibrate/finalize.py b/src/xfel_calibrate/finalize.py index 4fc25b57d..368306301 100644 --- a/src/xfel_calibrate/finalize.py +++ b/src/xfel_calibrate/finalize.py @@ -240,7 +240,7 @@ def make_report(run_path: Path, tmp_path: Path, project: str, "--ext-intersphinx", "--ext-mathjax", "--makefile", - "--no-batchfile", run_path], input=b'') + "--no-batchfile", run_path]) except CalledProcessError: raise Exception("Failed to run sphinx-quickstart. Is sphinx installed?" @@ -322,7 +322,7 @@ def make_report(run_path: Path, tmp_path: Path, project: str, chdir(run_path) try: check_call(["make", f"SPHINXBUILD={sys.executable} -m sphinx", - "latexpdf"], input=b'') + "latexpdf"]) except CalledProcessError: print("Failed to make pdf documentation") -- GitLab