-
-
Notifications
You must be signed in to change notification settings - Fork 310
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'release/4.41.0' into master
- Loading branch information
Showing
24 changed files
with
344 additions
and
122 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
name: Publishing | ||
|
||
on: | ||
workflow_dispatch: | ||
push: | ||
tags: | ||
- '*' | ||
|
@@ -9,28 +10,28 @@ jobs: | |
|
||
tests: | ||
name: Run tests | ||
runs-on: ubuntu-20.04 | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.10" | ||
python-version: 3.11 | ||
- run: pip install tox | ||
- run: tox | ||
env: | ||
TOXENV: "3.10" | ||
TOXENV: 3.11 | ||
|
||
linters: | ||
name: Run linters | ||
runs-on: ubuntu-20.04 | ||
runs-on: ubuntu-22.04 | ||
strategy: | ||
matrix: | ||
toxenv: [flake8, pydocstyle, mypy, pylint] | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.10" | ||
python-version: 3.11 | ||
- run: pip install tox | ||
- run: tox | ||
env: | ||
|
@@ -39,14 +40,14 @@ jobs: | |
build-sdist: | ||
name: Build source tarball | ||
needs: [tests, linters] | ||
runs-on: ubuntu-20.04 | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.10" | ||
python-version: 3.11 | ||
- run: python setup.py sdist | ||
- uses: actions/upload-artifact@v2 | ||
- uses: actions/upload-artifact@v3 | ||
with: | ||
path: ./dist/* | ||
|
||
|
@@ -56,63 +57,60 @@ jobs: | |
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-20.04, windows-2019, macOS-10.15] | ||
os: [ubuntu-22.04, windows-2019, macos-11] | ||
env: | ||
CIBW_SKIP: cp27-win* | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
with: | ||
python-version: "3.10" | ||
- run: pip install cibuildwheel==2.1.3 | ||
- run: cibuildwheel --output-dir wheelhouse | ||
- uses: actions/upload-artifact@v2 | ||
- uses: actions/checkout@v3 | ||
- name: Build wheels | ||
uses: pypa/[email protected] | ||
- uses: actions/upload-artifact@v3 | ||
with: | ||
path: ./wheelhouse/*.whl | ||
|
||
build-wheels-linux-aarch64: | ||
name: Build wheels (ubuntu-latest-aarch64) | ||
name: Build wheels (ubuntu-22.04-aarch64) | ||
needs: [tests, linters] | ||
runs-on: ubuntu-20.04 | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v3 | ||
- name: Set up QEMU | ||
uses: docker/setup-qemu-action@v1 | ||
- uses: actions/setup-python@v2 | ||
with: | ||
python-version: "3.10" | ||
- run: pip install cibuildwheel==2.1.3 | ||
- run: cibuildwheel --archs aarch64 --output-dir wheelhouse | ||
- uses: actions/upload-artifact@v2 | ||
if: runner.os == 'Linux' | ||
uses: docker/setup-qemu-action@v2 | ||
- name: Build wheels | ||
uses: pypa/[email protected] | ||
env: | ||
CIBW_ARCHS_LINUX: aarch64 | ||
- uses: actions/upload-artifact@v3 | ||
with: | ||
path: ./wheelhouse/*.whl | ||
|
||
publish: | ||
name: Publish on PyPI | ||
needs: [build-sdist, build-wheels, build-wheels-linux-aarch64] | ||
runs-on: ubuntu-20.04 | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/download-artifact@v2 | ||
- uses: actions/download-artifact@v3 | ||
with: | ||
name: artifact | ||
path: dist | ||
- uses: pypa/gh-action-pypi-publish@master | ||
- uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
user: __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/ | ||
# For publishing to Test PyPI, uncomment next two lines: | ||
# password: ${{ secrets.TEST_PYPI_API_TOKEN }} | ||
# repository_url: https://test.pypi.org/legacy/ | ||
|
||
publish-docs: | ||
name: Publish docs | ||
needs: [publish] | ||
runs-on: ubuntu-18.04 | ||
runs-on: ubuntu-22.04 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.10" | ||
python-version: 3.11 | ||
- run: pip install -r requirements-doc.txt | ||
- run: pip install awscli | ||
- run: pip install -e . | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,6 +7,22 @@ that were made in every particular version. | |
From version 0.7.6 *Dependency Injector* framework strictly | ||
follows `Semantic versioning`_ | ||
|
||
4.41.0 | ||
------ | ||
- Add support of Python 3.11. | ||
- Allow Closing to detect dependent resources `#633 <https://github.com/ets-labs/python-dependency-injector/issues/633>`_, | ||
`#636 <https://github.com/ets-labs/python-dependency-injector/pull/636>`_. Thanks `Jamie Stumme @StummeJ <https://github.com/StummeJ>`_ | ||
for the contribution. | ||
- Update CI/CD to use Ubuntu 22.04. | ||
- Update CI/CD to ``actions/checkout@v3``, ``actions/setup-python@v4``, ``actions/upload-artifact@v3``, ``pypa/[email protected]``, | ||
and ``actions/download-artifact@v3``. | ||
- Fix install crash on non-utf8 systems `#644 <https://github.com/ets-labs/python-dependency-injector/pull/644>`_. | ||
- Fix a bug in Windows build with default charset `#635 <https://github.com/ets-labs/python-dependency-injector/pull/635>`_. | ||
- Update FastAPI Redis example to use ``aioredis`` version 2 `#613 <https://github.com/ets-labs/python-dependency-injector/pull/613>`_. | ||
- Update documentation on creating custom providers `#598 <https://github.com/ets-labs/python-dependency-injector/pull/598>`_. | ||
- Regenerate C sources using Cython 0.29.32. | ||
- Fix builds badge. | ||
|
||
4.40.0 | ||
------ | ||
- Add ``Configuration.from_json()`` method to load configuration from a json file. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
FROM python:3.9-buster | ||
FROM python:3.10-buster | ||
|
||
ENV PYTHONUNBUFFERED=1 | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,10 @@ | ||
"""Redis client module.""" | ||
|
||
from typing import AsyncIterator | ||
|
||
from aioredis import create_redis_pool, Redis | ||
from aioredis import from_url, Redis | ||
|
||
|
||
async def init_redis_pool(host: str, password: str) -> AsyncIterator[Redis]: | ||
pool = await create_redis_pool(f"redis://{host}", password=password) | ||
yield pool | ||
pool.close() | ||
await pool.wait_closed() | ||
session = from_url(f"redis://{host}", password=password, encoding="utf-8", decode_responses=True) | ||
yield session | ||
session.close() | ||
await session.wait_closed() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.