Skip to content

Commit 15b8877

Browse files
committed
Skip CVX obsolete/placeholder entries
1 parent ca4ea65 commit 15b8877

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/pyobo/sources/cvx.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,13 @@ def iter_terms() -> Iterable[Term]:
6060
cvx_df[col] = cvx_df[col].map(lambda s: s.strip() if pd.notna(s) else s)
6161
terms = {}
6262
for cvx, short_name, full_name, notes, status, nonvaccine, _updated in cvx_df.values:
63+
if cvx == "99":
64+
continue # this is a placeholder
65+
66+
is_obsolete = pd.notna(notes) and "do not use" in notes.lower()
67+
if is_obsolete:
68+
# there are some records that have been obsoleted/replaced
69+
continue
6370
term = Term.from_triple(PREFIX, cvx, full_name)
6471
if short_name != full_name:
6572
term.append_synonym(short_name)

0 commit comments

Comments
 (0)