diff --git a/.bumpversion.cfg b/.bumpversion.cfg index 81bd1f0e..2f16203b 100644 --- a/.bumpversion.cfg +++ b/.bumpversion.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 0.45.0 +current_version = 0.46.0 commit = True tag = False message = chore: Bump version from {current_version} to {new_version} diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 8fe430d7..198965e5 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -37,7 +37,7 @@ jobs: - name: Set Up Python ${{ matrix.python_version }} id: set_up_python - uses: actions/setup-python@v5.4.0 + uses: actions/setup-python@v5.6.0 with: python-version: "${{ matrix.python_version }}" check-latest: true @@ -46,7 +46,7 @@ jobs: run: make python-virtualenv PYTHON_VIRTUALENV_DIR="venv" - name: Restoring/Saving Cache - uses: actions/cache@v4.2.2 + uses: actions/cache@v4.2.3 with: path: | .tox @@ -81,13 +81,13 @@ jobs: - name: Set Up Python ${{ matrix.python_version }} id: set_up_python - uses: actions/setup-python@v5.4.0 + uses: actions/setup-python@v5.6.0 with: python-version: "${{ matrix.python_version }}" check-latest: true - name: Restoring/Saving Cache - uses: actions/cache@v4.2.2 + uses: actions/cache@v4.2.3 with: path: | .tox @@ -128,7 +128,7 @@ jobs: make test-coverage-report - name: Upload coverage reports to Codecov - uses: codecov/codecov-action@v5.4.0 + uses: codecov/codecov-action@v5.4.2 with: token: ${{ secrets.CODECOV_TOKEN }} directory: ./test-reports/coverage/ @@ -143,7 +143,7 @@ jobs: - name: Store Artifacts if: ${{ always() }} - uses: actions/upload-artifact@v4.6.1 + uses: actions/upload-artifact@v4.6.2 with: name: test_reports_${{ matrix.python_version }} path: test-reports/ diff --git a/.github/workflows/dependency-review.yaml b/.github/workflows/dependency-review.yaml index e453b58a..9b18ff34 100644 --- a/.github/workflows/dependency-review.yaml +++ b/.github/workflows/dependency-review.yaml @@ -24,6 +24,6 @@ jobs: uses: actions/checkout@v4.2.2 - name: Dependency Review - uses: actions/dependency-review-action@v4.5.0 + uses: actions/dependency-review-action@v4.6.0 with: fail-on-severity: critical diff --git a/.github/workflows/deploy.yaml b/.github/workflows/deploy.yaml index 3de1e927..cae6519c 100644 --- a/.github/workflows/deploy.yaml +++ b/.github/workflows/deploy.yaml @@ -42,18 +42,18 @@ jobs: - name: Set Up Python id: set_up_python - uses: actions/setup-python@v5.4.0 + uses: actions/setup-python@v5.6.0 with: python-version: "3.10" - name: Restoring/Saving Cache - uses: actions/cache@v4.2.2 + uses: actions/cache@v4.2.3 with: path: "venv" key: py-v1-deps-${{ runner.os }}-${{ steps.set_up_python.outputs.python-version }}-${{ hashFiles('pyproject.toml', 'requirements.txt', 'requirements-dev.txt', 'Makefile', 'make/**.mk') }} - name: Restore Artifacts (Release) - uses: actions/download-artifact@v4.1.9 + uses: actions/download-artifact@v4.3.0 with: name: release path: ${{ inputs.artifacts_path }}/ diff --git a/.github/workflows/git-commit-lint.yaml b/.github/workflows/git-commit-lint.yaml index 59aee589..6e1c4d1b 100644 --- a/.github/workflows/git-commit-lint.yaml +++ b/.github/workflows/git-commit-lint.yaml @@ -8,6 +8,7 @@ on: - opened - reopened - synchronize + - ready_for_review permissions: contents: read diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 14f7cf16..7d38391f 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -39,7 +39,7 @@ jobs: - name: Set Up Python id: set_up_python - uses: actions/setup-python@v5.4.0 + uses: actions/setup-python@v5.6.0 with: python-version: "3.10" @@ -47,7 +47,7 @@ jobs: run: make python-virtualenv PYTHON_VIRTUALENV_DIR="venv" - name: Restoring/Saving Cache - uses: actions/cache@v4.2.2 + uses: actions/cache@v4.2.3 with: path: "venv" key: py-v1-deps-${{ runner.os }}-${{ steps.set_up_python.outputs.python-version }}-${{ hashFiles('pyproject.toml', 'requirements.txt', 'requirements-dev.txt', 'Makefile', 'make/**.mk') }} @@ -68,7 +68,7 @@ jobs: make dist - name: Store Artifacts - uses: actions/upload-artifact@v4.6.1 + uses: actions/upload-artifact@v4.6.2 with: name: release path: ${{ env.ARTIFACTS_PATH }}/ diff --git a/.github/workflows/task-release-and-deploy.yaml b/.github/workflows/task-release-and-deploy.yaml new file mode 100644 index 00000000..613481e7 --- /dev/null +++ b/.github/workflows/task-release-and-deploy.yaml @@ -0,0 +1,75 @@ +# GitHub Actions Workflow for 'Release and Deploy' Task + +name: "Task: Release and Deploy" + +on: + pull_request: + types: + - closed + branches: # Base reference + - develop + +permissions: {} + +jobs: + deploy: + name: Deploy + if: ${{ github.event.pull_request.merged == true && startsWith(github.head_ref, 'release/') }} + runs-on: ubuntu-22.04 + + permissions: + contents: write + pull-requests: write + + env: + CREATE_RELEASE_VCS_REVISION_ID: ${{ github.sha }} # Merge commit in base branch. + PREPARE_RELEASE_GITHUB_PULL_REQUEST_HTML_URL: ${{ github.event.pull_request.html_url }} + PREPARE_RELEASE_GITHUB_PULL_REQUEST_TITLE: ${{ github.event.pull_request.title }} + PREPARE_RELEASE_GITHUB_VCS_REF: ${{ github.event.pull_request.head.ref }} + RELEASE_ASSIGNEE: ${{ github.event.pull_request.assignee.login }} + RELEASE_VCS_REF: refs/heads/master + + steps: + - name: Check Out VCS Repository + uses: actions/checkout@v4.2.2 + with: + ref: ${{ env.CREATE_RELEASE_VCS_REVISION_ID }} + + - name: Prepare Git + run: | + echo 'Adding Git aliases…' + git config alias.publish \ + 'push --set-upstream origin HEAD' + + - name: Prepare Pull Request for Deployment + run: | + create_release_vcs_branch_name="${PREPARE_RELEASE_GITHUB_VCS_REF:?}" + create_release_vcs_branch_name="${create_release_vcs_branch_name/release/deploy}" + echo "Creating release creation VCS branch '$create_release_vcs_branch_name'…" + git checkout -b "${create_release_vcs_branch_name:?}" -- + git publish --verbose + + create_release_vcs_ref="refs/heads/${create_release_vcs_branch_name:?}" + echo "CREATE_RELEASE_VCS_REF=${create_release_vcs_ref:?}" >> "$GITHUB_ENV" + + create_release_github_pull_request_title="${PREPARE_RELEASE_GITHUB_PULL_REQUEST_TITLE:?}" + create_release_github_pull_request_title="deploy ${create_release_github_pull_request_title,,}" + create_release_github_pull_request_title="${create_release_github_pull_request_title@u}" + echo "CREATE_RELEASE_GITHUB_PULL_REQUEST_TITLE=${create_release_github_pull_request_title:?}" >> "$GITHUB_ENV" + + create_release_github_pull_request_description="Ref: ${PREPARE_RELEASE_GITHUB_PULL_REQUEST_HTML_URL:?}" + echo "CREATE_RELEASE_GITHUB_PULL_REQUEST_DESCRIPTION=${create_release_github_pull_request_description:?}" >> "$GITHUB_ENV" + + - name: Create GitHub Pull Request for Deployment + run: | + gh pr create \ + --base "$RELEASE_VCS_REF" \ + --head "$CREATE_RELEASE_VCS_REF" \ + --draft \ + --title "$CREATE_RELEASE_GITHUB_PULL_REQUEST_TITLE" \ + --body "$CREATE_RELEASE_GITHUB_PULL_REQUEST_DESCRIPTION" \ + --assignee "$RELEASE_ASSIGNEE" \ + --label 'task' \ + --label 'kind: deploy' + env: + GH_TOKEN: ${{ github.token }} diff --git a/HISTORY.md b/HISTORY.md index b4eb7b71..9c5d56eb 100644 --- a/HISTORY.md +++ b/HISTORY.md @@ -1,5 +1,23 @@ # History +## 0.46.0 (2025-05-22) + +- (PR #790, 2025-03-26) Add GitHub Actions workflow to release and deploy; Etc. +- (PR #792, 2025-04-02) deps: Bump the development-dependencies group with 5 updates +- (PR #794, 2025-04-02) chore(deps): Bump setuptools from 75.3.0 to 78.1.0 +- (PR #797, 2025-04-03) chore: Bump the production-dependencies group with 5 updates +- (PR #793, 2025-04-04) chore(deps): Bump djangorestframework from 3.15.2 to 3.16.0 +- (PR #795, 2025-04-07) chore(deps): Bump pytz from 2025.1 to 2025.2 +- (PR #796, 2025-04-07) chore(deps): Bump pydantic from 2.10.6 to 2.11.2 +- (PR #798, 2025-05-06) chore: Bump the production-dependencies group with 3 updates +- (PR #804, 2025-05-14) chore: Bump django from 4.2.20 to 4.2.21 +- (PR #805, 2025-05-19) chore: Bump setuptools from 78.1.0 to 78.1.1 +- (PR #802, 2025-05-19) chore(deps): Bump importlib-metadata from 8.6.1 to 8.7.0 +- (PR #799, 2025-05-22) chore(deps): Bump djangorestframework from 3.15.2 to 3.16.0 +- (PR #803, 2025-05-22) chore(deps): Bump lxml from 5.3.1 to 5.4.0 +- (PR #806, 2025-05-22) deps: Uninstall Python package `types-pyOpenSSL` +- (PR #801, 2025-05-22) chore(deps): Bump cryptography from 44.0.1 to 44.0.3 + ## 0.45.0 (2025-03-24) - (PR #784, 2025-03-13) chore(deps): Bump the development-dependencies group with 8 updates diff --git a/pyproject.toml b/pyproject.toml index a79bfbff..06a69e3e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -10,7 +10,7 @@ [build-system] requires = [ - "setuptools==75.3.0", + "setuptools==78.1.1", "wheel==0.45.1", ] build-backend = "setuptools.build_meta" @@ -51,7 +51,7 @@ dynamic = ["version"] [project.optional-dependencies] django = ["Django>=4.2"] django-filter = ["django-filter>=24.2"] -djangorestframework = ["djangorestframework>=3.10.3,<3.16"] +djangorestframework = ["djangorestframework>=3.10.3,<3.17"] pydantic = ["pydantic>=2.0"] [project.urls] diff --git a/requirements-dev.in b/requirements-dev.in index c1035d9c..fc44e173 100644 --- a/requirements-dev.in +++ b/requirements-dev.in @@ -7,15 +7,15 @@ black==25.1.0 build==1.2.2.post1 bumpversion==0.5.3 -coverage==7.6.12 -flake8==7.1.2 +coverage==7.8.0 +flake8==7.2.0 isort==6.0.1 mypy==1.15.0 pip-tools==7.4.1 -tox==4.24.2 +tox==4.25.0 twine==6.1.0 types-jsonschema==4.23.0.20241208 -types-lxml==2025.3.4 -types-pyOpenSSL==24.1.0.20240722 -types-pytz==2025.1.0.20250204 +types-lxml==2025.3.30 +types-pytz==2025.2.0.20250326 +types-setuptools==78.1.0.20250329 wheel==0.45.1 diff --git a/requirements-dev.txt b/requirements-dev.txt index f35a5a5f..6f976d9b 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -40,13 +40,12 @@ click==8.0.3 # pip-tools colorama==0.4.6 # via tox -coverage==7.6.12 +coverage==7.8.0 # via -r requirements-dev.in -cryptography==44.0.1 +cryptography==44.0.3 # via # -c requirements.txt # secretstorage - # types-pyopenssl cssselect==1.2.0 # via types-lxml distlib==0.3.7 @@ -57,13 +56,13 @@ filelock==3.16.1 # via # tox # virtualenv -flake8==7.1.2 +flake8==7.2.0 # via -r requirements-dev.in id==1.5.0 # via twine idna==3.7 # via requests -importlib-metadata==8.6.1 +importlib-metadata==8.7.0 # via # -c requirements.txt # build @@ -107,13 +106,13 @@ platformdirs==4.3.6 # virtualenv pluggy==1.5.0 # via tox -pycodestyle==2.12.0 +pycodestyle==2.13.0 # via flake8 pycparser==2.22 # via # -c requirements.txt # cffi -pyflakes==3.2.0 +pyflakes==3.3.2 # via flake8 pygments==2.15.0 # via @@ -161,24 +160,20 @@ tomli==2.2.1 # pyproject-api # pyproject-hooks # tox -tox==4.24.2 +tox==4.25.0 # via -r requirements-dev.in twine==6.1.0 # via -r requirements-dev.in -types-cffi==1.16.0.20240331 - # via types-pyopenssl types-html5lib==1.1.11.20241018 # via types-lxml types-jsonschema==4.23.0.20241208 # via -r requirements-dev.in -types-lxml==2025.3.4 +types-lxml==2025.3.30 # via -r requirements-dev.in -types-pyopenssl==24.1.0.20240722 +types-pytz==2025.2.0.20250326 # via -r requirements-dev.in -types-pytz==2025.1.0.20250204 +types-setuptools==78.1.0.20250329 # via -r requirements-dev.in -types-setuptools==75.3.0.20241112 - # via types-cffi typing-extensions==4.12.2 # via # -c requirements.txt @@ -207,5 +202,7 @@ zipp==3.20.2 # The following packages are considered to be unsafe in a requirements file: pip==24.2 # via pip-tools -setuptools==75.3.0 - # via pip-tools +setuptools==78.1.1 + # via + # pip-tools + # types-setuptools diff --git a/requirements.in b/requirements.in index a8c7e54c..b499c2b8 100644 --- a/requirements.in +++ b/requirements.in @@ -6,17 +6,17 @@ # git+https://github.com/example/example.git@example-vcs-ref#egg=example-pkg[foo,bar]==1.42.3 backports-zoneinfo==0.2.1 ; python_version < "3.9" # Used by `djangorestframework`. -cryptography==44.0.1 +cryptography==44.0.3 defusedxml==0.7.1 django-filter>=24.2 Django>=4.2 -djangorestframework>=3.10.3,<3.16 -importlib-metadata==8.6.1 +djangorestframework>=3.10.3,<3.17 +importlib-metadata==8.7.0 jsonschema==4.23.0 -lxml==5.3.1 +lxml==5.4.0 marshmallow==3.26.1 -pydantic==2.10.6 +pydantic==2.11.2 pyOpenSSL==25.0.0 -pytz==2025.1 +pytz==2025.2 signxml==4.0.3 typing-extensions==4.12.2 diff --git a/requirements.txt b/requirements.txt index 72df99c2..e40cf60e 100644 --- a/requirements.txt +++ b/requirements.txt @@ -16,29 +16,29 @@ certifi==2024.7.4 # via signxml cffi==1.16.0 # via cryptography -cryptography==44.0.1 +cryptography==44.0.3 # via # -r requirements.in # pyopenssl # signxml defusedxml==0.7.1 # via -r requirements.in -django==4.2.20 +django==4.2.21 # via # -r requirements.in # django-filter # djangorestframework django-filter==25.1 # via -r requirements.in -djangorestframework==3.15.2 +djangorestframework==3.16.0 # via -r requirements.in -importlib-metadata==8.6.1 +importlib-metadata==8.7.0 # via -r requirements.in jsonschema==4.23.0 # via -r requirements.in jsonschema-specifications==2023.12.1 # via jsonschema -lxml==5.3.1 +lxml==5.4.0 # via # -r requirements.in # signxml @@ -48,13 +48,13 @@ packaging==24.2 # via marshmallow pycparser==2.22 # via cffi -pydantic==2.10.6 +pydantic==2.11.2 # via -r requirements.in -pydantic-core==2.27.2 +pydantic-core==2.33.1 # via pydantic pyopenssl==25.0.0 # via -r requirements.in -pytz==2025.1 +pytz==2025.2 # via -r requirements.in referencing==0.35.1 # via @@ -75,5 +75,8 @@ typing-extensions==4.12.2 # pydantic # pydantic-core # pyopenssl + # typing-inspection +typing-inspection==0.4.0 + # via pydantic zipp==3.20.2 # via importlib-metadata diff --git a/src/cl_sii/__init__.py b/src/cl_sii/__init__.py index f87c773b..68fda69f 100644 --- a/src/cl_sii/__init__.py +++ b/src/cl_sii/__init__.py @@ -4,4 +4,4 @@ """ -__version__ = '0.45.0' +__version__ = '0.46.0' diff --git a/src/tests/test_libs_xml_utils.py b/src/tests/test_libs_xml_utils.py index e2aa359f..5c6fd295 100644 --- a/src/tests/test_libs_xml_utils.py +++ b/src/tests/test_libs_xml_utils.py @@ -60,7 +60,7 @@ def test_attack_billion_laughs_1(self) -> None: ( "XML syntax error." " Maximum entity amplification factor exceeded, see xmlCtxtSetMaxAmplification.," - " line 1, column 25.", + " line 1, column 7.", ), )