Skip to content

Commit 88b6fc0

Browse files
committed
fix(py27): uncaught exception in python 2
1 parent 7d92126 commit 88b6fc0

File tree

2 files changed

+1
-3
lines changed

2 files changed

+1
-3
lines changed

nipype/pipeline/engine/utils.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -255,8 +255,6 @@ def load_resultfile(results_file):
255255
"""
256256
aggregate = True
257257
results_file = Path(results_file)
258-
path = '%s' % results_file.parents
259-
260258
result = None
261259
attribute_error = False
262260
if results_file.exists():

nipype/utils/filemanip.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -688,7 +688,7 @@ def loadpkl(infile, versioning=False):
688688
try: # Look if pkl file contains version file
689689
pkl_metadata_line = pkl_file.readline()
690690
pkl_metadata = json.loads(pkl_metadata_line)
691-
except UnicodeDecodeError:
691+
except (UnicodeDecodeError, json.JSONDecodeError):
692692
pass
693693
finally:
694694
# Could not get version info

0 commit comments

Comments
 (0)