updated python versiions in CI (#1663)

* updated python versiions in CI

* updated python versiions in CI with

* updated tox

* updated ci

* Update .github/workflows/ci.yaml

* Update .github/workflows/ci.yaml

* Update .github/workflows/ci.yaml
This commit is contained in:
Asif Saif Uddin 2023-03-13 10:57:16 +06:00 committed by GitHub
parent c310364cc0
commit 208eccefd4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 24 additions and 24 deletions

View File

@ -6,7 +6,7 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
strategy: strategy:
matrix: matrix:
python-version: [3.7,3.8,3.9] python-version: [3.7,3.8,3.9,"3.10"]
steps: steps:
- name: Install system packages - name: Install system packages
run: sudo apt update && sudo apt-get install libcurl4-openssl-dev libssl-dev run: sudo apt update && sudo apt-get install libcurl4-openssl-dev libssl-dev
@ -29,12 +29,10 @@ jobs:
strategy: strategy:
fail-fast: false fail-fast: false
matrix: matrix:
python-version: [3.7,3.8,3.9] python-version: [3.8,3.9,"3.10"]
experimental: [false] experimental: [false]
include: include:
- python-version: pypy-3.7 - python-version: pypy-3.9
experimental: true
- python-version: pypy-3.8
experimental: true experimental: true
steps: steps:
- name: Install system packages - name: Install system packages
@ -48,7 +46,7 @@ jobs:
python-version: ${{ matrix.python-version }} python-version: ${{ matrix.python-version }}
- name: Install dependencies - name: Install dependencies
run: pip install --upgrade pip setuptools wheel tox tox-docker run: pip install --upgrade pip setuptools wheel tox tox-docker
# Tox fails if a Python versions contains a hyphen, this changes "pypy-3.8" to "pypy3.8". # Tox fails if a Python versions contains a hyphen, this changes "pypy-3.9" to "pypy3.9".
- name: Determine Python version - name: Determine Python version
run: echo PYTHON_VERSION=$(echo ${{ matrix.python-version }} | sed s/-//) >> $GITHUB_ENV run: echo PYTHON_VERSION=$(echo ${{ matrix.python-version }} | sed s/-//) >> $GITHUB_ENV
- name: Run AMQP integration tests - name: Run AMQP integration tests
@ -58,7 +56,7 @@ jobs:
- name: Run MongoDB integration tests - name: Run MongoDB integration tests
run: tox -v -e ${{ env.PYTHON_VERSION }}-linux-integration-py-mongodb -- -v run: tox -v -e ${{ env.PYTHON_VERSION }}-linux-integration-py-mongodb -- -v
- name: Run kafka integration tests - name: Run kafka integration tests
if: ${{ env.PYTHON_VERSION != 'pypy3.7' && env.PYTHON_VERSION != 'pypy3.8' }} if: ${{ env.PYTHON_VERSION != 'pypy3.9'}}
run: tox -v -e ${{ env.PYTHON_VERSION }}-linux-integration-py-kafka -- -v run: tox -v -e ${{ env.PYTHON_VERSION }}-linux-integration-py-kafka -- -v
#################### Linters and checkers #################### #################### Linters and checkers ####################
@ -67,7 +65,7 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
strategy: strategy:
matrix: matrix:
python-version: [3.9] python-version: ["3.10"]
steps: steps:
- name: Install system packages - name: Install system packages
run: sudo apt update && sudo apt-get install libcurl4-openssl-dev libssl-dev run: sudo apt update && sudo apt-get install libcurl4-openssl-dev libssl-dev

34
tox.ini
View File

@ -1,10 +1,10 @@
[tox] [tox]
envlist = envlist =
{pypy3.7,pypy3.8,3.7,3.8,3.9,3.10}-unit {pypy3.9,3.7,3.8,3.9,3.10,3.11}-unit
{pypy3.7,pypy3.8,3.7,3.8,3.9,3.10}-linux-integration-py-amqp {pypy3.9,3.7,3.8,3.9,3.10,3.11}-linux-integration-py-amqp
{pypy3.7,pypy3.8,3.7,3.8,3.9,3.10}-linux-integration-redis {pypy3.9,3.7,3.8,3.9,3.10,3.11}-linux-integration-redis
{pypy3.7,pypy3.8,3.7,3.8,3.9,3.10}-linux-integration-mongodb {pypy3.9,3.7,3.8,3.9,3.10,3.11}-linux-integration-mongodb
{3.7,3.8,3.9,3.10}-linux-integration-kafka {3.7,3.8,3.9,3.10,3.11}-linux-integration-kafka
flake8 flake8
apicheck apicheck
pydocstyle pydocstyle
@ -17,6 +17,7 @@ python =
3.8: py38 3.8: py38
3.9: py39 3.9: py39
3.10: py310, mypy 3.10: py310, mypy
3.11: py311
[testenv] [testenv]
sitepackages = False sitepackages = False
@ -25,28 +26,29 @@ passenv =
DISTUTILS_USE_SDK DISTUTILS_USE_SDK
deps= deps=
-r{toxinidir}/requirements/dev.txt -r{toxinidir}/requirements/dev.txt
apicheck,pypy3.7,pypy3.8,3.7,3.8,3.9,3.10: -r{toxinidir}/requirements/default.txt apicheck,pypy3.9,3.7,3.8,3.9,3.10,3.11: -r{toxinidir}/requirements/default.txt
apicheck,pypy3.7,pypy3.8,3.7,3.8,3.9,3.10: -r{toxinidir}/requirements/test.txt apicheck,pypy3.9,3.7,3.8,3.9,3.10,3.11: -r{toxinidir}/requirements/test.txt
apicheck,pypy3.7,pypy3.8,3.7-linux,3.8-linux,3.9-linux,3.10-linux: -r{toxinidir}/requirements/test-ci.txt apicheck,pypy3.9,3.7-linux,3.8-linux,3.9-linux,3.10-linux,3.11-linux: -r{toxinidir}/requirements/test-ci.txt
apicheck,3.7-linux,3.8-linux,3.9-linux,3.10-linux: -r{toxinidir}/requirements/extras/confluentkafka.txt apicheck,3.7-linux,3.8-linux,3.9-linux,3.10-linux,3.11-linux: -r{toxinidir}/requirements/extras/confluentkafka.txt
3.7-windows,3.8-windows,3.9-windows,3.10-windows: -r{toxinidir}/requirements/test-ci-windows.txt 3.8-windows,3.9-windows,3.10-windows,3.11-windows: -r{toxinidir}/requirements/test-ci-windows.txt
apicheck,linkcheck: -r{toxinidir}/requirements/docs.txt apicheck,linkcheck: -r{toxinidir}/requirements/docs.txt
flake8,flakeplus,pydocstyle,mypy: -r{toxinidir}/requirements/pkgutils.txt flake8,pydocstyle,mypy: -r{toxinidir}/requirements/pkgutils.txt
commands = commands =
unit: python -bb -m pytest -rxs -xv --cov=kombu --cov-report=xml --no-cov-on-fail {posargs} unit: python -bb -m pytest -rxs -xv --cov=kombu --cov-report=xml --no-cov-on-fail {posargs}
integration-py-amqp: py.test -xv -E py-amqp t/integration {posargs:-n2} integration-py-amqp: pytest -xv -E py-amqp t/integration {posargs:-n2}
integration-redis: py.test -xv -E redis t/integration {posargs:-n2} integration-redis: pytest -xv -E redis t/integration {posargs:-n2}
integration-mongodb: py.test -xv -E mongodb t/integration {posargs:-n2} integration-mongodb: pytest -xv -E mongodb t/integration {posargs:-n2}
integration-kafka: py.test -xv -E kafka t/integration {posargs:-n2} integration-kafka: pytest -xv -E kafka t/integration {posargs:-n2}
basepython = basepython =
pypy3.7: pypy3.7 pypy3.9: pypy3.9
pypy3.8: pypy3.8 pypy3.8: pypy3.8
3.7: python3.7 3.7: python3.7
3.8,mypy: python3.8 3.8,mypy: python3.8
3.9,apicheck,pydocstyle,flake8,linkcheck,cov: python3.9 3.9,apicheck,pydocstyle,flake8,linkcheck,cov: python3.9
3.10: python3.10 3.10: python3.10
3.11: python3.11
install_command = python -m pip --disable-pip-version-check install {opts} {packages} install_command = python -m pip --disable-pip-version-check install {opts} {packages}