Skip to content

Commit 885109f

Browse files
committed
Converting non-str to str for list compare
1 parent a22513b commit 885109f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

candore/modules/comparator.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ def _is_data_type_list_contains_dict(self, pre, post):
113113
def _is_data_type_list(self, pre, post, unique_key=""):
114114

115115
def custom_key(elem):
116-
return 'None' if elem is None else elem
116+
return 'None' if elem is None else str(elem)
117117

118118
if not is_list_contains_dict(pre):
119119
if sorted(pre, key=custom_key) != sorted(post, key=custom_key):

0 commit comments

Comments
 (0)