From 6bda1e351f953732a79d814284bde70a69e7e2cf Mon Sep 17 00:00:00 2001 From: matejcik Date: Fri, 1 Feb 2019 12:58:20 +0100 Subject: [PATCH] cointool: fix filtering on non-string fields --- tools/cointool.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/cointool.py b/tools/cointool.py index 1f9291ff27..92820cf4f7 100755 --- a/tools/cointool.py +++ b/tools/cointool.py @@ -672,13 +672,13 @@ def dump( filter = filter.lower() if field not in coin: return False - if not fnmatch.fnmatch(coin[field].lower(), filter): + if not fnmatch.fnmatch(str(coin[field]).lower(), filter): return False for field, filter in exclude_filters: filter = filter.lower() if field not in coin: continue - if fnmatch.fnmatch(coin[field].lower(), filter): + if fnmatch.fnmatch(str(coin[field]).lower(), filter): return False if device: is_supported = support_info[coin["key"]].get(device, None)