forked from sopherapps/pydantic-redis
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* ci: update tests and precommit * ci: bump ruff * ci: update release workflow * chore: bump fakeredis * chore: bump types-chroniter * ci: updates, pre-commit runs, etc * chore: drop 3.7, update bandit * ci: bump fastapi * docs: update doc requirements
- Loading branch information
1 parent
aa0f36c
commit 67b8f08
Showing
37 changed files
with
1,320 additions
and
1,760 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
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,8 +1,6 @@ | ||
|
||
pip==23.1.2 | ||
nox==2023.4.22 | ||
pip==24.0.0 | ||
nox==2024.4.15 | ||
nox-poetry==1.0.3 | ||
poetry==1.8.2 | ||
virtualenv==20.23.1 | ||
poetry-dynamic-versioning==0.24.0 | ||
virtualenv==20.26.1 | ||
toml==0.10.2 |
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 |
---|---|---|
|
@@ -8,32 +8,27 @@ jobs: | |
release: | ||
name: Release | ||
runs-on: ubuntu-latest | ||
environment: | ||
name: pypi | ||
url: https://pypi.org/p/pydantic-aioredis | ||
permissions: | ||
id-token: write | ||
steps: | ||
- name: Check out the repository | ||
uses: actions/checkout@v4 | ||
uses: actions/checkout@v4.1.4 | ||
with: | ||
fetch-depth: 2 | ||
- name: Set up Python | ||
uses: actions/[email protected] | ||
with: | ||
python-version: "3.10" | ||
|
||
- name: Upgrade pip | ||
python-version: "3.11" | ||
- name: Install pip and poetry | ||
run: | | ||
pip install --constraint=.github/workflows/constraints.txt pip | ||
pip install --upgrade --constraint .github/workflows/constraints.txt pip poetry | ||
pip --version | ||
- name: Install Poetry | ||
run: | | ||
pip install --constraint=.github/workflows/constraints.txt poetry poetry-dynamic-versioning | ||
poetry --version | ||
- name: Build package | ||
run: | | ||
poetry build --ansi | ||
- name: Publish package on PyPI | ||
uses: pypa/[email protected] | ||
with: | ||
user: __token__ | ||
password: ${{ secrets.PYPI_TOKEN }} | ||
poetry build | ||
- name: Publish package distributions to PyPI | ||
uses: pypa/gh-action-pypi-publish@release/v1 |
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 |
---|---|---|
|
@@ -11,22 +11,14 @@ jobs: | |
fail-fast: false | ||
matrix: | ||
include: | ||
- { python: "3.10", os: "ubuntu-latest", session: "pre-commit" } | ||
- { python: "3.10", os: "ubuntu-latest", session: "safety" } | ||
# - { python: "3.10", os: "ubuntu-latest", session: "mypy" } | ||
# - { python: "3.9", os: "ubuntu-latest", session: "mypy" } | ||
# - { python: "3.8", os: "ubuntu-latest", session: "mypy" } | ||
# - { python: "3.7", os: "ubuntu-latest", session: "mypy" } | ||
- { python: "3.10", os: "ubuntu-latest", session: "tests" } | ||
- { python: "3.11", os: "ubuntu-latest", session: "pre-commit" } | ||
- { python: "3.11", os: "ubuntu-latest", session: "safety" } | ||
- { python: "3.12", os: "ubuntu-latest", session: "tests" } | ||
- { python: "3.11", os: "ubuntu-latest", session: "tests" } | ||
- { python: "3.10", os: "ubuntu-latest", session: "tests" } | ||
- { python: "3.9", os: "ubuntu-latest", session: "tests" } | ||
- { python: "3.8", os: "ubuntu-latest", session: "tests" } | ||
- { python: "3.7", os: "ubuntu-latest", session: "tests" } | ||
# - { python: "3.10", os: "windows-latest", session: "tests" } | ||
# - { python: "3.10", os: "macos-latest", session: "tests" } | ||
# - { python: "3.10", os: "ubuntu-latest", session: "typeguard" } | ||
- { python: "3.10", os: "ubuntu-latest", session: "xdoctest" } | ||
- { python: "3.10", os: "ubuntu-latest", session: "docs-build" } | ||
- { python: "3.11", os: "ubuntu-latest", session: "docs-build" } | ||
|
||
env: | ||
NOXSESSION: ${{ matrix.session }} | ||
|
@@ -42,30 +34,12 @@ jobs: | |
with: | ||
python-version: ${{ matrix.python }} | ||
|
||
- name: Upgrade pip | ||
- name: Install needed tools | ||
run: | | ||
pip install --constraint=.github/workflows/constraints.txt pip | ||
pip install --upgrade pip nox poetry virtualenv toml --constraint=.github/workflows/constraints.txt | ||
pip --version | ||
- name: Upgrade pip in virtual environments | ||
shell: python | ||
run: | | ||
import os | ||
import pip | ||
with open(os.environ["GITHUB_ENV"], mode="a") as io: | ||
print(f"VIRTUALENV_PIP={pip.__version__}", file=io) | ||
- name: Install Poetry | ||
run: | | ||
pipx install --pip-args=--constraint=.github/workflows/constraints.txt poetry | ||
poetry --version | ||
- name: Install Nox | ||
run: | | ||
pipx install --pip-args=--constraint=.github/workflows/constraints.txt nox | ||
pipx inject --pip-args=--constraint=.github/workflows/constraints.txt nox nox-poetry | ||
nox --version | ||
# separate out nox-poetry until it gets a released version with support for 1.8 | ||
pip install --upgrade nox-poetry --constraint=.github/workflows/constraints.txt | ||
- name: Compute pre-commit cache key | ||
if: matrix.session == 'pre-commit' | ||
|
@@ -80,12 +54,12 @@ jobs: | |
payload = sys.version.encode() + sys.executable.encode() | ||
digest = hashlib.sha256(payload).hexdigest() | ||
result = "${{ runner.os }}-{}-{}-pre-commit".format(python, digest[:8]) | ||
with open(os.environ['GITHUB_OUTPUT'], 'a') as fh: | ||
fh.write(f"result={result}\n") | ||
- name: Restore pre-commit cache | ||
uses: actions/cache@v3.0.5 | ||
uses: actions/cache@v4.0.2 | ||
if: matrix.session == 'pre-commit' | ||
with: | ||
path: ~/.cache/pre-commit | ||
|
@@ -96,53 +70,3 @@ jobs: | |
- name: Run Nox | ||
run: | | ||
nox --force-color --python=${{ matrix.python }} | ||
- name: Upload coverage data | ||
if: always() && matrix.session == 'tests' | ||
uses: "actions/[email protected]" | ||
with: | ||
name: coverage-data | ||
path: ".coverage.*" | ||
|
||
- name: Upload documentation | ||
if: matrix.session == 'docs-build' | ||
uses: actions/[email protected] | ||
with: | ||
name: docs | ||
path: docs/_build | ||
|
||
coverage: | ||
runs-on: ubuntu-latest | ||
needs: tests | ||
steps: | ||
- name: Check out the repository | ||
uses: actions/checkout@v4 | ||
|
||
- name: Set up Python | ||
uses: actions/[email protected] | ||
with: | ||
python-version: "3.10" | ||
|
||
- name: Upgrade pip | ||
run: | | ||
pip install --constraint=.github/workflows/constraints.txt pip | ||
pip --version | ||
- name: Install Poetry | ||
run: | | ||
pipx install --pip-args=--constraint=.github/workflows/constraints.txt poetry | ||
poetry --version | ||
- name: Install Nox | ||
run: | | ||
pipx install --pip-args=--constraint=.github/workflows/constraints.txt nox | ||
pipx inject --pip-args=--constraint=.github/workflows/constraints.txt nox nox-poetry | ||
nox --version | ||
- name: Download coverage data | ||
uses: actions/[email protected] | ||
with: | ||
name: coverage-data | ||
|
||
- name: Upload coverage report | ||
uses: codecov/[email protected] |
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 |
---|---|---|
|
@@ -12,3 +12,4 @@ __pycache__/ | |
examples/benchmarks/.benchmarks | ||
examples/benchmarks/.coverage | ||
.hypothesis | ||
docs/_autosummary/* |
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 was deleted.
Oops, something went wrong.
47 changes: 0 additions & 47 deletions
47
docs/_autosummary/pydantic_aioredis.config.RedisConfig.rst
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.