From 5cc778e3db7035b49a8c5f37b98dcd3a07fafa26 Mon Sep 17 00:00:00 2001 From: Munyoki Kilyungi Date: Tue, 17 Jan 2023 11:49:48 +0300 Subject: Return a trait's display name if the name is non-existent * scripts/sampledata.py (fetch_all_traits): Should the name of a trait not exists, e.g. in probeset data, return it's display name. --- scripts/sampledata.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/sampledata.py b/scripts/sampledata.py index 4777b6f9..8b060e82 100644 --- a/scripts/sampledata.py +++ b/scripts/sampledata.py @@ -60,7 +60,7 @@ def fetch_all_traits(species, group, type_, dataset): "dataset": dataset, "search_terms_or": "*", }).trait_list: - yield result.get('name') + yield result.get('name') or result.get('display_name') if __name__ == "__main__": -- cgit v1.2.3