From dd55b1376cbff6c9870b3173f8dc6207505a57c6 Mon Sep 17 00:00:00 2001 From: Frederick Muriuki Muriithi Date: Thu, 9 Dec 2021 07:01:32 +0300 Subject: Provide clearer error message Issue: https://github.com/genenetwork/gn-gemtext-threads/blob/main/topics/gn1-migration-to-gn2/partial-correlations.gmi * To help with debugging error conditions, provide the original name to help with figuring out why the error was raised --- gn3/db/traits.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gn3/db') diff --git a/gn3/db/traits.py b/gn3/db/traits.py index 4098b08..7994aef 100644 --- a/gn3/db/traits.py +++ b/gn3/db/traits.py @@ -550,7 +550,7 @@ def build_trait_name(trait_fullname): return "ProbeSet" name_parts = trait_fullname.split("::") - assert len(name_parts) >= 2, "Name format error" + assert len(name_parts) >= 2, f"Name format error: '{trait_fullname}'" dataset_name = name_parts[0] dataset_type = dataset_type(dataset_name) return { -- cgit v1.2.3