Skip to content

Commit

Permalink
Implement new annonars model
Browse files Browse the repository at this point in the history
  • Loading branch information
gromdimon committed Apr 30, 2024
1 parent 419a94b commit e40eb12
Show file tree
Hide file tree
Showing 7 changed files with 1,403 additions and 202 deletions.
2 changes: 1 addition & 1 deletion .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
"type": "debugpy",
"request": "launch",
"module": "src.cli",
"args": ["NM_000152.4:c.1A>G", "--genome-release", "grch38"],
"args": ["NM_000314.6:c.1134_1135insCTGG", "--genome-release", "grch37"],
"console": "integratedTerminal"
}
]
Expand Down
3 changes: 3 additions & 0 deletions src/api/annonars.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@ def get_variant_from_range(
response.raise_for_status()
return AnnonarsRangeResponse.model_validate(response.json())
except requests.RequestException:
print(f"Annonars API request failed: {url}")
return None
except ValidationError as e:
print(f"Validation error: {e}")
print(response.json(), file=open("ann.json", "w"))
return None
Loading

0 comments on commit e40eb12

Please sign in to comment.