diff --git a/.github/workflows/ndex.yml b/.github/workflows/ndex.yml index 6d2be0ee..4dd7785b 100644 --- a/.github/workflows/ndex.yml +++ b/.github/workflows/ndex.yml @@ -14,7 +14,7 @@ jobs: - uses: actions/checkout@master - uses: actions/setup-python@v2 with: - python-version: "3.13" + python-version: "3.14" - name: Install dependencies run: | pip install tox tox-uv diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 142cfb32..5c00be8c 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -25,7 +25,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: [ "3.13", "3.10" ] + python-version: [ "3.14", "3.10" ] tox-command: [ "lint", "pyroma", "mypy" ] steps: - uses: actions/checkout@v4 @@ -48,7 +48,7 @@ jobs: # We only test documentation on the latest version # sphinx 8.0 / sphinx-rtd-theme 3.0 discontinued Python 3.9 support # a year early, which prompted re-thinking about this. - python-version: [ "3.13" ] + python-version: [ "3.14" ] steps: - uses: actions/checkout@v4 - name: "Install uv" @@ -76,7 +76,7 @@ jobs: strategy: matrix: os: [ ubuntu-latest ] - python-version: [ "3.13", "3.10" ] + python-version: [ "3.14", "3.10" ] steps: - uses: actions/checkout@v4 - name: "Install uv" diff --git a/.github/workflows/update_web.yml b/.github/workflows/update_web.yml index ae0bdd79..e7109916 100644 --- a/.github/workflows/update_web.yml +++ b/.github/workflows/update_web.yml @@ -14,10 +14,10 @@ jobs: - uses: actions/checkout@master with: persist-credentials: false # otherwise, the token used is the GITHUB_TOKEN, instead of your personal token - fetch-depth: 0 # otherwise, you will failed to push refs to dest repo + fetch-depth: 0 # otherwise, you will fail to push refs to dest repo - uses: actions/setup-python@v2 with: - python-version: "3.13" + python-version: "3.14" - name: Install dependencies run: | pip install tox tox-uv diff --git a/pyproject.toml b/pyproject.toml index 05264b88..b023eb84 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ dependencies = [ "curies>=0.13.0", "bioregistry>=0.13.0", "sssom-pydantic>=0.4.1", - "sssom-curator[web]>=0.3.0", + "sssom-curator[web]>=0.3.1", ] # see https://peps.python.org/pep-0735/ and https://docs.astral.sh/uv/concepts/dependencies/#dependency-groups diff --git a/scripts/generate_cl_mesh_mappings.py b/scripts/generate_cl_mesh_mappings.py index c0962a3b..9cd01aa0 100644 --- a/scripts/generate_cl_mesh_mappings.py +++ b/scripts/generate_cl_mesh_mappings.py @@ -33,12 +33,12 @@ if has_mesh_id: continue - matches = gilda.ground(data["name"]) + matches = gilda.ground(data["name"]) # type:ignore[no-untyped-call] if not matches: if data["name"].endswith(" cells"): - matches = gilda.ground(data["name"].replace(" cells", "")) + matches = gilda.ground(data["name"].replace(" cells", "")) # type:ignore[no-untyped-call] elif data["name"].endswith(" cell"): - matches = gilda.ground(data["name"].replace(" cell", "")) + matches = gilda.ground(data["name"].replace(" cell", "")) # type:ignore[no-untyped-call] if not matches: continue diff --git a/scripts/generate_vaccine_mappings.py b/scripts/generate_vaccine_mappings.py index b7387e82..c3e85f1f 100644 --- a/scripts/generate_vaccine_mappings.py +++ b/scripts/generate_vaccine_mappings.py @@ -2,6 +2,7 @@ import click import pyobo +import ssslm from curies.vocabulary import exact_match, lexical_matching_process from pyobo.sources.cpt import iter_terms from sssom_pydantic import MappingTool, SemanticMapping @@ -19,10 +20,12 @@ def main() -> None: append_lexical_predictions("cpt", ["mesh", "vo"], mapping_tool=provenance) preds = [] - grounder = pyobo.get_grounder(["mesh", "vo"], versions=["2023", None]) + grounder: ssslm.Grounder = pyobo.get_grounder(["mesh", "vo"], versions=["2023", None]) for term in iter_terms(): texts = [term.name, *(s.name for s in term.synonyms)] for text in texts: + if not text: + continue for scored_match in grounder.get_matches(text + " vaccine"): pred = SemanticMapping( subject=term.reference, diff --git a/scripts/generate_wikipathways_orthologs.py b/scripts/generate_wikipathways_orthologs.py index 761d0068..24390505 100644 --- a/scripts/generate_wikipathways_orthologs.py +++ b/scripts/generate_wikipathways_orthologs.py @@ -16,7 +16,7 @@ def _lexical_exact_match(name1: str, name2: str) -> bool: - return cast(str, normalize(name1)) == cast(str, normalize(name2)) + return cast(str, normalize(name1)) == cast(str, normalize(name2)) # type:ignore[no-untyped-call] def iterate_orthologous_lexical_matches(prefix: str = "wikipathways") -> Iterable[SemanticMapping]: diff --git a/tox.ini b/tox.ini index f992e2d1..33a60342 100644 --- a/tox.ini +++ b/tox.ini @@ -148,10 +148,9 @@ dependency_groups = commands = mypy --ignore-missing-imports --strict src/ tests/ scripts/ extras = web - pyobo - gilda-slim + predict-lexical + predict-embeddings exports - charts [testenv:docs-lint] skip_install = true