Skip to content

Commit 016770e

Browse files
authored
Bump minimum Python to 3.11 and support Python 3.14 (#479)
1 parent 31ac983 commit 016770e

6 files changed

Lines changed: 14 additions & 14 deletions

File tree

.github/workflows/tests.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
runs-on: ubuntu-latest
2626
strategy:
2727
matrix:
28-
python-version: [ "3.13", "3.10" ]
28+
python-version: [ "3.14", "3.11" ]
2929
tox-command: [ "lint", "pyroma", "mypy" ]
3030
steps:
3131
- uses: actions/checkout@v4
@@ -48,7 +48,7 @@ jobs:
4848
# We only test documentation on the latest version
4949
# sphinx 8.0 / sphinx-rtd-theme 3.0 discontinued Python 3.9 support
5050
# a year early, which prompted re-thinking about this.
51-
python-version: [ "3.13" ]
51+
python-version: [ "3.14" ]
5252
steps:
5353
- uses: actions/checkout@v4
5454
- name: "Install uv"
@@ -76,7 +76,7 @@ jobs:
7676
strategy:
7777
matrix:
7878
os: [ ubuntu-latest ]
79-
python-version: [ "3.13", "3.10" ]
79+
python-version: [ "3.14", "3.11" ]
8080
steps:
8181
- uses: actions/checkout@v4
8282
- name: "Install uv"

pyproject.toml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ classifiers = [
2727
"Framework :: Sphinx",
2828
"Natural Language :: English",
2929
"Programming Language :: Python",
30-
"Programming Language :: Python :: 3.10",
3130
"Programming Language :: Python :: 3.11",
3231
"Programming Language :: Python :: 3.12",
3332
"Programming Language :: Python :: 3.13",
33+
"Programming Language :: Python :: 3.14",
3434
"Programming Language :: Python :: 3 :: Only",
3535
"Typing :: Typed",
3636
"Topic :: Scientific/Engineering :: Bio-Informatics",
@@ -55,7 +55,7 @@ license-files = [
5555
"LICENSE",
5656
]
5757

58-
requires-python = ">=3.10"
58+
requires-python = ">=3.11"
5959
dependencies = [
6060
"obonet>=0.3.0",
6161
"click",
@@ -162,7 +162,9 @@ gilda-slim = [
162162
"ssslm[gilda-slim]",
163163
]
164164
sources = [
165-
"pyobo[drugcentral,pid]",
165+
# keep as sum of all sources
166+
"psycopg2-binary",
167+
"protmapper"
166168
]
167169
drugcentral =[
168170
"psycopg2-binary",

src/pyobo/api/hierarchy.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@
44
import warnings
55
from collections.abc import Iterable
66
from functools import lru_cache
7-
from typing import overload
7+
from typing import NotRequired, overload
88

99
import networkx as nx
1010
from curies import ReferenceTuple
11-
from typing_extensions import NotRequired, Unpack
11+
from typing_extensions import Unpack
1212

1313
from .edges import get_edges
1414
from .names import get_name, get_references

src/pyobo/constants.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@
66
import re
77
from collections.abc import Callable
88
from pathlib import Path
9-
from typing import Literal, NamedTuple, TypeAlias
9+
from typing import Literal, NamedTuple, NotRequired, TypeAlias
1010

1111
import pystow
12-
from typing_extensions import NotRequired, TypedDict
12+
from typing_extensions import TypedDict
1313

1414
__all__ = [
1515
"DATABASE_DIRECTORY",

src/pyobo/struct/struct.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
from dataclasses import dataclass, field
1717
from pathlib import Path
1818
from textwrap import dedent
19-
from typing import Annotated, Any, ClassVar, TextIO
19+
from typing import Annotated, Any, ClassVar, Self, TextIO
2020

2121
import bioregistry
2222
import click
@@ -29,7 +29,6 @@
2929
from more_click import force_option, verbose_option
3030
from pystow.utils import safe_open
3131
from tqdm.auto import tqdm
32-
from typing_extensions import Self
3332

3433
from . import vocabulary as v
3534
from .reference import (

src/pyobo/struct/struct_utils.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,15 +9,14 @@
99
from abc import ABC, abstractmethod
1010
from collections import defaultdict
1111
from collections.abc import Iterable, Mapping, Sequence
12-
from typing import TYPE_CHECKING, Literal, NamedTuple, TypeAlias, overload
12+
from typing import TYPE_CHECKING, Literal, NamedTuple, Self, TypeAlias, overload
1313

1414
import curies
1515
from curies import ReferenceTuple
1616
from curies import vocabulary as _v
1717
from curies.vocabulary import SynonymScope
1818
from pydantic import BaseModel, ConfigDict
1919
from ssslm import LiteralMapping
20-
from typing_extensions import Self
2120

2221
from . import vocabulary as v
2322
from .reference import (

0 commit comments

Comments
 (0)