Skip to content

Commit

Permalink
py3.12 incompatibility with scipy and rdkit update (#1500)
Browse files Browse the repository at this point in the history
* fix: rdkit-dependency-failure-on-py3.12

* scipy version update to be *

---------

Co-authored-by: Dhanshree Arora <[email protected]>
  • Loading branch information
Abellegese and DhanshreeA authored Jan 14, 2025
1 parent 4f099d5 commit 5dc3e30
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
5 changes: 2 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,7 @@ pytest-benchmark = { version = "<=4.0.0", optional = true }
fuzzywuzzy = { version = "^0.18.0", optional = true }
sphinx = { version = ">=6.0.0", optional = true } # for minimum version and support for Python 3.10
jinja2 = { version = "^3.1.2", optional = true }
scipy = { version = "<=1.10.0", optional = true }
rdkit-pypi = { version = "*", optional = true }
scipy = { version = "*", optional = true }
nox = { version = "*", optional = true }
rich = { version = "*", optional = true }
ruff = { version = "*", optional = true }
Expand All @@ -70,7 +69,7 @@ pre-commit = { version = "*", optional = true }
# Instead of using poetry dependency groups, we use extras to make it pip installable
lake = ["isaura"]
docs = ["sphinx", "jinja2"]
test = ["pytest", "pytest-asyncio", "pytest-benchmark", "nox", "rich", "fuzzywuzzy", "scipy", "rdkit-pypi", "ruff", "pre-commit"]
test = ["pytest", "pytest-asyncio", "pytest-benchmark", "nox", "rich", "fuzzywuzzy", "scipy", "ruff", "pre-commit"]
#all = [lake, docs, test]

[tool.poetry.scripts]
Expand Down
10 changes: 9 additions & 1 deletion test/cli/test_run.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@
from ersilia.core.model import ErsiliaModel
from ersilia.core.session import Session
from ersilia.serve.standard_api import StandardCSVRunApi
from ersilia.setup.requirements.compound import (
ChemblWebResourceClientRequirement,
RdkitRequirement,
)
from ersilia.utils.logging import logger

from .utils import create_compound_input_csv
Expand All @@ -24,6 +28,10 @@
MAX_WEIGHT = 60.0
HEADER = ["key", "input", "value"]

@pytest.fixture
def setup():
RdkitRequirement()
ChemblWebResourceClientRequirement()

@pytest.fixture
def mock_fetcher():
Expand Down Expand Up @@ -119,7 +127,7 @@ def mock_post_side_effect(input, output, output_source):


@pytest.fixture
def mock_session(compound_csv):
def mock_session(setup, compound_csv):
with (
patch.object(Session, "current_model_id", return_value=MODEL_ID),
patch.object(Session, "current_service_class", return_value="pulled_docker"),
Expand Down

0 comments on commit 5dc3e30

Please sign in to comment.