From 8dbce9195bf08f235d739946c12161938a294704 Mon Sep 17 00:00:00 2001 From: Kevin James Date: Fri, 26 Apr 2024 15:44:23 +0100 Subject: [PATCH] feat(compat): officially support pythons 3.11 and 3.12 (#419) --- .circleci/config.yml | 10 +++++++++- .github/workflows/build.yml | 2 +- .github/workflows/test.yml | 2 +- .readthedocs.yml | 2 +- Dockerfile | 2 +- poetry.lock | 4 ++-- pyproject.toml | 9 +++++++-- tox.ini | 4 +++- 8 files changed, 25 insertions(+), 10 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index f34b480..ef0b3f9 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -21,6 +21,14 @@ executors: docker: - image: python:3.10-alpine resource_class: small + py311: + docker: + - image: python:3.11-alpine + resource_class: small + py312: + docker: + - image: python:3.12-alpine + resource_class: small pypy737: # py38 docker: - image: pypy:3-7.3.7-slim @@ -161,7 +169,7 @@ workflows: name: test-<> matrix: parameters: - executor: [py38, py39, py310] + executor: [py38, py39, py310, py311, py312] - toxpypy: name: test-<> matrix: diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index f715da9..6ab66a7 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -15,7 +15,7 @@ jobs: - uses: actions/checkout@v4.1.4 - uses: actions/setup-python@v4 with: - python-version: '3.10' + python-version: '3.12' - uses: snok/install-poetry@v1.3.4 with: # TODO: renovate diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index b6acca5..e9f413e 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -7,7 +7,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: ['3.8', '3.9', '3.10'] + python-version: ['3.8', '3.9', '3.10', '3.11', '3.12'] steps: - uses: actions/checkout@v4.1.4 diff --git a/.readthedocs.yml b/.readthedocs.yml index 9b6b848..79826fc 100644 --- a/.readthedocs.yml +++ b/.readthedocs.yml @@ -3,7 +3,7 @@ version: 2 build: os: ubuntu-lts-latest tools: - python: "3.10" + python: "3.12" jobs: post_create_environment: - pip install poetry diff --git a/Dockerfile b/Dockerfile index 3e0f41d..401754f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -6,7 +6,7 @@ ARG COVERALLS_VERSION=3.3.1 ARG GIT_VERSION=2.43.0-r0 -FROM python:3.10-alpine3.19 +FROM python:3.12-alpine3.19 ARG GIT_VERSION RUN --mount=type=cache,target=/var/cache/apk \ diff --git a/poetry.lock b/poetry.lock index f15ac8b..db60189 100644 --- a/poetry.lock +++ b/poetry.lock @@ -722,5 +722,5 @@ yaml = ["pyyaml"] [metadata] lock-version = "2.0" -python-versions = ">=3.8,<3.11" -content-hash = "49f14d61c19b54969f1b64e510c22db89f8e3db8667ae3db5afa8795e980470e" +python-versions = ">=3.8,<3.13" +content-hash = "a39b94bd5df24109488ee8f93e8e4823df2f1b3f66a5a416a77cae7bb0f835f1" diff --git a/pyproject.toml b/pyproject.toml index 3ebb5c6..da967de 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -30,7 +30,7 @@ Docs = "https://coveralls-python.rtfd.io/" coveralls = "coveralls.cli:main" [tool.poetry.dependencies] -python = ">=3.8,<3.11" +python = ">=3.8,<3.13" coverage = ">=5.0,<7.0,!=6.0.*,!=6.1,!=6.1.1" docopt = ">=0.6.1,<0.7.0" requests = ">=1.0.0,<3.0.0" @@ -50,7 +50,12 @@ sphinx = { version = "7.3.7", python = ">=3.9" } yaml = ["pyyaml"] [tool.pytest.ini_options] -addopts = "-Werror" +# addopts = "-Werror" +filterwarnings = [ + "error", + # cov5 and cov6 are deprecated on py3.12+ + "ignore:co_lnotab is deprecated, use co_lines instead:DeprecationWarning", +] [build-system] requires = ["poetry-core>=1.0.0"] diff --git a/tox.ini b/tox.ini index 63572d5..de80964 100644 --- a/tox.ini +++ b/tox.ini @@ -1,11 +1,13 @@ [tox] -envlist = py{38,39,310,py3}-cov{5,6}-{default,pyyaml} +envlist = py{38,39,310,311,312,py3}-cov{5,6}-{default,pyyaml} [gh-actions] python = 3.8: py38,upload 3.9: py39,upload 3.10: py310,upload + 3.11: py311,upload + 3.12: py312,upload [testenv] passenv = *