diff --git a/octofludb/domain_flu.py b/octofludb/domain_flu.py index fda5e61..8fb410d 100644 --- a/octofludb/domain_flu.py +++ b/octofludb/domain_flu.py @@ -16,7 +16,7 @@ p_internal_gene = p.regex("PB2|PB1|PA|NP") ^ p_ns ^ p_m p_segment = p_internal_gene ^ p.string("HA") ^ p.string("NA") -p_constellation = p.regex("[TPVHX-]{6}|MIXED") +p_constellation = p.regex("[A-Z-]{6}|MIXED|mixed") p_segment_number = p.regex("[1-8]") p_segment_subtype = p_segment ^ p_HA ^ p_NA diff --git a/octofludb/formatting.py b/octofludb/formatting.py index 5875c9c..6563db6 100644 --- a/octofludb/formatting.py +++ b/octofludb/formatting.py @@ -95,6 +95,9 @@ def _make_constellations(rows: List[Tuple[str, str, str]]) -> List[Tuple[str, st # add flexible matching for c_lookup, c_letter in clade_lookup.items(): if c_lookup.lower() in clade.lower(): + log( + f"{bad('WARNING:')} closest match found is partial and/or case-insensitive, {str((strain, clade, c_lookup))}" + ) char = c_letter break else: