Skip to content

Commit cf51ce7

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 1ba1a8d commit cf51ce7

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

pydra/engine/run_pickled.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
import pydra
33
import sys
44

5+
56
def run_pickled(*file_paths, rerun=False):
67
loaded_objects = []
78

@@ -18,6 +19,7 @@ def run_pickled(*file_paths, rerun=False):
1819

1920
print(f"Result: {result}")
2021

22+
2123
if __name__ == "__main__":
2224
rerun = False # Default value for rerun
2325
file_paths = sys.argv[1:]

pydra/engine/workers.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -911,7 +911,7 @@ def make_spec(self, cmd=None, arg=None):
911911
spec = self.psij.JobSpec()
912912
spec.executable = cmd
913913
spec.arguments = arg
914-
914+
915915
return spec
916916

917917
def make_job(self, spec, attributes):
@@ -963,16 +963,18 @@ async def exec_psij(self, runnable, rerun=False):
963963

964964
spec.stdout_path = os.path.join(cache_dir, "demo.stdout")
965965
spec.stderr_path = os.path.join(cache_dir, "demo.stderr")
966-
966+
967967
job = self.make_job(spec, None)
968968
jex.submit(job)
969969
job.wait()
970970

971971
if os.path.getsize(spec.stderr_path) > 0:
972972
with open(spec.stderr_path, "r") as stderr_file:
973973
stderr_contents = stderr_file.read()
974-
raise Exception(f"stderr_path '{spec.stderr_path}' is not empty. Contents:\n{stderr_contents}")
975-
974+
raise Exception(
975+
f"stderr_path '{spec.stderr_path}' is not empty. Contents:\n{stderr_contents}"
976+
)
977+
976978
return
977979

978980
def close(self):

0 commit comments

Comments
 (0)