Skip to content

Commit

Permalink
Merge branch 'main' into multiple_conditions_explanation
Browse files Browse the repository at this point in the history
  • Loading branch information
northwestwitch authored Feb 9, 2024
2 parents ccc3cc6 + e0a52b5 commit 69ab2b0
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
4 changes: 3 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
### Changed
- Updated version of external images in GitHub actions
- Updated API submission schema to the latest
- Dmo variant to take care of "Somatic mutation" no longer available among Mode of inheritance choices
- Demo variant to take care of "Somatic mutation" no longer available among Mode of inheritance choices
- `clinicalSignificance.clinicalSignificanceDescription` value extracted from `Clinical significance` or `Germline classification` column
- `clinicalSignificance.comment` values extracted from `Comment on clinical significance` or `Comment on classification` column
- Parse `conditionSet.MultipleConditionExplanation` value from `Explanation for multiple conditions` column of variants file
### Fixed
- Bump certifi from 2022.12.7 to 2023.7.22
Expand Down
10 changes: 7 additions & 3 deletions preClinVar/file_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,14 +44,18 @@ def set_item_clin_sig(item, variant_dict):
variant_dict(dict). Example: {'##Local ID': '1d9ce6ebf2f82d913cfbe20c5085947b', 'Linking ID': '1d9ce6ebf2f82d913cfbe20c5085947b', 'Gene symbol': 'XDH', 'Reference sequence': 'NM_000379.4', 'HGVS': 'c.2751del', ..}
"""
# set first required params
clinsig = variant_dict.get("Clinical significance")
clinsig = variant_dict.get("Clinical significance") or variant_dict.get(
"Germline classification"
)
# Make sure clinsig term is compliant with API standards:
for term in CLNSIG_TERMS:
if clinsig.lower() == term.lower():
clinsig = term
break

clinsig_comment = variant_dict.get("Comment on clinical significance")
clinsig_comment = variant_dict.get("Comment on clinical significance") or variant_dict.get(
"Comment on classification"
)
last_eval = variant_dict.get("Date last evaluated")
inherit_mode = variant_dict.get("Mode of inheritance")

Expand All @@ -64,7 +68,7 @@ def set_item_clin_sig(item, variant_dict):
item["clinicalSignificance"]["modeOfInheritance"] = inherit_mode

# NOT parsing the following key/values for now:
# citation
# “Clinical significance citations” or “Classification citations”
# customAssertionScore


Expand Down

0 comments on commit 69ab2b0

Please sign in to comment.