Skip to content

Commit 6bce98b

Browse files
committed
Add list check and conversion to dict
1 parent 3b9e5bf commit 6bce98b

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

nipype/utils/logger.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,13 @@ def logdebug_dict_differences(self, dold, dnew, prefix=""):
8787
8888
typical use -- log difference for hashed_inputs
8989
"""
90+
# First check inputs, since they usually are lists of tuples
91+
# and dicts are required.
92+
if isinstance(dnew, list):
93+
dnew = dict(dnew)
94+
if isinstance(dold, list):
95+
dold = dict(dold)
96+
9097
# Compare against hashed_inputs
9198
# Keys: should rarely differ
9299
new_keys = set(dnew.keys())

0 commit comments

Comments
 (0)