Skip to content

Commit

Permalink
Fix amici.petab.import_helpers._can_import_model
Browse files Browse the repository at this point in the history
  • Loading branch information
dweindl committed Nov 26, 2024
1 parent c75909d commit 010ee0b
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions python/sdist/amici/petab/import_helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
Functions for PEtab import that are independent of the model format.
"""

import importlib
import logging
import os
import re
Expand Down Expand Up @@ -138,8 +137,7 @@ def _can_import_model(model_name: str, model_output_dir: str | Path) -> bool:
"""
# try to import (in particular checks version)
try:
with amici.add_path(model_output_dir):
model_module = importlib.import_module(model_name)
model_module = amici.import_model_module(model_name, model_output_dir)
except ModuleNotFoundError:
return False

Expand Down

0 comments on commit 010ee0b

Please sign in to comment.