From 96af4e9e32ed167a8d70cf7761b709b1a37bb344 Mon Sep 17 00:00:00 2001 From: Muriithi Frederick Muriuki Date: Fri, 20 Aug 2021 14:14:12 +0300 Subject: Fix typing issue(s) caught by mypy Issue: https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/clustering.gmi * gn3/computations/heatmap.py: Use `Sequence` type not `Iterator` type --- gn3/computations/heatmap.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gn3/computations/heatmap.py b/gn3/computations/heatmap.py index 5a3c619..c9c2b8a 100644 --- a/gn3/computations/heatmap.py +++ b/gn3/computations/heatmap.py @@ -156,8 +156,8 @@ def heatmap_data(formd, search_result, conn: Any): traits_details = [ __retrieve_traitlist_and_datalist(threshold, fullname) for fullname in search_result] - traits_list = map(lambda x: x[0], traits_details) - traits_data_list = map(lambda x: x[1], traits_details) + traits_list = tuple(x[0] for x in traits_details) + traits_data_list = tuple(x[1] for x in traits_details) return { "target_description_checked": formd.formdata.getvalue( -- cgit v1.2.3