Skip to content
Open
3 changes: 2 additions & 1 deletion graphgen/models/searcher/db/rnacentral_searcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,8 @@ def _rna_data_to_dict(
acc = xref.get("accession", {})
if s := acc.get("species"):
organisms.add(s)
if g := acc.get("gene", "").strip():
gene_value = acc.get("gene")
if gene_value and isinstance(gene_value, str) and (g := gene_value.strip()):
gene_names.add(g)
if m := xref.get("modifications"):
modifications.extend(m)
Expand Down