Python 3.10 (#520)

* Add GA test and linter jobs

* Remove not used async run() functions from tests

* Update aiohttp ext test

* Add botocore warning ignores

* Update changelog

* Update publishing job config for testing

* Publishing test #1

* Update GA tests-and-linters job to use latest ubuntu for tests

* Update publishing GA job
This commit is contained in:
Roman Mogylatov 2021-10-20 12:10:05 -04:00 committed by GitHub
parent 94aca21fb8
commit b97862cb9f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 31 additions and 23 deletions

View File

@ -9,20 +9,20 @@ jobs:
tests: tests:
name: Run tests name: Run tests
runs-on: ubuntu-18.04 runs-on: ubuntu-20.04
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
with: with:
python-version: 3.9 python-version: "3.10"
- run: pip install tox - run: pip install tox
- run: tox - run: tox
env: env:
TOXENV: 3.9 TOXENV: "3.10"
linters: linters:
name: Run linters name: Run linters
runs-on: ubuntu-18.04 runs-on: ubuntu-20.04
strategy: strategy:
matrix: matrix:
toxenv: [flake8, pydocstyle, mypy, pylint] toxenv: [flake8, pydocstyle, mypy, pylint]
@ -30,7 +30,7 @@ jobs:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
with: with:
python-version: 3.9 python-version: "3.10"
- run: pip install tox - run: pip install tox
- run: tox - run: tox
env: env:
@ -39,12 +39,12 @@ jobs:
build-sdist: build-sdist:
name: Build source tarball name: Build source tarball
needs: [tests, linters] needs: [tests, linters]
runs-on: ubuntu-18.04 runs-on: ubuntu-20.04
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
with: with:
python-version: 3.9 python-version: "3.10"
- run: python setup.py sdist - run: python setup.py sdist
- uses: actions/upload-artifact@v2 - uses: actions/upload-artifact@v2
with: with:
@ -56,15 +56,15 @@ jobs:
runs-on: ${{ matrix.os }} runs-on: ${{ matrix.os }}
strategy: strategy:
matrix: matrix:
os: [ubuntu-18.04, windows-latest, macos-latest] os: [ubuntu-20.04, windows-2019, macOS-10.15]
env: env:
CIBW_SKIP: cp27-win* CIBW_SKIP: cp27-win*
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
with: with:
python-version: 3.9 python-version: "3.10"
- run: pip install cibuildwheel==1.8.0 - run: pip install cibuildwheel==2.1.3
- run: cibuildwheel --output-dir wheelhouse - run: cibuildwheel --output-dir wheelhouse
- uses: actions/upload-artifact@v2 - uses: actions/upload-artifact@v2
with: with:
@ -73,15 +73,15 @@ jobs:
build-wheels-linux-aarch64: build-wheels-linux-aarch64:
name: Build wheels (ubuntu-latest-aarch64) name: Build wheels (ubuntu-latest-aarch64)
needs: [tests, linters] needs: [tests, linters]
runs-on: ubuntu-18.04 runs-on: ubuntu-20.04
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- name: Set up QEMU - name: Set up QEMU
uses: docker/setup-qemu-action@v1 uses: docker/setup-qemu-action@v1
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
with: with:
python-version: 3.9 python-version: "3.10"
- run: pip install cibuildwheel==1.8.0 - run: pip install cibuildwheel==2.1.3
- run: cibuildwheel --archs aarch64 --output-dir wheelhouse - run: cibuildwheel --archs aarch64 --output-dir wheelhouse
- uses: actions/upload-artifact@v2 - uses: actions/upload-artifact@v2
with: with:
@ -90,7 +90,7 @@ jobs:
publish: publish:
name: Publish on PyPI name: Publish on PyPI
needs: [build-sdist, build-wheels, build-wheels-linux-aarch64] needs: [build-sdist, build-wheels, build-wheels-linux-aarch64]
runs-on: ubuntu-18.04 runs-on: ubuntu-20.04
steps: steps:
- uses: actions/download-artifact@v2 - uses: actions/download-artifact@v2
with: with:
@ -100,6 +100,9 @@ jobs:
with: with:
user: __token__ user: __token__
password: ${{ secrets.PYPI_API_TOKEN }} password: ${{ secrets.PYPI_API_TOKEN }}
# For publishing to Test PyPI, uncomment next two lines:
# password: ${{ secrets.TEST_PYPI_API_TOKEN }}
# repository_url: https://test.pypi.org/legacy/
publish-docs: publish-docs:
name: Publish docs name: Publish docs
@ -109,7 +112,7 @@ jobs:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
with: with:
python-version: 3.9 python-version: "3.10"
- run: pip install -r requirements-doc.txt - run: pip install -r requirements-doc.txt
- run: pip install awscli - run: pip install awscli
- run: pip install -e . - run: pip install -e .

View File

@ -6,10 +6,10 @@ jobs:
test-on-different-versions: test-on-different-versions:
name: Run tests name: Run tests
runs-on: ubuntu-18.04 runs-on: ubuntu-latest
strategy: strategy:
matrix: matrix:
python-version: [2.7, 3.5, 3.6, 3.7, 3.8, 3.9, pypy2, pypy3] python-version: [2.7, 3.5, 3.6, 3.7, 3.8, 3.9, "3.10", pypy2, pypy3]
steps: steps:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
@ -31,7 +31,7 @@ jobs:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
with: with:
python-version: 3.9 python-version: "3.10"
- run: pip install tox cython - run: pip install tox cython
- run: make cythonize - run: make cythonize
- run: tox - run: tox
@ -48,7 +48,7 @@ jobs:
- uses: actions/checkout@v2 - uses: actions/checkout@v2
- uses: actions/setup-python@v2 - uses: actions/setup-python@v2
with: with:
python-version: 3.9 python-version: "3.10"
- run: pip install tox - run: pip install tox
- run: tox - run: tox
env: env:

View File

@ -9,6 +9,7 @@ follows `Semantic versioning`_
Develop Develop
------- -------
- Add support of Python 3.10.
- Improve wiring with adding importing modules and packages from a string - Improve wiring with adding importing modules and packages from a string
``container.wire(modules=["yourapp.module1"])``. ``container.wire(modules=["yourapp.module1"])``.
- Add container wiring configuration ``wiring_config = containers.WiringConfiguration()``. - Add container wiring configuration ``wiring_config = containers.WiringConfiguration()``.

View File

@ -101,6 +101,7 @@ setup(name="dependency-injector",
"Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: Implementation :: CPython", "Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy", "Programming Language :: Python :: Implementation :: PyPy",
"Framework :: AsyncIO", "Framework :: AsyncIO",

View File

@ -1,6 +1,7 @@
[pytest] [pytest]
testpaths = tests/unit testpaths = tests/unit/
python_files = test_*_py2_py3.py python_files = test_*_py2_py3.py
filterwarnings = filterwarnings =
ignore:Module \"dependency_injector.ext.aiohttp\" is deprecated since version 4\.0\.0:DeprecationWarning ignore:Module \"dependency_injector.ext.aiohttp\" is deprecated since version 4\.0\.0:DeprecationWarning
ignore:Module \"dependency_injector.ext.flask\" is deprecated since version 4\.0\.0:DeprecationWarning ignore:Module \"dependency_injector.ext.flask\" is deprecated since version 4\.0\.0:DeprecationWarning
ignore:ssl\.PROTOCOL_TLS is deprecated:DeprecationWarning:botocore.*

View File

@ -1,6 +1,7 @@
[pytest] [pytest]
testpaths = tests/unit testpaths = tests/unit/
python_files = test_*_py3.py python_files = test_*_py3.py
filterwarnings = filterwarnings =
ignore:Module \"dependency_injector.ext.aiohttp\" is deprecated since version 4\.0\.0:DeprecationWarning ignore:Module \"dependency_injector.ext.aiohttp\" is deprecated since version 4\.0\.0:DeprecationWarning
ignore:Module \"dependency_injector.ext.flask\" is deprecated since version 4\.0\.0:DeprecationWarning ignore:Module \"dependency_injector.ext.flask\" is deprecated since version 4\.0\.0:DeprecationWarning
ignore:ssl\.PROTOCOL_TLS is deprecated:DeprecationWarning:botocore.*

View File

@ -4,3 +4,4 @@ python_files = test_*_py3*.py
filterwarnings = filterwarnings =
ignore:Module \"dependency_injector.ext.aiohttp\" is deprecated since version 4\.0\.0:DeprecationWarning ignore:Module \"dependency_injector.ext.aiohttp\" is deprecated since version 4\.0\.0:DeprecationWarning
ignore:Module \"dependency_injector.ext.flask\" is deprecated since version 4\.0\.0:DeprecationWarning ignore:Module \"dependency_injector.ext.flask\" is deprecated since version 4\.0\.0:DeprecationWarning
ignore:ssl\.PROTOCOL_TLS is deprecated:DeprecationWarning:botocore.*

View File

@ -1,6 +1,6 @@
[tox] [tox]
envlist= envlist=
coveralls, pylint, flake8, pydocstyle, 2.7, 3.5, 3.6, 3.7, 3.8, 3.9, pypy2, pypy3 coveralls, pylint, flake8, pydocstyle, 2.7, 3.5, 3.6, 3.7, 3.8, 3.9, 3.10, pypy2, pypy3
[testenv] [testenv]
deps= deps=
@ -24,7 +24,7 @@ python_files = test_*_py3*.py
[testenv:coveralls] [testenv:coveralls]
passenv = GITHUB_* COVERALLS_* passenv = GITHUB_* COVERALLS_*
basepython=python3.9 basepython=python3.10
usedevelop=True usedevelop=True
deps= deps=
{[testenv]deps} {[testenv]deps}