diff --git a/.github/workflows/run-all-tests.yml b/.github/workflows/run-all-tests.yml index c325701..0ddbddc 100644 --- a/.github/workflows/run-all-tests.yml +++ b/.github/workflows/run-all-tests.yml @@ -129,6 +129,9 @@ jobs: needs: [cpython, static-tests, pypy, hypothesis-tests] name: Build and publish to PyPI and TestPyPI runs-on: ubuntu-latest + environment: release + permissions: + id-token: write steps: - uses: actions/checkout@v4 - name: Set up Python 3.12 @@ -150,13 +153,10 @@ jobs: --outdir dist/ - name: Publish distribution 📦 to Test PyPI for tags if: startsWith(github.ref, 'refs/tags') - uses: pypa/gh-action-pypi-publish@master + uses: pypa/gh-action-pypi-publish@release/v1 with: - password: ${{ secrets.TEST_PYPI_API_TOKEN }} repository_url: https://test.pypi.org/legacy/ - name: Publish distribution 📦 to PyPI for push to main if: github.event_name == 'push' && github.ref == 'refs/heads/main' - uses: pypa/gh-action-pypi-publish@master - with: - password: ${{ secrets.PYPI_API_TOKEN }} + uses: pypa/gh-action-pypi-publish@release/v1 ... diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 2ebf92a..3003cbe 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -4,7 +4,7 @@ repos: hooks: - id: check-useless-excludes - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.6.0 + rev: v5.0.0 hooks: - id: check-added-large-files - id: check-docstring-first @@ -36,11 +36,11 @@ repos: hooks: - id: isort - repo: https://github.com/psf/black - rev: 24.8.0 + rev: 24.10.0 hooks: - id: black - repo: https://github.com/astral-sh/ruff-pre-commit - rev: 'v0.6.7' + rev: 'v0.6.9' hooks: - id: ruff args: [--fix, --exit-non-zero-on-fix] @@ -78,7 +78,7 @@ repos: # hooks: # - id: rst-linter - repo: https://github.com/abravalheri/validate-pyproject - rev: v0.19 + rev: v0.20.2 hooks: - id: validate-pyproject - repo: https://github.com/kieran-ryan/pyprojectsort @@ -86,7 +86,7 @@ repos: hooks: - id: pyprojectsort - repo: https://github.com/python-jsonschema/check-jsonschema - rev: "0.29.2" + rev: "0.29.4" hooks: - id: check-github-workflows - id: check-github-actions