From 0cd809ee7d8c8808214c09b27bac6bde3abf44c4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 22 Mar 2024 07:30:56 +0000 Subject: [PATCH 1/2] Bump pytest-mock from 3.11.1 to 3.14.0 Bumps [pytest-mock](https://github.com/pytest-dev/pytest-mock) from 3.11.1 to 3.14.0. - [Release notes](https://github.com/pytest-dev/pytest-mock/releases) - [Changelog](https://github.com/pytest-dev/pytest-mock/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest-mock/compare/v3.11.1...v3.14.0) --- updated-dependencies: - dependency-name: pytest-mock dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- requirements-dev.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/requirements-dev.txt b/requirements-dev.txt index d7eba41..8f10c7e 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -4,4 +4,4 @@ pytest-cov==4.1.0 pytest-order==1.1.0 parameterized==0.9.0 requests-mock==1.11.0 -pytest-mock==3.11.1 +pytest-mock==3.14.0 From 191c83434dd2340ead1f1fe8213736b81cf78632 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Fri, 22 Mar 2024 07:31:12 +0000 Subject: [PATCH 2/2] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- example/example_run.py | 18 +++++++++--------- geneplexus/geneplexus.py | 6 +++--- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/example/example_run.py b/example/example_run.py index 7f415eb..3fcfe6e 100755 --- a/example/example_run.py +++ b/example/example_run.py @@ -41,20 +41,20 @@ tasks="All", networks="STRING", features="SixSpeciesN2V", - sp_trn = "Human", - sp_tst = "Mouse", - gsc= "GO", + sp_trn="Human", + sp_tst="Mouse", + gsc="GO", ) # Run through the pipeline # First initialize the geneplexus object myclass = geneplexus.GenePlexus( - file_loc = fp_data, - gsc = "Combined", - features = "SixSpeciesN2V", - net_type = "STRING", - sp_trn = "Human", - sp_tst = "Mouse", + file_loc=fp_data, + gsc="Combined", + features="SixSpeciesN2V", + net_type="STRING", + sp_trn="Human", + sp_tst="Mouse", ) # Load the input genes into the class and set up positives/negatives diff --git a/geneplexus/geneplexus.py b/geneplexus/geneplexus.py index e6144dd..8204ce2 100755 --- a/geneplexus/geneplexus.py +++ b/geneplexus/geneplexus.py @@ -16,7 +16,8 @@ from ._config import logger from ._config.logger_util import set_stream_level from .download import download_select_data -from .exception import CustomDataError, ZebrafishBioGRIDError +from .exception import CustomDataError +from .exception import ZebrafishBioGRIDError class GenePlexus: @@ -88,14 +89,13 @@ def __init__( if input_genes is not None: self.load_genes(input_genes) - + if ("Zebrafish" == (self.sp_trn or self.sp_tst)) and (self.net_type == "BioGRID"): raise ZebrafishBioGRIDError( f"The BioGRID network for Zebrafish is not " "included due to it not having enough nodes " "so this combination is not allowed.", ) - @property def _params(self) -> List[str]: