diff --git a/pyproject.toml b/pyproject.toml index 3873449d..b40fd1c8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -9,7 +9,7 @@ authors = [ ] license = {text = "MIT"} readme = "README.md" -requires-python = ">=3.8,<=3.11" +requires-python = ">=3.8,<3.12" dynamic = ["version"] keywords = ["pdes", "partial-differential-equations", "dynamical-systems"] diff --git a/scripts/_templates/pyproject.toml b/scripts/_templates/pyproject.toml index 54df9fed..31666426 100644 --- a/scripts/_templates/pyproject.toml +++ b/scripts/_templates/pyproject.toml @@ -6,7 +6,7 @@ authors = [ ] license = {text = "MIT"} readme = "README.md" -requires-python = ">=$MIN_PYTHON_VERSION,<=$MAX_PYTHON_VERSION" +requires-python = ">=$MIN_PYTHON_VERSION,<$MAX_PYTHON_VERSION_NEXT" dynamic = ["version"] keywords = ["pdes", "partial-differential-equations", "dynamical-systems"] diff --git a/scripts/create_requirements.py b/scripts/create_requirements.py index f239bdea..d497e7ac 100755 --- a/scripts/create_requirements.py +++ b/scripts/create_requirements.py @@ -270,11 +270,16 @@ def write_from_template( with template_path.open("r") as fp: template = Template(fp.read()) + # parse python version + major, minor = MAX_PYTHON_VERSION.split(".") + minor_next = int(minor) + 1 + # determine template substitutes substitutes = { "MIN_PYTHON_VERSION": MIN_PYTHON_VERSION, "MIN_PYTHON_VERSION_NODOT": MIN_PYTHON_VERSION.replace(".", ""), "MAX_PYTHON_VERSION": MAX_PYTHON_VERSION, + "MAX_PYTHON_VERSION_NEXT": f"{major}.{minor_next}", } if requirements: req_list = ( diff --git a/tests/requirements.txt b/tests/requirements.txt index 656d0d41..8961b6a6 100644 --- a/tests/requirements.txt +++ b/tests/requirements.txt @@ -4,7 +4,6 @@ importlib-metadata>=5 isort>=5.1 jupyter_contrib_nbextensions>=0.5 mypy>=0.770 -nbconvert>=5 pyinstrument>=3 pytest>=5.4 pytest-cov>=2.8