From 6bce98b241f15461d0bfce6c780ac7d5cfa7cadb Mon Sep 17 00:00:00 2001 From: Oscar Esteban Date: Tue, 15 Dec 2015 11:43:12 +0100 Subject: [PATCH 1/2] Add list check and conversion to dict --- nipype/utils/logger.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/nipype/utils/logger.py b/nipype/utils/logger.py index 4c69af5822..38edd8e1e6 100644 --- a/nipype/utils/logger.py +++ b/nipype/utils/logger.py @@ -87,6 +87,13 @@ def logdebug_dict_differences(self, dold, dnew, prefix=""): typical use -- log difference for hashed_inputs """ + # First check inputs, since they usually are lists of tuples + # and dicts are required. + if isinstance(dnew, list): + dnew = dict(dnew) + if isinstance(dold, list): + dold = dict(dold) + # Compare against hashed_inputs # Keys: should rarely differ new_keys = set(dnew.keys()) From 61721196412223a1d83914b495622208707df12d Mon Sep 17 00:00:00 2001 From: Oscar Esteban Date: Tue, 15 Dec 2015 11:46:47 +0100 Subject: [PATCH 2/2] update CHANGES --- CHANGES | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGES b/CHANGES index 0b0e52d61c..88905eef5b 100644 --- a/CHANGES +++ b/CHANGES @@ -1,6 +1,7 @@ Next release ============ +* FIX: Minor bugfix logging hash differences (https://github.com/nipy/nipype/pull/1298) * FIX: VTK version check missing when using tvtk (https://github.com/nipy/nipype/pull/1219) * ENH: Added an OAR scheduler plugin (https://github.com/nipy/nipype/pull/1259) * ENH: New ANTs interface: antsBrainExtraction (https://github.com/nipy/nipype/pull/1231)