We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 233dccb commit fab7da7Copy full SHA for fab7da7
pyard/ard.py
@@ -23,6 +23,7 @@
23
#
24
import functools
25
import re
26
+import sqlite3
27
import sys
28
from typing import Iterable, List
29
@@ -472,7 +473,11 @@ def is_mac(self, allele: str) -> bool:
472
473
"""
474
if ":" in allele:
475
code = allele.split(":")[1]
- return db.is_valid_mac_code(self.db_connection, code)
476
+ try:
477
+ if code.isalpha():
478
+ return db.is_valid_mac_code(self.db_connection, code)
479
+ except sqlite3.OperationalError as e:
480
+ print("Error: ", e)
481
return False
482
483
def is_v2(self, allele: str) -> bool:
0 commit comments