From 065bf0109a7341068d2ee9bd1ae4c2659e1ce2ab Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 1 Jan 2024 10:36:02 +0000 Subject: [PATCH 0001/1003] Bump types-requests from 2.31.0.10 to 2.31.0.20231231 Bumps [types-requests](https://github.com/python/typeshed) from 2.31.0.10 to 2.31.0.20231231. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 414629242..4ba1cf4df 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -248,7 +248,7 @@ dev = [ "Sphinx-Substitution-Extensions==2022.2.16", "sphinxcontrib-spelling==8", "sybil==6.0.2", - "types-requests==2.31.0.10", + "types-requests==2.31.0.20231231", "vulture==2.10", "VWS-Python-Mock==2023.5.21", "VWS-Test-Fixtures==2023.3.5", From d63fa115d77d397d7016738d549dc8cdf214a418 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 1 Jan 2024 10:36:10 +0000 Subject: [PATCH 0002/1003] Bump pyright from 1.1.343 to 1.1.344 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.343 to 1.1.344. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.343...v1.1.344) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 414629242..fe65bcc6e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -236,7 +236,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.0.3", "pyproject-fmt==1.5.3", - "pyright==1.1.343", + "pyright==1.1.344", "pyroma==4.2", "pytest==7.4.3", "pytest-cov==4.1", From 53fd23b1a7f7c5bca4bed5c71c4ef0b4ccdd18ae Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 1 Jan 2024 10:36:22 +0000 Subject: [PATCH 0003/1003] Bump pytest from 7.4.3 to 7.4.4 Bumps [pytest](https://github.com/pytest-dev/pytest) from 7.4.3 to 7.4.4. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/7.4.3...7.4.4) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 414629242..de2ba17d9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -238,7 +238,7 @@ dev = [ "pyproject-fmt==1.5.3", "pyright==1.1.343", "pyroma==4.2", - "pytest==7.4.3", + "pytest==7.4.4", "pytest-cov==4.1", "PyYAML==6.0.1", "ruff==0.1.9", From 3e572471450e584eca55d57ffb839bb871636efa Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 2 Jan 2024 10:15:06 +0000 Subject: [PATCH 0004/1003] Bump pdm from 2.11.1 to 2.11.2 Bumps [pdm](https://github.com/pdm-project/pdm) from 2.11.1 to 2.11.2. - [Release notes](https://github.com/pdm-project/pdm/releases) - [Changelog](https://github.com/pdm-project/pdm/blob/main/CHANGELOG.md) - [Commits](https://github.com/pdm-project/pdm/compare/2.11.1...2.11.2) --- updated-dependencies: - dependency-name: pdm dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b1f8d8728..ae18a0e67 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -229,7 +229,7 @@ dev = [ "freezegun==1.4.0", "furo==2023.9.10", "mypy==1.8.0", - "pdm==2.11.1", + "pdm==2.11.2", "pip_check_reqs==2.5.3", "pydocstyle==6.3", "pyenchant==3.2.2", From c2c1ac24e0efa869f06c9c2b689fe3d27b65610c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 3 Jan 2024 10:19:43 +0000 Subject: [PATCH 0005/1003] Bump ruff from 0.1.9 to 0.1.11 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.1.9 to 0.1.11. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.1.9...v0.1.11) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ae18a0e67..cc99817a0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -241,7 +241,7 @@ dev = [ "pytest==7.4.4", "pytest-cov==4.1", "PyYAML==6.0.1", - "ruff==0.1.9", + "ruff==0.1.11", "Sphinx==7.2.6", "sphinx-autodoc-typehints==1.25.2", "sphinx-prompt==1.8", From 02212938c0db6494510231e553034aa964c47325 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Jan 2024 10:05:53 +0000 Subject: [PATCH 0006/1003] Bump types-requests from 2.31.0.20231231 to 2.31.0.20240106 Bumps [types-requests](https://github.com/python/typeshed) from 2.31.0.20231231 to 2.31.0.20240106. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index cc99817a0..e377b7896 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -248,7 +248,7 @@ dev = [ "Sphinx-Substitution-Extensions==2022.2.16", "sphinxcontrib-spelling==8", "sybil==6.0.2", - "types-requests==2.31.0.20231231", + "types-requests==2.31.0.20240106", "vulture==2.10", "VWS-Python-Mock==2023.5.21", "VWS-Test-Fixtures==2023.3.5", From 844d3d5466c1b1d13521ea4781427c7e898d47b5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 9 Jan 2024 10:24:09 +0000 Subject: [PATCH 0007/1003] Bump pyright from 1.1.344 to 1.1.345 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.344 to 1.1.345. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.344...v1.1.345) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index cc99817a0..4b70fd7fa 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -236,7 +236,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.0.3", "pyproject-fmt==1.5.3", - "pyright==1.1.344", + "pyright==1.1.345", "pyroma==4.2", "pytest==7.4.4", "pytest-cov==4.1", From fe59267ac05057275d4786fe5313bc16ceae8da9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 11 Jan 2024 10:52:46 +0000 Subject: [PATCH 0008/1003] Bump pyproject-fmt from 1.5.3 to 1.6.0 Bumps [pyproject-fmt](https://github.com/tox-dev/pyproject-fmt) from 1.5.3 to 1.6.0. - [Release notes](https://github.com/tox-dev/pyproject-fmt/releases) - [Commits](https://github.com/tox-dev/pyproject-fmt/compare/1.5.3...1.6.0) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 99ac7348c..4a382313d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -235,7 +235,7 @@ dev = [ "pyenchant==3.2.2", "Pygments==2.17.2", "pylint==3.0.3", - "pyproject-fmt==1.5.3", + "pyproject-fmt==1.6.0", "pyright==1.1.345", "pyroma==4.2", "pytest==7.4.4", From 4294744b287a96dd396340af1e5ecf9563e793e8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 12 Jan 2024 10:32:50 +0000 Subject: [PATCH 0009/1003] Bump ruff from 0.1.11 to 0.1.12 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.1.11 to 0.1.12. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.1.11...v0.1.12) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4a382313d..07e8c886a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -241,7 +241,7 @@ dev = [ "pytest==7.4.4", "pytest-cov==4.1", "PyYAML==6.0.1", - "ruff==0.1.11", + "ruff==0.1.12", "Sphinx==7.2.6", "sphinx-autodoc-typehints==1.25.2", "sphinx-prompt==1.8", From 2236300e50da9e3b934c6f4f20b23bc6c56dada7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 15 Jan 2024 11:00:51 +0000 Subject: [PATCH 0010/1003] Bump pyright from 1.1.345 to 1.1.346 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.345 to 1.1.346. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.345...v1.1.346) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 07e8c886a..28b184926 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -236,7 +236,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.0.3", "pyproject-fmt==1.6.0", - "pyright==1.1.345", + "pyright==1.1.346", "pyroma==4.2", "pytest==7.4.4", "pytest-cov==4.1", From e3b9b19f26d5775fbee4e2a64e6e4346bcf43a64 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 15 Jan 2024 11:01:30 +0000 Subject: [PATCH 0011/1003] Bump ruff from 0.1.12 to 0.1.13 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.1.12 to 0.1.13. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.1.12...v0.1.13) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 07e8c886a..ef9d6d9e1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -241,7 +241,7 @@ dev = [ "pytest==7.4.4", "pytest-cov==4.1", "PyYAML==6.0.1", - "ruff==0.1.12", + "ruff==0.1.13", "Sphinx==7.2.6", "sphinx-autodoc-typehints==1.25.2", "sphinx-prompt==1.8", From b76d5e7a2889feb6982c799595e6be9615c83d1f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 16 Jan 2024 10:30:24 +0000 Subject: [PATCH 0012/1003] Bump pyright from 1.1.346 to 1.1.347 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.346 to 1.1.347. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.346...v1.1.347) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2e2ff73b0..40f5854e9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -236,7 +236,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.0.3", "pyproject-fmt==1.6.0", - "pyright==1.1.346", + "pyright==1.1.347", "pyroma==4.2", "pytest==7.4.4", "pytest-cov==4.1", From 2a97e6195cca682053583e3c76d02ed08cf612d7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 17 Jan 2024 10:23:57 +0000 Subject: [PATCH 0013/1003] Bump pdm from 2.11.2 to 2.12.1 Bumps [pdm](https://github.com/pdm-project/pdm) from 2.11.2 to 2.12.1. - [Release notes](https://github.com/pdm-project/pdm/releases) - [Changelog](https://github.com/pdm-project/pdm/blob/main/CHANGELOG.md) - [Commits](https://github.com/pdm-project/pdm/compare/2.11.2...2.12.1) --- updated-dependencies: - dependency-name: pdm dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 40f5854e9..1c960d30b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -229,7 +229,7 @@ dev = [ "freezegun==1.4.0", "furo==2023.9.10", "mypy==1.8.0", - "pdm==2.11.2", + "pdm==2.12.1", "pip_check_reqs==2.5.3", "pydocstyle==6.3", "pyenchant==3.2.2", From 57c0bec1806a10b6475d4c29e3339a17b6b0e68a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 18 Jan 2024 11:00:01 +0000 Subject: [PATCH 0014/1003] Bump actions/cache from 3 to 4 Bumps [actions/cache](https://github.com/actions/cache) from 3 to 4. - [Release notes](https://github.com/actions/cache/releases) - [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md) - [Commits](https://github.com/actions/cache/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/cache dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- .github/workflows/windows-ci.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 22c5f7d90..915b97b26 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,7 +29,7 @@ jobs: with: python-version: ${{ matrix.python-version }} - - uses: actions/cache@v3 + - uses: actions/cache@v4 with: path: ~/.cache/pip key: ${{ runner.os }}-pip-${{ hashFiles('pyproject.toml') }} diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index c13708757..ade6b5e71 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -29,7 +29,7 @@ jobs: with: python-version: ${{ matrix.python-version }} - - uses: actions/cache@v3 + - uses: actions/cache@v4 with: path: ~\AppData\Local\pip\Cache key: ${{ runner.os }}-pip-${{ hashFiles('pyproject.toml') }} From b0694f07bdb2783b0414e149e5bc0d493eeca82e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 21 Jan 2024 11:48:12 +0000 Subject: [PATCH 0015/1003] Bump vws-python-mock from 2023.5.21 to 2024.1.21 Bumps [vws-python-mock](https://github.com/VWS-Python/vws-python-mock) from 2023.5.21 to 2024.1.21. - [Release notes](https://github.com/VWS-Python/vws-python-mock/releases) - [Changelog](https://github.com/VWS-Python/vws-python-mock/blob/main/CHANGELOG.rst) - [Commits](https://github.com/VWS-Python/vws-python-mock/compare/2023.05.21...2024.01.21) --- updated-dependencies: - dependency-name: vws-python-mock dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1c960d30b..ad134ba09 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -250,7 +250,7 @@ dev = [ "sybil==6.0.2", "types-requests==2.31.0.20240106", "vulture==2.10", - "VWS-Python-Mock==2023.5.21", + "VWS-Python-Mock==2024.1.21", "VWS-Test-Fixtures==2023.3.5", ] [project.urls] From ef1163e19b7453ddc8bdf7a17da1878b16b11983 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 21 Jan 2024 11:57:15 +0000 Subject: [PATCH 0016/1003] Bump pdm from 2.12.1 to 2.12.2 Bumps [pdm](https://github.com/pdm-project/pdm) from 2.12.1 to 2.12.2. - [Release notes](https://github.com/pdm-project/pdm/releases) - [Changelog](https://github.com/pdm-project/pdm/blob/main/CHANGELOG.md) - [Commits](https://github.com/pdm-project/pdm/compare/2.12.1...2.12.2) --- updated-dependencies: - dependency-name: pdm dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ad134ba09..69a1f167a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -229,7 +229,7 @@ dev = [ "freezegun==1.4.0", "furo==2023.9.10", "mypy==1.8.0", - "pdm==2.12.1", + "pdm==2.12.2", "pip_check_reqs==2.5.3", "pydocstyle==6.3", "pyenchant==3.2.2", From 4caecf739d6046f070d52845b75afa85f98f9d91 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 21 Jan 2024 11:57:20 +0000 Subject: [PATCH 0017/1003] Bump vulture from 2.10 to 2.11 Bumps [vulture](https://github.com/jendrikseipp/vulture) from 2.10 to 2.11. - [Release notes](https://github.com/jendrikseipp/vulture/releases) - [Changelog](https://github.com/jendrikseipp/vulture/blob/main/CHANGELOG.md) - [Commits](https://github.com/jendrikseipp/vulture/compare/v2.10...v2.11) --- updated-dependencies: - dependency-name: vulture dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ad134ba09..4263e2d02 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -249,7 +249,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.2", "types-requests==2.31.0.20240106", - "vulture==2.10", + "vulture==2.11", "VWS-Python-Mock==2024.1.21", "VWS-Test-Fixtures==2023.3.5", ] From 2daa6b34d87a74dbd28ebef23d6cdea253fb99c7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 21 Jan 2024 11:57:26 +0000 Subject: [PATCH 0018/1003] Bump ruff from 0.1.13 to 0.1.14 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.1.13 to 0.1.14. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.1.13...v0.1.14) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ad134ba09..f1f410ef4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -241,7 +241,7 @@ dev = [ "pytest==7.4.4", "pytest-cov==4.1", "PyYAML==6.0.1", - "ruff==0.1.13", + "ruff==0.1.14", "Sphinx==7.2.6", "sphinx-autodoc-typehints==1.25.2", "sphinx-prompt==1.8", From 61bc75eed090e991242498cc8527e7a3436f8e57 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 22 Jan 2024 10:10:32 +0000 Subject: [PATCH 0019/1003] Bump pyright from 1.1.347 to 1.1.348 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.347 to 1.1.348. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.347...v1.1.348) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2cc23c18c..ae088d71b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -236,7 +236,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.0.3", "pyproject-fmt==1.6.0", - "pyright==1.1.347", + "pyright==1.1.348", "pyroma==4.2", "pytest==7.4.4", "pytest-cov==4.1", From eccc2007a3a8c9925326d6eea30f69068101ba51 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 23 Jan 2024 09:36:00 +0000 Subject: [PATCH 0020/1003] Use pyproject.toml configuration for pyproject-fmt --- .vscode/settings.json | 2 +- lint.mk | 4 +- pyproject.toml | 96 ++++++++++++++++++++++--------------------- 3 files changed, 53 insertions(+), 49 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index a05041473..9f41e3120 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,7 +1,7 @@ { "[python]": { "editor.codeActionsOnSave": { - "source.fixAll": true + "source.fixAll": "explicit" }, "editor.defaultFormatter": "charliermarsh.ruff", "editor.formatOnSave": true diff --git a/lint.mk b/lint.mk index f0e82e1cc..61cc97d84 100644 --- a/lint.mk +++ b/lint.mk @@ -54,11 +54,11 @@ linkcheck: .PHONY: pyproject-fmt pyproject-fmt: - pyproject-fmt --keep-full-version --check --indent=4 pyproject.toml + pyproject-fmt --check pyproject.toml .PHONY: fix-pyproject-fmt fix-pyproject-fmt: - pyproject-fmt --keep-full-version --indent=4 pyproject.toml + pyproject-fmt pyproject.toml .PHONY: spelling spelling: diff --git a/pyproject.toml b/pyproject.toml index ae088d71b..c63ed67b8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -140,10 +140,10 @@ strict = true [build-system] build-backend = "setuptools.build_meta" requires = [ - "pip", - "setuptools", - "setuptools_scm[toml]>=7.1", - "wheel", + "pip", + "setuptools", + "setuptools_scm[toml]>=7.1", + "wheel", ] [tool.distutils.bdist_wheel] @@ -198,60 +198,60 @@ name = "vws-python" description = "Interact with the Vuforia Web Services (VWS) API." readme = { file = "README.rst", content-type = "text/x-rst"} keywords = [ - "client", - "vuforia", - "vws", + "client", + "vuforia", + "vws", ] license = { file = "LICENSE" } authors = [ { name = "Adam Dangoor", email = "adamdangoor@gmail.com"} ] requires-python = ">=3.12" classifiers = [ - "Development Status :: 5 - Production/Stable", - "Environment :: Web Environment", - "License :: OSI Approved :: MIT License", - "Operating System :: POSIX", - "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3.12", + "Development Status :: 5 - Production/Stable", + "Environment :: Web Environment", + "License :: OSI Approved :: MIT License", + "Operating System :: POSIX", + "Programming Language :: Python :: 3 :: Only", + "Programming Language :: Python :: 3.12", ] dynamic = [ - "version", + "version", ] dependencies = [ - "requests", - "urllib3", - "VWS-Auth-Tools", + "requests", + "urllib3", + "VWS-Auth-Tools", ] [project.optional-dependencies] dev = [ - "check-manifest==0.49", - "doc8==1.1.1", - "dodgy==0.2.1", - "freezegun==1.4.0", - "furo==2023.9.10", - "mypy==1.8.0", - "pdm==2.12.2", - "pip_check_reqs==2.5.3", - "pydocstyle==6.3", - "pyenchant==3.2.2", - "Pygments==2.17.2", - "pylint==3.0.3", - "pyproject-fmt==1.6.0", - "pyright==1.1.348", - "pyroma==4.2", - "pytest==7.4.4", - "pytest-cov==4.1", - "PyYAML==6.0.1", - "ruff==0.1.14", - "Sphinx==7.2.6", - "sphinx-autodoc-typehints==1.25.2", - "sphinx-prompt==1.8", - "Sphinx-Substitution-Extensions==2022.2.16", - "sphinxcontrib-spelling==8", - "sybil==6.0.2", - "types-requests==2.31.0.20240106", - "vulture==2.11", - "VWS-Python-Mock==2024.1.21", - "VWS-Test-Fixtures==2023.3.5", + "check-manifest==0.49", + "doc8==1.1.1", + "dodgy==0.2.1", + "freezegun==1.4", + "furo==2023.9.10", + "mypy==1.8", + "pdm==2.12.2", + "pip_check_reqs==2.5.3", + "pydocstyle==6.3", + "pyenchant==3.2.2", + "Pygments==2.17.2", + "pylint==3.0.3", + "pyproject-fmt==1.7", + "pyright==1.1.348", + "pyroma==4.2", + "pytest==7.4.4", + "pytest-cov==4.1", + "PyYAML==6.0.1", + "ruff==0.1.14", + "Sphinx==7.2.6", + "sphinx-autodoc-typehints==1.25.2", + "sphinx-prompt==1.8", + "Sphinx-Substitution-Extensions==2022.2.16", + "sphinxcontrib-spelling==8", + "sybil==6.0.2", + "types-requests==2.31.0.20240106", + "vulture==2.11", + "VWS-Python-Mock==2024.1.21", + "VWS-Test-Fixtures==2023.3.5", ] [project.urls] Documentation = "https://vws-python.readthedocs.io/en/latest/" @@ -268,6 +268,10 @@ vws = ["py.typed"] [tool.setuptools_scm] +[tool.pyproject-fmt] +indent = 4 +keep_full_version = false + [tool.pyright] typeCheckingMode = "strict" From 312fa760ed399a00254beda6e18e59a1387e0494 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 23 Jan 2024 09:37:39 +0000 Subject: [PATCH 0021/1003] Fix double spacing --- Makefile | 2 +- lint.mk | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 320a0bec8..839f037dc 100644 --- a/Makefile +++ b/Makefile @@ -14,7 +14,7 @@ lint: \ ruff \ pip-extra-reqs \ pip-missing-reqs \ - pyproject-fmt \ + pyproject-fmt \ pyright \ pyroma \ spelling \ diff --git a/lint.mk b/lint.mk index 61cc97d84..f837b0069 100644 --- a/lint.mk +++ b/lint.mk @@ -54,11 +54,11 @@ linkcheck: .PHONY: pyproject-fmt pyproject-fmt: - pyproject-fmt --check pyproject.toml + pyproject-fmt --check pyproject.toml .PHONY: fix-pyproject-fmt fix-pyproject-fmt: - pyproject-fmt pyproject.toml + pyproject-fmt pyproject.toml .PHONY: spelling spelling: From e33a4d0f13384836b9540665452cef37223d2975 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 23 Jan 2024 09:40:14 +0000 Subject: [PATCH 0022/1003] Fix double spacing --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 839f037dc..320a0bec8 100644 --- a/Makefile +++ b/Makefile @@ -14,7 +14,7 @@ lint: \ ruff \ pip-extra-reqs \ pip-missing-reqs \ - pyproject-fmt \ + pyproject-fmt \ pyright \ pyroma \ spelling \ From 07f56b26f12d8a3c5c3872b0fb5cc10e51eae823 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 23 Jan 2024 09:42:24 +0000 Subject: [PATCH 0023/1003] Use original version --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c63ed67b8..4f9a2ef9c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -270,7 +270,7 @@ vws = ["py.typed"] [tool.pyproject-fmt] indent = 4 -keep_full_version = false +keep_full_version = true [tool.pyright] From 9ddd70864e112cea6290c12352e9e0529304a712 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 23 Jan 2024 10:10:45 +0000 Subject: [PATCH 0024/1003] Bump version of pyproject-fmt --- pyproject.toml | 92 +++++++++++++++++++++++++------------------------- 1 file changed, 46 insertions(+), 46 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 4f9a2ef9c..4bbe56bb1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -140,10 +140,10 @@ strict = true [build-system] build-backend = "setuptools.build_meta" requires = [ - "pip", - "setuptools", - "setuptools_scm[toml]>=7.1", - "wheel", + "pip", + "setuptools", + "setuptools_scm[toml]>=7.1", + "wheel", ] [tool.distutils.bdist_wheel] @@ -198,60 +198,60 @@ name = "vws-python" description = "Interact with the Vuforia Web Services (VWS) API." readme = { file = "README.rst", content-type = "text/x-rst"} keywords = [ - "client", - "vuforia", - "vws", + "client", + "vuforia", + "vws", ] license = { file = "LICENSE" } authors = [ { name = "Adam Dangoor", email = "adamdangoor@gmail.com"} ] requires-python = ">=3.12" classifiers = [ - "Development Status :: 5 - Production/Stable", - "Environment :: Web Environment", - "License :: OSI Approved :: MIT License", - "Operating System :: POSIX", - "Programming Language :: Python :: 3 :: Only", - "Programming Language :: Python :: 3.12", + "Development Status :: 5 - Production/Stable", + "Environment :: Web Environment", + "License :: OSI Approved :: MIT License", + "Operating System :: POSIX", + "Programming Language :: Python :: 3 :: Only", + "Programming Language :: Python :: 3.12", ] dynamic = [ - "version", + "version", ] dependencies = [ - "requests", - "urllib3", - "VWS-Auth-Tools", + "requests", + "urllib3", + "VWS-Auth-Tools", ] [project.optional-dependencies] dev = [ - "check-manifest==0.49", - "doc8==1.1.1", - "dodgy==0.2.1", - "freezegun==1.4", - "furo==2023.9.10", - "mypy==1.8", - "pdm==2.12.2", - "pip_check_reqs==2.5.3", - "pydocstyle==6.3", - "pyenchant==3.2.2", - "Pygments==2.17.2", - "pylint==3.0.3", - "pyproject-fmt==1.7", - "pyright==1.1.348", - "pyroma==4.2", - "pytest==7.4.4", - "pytest-cov==4.1", - "PyYAML==6.0.1", - "ruff==0.1.14", - "Sphinx==7.2.6", - "sphinx-autodoc-typehints==1.25.2", - "sphinx-prompt==1.8", - "Sphinx-Substitution-Extensions==2022.2.16", - "sphinxcontrib-spelling==8", - "sybil==6.0.2", - "types-requests==2.31.0.20240106", - "vulture==2.11", - "VWS-Python-Mock==2024.1.21", - "VWS-Test-Fixtures==2023.3.5", + "check-manifest==0.49", + "doc8==1.1.1", + "dodgy==0.2.1", + "freezegun==1.4.0", + "furo==2023.9.10", + "mypy==1.8.0", + "pdm==2.12.2", + "pip_check_reqs==2.5.3", + "pydocstyle==6.3", + "pyenchant==3.2.2", + "Pygments==2.17.2", + "pylint==3.0.3", + "pyproject-fmt==1.7.0", + "pyright==1.1.348", + "pyroma==4.2", + "pytest==7.4.4", + "pytest-cov==4.1", + "PyYAML==6.0.1", + "ruff==0.1.14", + "Sphinx==7.2.6", + "sphinx-autodoc-typehints==1.25.2", + "sphinx-prompt==1.8", + "Sphinx-Substitution-Extensions==2022.2.16", + "sphinxcontrib-spelling==8", + "sybil==6.0.2", + "types-requests==2.31.0.20240106", + "vulture==2.11", + "VWS-Python-Mock==2024.1.21", + "VWS-Test-Fixtures==2023.3.5", ] [project.urls] Documentation = "https://vws-python.readthedocs.io/en/latest/" From 4b450b584493e4f4bfaafd0604cbac4cbd42058a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 23 Jan 2024 11:08:55 +0000 Subject: [PATCH 0025/1003] Remove unnecessary pyright ignores --- conftest.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/conftest.py b/conftest.py index 9d744c035..881a76db2 100644 --- a/conftest.py +++ b/conftest.py @@ -2,14 +2,14 @@ from doctest import ELLIPSIS -from sybil import Sybil # pyright: ignore[reportMissingTypeStubs] -from sybil.parsers.rest import ( # pyright: ignore[reportMissingTypeStubs] +from sybil import Sybil +from sybil.parsers.rest import ( ClearNamespaceParser, DocTestParser, PythonCodeBlockParser, ) -pytest_collect_file = Sybil( # pyright: ignore[reportUnknownVariableType] +pytest_collect_file = Sybil( parsers=[ ClearNamespaceParser(), DocTestParser(optionflags=ELLIPSIS), From 03ad402014847e6af6bb892ab5e71deadbd6f57e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 23 Jan 2024 22:01:56 +0000 Subject: [PATCH 0026/1003] Report an error on unnecessary pyright ignores --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index 4bbe56bb1..85b076d81 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -274,4 +274,5 @@ keep_full_version = true [tool.pyright] +reportUnnecessaryTypeIgnoreComment = true typeCheckingMode = "strict" From dcad4fb8f4f074ce69e74d7450586b74d05a3cfe Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 25 Jan 2024 10:48:59 +0000 Subject: [PATCH 0027/1003] Bump types-requests from 2.31.0.20240106 to 2.31.0.20240125 Bumps [types-requests](https://github.com/python/typeshed) from 2.31.0.20240106 to 2.31.0.20240125. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 85b076d81..2707b868f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -248,7 +248,7 @@ dev = [ "Sphinx-Substitution-Extensions==2022.2.16", "sphinxcontrib-spelling==8", "sybil==6.0.2", - "types-requests==2.31.0.20240106", + "types-requests==2.31.0.20240125", "vulture==2.11", "VWS-Python-Mock==2024.1.21", "VWS-Test-Fixtures==2023.3.5", From 2b7c5b4cee050846529d64090ad570ae749aeb6c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 29 Jan 2024 10:42:56 +0000 Subject: [PATCH 0028/1003] Bump pyright from 1.1.348 to 1.1.349 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.348 to 1.1.349. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.348...v1.1.349) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2707b868f..05b98cac1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -236,7 +236,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.0.3", "pyproject-fmt==1.7.0", - "pyright==1.1.348", + "pyright==1.1.349", "pyroma==4.2", "pytest==7.4.4", "pytest-cov==4.1", From a5dcf5a4b1ce8ceb613887ee2752a8dc971cd019 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 29 Jan 2024 10:43:04 +0000 Subject: [PATCH 0029/1003] Bump sphinx-autodoc-typehints from 1.25.2 to 1.25.3 Bumps [sphinx-autodoc-typehints](https://github.com/tox-dev/sphinx-autodoc-typehints) from 1.25.2 to 1.25.3. - [Release notes](https://github.com/tox-dev/sphinx-autodoc-typehints/releases) - [Changelog](https://github.com/tox-dev/sphinx-autodoc-typehints/blob/main/CHANGELOG.md) - [Commits](https://github.com/tox-dev/sphinx-autodoc-typehints/compare/1.25.2...1.25.3) --- updated-dependencies: - dependency-name: sphinx-autodoc-typehints dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2707b868f..f4a643f73 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -243,7 +243,7 @@ dev = [ "PyYAML==6.0.1", "ruff==0.1.14", "Sphinx==7.2.6", - "sphinx-autodoc-typehints==1.25.2", + "sphinx-autodoc-typehints==1.25.3", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2022.2.16", "sphinxcontrib-spelling==8", From ea4ee71fd13a71287f75eeb23c08cb85d51669f5 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 29 Jan 2024 16:40:52 +0000 Subject: [PATCH 0030/1003] Remove unnecessary items from MANIFEST --- MANIFEST.in | 2 -- 1 file changed, 2 deletions(-) delete mode 100644 MANIFEST.in diff --git a/MANIFEST.in b/MANIFEST.in deleted file mode 100644 index 15fe1e8bb..000000000 --- a/MANIFEST.in +++ /dev/null @@ -1,2 +0,0 @@ -include src/vws/py.typed -include pyproject.toml From d8a2f8759f6dc3a909f7cb05bd9a1f4939527ab4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 30 Jan 2024 10:34:30 +0000 Subject: [PATCH 0031/1003] Bump furo from 2023.9.10 to 2024.1.29 Bumps [furo](https://github.com/pradyunsg/furo) from 2023.9.10 to 2024.1.29. - [Release notes](https://github.com/pradyunsg/furo/releases) - [Changelog](https://github.com/pradyunsg/furo/blob/main/docs/changelog.md) - [Commits](https://github.com/pradyunsg/furo/compare/2023.09.10...2024.01.29) --- updated-dependencies: - dependency-name: furo dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0236bc651..3050e02b3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -227,7 +227,7 @@ dev = [ "doc8==1.1.1", "dodgy==0.2.1", "freezegun==1.4.0", - "furo==2023.9.10", + "furo==2024.1.29", "mypy==1.8.0", "pdm==2.12.2", "pip_check_reqs==2.5.3", From ef07615f4c79c53100dc0e701e4c36525f5c6b35 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 30 Jan 2024 10:34:47 +0000 Subject: [PATCH 0032/1003] Bump ruff from 0.1.14 to 0.1.15 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.1.14 to 0.1.15. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.1.14...v0.1.15) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0236bc651..64c9510af 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -241,7 +241,7 @@ dev = [ "pytest==7.4.4", "pytest-cov==4.1", "PyYAML==6.0.1", - "ruff==0.1.14", + "ruff==0.1.15", "Sphinx==7.2.6", "sphinx-autodoc-typehints==1.25.3", "sphinx-prompt==1.8", From 96e188a336f3f30692a895e8e56e6f909e69c4c9 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 30 Jan 2024 11:32:08 +0000 Subject: [PATCH 0033/1003] Ignore D413 ruff rule --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index 64c9510af..21eacc736 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -170,6 +170,7 @@ ignore = [ # docstrings. "D406", "D407", + "D413", # We have an existing interface to support and so we do not want to change # exception names. "N818", From bd18c492305755d475c091348ad462fe0f40cda0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 31 Jan 2024 10:20:57 +0000 Subject: [PATCH 0034/1003] Bump sybil from 6.0.2 to 6.0.3 Bumps [sybil](https://github.com/simplistix/sybil) from 6.0.2 to 6.0.3. - [Changelog](https://github.com/simplistix/sybil/blob/master/CHANGELOG.rst) - [Commits](https://github.com/simplistix/sybil/compare/6.0.2...6.0.3) --- updated-dependencies: - dependency-name: sybil dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 92e4081c1..e79bae21d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -248,7 +248,7 @@ dev = [ "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2022.2.16", "sphinxcontrib-spelling==8", - "sybil==6.0.2", + "sybil==6.0.3", "types-requests==2.31.0.20240125", "vulture==2.11", "VWS-Python-Mock==2024.1.21", From 3a1f0e31fc6e680a48da3169f3c90b56df1d4c8d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 31 Jan 2024 10:56:20 +0000 Subject: [PATCH 0035/1003] Bump pytest from 7.4.4 to 8.0.0 Bumps [pytest](https://github.com/pytest-dev/pytest) from 7.4.4 to 8.0.0. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/7.4.4...8.0.0) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e79bae21d..b1461e8e3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -239,7 +239,7 @@ dev = [ "pyproject-fmt==1.7.0", "pyright==1.1.349", "pyroma==4.2", - "pytest==7.4.4", + "pytest==8.0.0", "pytest-cov==4.1", "PyYAML==6.0.1", "ruff==0.1.15", From 7a878581848477ce4d28bc88996cca1967ee293c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 31 Jan 2024 17:54:31 +0000 Subject: [PATCH 0036/1003] Use PyPI trusted publisher rather than API token --- .github/workflows/release.yml | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 8974001cd..3f8b0002a 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -9,6 +9,17 @@ jobs: name: Publish a release runs-on: ubuntu-latest + # Specifying an environment is strongly recommended by PyPI. + # See https://github.com/pypa/gh-action-pypi-publish/tree/release/v1/?tab=readme-ov-file#trusted-publishing. + environment: release + + permissions: + # This is needed for PyPI publishing. + # See https://github.com/pypa/gh-action-pypi-publish/tree/release/v1/?tab=readme-ov-file#trusted-publishing. + id-token: write + # This is needed for https://github.com/stefanzweifel/git-auto-commit-action. + contents: write + strategy: matrix: python-version: ["3.12"] @@ -69,8 +80,9 @@ jobs: python -m pip install build python -m build --sdist --wheel --outdir dist/ . + # We use PyPI trusted publishing rather than a PyPI API token. + # See https://github.com/pypa/gh-action-pypi-publish/tree/release/v1/?tab=readme-ov-file#trusted-publishing. - name: Publish distribution 📦 to PyPI uses: pypa/gh-action-pypi-publish@release/v1 with: - password: ${{ secrets.PYPI_API_TOKEN }} verbose: true From 51a1a30b6dad5cab945d92d7a0fccd0ae86786ef Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 31 Jan 2024 18:28:23 +0000 Subject: [PATCH 0037/1003] Lint GitHub Actions workflows using actionlint --- .github/workflows/release.yml | 2 +- Makefile | 1 + lint.mk | 4 ++++ pyproject.toml | 1 + 4 files changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3f8b0002a..f5e9d9793 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -76,7 +76,7 @@ jobs: run: | # Checkout the latest tag - the one we just created. git fetch --tags - git checkout $(git describe --tags $(git rev-list --tags --max-count=1)) + git checkout "$(git describe --tags "$(git rev-list --tags --max-count=1)")" python -m pip install build python -m build --sdist --wheel --outdir dist/ . diff --git a/Makefile b/Makefile index 320a0bec8..1530f4eb7 100644 --- a/Makefile +++ b/Makefile @@ -7,6 +7,7 @@ SPHINXOPTS := -W .PHONY: lint lint: \ + actionlint \ check-manifest \ doc8 \ linkcheck \ diff --git a/lint.mk b/lint.mk index f837b0069..3127f8a84 100644 --- a/lint.mk +++ b/lint.mk @@ -2,6 +2,10 @@ SHELL := /bin/bash -euxo pipefail +.PHONY: actionlint +actionlint: + actionlint + .PHONY: mypy mypy: mypy . diff --git a/pyproject.toml b/pyproject.toml index b1461e8e3..8070eb8ec 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -224,6 +224,7 @@ dependencies = [ ] [project.optional-dependencies] dev = [ + "actionlint-py==1.6.26.11", "check-manifest==0.49", "doc8==1.1.1", "dodgy==0.2.1", From be43c414f130314ff643f0aaf82d6884a6842e6a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 1 Feb 2024 10:25:04 +0000 Subject: [PATCH 0038/1003] Bump codecov/codecov-action from 3 to 4 Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 3 to 4. - [Release notes](https://github.com/codecov/codecov-action/releases) - [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md) - [Commits](https://github.com/codecov/codecov-action/compare/v3...v4) --- updated-dependencies: - dependency-name: codecov/codecov-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 915b97b26..50ffc9c15 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -55,4 +55,4 @@ jobs: pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml - name: "Upload coverage to Codecov" - uses: "codecov/codecov-action@v3" + uses: "codecov/codecov-action@v4" From 4da40a507b44826b12c0ad009a28357985b4b3fe Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 1 Feb 2024 10:45:43 +0000 Subject: [PATCH 0039/1003] Bump pdm from 2.12.2 to 2.12.3 Bumps [pdm](https://github.com/pdm-project/pdm) from 2.12.2 to 2.12.3. - [Release notes](https://github.com/pdm-project/pdm/releases) - [Changelog](https://github.com/pdm-project/pdm/blob/main/CHANGELOG.md) - [Commits](https://github.com/pdm-project/pdm/compare/2.12.2...2.12.3) --- updated-dependencies: - dependency-name: pdm dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8070eb8ec..0a5874a8f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -231,7 +231,7 @@ dev = [ "freezegun==1.4.0", "furo==2024.1.29", "mypy==1.8.0", - "pdm==2.12.2", + "pdm==2.12.3", "pip_check_reqs==2.5.3", "pydocstyle==6.3", "pyenchant==3.2.2", From a06dfc4aad1a1dc4b088efb1bb19088786d691d9 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 1 Feb 2024 18:24:24 +0000 Subject: [PATCH 0040/1003] Use strict pylint settings --- pyproject.toml | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index 0a5874a8f..4b4186d2f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -10,9 +10,28 @@ # List of plugins (as comma separated values of python modules names) to load, # usually to register additional checkers. + # See https://chezsoi.org/lucas/blog/pylint-strict-base-configuration.html. + # We do not use the plugins: + # - pylint.extensions.code_style + # - pylint.extensions.magic_value + # - pylint.extensions.while_used + # as they seemed to get in the way. load-plugins = [ + 'pylint.extensions.bad_builtin', + 'pylint.extensions.comparison_placement', + 'pylint.extensions.consider_refactoring_into_while_condition', 'pylint.extensions.docparams', + 'pylint.extensions.dunder', + 'pylint.extensions.eq_without_hash', + 'pylint.extensions.for_any_all', + 'pylint.extensions.mccabe', 'pylint.extensions.no_self_use', + 'pylint.extensions.overlapping_exceptions', + 'pylint.extensions.private_import', + 'pylint.extensions.redefined_loop_name', + 'pylint.extensions.redefined_variable_type', + 'pylint.extensions.set_membership', + 'pylint.extensions.typing', ] # Allow loading of arbitrary C extensions. Extensions are imported into the @@ -26,7 +45,11 @@ # multiple time (only on the command line, not in the configuration file where # it should appear only once). See also the "--disable" option for examples. enable = [ + 'bad-inline-option', + 'deprecated-pragma', + 'file-ignored', 'spelling', + 'use-symbolic-message-instead', 'useless-suppression', ] From 62db2a943f306fcf9d1c60c2d2834428139a31ad Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 2 Feb 2024 04:10:18 +0000 Subject: [PATCH 0041/1003] Upgrade to ruff 0.2.0 --- pyproject.toml | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 4b4186d2f..8a1ad5d17 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -173,14 +173,18 @@ requires = [ universal = true [tool.ruff] -select = ["ALL"] line-length = 79 +[tool.ruff.lint] +select = ["ALL"] + ignore = [ # We do not annotate the type of 'self'. "ANN101", # We are happy to manage our own "complexity". "C901", + # Ruff warns that this conflicts with the formatter. + "COM812", # Allow our chosen docstring line-style - no one-line summary. "D200", "D203", @@ -194,6 +198,8 @@ ignore = [ "D406", "D407", "D413", + # Ruff warns that this conflicts with the formatter. + "ISC001", # We have an existing interface to support and so we do not want to change # exception names. "N818", @@ -211,7 +217,7 @@ ignore = [ # is sometimes annoyingly removed. unfixable = ["ERA001"] -[tool.ruff.per-file-ignores] +[tool.ruff.lint.per-file-ignores] "tests/test_*.py" = [ # Do not require tests to have a one-line summary. "D205", @@ -266,7 +272,7 @@ dev = [ "pytest==8.0.0", "pytest-cov==4.1", "PyYAML==6.0.1", - "ruff==0.1.15", + "ruff==0.2.0", "Sphinx==7.2.6", "sphinx-autodoc-typehints==1.25.3", "sphinx-prompt==1.8", From 8f745dc188c07affd87e54ced7b424af7e377b8d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 2 Feb 2024 13:29:51 +0000 Subject: [PATCH 0042/1003] Simplify coverage.py settings by switching from exclude_lines to exclude_also --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8a1ad5d17..3384b141d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -112,7 +112,7 @@ branch = true [tool.coverage.report] -exclude_lines = ["pragma: no cover", "if TYPE_CHECKING:"] +exclude_also = ["if TYPE_CHECKING:"] [tool.pytest.ini_options] From 2e12b7a4cfecaa75603ccc5f381d3771c7198056 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 4 Feb 2024 01:27:39 +0000 Subject: [PATCH 0043/1003] Return a new error when the server returns a 5xx status code. --- CHANGELOG.rst | 2 ++ src/vws/exceptions/custom_exceptions.py | 21 +++++++++++++++++++++ src/vws/query.py | 6 ++++++ src/vws/vws.py | 6 ++++++ 4 files changed, 35 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 281270708..2233deab5 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,8 @@ Changelog Next ---- +* Return a new error (``vws.custom_exceptions.ServerError``) when the server returns a 5xx status code. + 2023.12.27 ------------ diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index ef88d53aa..41d13febf 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -42,3 +42,24 @@ class TargetProcessingTimeout(Exception): """ Exception raised when waiting for a target to be processed times out. """ + + +class ServerError(Exception): # pragma: no cover + """ + Exception raised when VWS returns a server error. + """ + + def __init__(self, response: Response) -> None: + """ + Args: + response: The response returned by Vuforia. + """ + super().__init__(response.text) + self._response = response + + @property + def response(self) -> Response: + """ + The response returned by Vuforia which included this error. + """ + return self._response diff --git a/src/vws/query.py b/src/vws/query.py index 5df811252..d4efa45b9 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -22,6 +22,7 @@ ) from vws.exceptions.custom_exceptions import ( RequestEntityTooLarge, + ServerError, ) from vws.include_target_data import CloudRecoIncludeTargetData from vws.reports import QueryResult, TargetData @@ -145,6 +146,11 @@ def query( if "Integer out of range" in response.text: raise MaxNumResultsOutOfRange(response=response) + if ( + response.status_code >= HTTPStatus.INTERNAL_SERVER_ERROR + ): # pragma: no cover + raise ServerError(response=response) + result_code = response.json()["result_code"] if result_code != "Success": exception = { diff --git a/src/vws/vws.py b/src/vws/vws.py index 267f88411..2962bc6b8 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -18,6 +18,7 @@ from vws.exceptions.custom_exceptions import ( OopsAnErrorOccurredPossiblyBadName, + ServerError, TargetProcessingTimeout, ) from vws.exceptions.vws_exceptions import ( @@ -188,6 +189,11 @@ def _make_request( # The Vuforia API returns a 429 response with no JSON body. raise TooManyRequests(response=response) + if ( + response.status_code >= HTTPStatus.INTERNAL_SERVER_ERROR + ): # pragma: no cover + raise ServerError(response=response) + result_code = response.json()["result_code"] if result_code == expected_result_code: From ca07d2351b576f3802d6716a9cb3ff4b49db38ad Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 4 Feb 2024 13:19:31 +0000 Subject: [PATCH 0044/1003] Document ServerError might be raised in functions which might raise it --- src/vws/exceptions/custom_exceptions.py | 22 +++++++++++++ src/vws/exceptions/vws_exceptions.py | 7 ----- src/vws/query.py | 2 ++ src/vws/vws.py | 42 ++++++++++++++++++++++++- 4 files changed, 65 insertions(+), 8 deletions(-) diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index 41d13febf..5a7c1a9b5 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -63,3 +63,25 @@ def response(self) -> Response: The response returned by Vuforia which included this error. """ return self._response + + +class TooManyRequests(Exception): # pragma: no cover + """ + Exception raised when Vuforia returns a response with a result code + 'TooManyRequests'. + """ + + def __init__(self, response: Response) -> None: + """ + Args: + response: The response returned by Vuforia. + """ + super().__init__(response.text) + self._response = response + + @property + def response(self) -> Response: + """ + The response returned by Vuforia which included this error. + """ + return self._response diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index 9ff990255..3e080faf3 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -56,13 +56,6 @@ class RequestQuotaReached(VWSException): # pragma: no cover """ -class TooManyRequests(VWSException): # pragma: no cover - """ - Exception raised when Vuforia returns a response with a result code - 'TooManyRequests'. - """ - - class TargetStatusProcessing(VWSException): """ Exception raised when Vuforia returns a response with a result code diff --git a/src/vws/query.py b/src/vws/query.py index d4efa45b9..85501a3b0 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -95,6 +95,8 @@ def query( file in the grayscale or RGB color space. ~vws.exceptions.custom_exceptions.RequestEntityTooLarge: The given image is too large. + ~vws.exceptions.custom_exceptions.ServerError: There is an error + with Vuforia's servers. Returns: An ordered list of target details of matching targets. diff --git a/src/vws/vws.py b/src/vws/vws.py index 2962bc6b8..ca2f59963 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -20,6 +20,7 @@ OopsAnErrorOccurredPossiblyBadName, ServerError, TargetProcessingTimeout, + TooManyRequests, ) from vws.exceptions.vws_exceptions import ( AuthenticationFailure, @@ -37,7 +38,6 @@ TargetQuotaReached, TargetStatusNotSuccess, TargetStatusProcessing, - TooManyRequests, UnknownTarget, ) from vws.reports import ( @@ -167,6 +167,10 @@ def _make_request( an HTML page with the text "Oops, an error occurred". This has been seen to happen when the given name includes a bad character. + ~vws.exceptions.custom_exceptions.ServerError: There is an error + with Vuforia's servers. + ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + limiting access. json.decoder.JSONDecodeError: The server did not respond with valid JSON. This may happen if the server address is not a valid Vuforia server. @@ -274,6 +278,10 @@ def add_target( Vuforia returns an HTML page with the text "Oops, an error occurred". This has been seen to happen when the given name includes a bad character. + ~vws.exceptions.custom_exceptions.ServerError: There is an error + with Vuforia's servers. + ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + limiting access. """ image_data = _get_image_data(image=image) image_data_encoded = base64.b64encode(image_data).decode("ascii") @@ -320,6 +328,10 @@ def get_target_record(self, target_id: str) -> TargetStatusAndRecord: does not match a target in the database. ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an error with the time sent to Vuforia. + ~vws.exceptions.custom_exceptions.ServerError: There is an error + with Vuforia's servers. + ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + limiting access. """ response = self._make_request( method="GET", @@ -377,6 +389,10 @@ def wait_for_target_processed( does not match a target in the database. ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an error with the time sent to Vuforia. + ~vws.exceptions.custom_exceptions.ServerError: There is an error + with Vuforia's servers. + ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + limiting access. """ start_time = time.monotonic() while True: @@ -408,6 +424,10 @@ def list_targets(self) -> list[str]: known database. ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an error with the time sent to Vuforia. + ~vws.exceptions.custom_exceptions.ServerError: There is an error + with Vuforia's servers. + ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + limiting access. """ response = self._make_request( method="GET", @@ -441,6 +461,10 @@ def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: does not match a target in the database. ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an error with the time sent to Vuforia. + ~vws.exceptions.custom_exceptions.ServerError: There is an error + with Vuforia's servers. + ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + limiting access. """ response = self._make_request( method="GET", @@ -480,6 +504,10 @@ def get_database_summary_report(self) -> DatabaseSummaryReport: known database. ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an error with the time sent to Vuforia. + ~vws.exceptions.custom_exceptions.ServerError: There is an error + with Vuforia's servers. + ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + limiting access. """ response = self._make_request( method="GET", @@ -526,6 +554,10 @@ def delete_target(self, target_id: str) -> None: target is in the processing state. ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an error with the time sent to Vuforia. + ~vws.exceptions.custom_exceptions.ServerError: There is an error + with Vuforia's servers. + ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + limiting access. """ self._make_request( method="DELETE", @@ -559,6 +591,10 @@ def get_duplicate_targets(self, target_id: str) -> list[str]: inactive. ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an error with the time sent to Vuforia. + ~vws.exceptions.custom_exceptions.ServerError: There is an error + with Vuforia's servers. + ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + limiting access. """ response = self._make_request( method="GET", @@ -618,6 +654,10 @@ def update_target( inactive. ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an error with the time sent to Vuforia. + ~vws.exceptions.custom_exceptions.ServerError: There is an error + with Vuforia's servers. + ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + limiting access. """ data: dict[str, str | bool | float | int] = {} From 26efcea291c9e129943f1d4fe48a03d3cbdf3086 Mon Sep 17 00:00:00 2001 From: adamtheturtle Date: Sun, 4 Feb 2024 13:34:06 +0000 Subject: [PATCH 0045/1003] Bump CHANGELOG --- CHANGELOG.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 2233deab5..dfedf99eb 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,9 @@ Changelog Next ---- +2024.02.04 +------------ + * Return a new error (``vws.custom_exceptions.ServerError``) when the server returns a 5xx status code. 2023.12.27 From 28611d427ed1d1190d927358dbaa69b567d3ad2b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 4 Feb 2024 14:44:18 +0000 Subject: [PATCH 0046/1003] Move back TooManyRequests --- src/vws/exceptions/custom_exceptions.py | 22 ---------------------- src/vws/exceptions/vws_exceptions.py | 7 +++++++ src/vws/vws.py | 22 +++++++++++----------- 3 files changed, 18 insertions(+), 33 deletions(-) diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index 5a7c1a9b5..41d13febf 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -63,25 +63,3 @@ def response(self) -> Response: The response returned by Vuforia which included this error. """ return self._response - - -class TooManyRequests(Exception): # pragma: no cover - """ - Exception raised when Vuforia returns a response with a result code - 'TooManyRequests'. - """ - - def __init__(self, response: Response) -> None: - """ - Args: - response: The response returned by Vuforia. - """ - super().__init__(response.text) - self._response = response - - @property - def response(self) -> Response: - """ - The response returned by Vuforia which included this error. - """ - return self._response diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index 3e080faf3..1eb751de5 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -164,3 +164,10 @@ def target_id(self) -> str: # Every HTTP path which can raise this error is in the format # `/something/{target_id}`. return path.split(sep="/", maxsplit=2)[-1] + + +class TooManyRequests(VWSException): # pragma: no cover + """ + Exception raised when Vuforia returns a response with a result code + 'TooManyRequests'. + """ diff --git a/src/vws/vws.py b/src/vws/vws.py index ca2f59963..d3f19cc6a 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -20,7 +20,6 @@ OopsAnErrorOccurredPossiblyBadName, ServerError, TargetProcessingTimeout, - TooManyRequests, ) from vws.exceptions.vws_exceptions import ( AuthenticationFailure, @@ -38,6 +37,7 @@ TargetQuotaReached, TargetStatusNotSuccess, TargetStatusProcessing, + TooManyRequests, UnknownTarget, ) from vws.reports import ( @@ -169,7 +169,7 @@ def _make_request( character. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate limiting access. json.decoder.JSONDecodeError: The server did not respond with valid JSON. This may happen if the server address is not a valid @@ -280,7 +280,7 @@ def add_target( includes a bad character. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate limiting access. """ image_data = _get_image_data(image=image) @@ -330,7 +330,7 @@ def get_target_record(self, target_id: str) -> TargetStatusAndRecord: error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate limiting access. """ response = self._make_request( @@ -391,7 +391,7 @@ def wait_for_target_processed( error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate limiting access. """ start_time = time.monotonic() @@ -426,7 +426,7 @@ def list_targets(self) -> list[str]: error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate limiting access. """ response = self._make_request( @@ -463,7 +463,7 @@ def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate limiting access. """ response = self._make_request( @@ -506,7 +506,7 @@ def get_database_summary_report(self) -> DatabaseSummaryReport: error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate limiting access. """ response = self._make_request( @@ -556,7 +556,7 @@ def delete_target(self, target_id: str) -> None: error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate limiting access. """ self._make_request( @@ -593,7 +593,7 @@ def get_duplicate_targets(self, target_id: str) -> list[str]: error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate limiting access. """ response = self._make_request( @@ -656,7 +656,7 @@ def update_target( error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.custom_exceptions.TooManyRequests: Vuforia is rate + ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate limiting access. """ data: dict[str, str | bool | float | int] = {} From 5d60a44066efff74741e7db2998c6c2ea650ae8d Mon Sep 17 00:00:00 2001 From: adamtheturtle Date: Sun, 4 Feb 2024 14:58:16 +0000 Subject: [PATCH 0047/1003] Bump CHANGELOG --- CHANGELOG.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index dfedf99eb..2afc25f50 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,9 @@ Changelog Next ---- +2024.02.04.1 +------------ + 2024.02.04 ------------ From 26fccba7fc29bcaca037a72fbde0bbf5f01f657c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 6 Feb 2024 02:01:35 +0000 Subject: [PATCH 0048/1003] Use custom response type in exceptions, to avoid needing to use requests' API to handle exceptions, and to avoid relying on requests's types which are incomplete --- Makefile | 1 + docs/source/api-reference.rst | 4 ++++ lint.mk | 4 ++++ src/vws/exceptions/base_exceptions.py | 5 +---- src/vws/exceptions/custom_exceptions.py | 2 +- src/vws/exceptions/response.py | 16 +++++++++++++++ src/vws/exceptions/vws_exceptions.py | 4 ++-- src/vws/query.py | 15 +++++++++++--- src/vws/vws.py | 27 ++++++++++++++++--------- 9 files changed, 59 insertions(+), 19 deletions(-) create mode 100644 src/vws/exceptions/response.py diff --git a/Makefile b/Makefile index 1530f4eb7..e215a0026 100644 --- a/Makefile +++ b/Makefile @@ -17,6 +17,7 @@ lint: \ pip-missing-reqs \ pyproject-fmt \ pyright \ + pyright-verifytypes \ pyroma \ spelling \ vulture \ diff --git a/docs/source/api-reference.rst b/docs/source/api-reference.rst index 3ffbc13da..93b39a48e 100644 --- a/docs/source/api-reference.rst +++ b/docs/source/api-reference.rst @@ -5,6 +5,10 @@ API Reference :undoc-members: :members: +.. automodule:: vws.exceptions.response + :undoc-members: + :members: + .. automodule:: vws.reports :undoc-members: :members: diff --git a/lint.mk b/lint.mk index 3127f8a84..555270f4a 100644 --- a/lint.mk +++ b/lint.mk @@ -48,6 +48,10 @@ pyroma: pyright: pyright . +.PHONY: pyright-verifytypes +pyright-verifytypes: + pyright --verifytypes vws + .PHONY: vulture vulture: vulture --min-confidence 100 --exclude _vendor --exclude .eggs . diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index 730d1a2a5..5c45e823a 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -5,10 +5,7 @@ from __future__ import annotations -from typing import TYPE_CHECKING - -if TYPE_CHECKING: - from requests import Response +from .response import Response class CloudRecoException(Exception): diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index 41d13febf..6de381f2b 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -5,7 +5,7 @@ """ -from requests import Response +from .response import Response class OopsAnErrorOccurredPossiblyBadName(Exception): diff --git a/src/vws/exceptions/response.py b/src/vws/exceptions/response.py new file mode 100644 index 000000000..89a42870b --- /dev/null +++ b/src/vws/exceptions/response.py @@ -0,0 +1,16 @@ +"""Responses for exceptions.""" + +from dataclasses import dataclass + + +@dataclass +class Response: + """ + A response from a request. + """ + + text: str + url: str + status_code: int + headers: dict[str, str] + request_body: bytes | str | None diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index 1eb751de5..a43323380 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -137,8 +137,8 @@ def target_name(self) -> str: """ The target name which already exists. """ - response_body = self.response.request.body or b"" - request_json = json.loads(response_body) + response_body = self.response.request_body or b"" + request_json = json.loads(s=response_body) return str(request_json["name"]) diff --git a/src/vws/query.py b/src/vws/query.py index 85501a3b0..a30e59a9c 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -5,6 +5,7 @@ from __future__ import annotations import datetime +import json from http import HTTPStatus from typing import Any, BinaryIO from urllib.parse import urljoin @@ -24,6 +25,7 @@ RequestEntityTooLarge, ServerError, ) +from vws.exceptions.response import Response from vws.include_target_data import CloudRecoIncludeTargetData from vws.reports import QueryResult, TargetData @@ -133,7 +135,7 @@ def query( "Content-Type": content_type_header, } - response = requests.request( + requests_response = requests.request( method=method, url=urljoin(base=self._base_vwq_url, url=request_path), headers=headers, @@ -141,6 +143,13 @@ def query( # We should make the timeout customizable. timeout=None, ) + response = Response( + text=requests_response.text, + url=requests_response.url, + status_code=requests_response.status_code, + headers=dict(requests_response.headers), + request_body=requests_response.request.body, + ) if response.status_code == HTTPStatus.REQUEST_ENTITY_TOO_LARGE: raise RequestEntityTooLarge @@ -153,7 +162,7 @@ def query( ): # pragma: no cover raise ServerError(response=response) - result_code = response.json()["result_code"] + result_code = json.loads(s=response.text)["result_code"] if result_code != "Success": exception = { "AuthenticationFailure": AuthenticationFailure, @@ -164,7 +173,7 @@ def query( raise exception(response=response) result: list[QueryResult] = [] - result_list = list(response.json()["results"]) + result_list = list(json.loads(s=response.text)["results"]) for item in result_list: target_data: TargetData | None = None if "target_data" in item: diff --git a/src/vws/vws.py b/src/vws/vws.py index d3f19cc6a..278f3a2b2 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -13,7 +13,6 @@ from urllib.parse import urljoin import requests -from requests import Response from vws_auth_tools import authorization_header, rfc_1123_date from vws.exceptions.custom_exceptions import ( @@ -48,6 +47,8 @@ TargetSummaryReport, ) +from .exceptions.response import Response + if TYPE_CHECKING: import io @@ -107,7 +108,7 @@ def _target_api_request( url = urljoin(base=base_vws_url, url=request_path) - return requests.request( + requests_response = requests.request( method=method, url=url, headers=headers, @@ -116,6 +117,14 @@ def _target_api_request( timeout=None, ) + return Response( + text=requests_response.text, + url=requests_response.url, + status_code=requests_response.status_code, + headers=dict(requests_response.headers), + request_body=requests_response.request.body, + ) + class VWS: """ @@ -198,7 +207,7 @@ def _make_request( ): # pragma: no cover raise ServerError(response=response) - result_code = response.json()["result_code"] + result_code = json.loads(s=response.text)["result_code"] if result_code == expected_result_code: return response @@ -303,7 +312,7 @@ def add_target( expected_result_code="TargetCreated", ) - return str(response.json()["target_id"]) + return str(json.loads(response.text)["target_id"]) def get_target_record(self, target_id: str) -> TargetStatusAndRecord: """ @@ -340,7 +349,7 @@ def get_target_record(self, target_id: str) -> TargetStatusAndRecord: expected_result_code="Success", ) - result_data = response.json() + result_data = json.loads(s=response.text) status = TargetStatuses(result_data["status"]) target_record_dict = dict(result_data["target_record"]) target_record = TargetRecord( @@ -436,7 +445,7 @@ def list_targets(self) -> list[str]: expected_result_code="Success", ) - return list(response.json()["results"]) + return list(json.loads(response.text)["results"]) def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: """ @@ -473,7 +482,7 @@ def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: expected_result_code="Success", ) - result_data = dict(response.json()) + result_data = dict(json.loads(response.text)) return TargetSummaryReport( status=TargetStatuses(result_data["status"]), database_name=result_data["database_name"], @@ -516,7 +525,7 @@ def get_database_summary_report(self) -> DatabaseSummaryReport: expected_result_code="Success", ) - response_data = dict(response.json()) + response_data = dict(json.loads(response.text)) return DatabaseSummaryReport( active_images=response_data["active_images"], current_month_recos=response_data["current_month_recos"], @@ -603,7 +612,7 @@ def get_duplicate_targets(self, target_id: str) -> list[str]: expected_result_code="Success", ) - return list(response.json()["similar_targets"]) + return list(json.loads(s=response.text)["similar_targets"]) def update_target( self, From 8ec6bd0a76415c66b616bf594d73e0a2e017f9aa Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 6 Feb 2024 02:11:27 +0000 Subject: [PATCH 0049/1003] Fix ruff --- src/vws/exceptions/base_exceptions.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index 5c45e823a..044c2b017 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -5,7 +5,10 @@ from __future__ import annotations -from .response import Response +from typing import TYPE_CHECKING + +if TYPE_CHECKING: + from .response import Response class CloudRecoException(Exception): From 6628c1fbd453299db0fed316276e8758a85d965f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 6 Feb 2024 02:18:05 +0000 Subject: [PATCH 0050/1003] Remove sphinx-autodoc-typehints. This had bugs and is no longer necessary for us with the latest Sphinx. --- docs/source/conf.py | 1 - pyproject.toml | 1 - 2 files changed, 2 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index c3861a1bf..37bfe5701 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -15,7 +15,6 @@ "sphinx.ext.autodoc", "sphinx.ext.intersphinx", "sphinx.ext.napoleon", - "sphinx_autodoc_typehints", "sphinx-prompt", "sphinx_substitution_extensions", "sphinxcontrib.spelling", diff --git a/pyproject.toml b/pyproject.toml index 3384b141d..aab57307d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -274,7 +274,6 @@ dev = [ "PyYAML==6.0.1", "ruff==0.2.0", "Sphinx==7.2.6", - "sphinx-autodoc-typehints==1.25.3", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2022.2.16", "sphinxcontrib-spelling==8", From e687f467b70204017bf7eed93c15e3e4e38b4692 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 6 Feb 2024 02:21:18 +0000 Subject: [PATCH 0051/1003] Remove sphinx-autodoc-typehints configuration variable. --- docs/source/conf.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 37bfe5701..0592ab540 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -86,5 +86,3 @@ .. |github-owner| replace:: VWS-Python .. |github-repository| replace:: vws-python """ - -always_document_param_types = True From 2110123cd3010bfce139f011cf2c40129277adec Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 6 Feb 2024 10:14:43 +0000 Subject: [PATCH 0052/1003] Bump pyright from 1.1.349 to 1.1.350 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.349 to 1.1.350. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.349...v1.1.350) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index aab57307d..e3b7588b1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -267,7 +267,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.0.3", "pyproject-fmt==1.7.0", - "pyright==1.1.349", + "pyright==1.1.350", "pyroma==4.2", "pytest==8.0.0", "pytest-cov==4.1", From ac22a7a5b7ed9095d1e5cbb8d6b507b74fd1a7f2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 6 Feb 2024 10:14:59 +0000 Subject: [PATCH 0053/1003] Bump ruff from 0.2.0 to 0.2.1 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.2.0 to 0.2.1. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.2.0...v0.2.1) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index aab57307d..59fe21472 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -272,7 +272,7 @@ dev = [ "pytest==8.0.0", "pytest-cov==4.1", "PyYAML==6.0.1", - "ruff==0.2.0", + "ruff==0.2.1", "Sphinx==7.2.6", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2022.2.16", From 648ddba5882c626a4d0cba92ad1938aa388d2a20 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 6 Feb 2024 10:50:39 +0000 Subject: [PATCH 0054/1003] Remove nitpick ignore Sphinx setting which is no longer needed --- docs/source/conf.py | 7 ------- 1 file changed, 7 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 0592ab540..d90db443f 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -59,13 +59,6 @@ } nitpicky = True warning_is_error = True -nitpick_ignore = [ - ("py:class", "_io.BytesIO"), - # Requests documentation exposes ``requests.Response``, not - # ``requests.models.response``. - ("py:class", "requests.models.Response"), -] - autoclass_content = "both" From 820944f5b4afbc718c4e015657540f0b3e39ee5a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 6 Feb 2024 10:51:28 +0000 Subject: [PATCH 0055/1003] Remove linkcheck ignore setting which is no longer needed --- docs/source/conf.py | 4 ---- 1 file changed, 4 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index d90db443f..21d419ce2 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -64,10 +64,6 @@ # Retry link checking to avoid transient network errors. linkcheck_retries = 5 -linkcheck_ignore = [ - # Requires login. - r"https://developer.vuforia.com/targetmanager", -] spelling_word_list_filename = "../../spelling_private_dict.txt" From feb26c31c4223920c7e993bef5ed9dc6ea308666 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 6 Feb 2024 10:53:58 +0000 Subject: [PATCH 0056/1003] Fix link to setuptools-scm documentation about Sphinx usage --- docs/source/conf.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 21d419ce2..d6ecf811c 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -32,7 +32,7 @@ # built documents. # # Use ``importlib.metadata.version`` as per -# https://github.com/pypa/setuptools_scm#usage-from-sphinx. +# https://setuptools-scm.readthedocs.io/en/latest/usage/#usage-from-sphinx version = importlib.metadata.version(distribution_name=project) _month, _day, _year, *_ = version.split(".") release = f"{_month}.{_day}.{_year}" From 52041be6d5088c96489e8b7aac9e90f2a892f973 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 6 Feb 2024 10:59:41 +0000 Subject: [PATCH 0057/1003] Remove sphinx-autodoc-typehints configuration variable. --- docs/source/conf.py | 7 ------- 1 file changed, 7 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 0592ab540..d90db443f 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -59,13 +59,6 @@ } nitpicky = True warning_is_error = True -nitpick_ignore = [ - ("py:class", "_io.BytesIO"), - # Requests documentation exposes ``requests.Response``, not - # ``requests.models.response``. - ("py:class", "requests.models.Response"), -] - autoclass_content = "both" From e52b5f872759e99f000790797490302ea163b831 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 6 Feb 2024 11:15:44 +0000 Subject: [PATCH 0058/1003] Move Response object object to exceptions documentation --- docs/source/api-reference.rst | 4 ---- docs/source/exceptions.rst | 7 +++++++ 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/docs/source/api-reference.rst b/docs/source/api-reference.rst index 93b39a48e..3ffbc13da 100644 --- a/docs/source/api-reference.rst +++ b/docs/source/api-reference.rst @@ -5,10 +5,6 @@ API Reference :undoc-members: :members: -.. automodule:: vws.exceptions.response - :undoc-members: - :members: - .. automodule:: vws.reports :undoc-members: :members: diff --git a/docs/source/exceptions.rst b/docs/source/exceptions.rst index f48730bfd..f23ab02b8 100644 --- a/docs/source/exceptions.rst +++ b/docs/source/exceptions.rst @@ -36,3 +36,10 @@ Custom exceptions :show-inheritance: :inherited-members: Exception :exclude-members: errno, filename, filename2, strerror + +Response +-------- + +.. automodule:: vws.exceptions.response + :undoc-members: + :members: From 986a4978367e8eb19ae7d2de2e8f170755b47f74 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 6 Feb 2024 11:16:49 +0000 Subject: [PATCH 0059/1003] Add changelog entry for Response objects --- CHANGELOG.rst | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 2afc25f50..df1018763 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,8 @@ Changelog Next ---- +* Exception response attributes are now ``vws.exceptions.response.Response`` instances rather than ``requests.Response`` objects. + 2024.02.04.1 ------------ From 12aae3af4dfa4ee3e90150a38100382b784cb714 Mon Sep 17 00:00:00 2001 From: adamtheturtle Date: Tue, 6 Feb 2024 11:27:40 +0000 Subject: [PATCH 0060/1003] Bump CHANGELOG --- CHANGELOG.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index df1018763..4b51aacc6 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,9 @@ Changelog Next ---- +2024.02.06 +------------ + * Exception response attributes are now ``vws.exceptions.response.Response`` instances rather than ``requests.Response`` objects. 2024.02.04.1 From 5c50e3356a851a8420d57c020dec3ec0c41f481c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 11:47:38 +0000 Subject: [PATCH 0061/1003] Switch from pip to uv in main CI --- .github/workflows/ci.yml | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 50ffc9c15..a5b0ccd60 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -30,19 +30,20 @@ jobs: python-version: ${{ matrix.python-version }} - uses: actions/cache@v4 + env: + UV_CACHE_DIR: ~/.cache/uv with: - path: ~/.cache/pip - key: ${{ runner.os }}-pip-${{ hashFiles('pyproject.toml') }} + path: "${{ env.UV_CACHE_DIR }}" + key: ${{ runner.os }}-uv-${{ hashFiles('pyproject.toml') }} restore-keys: | - ${{ runner.os }}-pip- + ${{ runner.os }}-uv- - name: "Install dependencies" + env: + UV_CACHE_DIR: ~/.cache/uv run: | - python -m pip install --upgrade pip setuptools wheel - # We use '--ignore-installed' to avoid GitHub's cache which can cause - # issues - we have seen packages from this cache be cause trouble with - # pip-extra-reqs. - python -m pip install --ignore-installed --upgrade --editable .[dev] + python -m pip install --upgrade uv + python -m uv pip install --upgrade --editable .[dev] - name: "Lint" run: | From feb6b1853979065ce35f0e9660d3f60ad225a6a1 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 11:56:21 +0000 Subject: [PATCH 0062/1003] Try using a virtualenv --- .github/workflows/ci.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a5b0ccd60..56b8bf17f 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -41,15 +41,21 @@ jobs: - name: "Install dependencies" env: UV_CACHE_DIR: ~/.cache/uv + VIRTUAL_ENV: ./.venv run: | python -m pip install --upgrade uv + uv venv python -m uv pip install --upgrade --editable .[dev] - name: "Lint" + env: + VIRTUAL_ENV: ./.venv run: | make lint - name: "Run tests" + env: + VIRTUAL_ENV: ./.venv run: | # We run tests against "." and not the tests directory as we test the README # and documentation. From 18eacda83c6512bb72821f54801d8e12820abe9c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 11:57:57 +0000 Subject: [PATCH 0063/1003] No need for editable install --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 56b8bf17f..a0334c8ce 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -45,7 +45,7 @@ jobs: run: | python -m pip install --upgrade uv uv venv - python -m uv pip install --upgrade --editable .[dev] + python -m uv pip install --upgrade .[dev] - name: "Lint" env: From 378f4064a0ed7064eba073b35fe73f5cb9223a3b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 11:58:34 +0000 Subject: [PATCH 0064/1003] Try another way of setting virtualenv --- .github/workflows/ci.yml | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a0334c8ce..ec8144e72 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -41,22 +41,20 @@ jobs: - name: "Install dependencies" env: UV_CACHE_DIR: ~/.cache/uv - VIRTUAL_ENV: ./.venv run: | python -m pip install --upgrade uv uv venv + source ./.venv/bin/activate python -m uv pip install --upgrade .[dev] - name: "Lint" - env: - VIRTUAL_ENV: ./.venv run: | + source ./.venv/bin/activate make lint - name: "Run tests" - env: - VIRTUAL_ENV: ./.venv run: | + source ./.venv/bin/activate # We run tests against "." and not the tests directory as we test the README # and documentation. pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 86dc69a1b13950ae8fb4a8e7ff3ebf4d7b3c7f80 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 11:59:40 +0000 Subject: [PATCH 0065/1003] Use python -m for creating virtualenv --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ec8144e72..5d5ed0c12 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -43,7 +43,7 @@ jobs: UV_CACHE_DIR: ~/.cache/uv run: | python -m pip install --upgrade uv - uv venv + python -m uv venv source ./.venv/bin/activate python -m uv pip install --upgrade .[dev] From 4afd4e5209f87d00b2d4bb42a3d26af2c1ea6bd6 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 12:04:37 +0000 Subject: [PATCH 0066/1003] Install uv without Python --- .github/workflows/ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 5d5ed0c12..2de669304 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,10 +42,10 @@ jobs: env: UV_CACHE_DIR: ~/.cache/uv run: | - python -m pip install --upgrade uv - python -m uv venv + curl -LsSf https://astral.sh/uv/install.sh | sh + uv venv source ./.venv/bin/activate - python -m uv pip install --upgrade .[dev] + uv pip install --upgrade .[dev] - name: "Lint" run: | From 865472112b773fa3ccd86a26e14545135752dba9 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 12:05:51 +0000 Subject: [PATCH 0067/1003] Try quoting install target --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2de669304..7bd4eeba0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -45,7 +45,7 @@ jobs: curl -LsSf https://astral.sh/uv/install.sh | sh uv venv source ./.venv/bin/activate - uv pip install --upgrade .[dev] + uv pip install --upgrade ".[dev]" - name: "Lint" run: | From 58787613578222221a1ccda33dea4f1400be975f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 12:08:28 +0000 Subject: [PATCH 0068/1003] Go back to editable install --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 7bd4eeba0..673efeb3e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -45,7 +45,7 @@ jobs: curl -LsSf https://astral.sh/uv/install.sh | sh uv venv source ./.venv/bin/activate - uv pip install --upgrade ".[dev]" + uv pip install --upgrade --editable ".[dev]" - name: "Lint" run: | From 44ec9e234d412eb2bc04b8d8f2d504b483bd5d6a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 12:18:48 +0000 Subject: [PATCH 0069/1003] Show ~ location --- .github/workflows/ci.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 673efeb3e..c61ff5cdd 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,6 +42,8 @@ jobs: env: UV_CACHE_DIR: ~/.cache/uv run: | + readlink -f ~ + echo "READLINK" curl -LsSf https://astral.sh/uv/install.sh | sh uv venv source ./.venv/bin/activate From c8622bb300781c513812093286050e1e4a9c6503 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 12:21:00 +0000 Subject: [PATCH 0070/1003] Try to set cache better --- .github/workflows/ci.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c61ff5cdd..e204a1f9e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -40,10 +40,9 @@ jobs: - name: "Install dependencies" env: - UV_CACHE_DIR: ~/.cache/uv + # `/home/runner` is the result of running `readlink -f ~` on the runner. + UV_CACHE_DIR: /home/runner/.cache/uv run: | - readlink -f ~ - echo "READLINK" curl -LsSf https://astral.sh/uv/install.sh | sh uv venv source ./.venv/bin/activate From 7f6598e210d727c81467da876887544c63f28dad Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 18:50:52 +0000 Subject: [PATCH 0071/1003] Put venv in /home/runner --- .github/workflows/ci.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e204a1f9e..b8d9931df 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -44,18 +44,18 @@ jobs: UV_CACHE_DIR: /home/runner/.cache/uv run: | curl -LsSf https://astral.sh/uv/install.sh | sh - uv venv - source ./.venv/bin/activate + uv /home/runner/.venv + source /home/runner/.venv/bin/activate uv pip install --upgrade --editable ".[dev]" - name: "Lint" run: | - source ./.venv/bin/activate + source /home/runner/.venv/bin/activate make lint - name: "Run tests" run: | - source ./.venv/bin/activate + source /home/runner/.venv/bin/activate # We run tests against "." and not the tests directory as we test the README # and documentation. pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 9bc7e38b57024a7cc69f2c5bc2d352f5edd19263 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 18:52:28 +0000 Subject: [PATCH 0072/1003] Fix venv create command --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b8d9931df..32302336b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -44,7 +44,7 @@ jobs: UV_CACHE_DIR: /home/runner/.cache/uv run: | curl -LsSf https://astral.sh/uv/install.sh | sh - uv /home/runner/.venv + uv venv /home/runner/.venv source /home/runner/.venv/bin/activate uv pip install --upgrade --editable ".[dev]" From 1b3362c3ab185e3d37ac4c7872bd2395ad46499f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:04:09 +0000 Subject: [PATCH 0073/1003] Use uv in Windows --- .github/workflows/windows-ci.yml | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index ade6b5e71..6127f62db 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -30,22 +30,26 @@ jobs: python-version: ${{ matrix.python-version }} - uses: actions/cache@v4 + env: + UV_CACHE_DIR: ~\AppData\Local\uv\Cache with: - path: ~\AppData\Local\pip\Cache - key: ${{ runner.os }}-pip-${{ hashFiles('pyproject.toml') }} + path: "${{ env.UV_CACHE_DIR }}" + key: ${{ runner.os }}-uv-${{ hashFiles('pyproject.toml') }} restore-keys: | - ${{ runner.os }}-pip- + ${{ runner.os }}-uv- - name: "Install dependencies" + env: + UV_CACHE_DIR: ~\AppData\Local\uv\Cache run: | - python -m pip install --upgrade pip setuptools wheel - # We use '--ignore-installed' to avoid GitHub's cache which can cause - # issues - we have seen packages from this cache be cause trouble with - # pip-extra-reqs. - python -m pip install --ignore-installed --upgrade --editable .[dev] + curl -LsSf https://astral.sh/uv/install.sh | sh + uv venv ~\AppData\Local\.venv + source ~\AppData\Local\.venv + uv pip install --upgrade --editable ".[dev]" - name: "Run tests" run: | + source ~\AppData\Local\.venv # We run tests against "." and not the tests directory as we test the README # and documentation. pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 0bdc1004522b5b7c8860a83b35bae9c542cf0877 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:11:40 +0000 Subject: [PATCH 0074/1003] Quote to avoid shellcheck worries --- .github/workflows/windows-ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 6127f62db..fa9cfa8cb 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -43,13 +43,13 @@ jobs: UV_CACHE_DIR: ~\AppData\Local\uv\Cache run: | curl -LsSf https://astral.sh/uv/install.sh | sh - uv venv ~\AppData\Local\.venv - source ~\AppData\Local\.venv + uv venv "~\AppData\Local\.venv" + source "~\AppData\Local\.venv" uv pip install --upgrade --editable ".[dev]" - name: "Run tests" run: | - source ~\AppData\Local\.venv + source "~\AppData\Local\.venv" # We run tests against "." and not the tests directory as we test the README # and documentation. pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From af277bb1488d244b678d146a18d5530bbaf69149 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:13:57 +0000 Subject: [PATCH 0075/1003] Switch to uv install supported Windows --- .github/workflows/windows-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index fa9cfa8cb..ca9f3a383 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -42,7 +42,7 @@ jobs: env: UV_CACHE_DIR: ~\AppData\Local\uv\Cache run: | - curl -LsSf https://astral.sh/uv/install.sh | sh + irm https://astral.sh/uv/install.ps1 | iex uv venv "~\AppData\Local\.venv" source "~\AppData\Local\.venv" uv pip install --upgrade --editable ".[dev]" From 550efba8bffc36d2aabc93918d4fd1889de21d2b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:21:45 +0000 Subject: [PATCH 0076/1003] Try to fix source command on Windows --- .github/workflows/windows-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index ca9f3a383..a71160e63 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -44,7 +44,7 @@ jobs: run: | irm https://astral.sh/uv/install.ps1 | iex uv venv "~\AppData\Local\.venv" - source "~\AppData\Local\.venv" + "~\AppData\Local\.venv\Scripts\activate.ps1" uv pip install --upgrade --editable ".[dev]" - name: "Run tests" From d9d036bc0c1be0c40f01ab3a8fb161b02decd642 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:28:47 +0000 Subject: [PATCH 0077/1003] Try to fix source command on Windows --- .github/workflows/windows-ci.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index a71160e63..a1f358d3b 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -41,11 +41,12 @@ jobs: - name: "Install dependencies" env: UV_CACHE_DIR: ~\AppData\Local\uv\Cache + VIRTUAL_ENV: ~\AppData\Local\.venv run: | irm https://astral.sh/uv/install.ps1 | iex - uv venv "~\AppData\Local\.venv" - "~\AppData\Local\.venv\Scripts\activate.ps1" - uv pip install --upgrade --editable ".[dev]" + uv venv ${{ env.VIRTUAL_ENV }} + "${{ env.VIRTUAL_ENV }}/Scripts\Activate.ps1" + uv pip install --upgrade --editable .[dev] - name: "Run tests" run: | From 3c44cf051309648edea65d404bc698b2249e1dc1 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:30:09 +0000 Subject: [PATCH 0078/1003] Fix source command in Windows test stage --- .github/workflows/windows-ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index a1f358d3b..1c859f2e8 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -49,8 +49,10 @@ jobs: uv pip install --upgrade --editable .[dev] - name: "Run tests" + env: + VIRTUAL_ENV: ~\AppData\Local\.venv run: | - source "~\AppData\Local\.venv" + "${{ env.VIRTUAL_ENV }}/Scripts\Activate.ps1" # We run tests against "." and not the tests directory as we test the README # and documentation. pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 689735c2ff36447beeda73eaaa86751bcf094b9f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:31:19 +0000 Subject: [PATCH 0079/1003] Remove unnecessary quotes --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 32302336b..930e8f574 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -46,7 +46,7 @@ jobs: curl -LsSf https://astral.sh/uv/install.sh | sh uv venv /home/runner/.venv source /home/runner/.venv/bin/activate - uv pip install --upgrade --editable ".[dev]" + uv pip install --upgrade --editable .[dev] - name: "Lint" run: | From 95501ca36e615d0bba22b18366840d89e81ca6ff Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:33:50 +0000 Subject: [PATCH 0080/1003] Use backslashes on Windows paths --- .github/workflows/windows-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 1c859f2e8..dcfeb7de9 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -45,14 +45,14 @@ jobs: run: | irm https://astral.sh/uv/install.ps1 | iex uv venv ${{ env.VIRTUAL_ENV }} - "${{ env.VIRTUAL_ENV }}/Scripts\Activate.ps1" + "${{ env.VIRTUAL_ENV }}\Scripts\Activate.ps1" uv pip install --upgrade --editable .[dev] - name: "Run tests" env: VIRTUAL_ENV: ~\AppData\Local\.venv run: | - "${{ env.VIRTUAL_ENV }}/Scripts\Activate.ps1" + "${{ env.VIRTUAL_ENV }}\Scripts\Activate.ps1" # We run tests against "." and not the tests directory as we test the README # and documentation. pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 28104b6db65141687151c06bef95e3195ffded04 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:35:24 +0000 Subject: [PATCH 0081/1003] Try python -m for pytest --- .github/workflows/windows-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index dcfeb7de9..5628d4cb7 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -55,4 +55,4 @@ jobs: "${{ env.VIRTUAL_ENV }}\Scripts\Activate.ps1" # We run tests against "." and not the tests directory as we test the README # and documentation. - pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml + python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 8044dba8c981e0a2ff91bac25fdd6f020bafdc2d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:39:42 +0000 Subject: [PATCH 0082/1003] Try finding Python in Windows --- .github/workflows/windows-ci.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 5628d4cb7..c37717d8a 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -45,14 +45,12 @@ jobs: run: | irm https://astral.sh/uv/install.ps1 | iex uv venv ${{ env.VIRTUAL_ENV }} - "${{ env.VIRTUAL_ENV }}\Scripts\Activate.ps1" uv pip install --upgrade --editable .[dev] - name: "Run tests" env: VIRTUAL_ENV: ~\AppData\Local\.venv run: | - "${{ env.VIRTUAL_ENV }}\Scripts\Activate.ps1" # We run tests against "." and not the tests directory as we test the README # and documentation. - python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml + "${{ env.VIRTUAL_ENV }}\bin\python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml" From da175cc25377924450273ad5f69485960003028f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:48:40 +0000 Subject: [PATCH 0083/1003] Try to run tests --- .github/workflows/windows-ci.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index c37717d8a..dd123abd0 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -50,7 +50,9 @@ jobs: - name: "Run tests" env: VIRTUAL_ENV: ~\AppData\Local\.venv + ACTIVATE_SCRIPT: ~\AppData\Local\.venv\Scripts\Activate.ps1 run: | + ${{ env.ACTIVATE_SCRIPT }} # We run tests against "." and not the tests directory as we test the README # and documentation. - "${{ env.VIRTUAL_ENV }}\bin\python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml" + python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml" From 38dca4563de76559d7d8bb733f852e2b0174d93c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:50:24 +0000 Subject: [PATCH 0084/1003] Remove unnecessary quotes --- .github/workflows/windows-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index dd123abd0..08a784c65 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -55,4 +55,4 @@ jobs: ${{ env.ACTIVATE_SCRIPT }} # We run tests against "." and not the tests directory as we test the README # and documentation. - python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml" + python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From e30d766e416815bdb98e1375337f4e55adf63d7d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:53:26 +0000 Subject: [PATCH 0085/1003] Try to fix Windows activation command --- .github/workflows/windows-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 08a784c65..665c719a5 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -52,7 +52,7 @@ jobs: VIRTUAL_ENV: ~\AppData\Local\.venv ACTIVATE_SCRIPT: ~\AppData\Local\.venv\Scripts\Activate.ps1 run: | - ${{ env.ACTIVATE_SCRIPT }} + ~/AppData/Local/.venv/Scripts/Activate.ps1 # We run tests against "." and not the tests directory as we test the README # and documentation. python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 8225159d66d809bd686f83ad1a541de9c03a54fe Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:56:06 +0000 Subject: [PATCH 0086/1003] Try double backslashes --- .github/workflows/windows-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 665c719a5..4e07791e6 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -52,7 +52,7 @@ jobs: VIRTUAL_ENV: ~\AppData\Local\.venv ACTIVATE_SCRIPT: ~\AppData\Local\.venv\Scripts\Activate.ps1 run: | - ~/AppData/Local/.venv/Scripts/Activate.ps1 + ~\\AppData\\Local\\.venv\\Scripts\\Activate.ps1 # We run tests against "." and not the tests directory as we test the README # and documentation. python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 40cd685d40ff0e659c335cc8429e53620b7421d2 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 19:59:25 +0000 Subject: [PATCH 0087/1003] Try to use just the script path --- .github/workflows/windows-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 4e07791e6..08a784c65 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -52,7 +52,7 @@ jobs: VIRTUAL_ENV: ~\AppData\Local\.venv ACTIVATE_SCRIPT: ~\AppData\Local\.venv\Scripts\Activate.ps1 run: | - ~\\AppData\\Local\\.venv\\Scripts\\Activate.ps1 + ${{ env.ACTIVATE_SCRIPT }} # We run tests against "." and not the tests directory as we test the README # and documentation. python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 37d11d08eeef34d0361bc35c1b004ba8b398db2e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 20:03:11 +0000 Subject: [PATCH 0088/1003] Try to use just the script path --- .github/workflows/windows-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 08a784c65..74cf7bb9d 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -52,7 +52,7 @@ jobs: VIRTUAL_ENV: ~\AppData\Local\.venv ACTIVATE_SCRIPT: ~\AppData\Local\.venv\Scripts\Activate.ps1 run: | - ${{ env.ACTIVATE_SCRIPT }} + ~\AppData\Local\.venv\Scripts\Activate.ps1 # We run tests against "." and not the tests directory as we test the README # and documentation. python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 4ade717b0b8a6f2454782ff2905d1a0584bc704e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 20:06:44 +0000 Subject: [PATCH 0089/1003] Try to use just the Python path --- .github/workflows/windows-ci.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 74cf7bb9d..0378e60db 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -50,9 +50,7 @@ jobs: - name: "Run tests" env: VIRTUAL_ENV: ~\AppData\Local\.venv - ACTIVATE_SCRIPT: ~\AppData\Local\.venv\Scripts\Activate.ps1 run: | - ~\AppData\Local\.venv\Scripts\Activate.ps1 # We run tests against "." and not the tests directory as we test the README # and documentation. - python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml + ${{ env.VIRTUAL_ENV}}/bin/python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 33593b19765fbe307646a8e9374942a69a7262fc Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 20:08:40 +0000 Subject: [PATCH 0090/1003] Try import-module --- .github/workflows/windows-ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 0378e60db..8be5ec48b 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -51,6 +51,7 @@ jobs: env: VIRTUAL_ENV: ~\AppData\Local\.venv run: | + Import-Module ~ # We run tests against "." and not the tests directory as we test the README # and documentation. ${{ env.VIRTUAL_ENV}}/bin/python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 2ee6a3c76b87fb43bed0ea8cdf835d51068b2136 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 20:13:04 +0000 Subject: [PATCH 0091/1003] Try another way of setting virtualenv --- .github/workflows/windows-ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 8be5ec48b..143b78158 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -41,17 +41,17 @@ jobs: - name: "Install dependencies" env: UV_CACHE_DIR: ~\AppData\Local\uv\Cache - VIRTUAL_ENV: ~\AppData\Local\.venv run: | irm https://astral.sh/uv/install.ps1 | iex - uv venv ${{ env.VIRTUAL_ENV }} + uv venv ${{ github.workspace }}/.venv + ${{ github.workspace }}/.venv/Scripts/Activate.ps1 uv pip install --upgrade --editable .[dev] - name: "Run tests" env: VIRTUAL_ENV: ~\AppData\Local\.venv run: | - Import-Module ~ + ${{ github.workspace }}/.venv/Scripts/Activate.ps1 # We run tests against "." and not the tests directory as we test the README # and documentation. ${{ env.VIRTUAL_ENV}}/bin/python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From f3c01a93d61fcdc283eab720a6d0a35ee5a60344 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 20:15:01 +0000 Subject: [PATCH 0092/1003] Revert setting python path completely --- .github/workflows/windows-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 143b78158..f3fc085fb 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -54,4 +54,4 @@ jobs: ${{ github.workspace }}/.venv/Scripts/Activate.ps1 # We run tests against "." and not the tests directory as we test the README # and documentation. - ${{ env.VIRTUAL_ENV}}/bin/python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml + python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 21b03302fb1bc5c33d91712015fef08d6e518762 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 20:18:19 +0000 Subject: [PATCH 0093/1003] Simplify setup of virtualenvs --- .github/workflows/ci.yml | 6 +++--- .github/workflows/windows-ci.yml | 2 -- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 930e8f574..8ddbb7e5e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -44,8 +44,8 @@ jobs: UV_CACHE_DIR: /home/runner/.cache/uv run: | curl -LsSf https://astral.sh/uv/install.sh | sh - uv venv /home/runner/.venv - source /home/runner/.venv/bin/activate + uv venv ${{ github.workspace }}/.venv + source ${{ github.workspace }}/.venv/bin/activate uv pip install --upgrade --editable .[dev] - name: "Lint" @@ -55,7 +55,7 @@ jobs: - name: "Run tests" run: | - source /home/runner/.venv/bin/activate + source ${{ github.workspace }}/.venv/bin/activate # We run tests against "." and not the tests directory as we test the README # and documentation. pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index f3fc085fb..30d9fa9ba 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -48,8 +48,6 @@ jobs: uv pip install --upgrade --editable .[dev] - name: "Run tests" - env: - VIRTUAL_ENV: ~\AppData\Local\.venv run: | ${{ github.workspace }}/.venv/Scripts/Activate.ps1 # We run tests against "." and not the tests directory as we test the README From 1d3dffa9e57e62f18c07d818b51c11cba4fc5c90 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 20:19:48 +0000 Subject: [PATCH 0094/1003] Fix source command in CI stage --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8ddbb7e5e..9e622501a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -50,7 +50,7 @@ jobs: - name: "Lint" run: | - source /home/runner/.venv/bin/activate + source ${{ github.workspace }}/.venv/bin/activate make lint - name: "Run tests" From b7c92bfffe8dce976e195a0347c25e7fe41815cb Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 20:23:21 +0000 Subject: [PATCH 0095/1003] Try another way of setting virtualenv not in current directory --- .github/workflows/ci.yml | 8 ++++---- .github/workflows/windows-ci.yml | 6 +++--- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9e622501a..c3e4318fb 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -44,18 +44,18 @@ jobs: UV_CACHE_DIR: /home/runner/.cache/uv run: | curl -LsSf https://astral.sh/uv/install.sh | sh - uv venv ${{ github.workspace }}/.venv - source ${{ github.workspace }}/.venv/bin/activate + uv venv ${{ github.workspace }}/../.venv + source ${{ github.workspace }}/../.venv/bin/activate uv pip install --upgrade --editable .[dev] - name: "Lint" run: | - source ${{ github.workspace }}/.venv/bin/activate + source ${{ github.workspace }}/../.venv/bin/activate make lint - name: "Run tests" run: | - source ${{ github.workspace }}/.venv/bin/activate + source ${{ github.workspace }}/../.venv/bin/activate # We run tests against "." and not the tests directory as we test the README # and documentation. pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 30d9fa9ba..964adee0a 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -43,13 +43,13 @@ jobs: UV_CACHE_DIR: ~\AppData\Local\uv\Cache run: | irm https://astral.sh/uv/install.ps1 | iex - uv venv ${{ github.workspace }}/.venv - ${{ github.workspace }}/.venv/Scripts/Activate.ps1 + uv venv ${{ github.workspace }}/../.venv + ${{ github.workspace }}/../.venv/Scripts/Activate.ps1 uv pip install --upgrade --editable .[dev] - name: "Run tests" run: | - ${{ github.workspace }}/.venv/Scripts/Activate.ps1 + ${{ github.workspace }}/../.venv/Scripts/Activate.ps1 # We run tests against "." and not the tests directory as we test the README # and documentation. python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From d73f42758a79fa4abf08d9ace52409b13e7b9ccc Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 20:30:47 +0000 Subject: [PATCH 0096/1003] Remove cache on Windows CI --- .github/workflows/windows-ci.yml | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 964adee0a..0c023fb76 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -29,18 +29,7 @@ jobs: with: python-version: ${{ matrix.python-version }} - - uses: actions/cache@v4 - env: - UV_CACHE_DIR: ~\AppData\Local\uv\Cache - with: - path: "${{ env.UV_CACHE_DIR }}" - key: ${{ runner.os }}-uv-${{ hashFiles('pyproject.toml') }} - restore-keys: | - ${{ runner.os }}-uv- - - name: "Install dependencies" - env: - UV_CACHE_DIR: ~\AppData\Local\uv\Cache run: | irm https://astral.sh/uv/install.ps1 | iex uv venv ${{ github.workspace }}/../.venv From 4519f8d14e094cfcce88b511f49fb3a946c76c78 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 16 Feb 2024 20:34:43 +0000 Subject: [PATCH 0097/1003] Try hardcoding to runner path Windows --- .github/workflows/ci.yml | 8 ++++---- .github/workflows/windows-ci.yml | 17 ++++++++++++++--- 2 files changed, 18 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c3e4318fb..930e8f574 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -44,18 +44,18 @@ jobs: UV_CACHE_DIR: /home/runner/.cache/uv run: | curl -LsSf https://astral.sh/uv/install.sh | sh - uv venv ${{ github.workspace }}/../.venv - source ${{ github.workspace }}/../.venv/bin/activate + uv venv /home/runner/.venv + source /home/runner/.venv/bin/activate uv pip install --upgrade --editable .[dev] - name: "Lint" run: | - source ${{ github.workspace }}/../.venv/bin/activate + source /home/runner/.venv/bin/activate make lint - name: "Run tests" run: | - source ${{ github.workspace }}/../.venv/bin/activate + source /home/runner/.venv/bin/activate # We run tests against "." and not the tests directory as we test the README # and documentation. pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 0c023fb76..d1b5aa939 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -29,16 +29,27 @@ jobs: with: python-version: ${{ matrix.python-version }} + - uses: actions/cache@v4 + env: + UV_CACHE_DIR: C:/Users/runner/.cache/ + with: + path: "${{ env.UV_CACHE_DIR }}" + key: ${{ runner.os }}-uv-${{ hashFiles('pyproject.toml') }} + restore-keys: | + ${{ runner.os }}-uv- + - name: "Install dependencies" + env: + UV_CACHE_DIR: C:/Users/runner/.cache/ run: | irm https://astral.sh/uv/install.ps1 | iex - uv venv ${{ github.workspace }}/../.venv - ${{ github.workspace }}/../.venv/Scripts/Activate.ps1 + uv venv C:/Users/runner/.venv + C:/Users/runner/.venv/Scripts/Activate.ps1 uv pip install --upgrade --editable .[dev] - name: "Run tests" run: | - ${{ github.workspace }}/../.venv/Scripts/Activate.ps1 + C:/Users/runner/.venv/Scripts/Activate.ps1 # We run tests against "." and not the tests directory as we test the README # and documentation. python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 06685e14b031c47ebd95b75c1b569bcde0d580aa Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 16 Feb 2024 23:46:50 +0000 Subject: [PATCH 0098/1003] Bump vws-python-mock from 2024.1.21 to 2024.2.16 Bumps [vws-python-mock](https://github.com/VWS-Python/vws-python-mock) from 2024.1.21 to 2024.2.16. - [Release notes](https://github.com/VWS-Python/vws-python-mock/releases) - [Changelog](https://github.com/VWS-Python/vws-python-mock/blob/main/CHANGELOG.rst) - [Commits](https://github.com/VWS-Python/vws-python-mock/compare/2024.01.21...2024.02.16) --- updated-dependencies: - dependency-name: vws-python-mock dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2a22dfcb8..c2ebda203 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -280,7 +280,7 @@ dev = [ "sybil==6.0.3", "types-requests==2.31.0.20240125", "vulture==2.11", - "VWS-Python-Mock==2024.1.21", + "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", ] [project.urls] From 48d8c938389eba1b58e6135b7a0e6c8d3a8b08d5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 16 Feb 2024 23:47:00 +0000 Subject: [PATCH 0099/1003] Bump pytest from 8.0.0 to 8.0.1 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.0.0 to 8.0.1. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.0.0...8.0.1) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2a22dfcb8..6e8b06ed5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -269,7 +269,7 @@ dev = [ "pyproject-fmt==1.7.0", "pyright==1.1.350", "pyroma==4.2", - "pytest==8.0.0", + "pytest==8.0.1", "pytest-cov==4.1", "PyYAML==6.0.1", "ruff==0.2.1", From 19aef0c6a7e3bb62eee38e8dd783f5e71c2d400a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 17 Feb 2024 02:12:13 +0000 Subject: [PATCH 0100/1003] Avoid cache for uv requirements - it doesn't make the build faster --- .github/workflows/windows-ci.yml | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index d1b5aa939..a9ad24e79 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -29,18 +29,8 @@ jobs: with: python-version: ${{ matrix.python-version }} - - uses: actions/cache@v4 - env: - UV_CACHE_DIR: C:/Users/runner/.cache/ - with: - path: "${{ env.UV_CACHE_DIR }}" - key: ${{ runner.os }}-uv-${{ hashFiles('pyproject.toml') }} - restore-keys: | - ${{ runner.os }}-uv- - + # We do not use the cache action as uv is faster than the cache action. - name: "Install dependencies" - env: - UV_CACHE_DIR: C:/Users/runner/.cache/ run: | irm https://astral.sh/uv/install.ps1 | iex uv venv C:/Users/runner/.venv From 4928f1969b49c220f4a53ac7a89549856467cacf Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 17 Feb 2024 02:13:27 +0000 Subject: [PATCH 0101/1003] Avoid cache for uv requirements - it doesn't make the build faster --- .github/workflows/ci.yml | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 930e8f574..307175e8a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -29,19 +29,8 @@ jobs: with: python-version: ${{ matrix.python-version }} - - uses: actions/cache@v4 - env: - UV_CACHE_DIR: ~/.cache/uv - with: - path: "${{ env.UV_CACHE_DIR }}" - key: ${{ runner.os }}-uv-${{ hashFiles('pyproject.toml') }} - restore-keys: | - ${{ runner.os }}-uv- - + # We do not use the cache action as uv is faster than the cache action. - name: "Install dependencies" - env: - # `/home/runner` is the result of running `readlink -f ~` on the runner. - UV_CACHE_DIR: /home/runner/.cache/uv run: | curl -LsSf https://astral.sh/uv/install.sh | sh uv venv /home/runner/.venv From 7f6cf21ffcc6cbaa1693d3a243829e91836fffeb Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 17 Feb 2024 04:41:35 +0000 Subject: [PATCH 0102/1003] Fail on Codecov failure, and use token to fix upload --- .github/workflows/ci.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 307175e8a..2024ed932 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -51,3 +51,6 @@ jobs: - name: "Upload coverage to Codecov" uses: "codecov/codecov-action@v4" + with: + fail_ci_if_error: true + token: ${{ secrets.CODECOV_TOKEN }} From 136685533171b7a075ef5d547df3e6ed369e317a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 17 Feb 2024 12:32:46 +0000 Subject: [PATCH 0103/1003] Switch from pdm to uv for pip-check-reqs --- lint.mk | 4 ++-- pyproject.toml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lint.mk b/lint.mk index 555270f4a..24c99b3e4 100644 --- a/lint.mk +++ b/lint.mk @@ -30,11 +30,11 @@ fix-ruff: .PHONY: pip-extra-reqs pip-extra-reqs: - pip-extra-reqs --requirements-file=<(pdm export --pyproject) src/ + pip-extra-reqs --requirements-file=<(uv pip compile --no-deps pyproject.toml) src/ .PHONY: pip-missing-reqs pip-missing-reqs: - pip-missing-reqs --requirements-file=<(pdm export --pyproject) src/ + pip-missing-reqs --requirements-file=<(uv pip compile --no-deps pyproject.toml) src/ .PHONY: pylint pylint: diff --git a/pyproject.toml b/pyproject.toml index 3c10afa40..f11493609 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -260,7 +260,6 @@ dev = [ "freezegun==1.4.0", "furo==2024.1.29", "mypy==1.8.0", - "pdm==2.12.3", "pip_check_reqs==2.5.3", "pydocstyle==6.3", "pyenchant==3.2.2", @@ -279,6 +278,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240125", + "uv==0.1.3", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From 3c69d3c2aa2c8e4970e0bf916a343ebfc9933043 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 18 Feb 2024 18:56:07 +0000 Subject: [PATCH 0104/1003] Remove dodgy dependency --- pyproject.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f11493609..c646a0356 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -256,7 +256,6 @@ dev = [ "actionlint-py==1.6.26.11", "check-manifest==0.49", "doc8==1.1.1", - "dodgy==0.2.1", "freezegun==1.4.0", "furo==2024.1.29", "mypy==1.8.0", From fe5cb2bd9beb041db76932a37b645736e659da74 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 19 Feb 2024 10:51:13 +0000 Subject: [PATCH 0105/1003] Bump ruff from 0.2.1 to 0.2.2 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.2.1 to 0.2.2. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.2.1...v0.2.2) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c646a0356..db71a71e2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -270,7 +270,7 @@ dev = [ "pytest==8.0.1", "pytest-cov==4.1", "PyYAML==6.0.1", - "ruff==0.2.1", + "ruff==0.2.2", "Sphinx==7.2.6", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2022.2.16", From e2f074f4300d0088b7741a53bf07bd9c25bbd30d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 19 Feb 2024 18:21:26 +0000 Subject: [PATCH 0106/1003] Bump uv from 0.1.3 to 0.1.5 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.3 to 0.1.5. - [Release notes](https://github.com/astral-sh/uv/releases) - [Commits](https://github.com/astral-sh/uv/compare/0.1.3...0.1.5) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index db71a71e2..f535da795 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240125", - "uv==0.1.3", + "uv==0.1.5", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From c9aca9ca4044ed4d24f92df59cf2dc095691f9ff Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 19 Feb 2024 19:18:49 +0000 Subject: [PATCH 0107/1003] Include response in RequestEntityTooLarge exception Useful in testing our mock --- src/vws/exceptions/custom_exceptions.py | 15 +++++++++++++++ src/vws/query.py | 2 +- tests/test_cloud_reco_exceptions.py | 6 +++++- 3 files changed, 21 insertions(+), 2 deletions(-) diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index 6de381f2b..dfc0cf575 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -37,6 +37,21 @@ class RequestEntityTooLarge(Exception): Exception raised when the given image is too large. """ + def __init__(self, response: Response) -> None: + """ + Args: + response: The response returned by Vuforia. + """ + super().__init__(response.text) + self._response = response + + @property + def response(self) -> Response: + """ + The response returned by Vuforia which included this error. + """ + return self._response + class TargetProcessingTimeout(Exception): """ diff --git a/src/vws/query.py b/src/vws/query.py index a30e59a9c..ffeedfc12 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -152,7 +152,7 @@ def query( ) if response.status_code == HTTPStatus.REQUEST_ENTITY_TOO_LARGE: - raise RequestEntityTooLarge + raise RequestEntityTooLarge(response=response) if "Integer out of range" in response.text: raise MaxNumResultsOutOfRange(response=response) diff --git a/tests/test_cloud_reco_exceptions.py b/tests/test_cloud_reco_exceptions.py index 7e7261599..ba063dece 100644 --- a/tests/test_cloud_reco_exceptions.py +++ b/tests/test_cloud_reco_exceptions.py @@ -58,9 +58,13 @@ def test_image_too_large( A ``RequestEntityTooLarge`` exception is raised if an image which is too large is given. """ - with pytest.raises(RequestEntityTooLarge): + with pytest.raises(RequestEntityTooLarge) as exc: cloud_reco_client.query(image=png_too_large) + assert ( + exc.value.response.status_code == HTTPStatus.REQUEST_ENTITY_TOO_LARGE + ) + def test_cloudrecoexception_inheritance() -> None: """ From acf218c75c52d670245167eb1fee304b5db602ea Mon Sep 17 00:00:00 2001 From: adamtheturtle Date: Mon, 19 Feb 2024 19:36:40 +0000 Subject: [PATCH 0108/1003] Bump CHANGELOG --- CHANGELOG.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 4b51aacc6..53069ad42 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,9 @@ Changelog Next ---- +2024.02.19 +------------ + 2024.02.06 ------------ From eedeb06d0c5bb8be58d5f32280117328d4072338 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 19 Feb 2024 19:37:41 +0000 Subject: [PATCH 0109/1003] Bump types-requests from 2.31.0.20240125 to 2.31.0.20240218 Bumps [types-requests](https://github.com/python/typeshed) from 2.31.0.20240125 to 2.31.0.20240218. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f535da795..c534a1700 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -276,7 +276,7 @@ dev = [ "Sphinx-Substitution-Extensions==2022.2.16", "sphinxcontrib-spelling==8", "sybil==6.0.3", - "types-requests==2.31.0.20240125", + "types-requests==2.31.0.20240218", "uv==0.1.5", "vulture==2.11", "VWS-Python-Mock==2024.2.16", From 2b156a7e8b6d3ed286ad6a6c954c44d32bc218ac Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 19 Feb 2024 21:39:31 +0000 Subject: [PATCH 0110/1003] Add CHANGELOG entry for previous release --- CHANGELOG.rst | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 53069ad42..ddd3ed91a 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -7,6 +7,8 @@ Next 2024.02.19 ------------ +* Add exception response attribute to ``vws.exceptions.custom_exceptions.RequestEntityTooLarge``. + 2024.02.06 ------------ From 5ccfa47de06e7fd41670e6b2508a156052b1345a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 20 Feb 2024 10:43:01 +0000 Subject: [PATCH 0111/1003] Bump pyright from 1.1.350 to 1.1.351 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.350 to 1.1.351. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.350...v1.1.351) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f535da795..f5cd96eb0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -265,7 +265,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.0.3", "pyproject-fmt==1.7.0", - "pyright==1.1.350", + "pyright==1.1.351", "pyroma==4.2", "pytest==8.0.1", "pytest-cov==4.1", From 80d8eb7232bb389425cc80a182dfbd5c6b153c00 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 21 Feb 2024 10:58:15 +0000 Subject: [PATCH 0112/1003] Bump uv from 0.1.5 to 0.1.6 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.5 to 0.1.6. - [Release notes](https://github.com/astral-sh/uv/releases) - [Commits](https://github.com/astral-sh/uv/compare/0.1.5...0.1.6) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index dca024a78..282640eae 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240218", - "uv==0.1.5", + "uv==0.1.6", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From 8f11a953947d0b61ae135efe8c0207c6262b58ed Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 21 Feb 2024 14:58:17 +0000 Subject: [PATCH 0113/1003] Switch from pip-check-reqs to deptry --- Makefile | 3 +-- lint.mk | 15 ++++++++------- pyproject.toml | 2 +- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/Makefile b/Makefile index e215a0026..71db4ef0b 100644 --- a/Makefile +++ b/Makefile @@ -9,12 +9,11 @@ SPHINXOPTS := -W lint: \ actionlint \ check-manifest \ + deptry \ doc8 \ linkcheck \ mypy \ ruff \ - pip-extra-reqs \ - pip-missing-reqs \ pyproject-fmt \ pyright \ pyright-verifytypes \ diff --git a/lint.mk b/lint.mk index 24c99b3e4..568acb340 100644 --- a/lint.mk +++ b/lint.mk @@ -28,13 +28,14 @@ fix-ruff: ruff --fix . ruff format . -.PHONY: pip-extra-reqs -pip-extra-reqs: - pip-extra-reqs --requirements-file=<(uv pip compile --no-deps pyproject.toml) src/ - -.PHONY: pip-missing-reqs -pip-missing-reqs: - pip-missing-reqs --requirements-file=<(uv pip compile --no-deps pyproject.toml) src/ +TEMPFILE:= $(shell mktemp) + +.PHONY: deptry +deptry: + uv pip compile --no-deps pyproject.toml > $(TEMPFILE) + mv pyproject.toml pyproject.bak.toml + deptry --requirements-txt=$(TEMPFILE) src/ || (mv pyproject.bak.toml pyproject.toml && exit 1) + mv pyproject.bak.toml pyproject.toml .PHONY: pylint pylint: diff --git a/pyproject.toml b/pyproject.toml index 282640eae..c0a444cf2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -255,11 +255,11 @@ dependencies = [ dev = [ "actionlint-py==1.6.26.11", "check-manifest==0.49", + "deptry==0.12.0", "doc8==1.1.1", "freezegun==1.4.0", "furo==2024.1.29", "mypy==1.8.0", - "pip_check_reqs==2.5.3", "pydocstyle==6.3", "pyenchant==3.2.2", "Pygments==2.17.2", From df86d121fba6f700541f53ef55e362541159193d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 22 Feb 2024 10:30:27 +0000 Subject: [PATCH 0114/1003] Bump uv from 0.1.6 to 0.1.7 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.6 to 0.1.7. - [Release notes](https://github.com/astral-sh/uv/releases) - [Commits](https://github.com/astral-sh/uv/compare/0.1.6...0.1.7) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c0a444cf2..a08e606a5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240218", - "uv==0.1.6", + "uv==0.1.7", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From 9b5bcc39386abf72cadec16312ac94438577f551 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 22 Feb 2024 11:04:16 +0000 Subject: [PATCH 0115/1003] Automatically merge dependabot PRs once status checks pass --- .github/workflows/dependabot-merge.yml | 24 ++++++++++++++++++++++++ .github/workflows/release.yml | 4 ++++ 2 files changed, 28 insertions(+) create mode 100644 .github/workflows/dependabot-merge.yml diff --git a/.github/workflows/dependabot-merge.yml b/.github/workflows/dependabot-merge.yml new file mode 100644 index 000000000..0f484eebe --- /dev/null +++ b/.github/workflows/dependabot-merge.yml @@ -0,0 +1,24 @@ +--- + +name: Dependabot auto-merge +on: pull_request + +permissions: + contents: write + pull-requests: write + +jobs: + dependabot: + runs-on: ubuntu-latest + if: github.actor == 'dependabot[bot]' + steps: + - name: Dependabot metadata + id: metadata + uses: dependabot/fetch-metadata@v1 + with: + github-token: "${{ secrets.GITHUB_TOKEN }}" + - name: Enable auto-merge for Dependabot PRs + run: gh pr merge --auto --merge "$PR_URL" + env: + PR_URL: ${{github.event.pull_request.html_url}} + GH_TOKEN: ${{secrets.GITHUB_TOKEN}} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index f5e9d9793..80877b4bd 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -26,6 +26,10 @@ jobs: steps: - uses: actions/checkout@v4 + with: + # See + # https://github.com/stefanzweifel/git-auto-commit-action?tab=readme-ov-file#push-to-protected-branches + token: ${{ secrets.RELEASE_PAT }} - name: "Set up Python" uses: actions/setup-python@v5 From 626662973f1c2055dad806f80c5140efedf833a0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 23 Feb 2024 10:37:04 +0000 Subject: [PATCH 0116/1003] Bump uv from 0.1.7 to 0.1.9 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.7 to 0.1.9. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.7...0.1.9) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a08e606a5..31efa5f7d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240218", - "uv==0.1.7", + "uv==0.1.9", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From 01fd96723e7d52f49f5569161a7ffd370f8dc1dc Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 24 Feb 2024 11:51:02 +0000 Subject: [PATCH 0117/1003] Change ruff invocations to use the new syntax --- lint.mk | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lint.mk b/lint.mk index 568acb340..f4d98eab8 100644 --- a/lint.mk +++ b/lint.mk @@ -20,12 +20,12 @@ doc8: .PHONY: ruff ruff: - ruff . + ruff check . ruff format --check . .PHONY: fix-ruff fix-ruff: - ruff --fix . + ruff check --fix . ruff format . TEMPFILE:= $(shell mktemp) From d705ad9ffa9792762185846629df708b6ec821ad Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 26 Feb 2024 10:53:41 +0000 Subject: [PATCH 0118/1003] Bump pytest from 8.0.1 to 8.0.2 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.0.1 to 8.0.2. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.0.1...8.0.2) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 31efa5f7d..e099cd114 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -267,7 +267,7 @@ dev = [ "pyproject-fmt==1.7.0", "pyright==1.1.351", "pyroma==4.2", - "pytest==8.0.1", + "pytest==8.0.2", "pytest-cov==4.1", "PyYAML==6.0.1", "ruff==0.2.2", From d0b0ee21be7c2e89eaa454cf744c57804d1c6ddb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 26 Feb 2024 10:58:10 +0000 Subject: [PATCH 0119/1003] Bump pylint from 3.0.3 to 3.1.0 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.0.3 to 3.1.0. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.0.3...v3.1.0) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e099cd114..0f71a706f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -263,7 +263,7 @@ dev = [ "pydocstyle==6.3", "pyenchant==3.2.2", "Pygments==2.17.2", - "pylint==3.0.3", + "pylint==3.1.0", "pyproject-fmt==1.7.0", "pyright==1.1.351", "pyroma==4.2", From f4e78823292decab7cd68f1b0a90bdd491a1c8d5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 26 Feb 2024 11:02:59 +0000 Subject: [PATCH 0120/1003] Bump uv from 0.1.9 to 0.1.10 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.9 to 0.1.10. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.9...0.1.10) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0f71a706f..3da446e5f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240218", - "uv==0.1.9", + "uv==0.1.10", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From 121a08b0adc2dde530fbfff92b6e35402e5f8be2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 26 Feb 2024 11:07:42 +0000 Subject: [PATCH 0121/1003] Bump sphinx-substitution-extensions from 2022.2.16 to 2024.2.25 Bumps [sphinx-substitution-extensions](https://github.com/adamtheturtle/sphinx-substitution-extensions) from 2022.2.16 to 2024.2.25. - [Release notes](https://github.com/adamtheturtle/sphinx-substitution-extensions/releases) - [Changelog](https://github.com/adamtheturtle/sphinx-substitution-extensions/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/sphinx-substitution-extensions/compare/2022.02.16...2024.02.25) --- updated-dependencies: - dependency-name: sphinx-substitution-extensions dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3da446e5f..8fb681c76 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -273,7 +273,7 @@ dev = [ "ruff==0.2.2", "Sphinx==7.2.6", "sphinx-prompt==1.8", - "Sphinx-Substitution-Extensions==2022.2.16", + "Sphinx-Substitution-Extensions==2024.2.25", "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240218", From 016193f3a725f4d74528bec9dfe40a06fcd1d037 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 27 Feb 2024 10:22:06 +0000 Subject: [PATCH 0122/1003] Bump uv from 0.1.10 to 0.1.11 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.10 to 0.1.11. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.10...0.1.11) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8fb681c76..3b099deae 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240218", - "uv==0.1.10", + "uv==0.1.11", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From f7e065951f8f2ec6c6735785f71dcd4a7e2d39b6 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 29 Feb 2024 10:22:29 +0000 Subject: [PATCH 0123/1003] Bump pyright from 1.1.351 to 1.1.352 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.351 to 1.1.352. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.351...v1.1.352) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3b099deae..d51c1fda5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -265,7 +265,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.1.0", "pyproject-fmt==1.7.0", - "pyright==1.1.351", + "pyright==1.1.352", "pyroma==4.2", "pytest==8.0.2", "pytest-cov==4.1", From 2893688389f3d87027b76643b56a474e233cf82d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 29 Feb 2024 10:51:42 +0000 Subject: [PATCH 0124/1003] Bump uv from 0.1.11 to 0.1.12 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.11 to 0.1.12. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.11...0.1.12) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d51c1fda5..196f1725c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240218", - "uv==0.1.11", + "uv==0.1.12", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From 140858fa9d1b1af35914bfda75f4a36f179e9bc3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 1 Mar 2024 10:18:54 +0000 Subject: [PATCH 0125/1003] Bump uv from 0.1.12 to 0.1.13 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.12 to 0.1.13. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.12...0.1.13) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 196f1725c..9fdcd6474 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240218", - "uv==0.1.12", + "uv==0.1.13", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From dbff2f0d890cf66d2cb3a18f32ceace578ca1a49 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 1 Mar 2024 10:23:25 +0000 Subject: [PATCH 0126/1003] Bump ruff from 0.2.2 to 0.3.0 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.2.2 to 0.3.0. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.2.2...v0.3.0) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9fdcd6474..1b8395a19 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -270,7 +270,7 @@ dev = [ "pytest==8.0.2", "pytest-cov==4.1", "PyYAML==6.0.1", - "ruff==0.2.2", + "ruff==0.3.0", "Sphinx==7.2.6", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", From 17d8a7de58bea6c48b968586170e9c89b141de3c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 1 Mar 2024 11:07:02 +0000 Subject: [PATCH 0127/1003] Run ruff format . --- src/vws/exceptions/cloud_reco_exceptions.py | 1 - src/vws/exceptions/custom_exceptions.py | 1 - src/vws/include_target_data.py | 1 - 3 files changed, 3 deletions(-) diff --git a/src/vws/exceptions/cloud_reco_exceptions.py b/src/vws/exceptions/cloud_reco_exceptions.py index 625f91c1d..ef5ab3218 100644 --- a/src/vws/exceptions/cloud_reco_exceptions.py +++ b/src/vws/exceptions/cloud_reco_exceptions.py @@ -2,7 +2,6 @@ Exceptions which match errors raised by the Vuforia Cloud Recognition Web APIs. """ - from vws.exceptions.base_exceptions import CloudRecoException diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index dfc0cf575..5a1868b5a 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -4,7 +4,6 @@ or simple errors given by the cloud recognition service. """ - from .response import Response diff --git a/src/vws/include_target_data.py b/src/vws/include_target_data.py index bff82c926..0083ceeed 100644 --- a/src/vws/include_target_data.py +++ b/src/vws/include_target_data.py @@ -2,7 +2,6 @@ Tools for managing ``CloudRecoService.query``'s ``include_target_data``. """ - from enum import StrEnum, auto From 26b5d4246f52a1af69782991109a6e0c81009886 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 3 Mar 2024 08:22:35 +0000 Subject: [PATCH 0128/1003] Use HTTPMethod constants in more places --- src/vws/query.py | 4 ++-- src/vws/vws.py | 18 +++++++++--------- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/src/vws/query.py b/src/vws/query.py index ffeedfc12..8baaaa5a0 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -6,7 +6,7 @@ import datetime import json -from http import HTTPStatus +from http import HTTPMethod, HTTPStatus from typing import Any, BinaryIO from urllib.parse import urljoin @@ -116,7 +116,7 @@ def query( date = rfc_1123_date() request_path = "/v1/query" content, content_type_header = encode_multipart_formdata(fields=body) - method = "POST" + method = HTTPMethod.POST authorization_string = authorization_header( access_key=self._client_access_key, diff --git a/src/vws/vws.py b/src/vws/vws.py index 278f3a2b2..c99e7bef8 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -8,7 +8,7 @@ import json import time from datetime import date -from http import HTTPStatus +from http import HTTPMethod, HTTPStatus from typing import TYPE_CHECKING, BinaryIO from urllib.parse import urljoin @@ -306,7 +306,7 @@ def add_target( content = bytes(json.dumps(data), encoding="utf-8") response = self._make_request( - method="POST", + method=HTTPMethod.POST, content=content, request_path="/targets", expected_result_code="TargetCreated", @@ -343,7 +343,7 @@ def get_target_record(self, target_id: str) -> TargetStatusAndRecord: limiting access. """ response = self._make_request( - method="GET", + method=HTTPMethod.GET, content=b"", request_path=f"/targets/{target_id}", expected_result_code="Success", @@ -439,7 +439,7 @@ def list_targets(self) -> list[str]: limiting access. """ response = self._make_request( - method="GET", + method=HTTPMethod.GET, content=b"", request_path="/targets", expected_result_code="Success", @@ -476,7 +476,7 @@ def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: limiting access. """ response = self._make_request( - method="GET", + method=HTTPMethod.GET, content=b"", request_path=f"/summary/{target_id}", expected_result_code="Success", @@ -519,7 +519,7 @@ def get_database_summary_report(self) -> DatabaseSummaryReport: limiting access. """ response = self._make_request( - method="GET", + method=HTTPMethod.GET, content=b"", request_path="/summary", expected_result_code="Success", @@ -569,7 +569,7 @@ def delete_target(self, target_id: str) -> None: limiting access. """ self._make_request( - method="DELETE", + method=HTTPMethod.DELETE, content=b"", request_path=f"/targets/{target_id}", expected_result_code="Success", @@ -606,7 +606,7 @@ def get_duplicate_targets(self, target_id: str) -> list[str]: limiting access. """ response = self._make_request( - method="GET", + method=HTTPMethod.GET, content=b"", request_path=f"/duplicates/{target_id}", expected_result_code="Success", @@ -690,7 +690,7 @@ def update_target( content = bytes(json.dumps(data), encoding="utf-8") self._make_request( - method="PUT", + method=HTTPMethod.PUT, content=content, request_path=f"/targets/{target_id}", expected_result_code="Success", From e541fd047c3acbd209102deeceb1f02321b6a94b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 3 Mar 2024 10:16:01 +0000 Subject: [PATCH 0129/1003] Use new uv --system flag for simpler GitHub Actions --- .github/workflows/ci.yml | 6 +----- .github/workflows/windows-ci.yml | 5 +---- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2024ed932..2a1fd129d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -33,18 +33,14 @@ jobs: - name: "Install dependencies" run: | curl -LsSf https://astral.sh/uv/install.sh | sh - uv venv /home/runner/.venv - source /home/runner/.venv/bin/activate - uv pip install --upgrade --editable .[dev] + uv pip install --system --upgrade --editable .[dev] - name: "Lint" run: | - source /home/runner/.venv/bin/activate make lint - name: "Run tests" run: | - source /home/runner/.venv/bin/activate # We run tests against "." and not the tests directory as we test the README # and documentation. pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index a9ad24e79..16bf4706a 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -33,13 +33,10 @@ jobs: - name: "Install dependencies" run: | irm https://astral.sh/uv/install.ps1 | iex - uv venv C:/Users/runner/.venv - C:/Users/runner/.venv/Scripts/Activate.ps1 - uv pip install --upgrade --editable .[dev] + uv pip install --system --upgrade --editable .[dev] - name: "Run tests" run: | - C:/Users/runner/.venv/Scripts/Activate.ps1 # We run tests against "." and not the tests directory as we test the README # and documentation. python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 61da3e24f7f51119794623232741bf060295f122 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Mar 2024 10:41:18 +0000 Subject: [PATCH 0130/1003] Bump pytest from 8.0.2 to 8.1.0 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.0.2 to 8.1.0. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.0.2...8.1.0) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1b8395a19..910a58190 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -267,7 +267,7 @@ dev = [ "pyproject-fmt==1.7.0", "pyright==1.1.352", "pyroma==4.2", - "pytest==8.0.2", + "pytest==8.1.0", "pytest-cov==4.1", "PyYAML==6.0.1", "ruff==0.3.0", From 2bdb3d8f4ef2cb4d015698c1b17a7960001d3655 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 5 Mar 2024 12:16:26 +0000 Subject: [PATCH 0131/1003] Revert "Bump pytest from 8.0.2 to 8.1.0" --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 910a58190..1b8395a19 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -267,7 +267,7 @@ dev = [ "pyproject-fmt==1.7.0", "pyright==1.1.352", "pyroma==4.2", - "pytest==8.1.0", + "pytest==8.0.2", "pytest-cov==4.1", "PyYAML==6.0.1", "ruff==0.3.0", From 503d58d5089105812b6f4e6e92545121726a1ead Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 5 Mar 2024 12:23:49 +0000 Subject: [PATCH 0132/1003] Bump uv from 0.1.13 to 0.1.14 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.13 to 0.1.14. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.13...0.1.14) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1b8395a19..59ce73b8a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240218", - "uv==0.1.13", + "uv==0.1.14", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From ca5dca748b7fdfe371a5851223500d5c764a8729 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 6 Mar 2024 10:55:16 +0000 Subject: [PATCH 0133/1003] Bump uv from 0.1.14 to 0.1.15 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.14 to 0.1.15. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.14...0.1.15) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 59ce73b8a..8ba07c0b4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240218", - "uv==0.1.14", + "uv==0.1.15", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From 50b13972d709f55d00ea94f84a6317d0afbe8958 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 7 Mar 2024 10:36:13 +0000 Subject: [PATCH 0134/1003] Bump ruff from 0.3.0 to 0.3.1 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.3.0 to 0.3.1. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.3.0...v0.3.1) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8ba07c0b4..772a6739d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -270,7 +270,7 @@ dev = [ "pytest==8.0.2", "pytest-cov==4.1", "PyYAML==6.0.1", - "ruff==0.3.0", + "ruff==0.3.1", "Sphinx==7.2.6", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", From e8691657fd019ed9d055653e5a4974ad5aea9439 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 8 Mar 2024 10:23:32 +0000 Subject: [PATCH 0135/1003] Bump pyright from 1.1.352 to 1.1.353 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.352 to 1.1.353. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.352...v1.1.353) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 772a6739d..61a2da9d4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -265,7 +265,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.1.0", "pyproject-fmt==1.7.0", - "pyright==1.1.352", + "pyright==1.1.353", "pyroma==4.2", "pytest==8.0.2", "pytest-cov==4.1", From cdd29d2a663f80dd995c11bdd990602b01fba8a7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 8 Mar 2024 10:28:11 +0000 Subject: [PATCH 0136/1003] Bump uv from 0.1.15 to 0.1.16 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.15 to 0.1.16. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.15...0.1.16) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 61a2da9d4..f7c30204e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240218", - "uv==0.1.15", + "uv==0.1.16", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From d6bd5410e97fcf3baf295b12a8a6b2f8d247bf2d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Mar 2024 10:49:05 +0000 Subject: [PATCH 0137/1003] Bump types-requests from 2.31.0.20240218 to 2.31.0.20240311 Bumps [types-requests](https://github.com/python/typeshed) from 2.31.0.20240218 to 2.31.0.20240311. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f7c30204e..7dd531f89 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -276,7 +276,7 @@ dev = [ "Sphinx-Substitution-Extensions==2024.2.25", "sphinxcontrib-spelling==8", "sybil==6.0.3", - "types-requests==2.31.0.20240218", + "types-requests==2.31.0.20240311", "uv==0.1.16", "vulture==2.11", "VWS-Python-Mock==2024.2.16", From 3e658f648943ca9ed2295b5c721ad6c0c3bd3c29 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Mar 2024 10:53:38 +0000 Subject: [PATCH 0138/1003] Bump mypy from 1.8.0 to 1.9.0 Bumps [mypy](https://github.com/python/mypy) from 1.8.0 to 1.9.0. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.8.0...1.9.0) --- updated-dependencies: - dependency-name: mypy dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7dd531f89..e3ce6ff6f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -259,7 +259,7 @@ dev = [ "doc8==1.1.1", "freezegun==1.4.0", "furo==2024.1.29", - "mypy==1.8.0", + "mypy==1.9.0", "pydocstyle==6.3", "pyenchant==3.2.2", "Pygments==2.17.2", From 2a69b9db7b089109661ec8a78908bde24c1e4daf Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Mar 2024 10:58:11 +0000 Subject: [PATCH 0139/1003] Bump ruff from 0.3.1 to 0.3.2 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.3.1 to 0.3.2. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.3.1...v0.3.2) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e3ce6ff6f..2134c2218 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -270,7 +270,7 @@ dev = [ "pytest==8.0.2", "pytest-cov==4.1", "PyYAML==6.0.1", - "ruff==0.3.1", + "ruff==0.3.2", "Sphinx==7.2.6", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", From 75f36cef8ed83f1bb5eacf220077795c305de3a1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Mar 2024 11:01:57 +0000 Subject: [PATCH 0140/1003] Bump mathieudutour/github-tag-action from 6.1 to 6.2 Bumps [mathieudutour/github-tag-action](https://github.com/mathieudutour/github-tag-action) from 6.1 to 6.2. - [Release notes](https://github.com/mathieudutour/github-tag-action/releases) - [Commits](https://github.com/mathieudutour/github-tag-action/compare/v6.1...v6.2) --- updated-dependencies: - dependency-name: mathieudutour/github-tag-action dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 80877b4bd..3f9a139a9 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -62,7 +62,7 @@ jobs: - name: Bump version and push tag id: tag_version - uses: mathieudutour/github-tag-action@v6.1 + uses: mathieudutour/github-tag-action@v6.2 with: github_token: ${{ secrets.GITHUB_TOKEN }} custom_tag: ${{ steps.calver.outputs.release }} From 6649b96bdf54986e92a478a5a4b25b2511972bd3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Mar 2024 11:02:52 +0000 Subject: [PATCH 0141/1003] Bump pytest from 8.0.2 to 8.1.1 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.0.2 to 8.1.1. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.0.2...8.1.1) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2134c2218..e06729275 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -267,7 +267,7 @@ dev = [ "pyproject-fmt==1.7.0", "pyright==1.1.353", "pyroma==4.2", - "pytest==8.0.2", + "pytest==8.1.1", "pytest-cov==4.1", "PyYAML==6.0.1", "ruff==0.3.2", From bca90b688123a4824dbe3a134cd64664ec4f3f2d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Mar 2024 11:07:33 +0000 Subject: [PATCH 0142/1003] Bump uv from 0.1.16 to 0.1.17 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.16 to 0.1.17. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.16...0.1.17) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e06729275..78d124c36 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240311", - "uv==0.1.16", + "uv==0.1.17", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From 577d560e8c27a5e373bb01ab8eb64d55869e9bb3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 13 Mar 2024 11:02:25 +0000 Subject: [PATCH 0143/1003] Bump uv from 0.1.17 to 0.1.18 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.17 to 0.1.18. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.17...0.1.18) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 78d124c36..1e4b48ae2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240311", - "uv==0.1.17", + "uv==0.1.18", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From c5ac9d56f23c468062defeb13a5d93ed1b7ba94b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 13 Mar 2024 11:06:57 +0000 Subject: [PATCH 0144/1003] Bump deptry from 0.12.0 to 0.13.0 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.12.0 to 0.13.0. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.12.0...0.13.0) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1e4b48ae2..1d5d4f3f8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -255,7 +255,7 @@ dependencies = [ dev = [ "actionlint-py==1.6.26.11", "check-manifest==0.49", - "deptry==0.12.0", + "deptry==0.13.0", "doc8==1.1.1", "freezegun==1.4.0", "furo==2024.1.29", From cc2ab1ff134bf8f32ac9280104b5347a52e9a795 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 14 Mar 2024 10:35:34 +0000 Subject: [PATCH 0145/1003] Bump pyright from 1.1.353 to 1.1.354 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.353 to 1.1.354. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.353...v1.1.354) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1d5d4f3f8..41c9e95c1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -265,7 +265,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.1.0", "pyproject-fmt==1.7.0", - "pyright==1.1.353", + "pyright==1.1.354", "pyroma==4.2", "pytest==8.1.1", "pytest-cov==4.1", From 23a52f5c7d6ab950ae6e14aa0f89446017ea98b4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 14 Mar 2024 10:40:14 +0000 Subject: [PATCH 0146/1003] Bump uv from 0.1.18 to 0.1.20 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.18 to 0.1.20. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.18...0.1.20) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 41c9e95c1..a711e3a0f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240311", - "uv==0.1.18", + "uv==0.1.20", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From be3263ecdd1037a9502b61f1e50d7b157e6e57ed Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 15 Mar 2024 10:38:35 +0000 Subject: [PATCH 0147/1003] Bump deptry from 0.13.0 to 0.14.0 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.13.0 to 0.14.0. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.13.0...0.14.0) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a711e3a0f..af632811f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -255,7 +255,7 @@ dependencies = [ dev = [ "actionlint-py==1.6.26.11", "check-manifest==0.49", - "deptry==0.13.0", + "deptry==0.14.0", "doc8==1.1.1", "freezegun==1.4.0", "furo==2024.1.29", From 4150fbc3cc10efc8f5febb046cf735c737635c19 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 15 Mar 2024 10:43:38 +0000 Subject: [PATCH 0148/1003] Bump uv from 0.1.20 to 0.1.21 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.20 to 0.1.21. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.20...0.1.21) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index af632811f..df86ce135 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240311", - "uv==0.1.20", + "uv==0.1.21", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From c887f9de66a4977cad06ca63c8b3f50734e111ba Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Mar 2024 10:33:53 +0000 Subject: [PATCH 0149/1003] Bump ruff from 0.3.2 to 0.3.3 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.3.2 to 0.3.3. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.3.2...v0.3.3) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index df86ce135..86b76b07b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -270,7 +270,7 @@ dev = [ "pytest==8.1.1", "pytest-cov==4.1", "PyYAML==6.0.1", - "ruff==0.3.2", + "ruff==0.3.3", "Sphinx==7.2.6", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", From 2e30602a7d7f5d018f08c48db647c3f33270d9c8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Mar 2024 10:59:47 +0000 Subject: [PATCH 0150/1003] Bump deptry from 0.14.0 to 0.14.2 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.14.0 to 0.14.2. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/0.14.2/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.14.0...0.14.2) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 86b76b07b..77349ca15 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -255,7 +255,7 @@ dependencies = [ dev = [ "actionlint-py==1.6.26.11", "check-manifest==0.49", - "deptry==0.14.0", + "deptry==0.14.2", "doc8==1.1.1", "freezegun==1.4.0", "furo==2024.1.29", From bd9d4f25ddb20d40eef4bc7161d6b0a5a3b4edfa Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 19 Mar 2024 11:06:03 +0000 Subject: [PATCH 0151/1003] Bump uv from 0.1.21 to 0.1.22 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.21 to 0.1.22. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.21...0.1.22) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 77349ca15..228c5c670 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240311", - "uv==0.1.21", + "uv==0.1.22", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From 1f077e9d2b46d838dd746f9c3a606ff36b8b17bf Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 20 Mar 2024 11:00:18 +0000 Subject: [PATCH 0152/1003] Bump pyright from 1.1.354 to 1.1.355 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.354 to 1.1.355. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.354...v1.1.355) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 228c5c670..4e6d9b9ba 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -265,7 +265,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.1.0", "pyproject-fmt==1.7.0", - "pyright==1.1.354", + "pyright==1.1.355", "pyroma==4.2", "pytest==8.1.1", "pytest-cov==4.1", From 2e8e8380c2e5be42b652af497551f00ad1088776 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 21 Mar 2024 10:10:44 +0000 Subject: [PATCH 0153/1003] Bump actionlint-py from 1.6.26.11 to 1.6.27.12 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.6.26.11 to 1.6.27.12. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.6.26.11...v1.6.27.12) --- updated-dependencies: - dependency-name: actionlint-py dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4e6d9b9ba..53d13c662 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -253,7 +253,7 @@ dependencies = [ ] [project.optional-dependencies] dev = [ - "actionlint-py==1.6.26.11", + "actionlint-py==1.6.27.12", "check-manifest==0.49", "deptry==0.14.2", "doc8==1.1.1", From 44ee48bac4ba62a6ce883a56591070ae4f452db3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 21 Mar 2024 10:15:36 +0000 Subject: [PATCH 0154/1003] Bump uv from 0.1.22 to 0.1.23 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.22 to 0.1.23. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.22...0.1.23) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 53d13c662..593a08860 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240311", - "uv==0.1.22", + "uv==0.1.23", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From 3ba003468a755725027dafc3ae7d3f8ce9ce755a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 22 Mar 2024 10:34:46 +0000 Subject: [PATCH 0155/1003] Bump dependabot/fetch-metadata from 1 to 2 Bumps [dependabot/fetch-metadata](https://github.com/dependabot/fetch-metadata) from 1 to 2. - [Release notes](https://github.com/dependabot/fetch-metadata/releases) - [Commits](https://github.com/dependabot/fetch-metadata/compare/v1...v2) --- updated-dependencies: - dependency-name: dependabot/fetch-metadata dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/dependabot-merge.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/dependabot-merge.yml b/.github/workflows/dependabot-merge.yml index 0f484eebe..1c75ca282 100644 --- a/.github/workflows/dependabot-merge.yml +++ b/.github/workflows/dependabot-merge.yml @@ -14,7 +14,7 @@ jobs: steps: - name: Dependabot metadata id: metadata - uses: dependabot/fetch-metadata@v1 + uses: dependabot/fetch-metadata@v2 with: github-token: "${{ secrets.GITHUB_TOKEN }}" - name: Enable auto-merge for Dependabot PRs From 67b983eb14b104cb60a88e2cdef16102a9bcd0ce Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 22 Mar 2024 11:05:23 +0000 Subject: [PATCH 0156/1003] Bump ruff from 0.3.3 to 0.3.4 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.3.3 to 0.3.4. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.3.3...v0.3.4) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 593a08860..6ecd90137 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -270,7 +270,7 @@ dev = [ "pytest==8.1.1", "pytest-cov==4.1", "PyYAML==6.0.1", - "ruff==0.3.3", + "ruff==0.3.4", "Sphinx==7.2.6", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", From ede86fa791ea634b06fb3f6d4d6a9a493246414b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 25 Mar 2024 10:06:26 +0000 Subject: [PATCH 0157/1003] Bump deptry from 0.14.2 to 0.15.0 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.14.2 to 0.15.0. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.14.2...0.15.0) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6ecd90137..c7c94acd5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -255,7 +255,7 @@ dependencies = [ dev = [ "actionlint-py==1.6.27.12", "check-manifest==0.49", - "deptry==0.14.2", + "deptry==0.15.0", "doc8==1.1.1", "freezegun==1.4.0", "furo==2024.1.29", From fcc5d12bc1d0caa7c54cf3daf5a60f17355c595f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 25 Mar 2024 10:10:48 +0000 Subject: [PATCH 0158/1003] Bump pytest-cov from 4.1 to 5.0.0 Bumps [pytest-cov](https://github.com/pytest-dev/pytest-cov) from 4.1 to 5.0.0. - [Changelog](https://github.com/pytest-dev/pytest-cov/blob/master/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest-cov/compare/v4.1.0...v5.0.0) --- updated-dependencies: - dependency-name: pytest-cov dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c7c94acd5..a2360a4b6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -268,7 +268,7 @@ dev = [ "pyright==1.1.355", "pyroma==4.2", "pytest==8.1.1", - "pytest-cov==4.1", + "pytest-cov==5.0.0", "PyYAML==6.0.1", "ruff==0.3.4", "Sphinx==7.2.6", From 497fd8ac3454ee6e27a86b157c3431152b79f1e1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 25 Mar 2024 10:19:06 +0000 Subject: [PATCH 0159/1003] Bump uv from 0.1.23 to 0.1.24 Bumps [uv](https://github.com/astral-sh/uv) from 0.1.23 to 0.1.24. - [Release notes](https://github.com/astral-sh/uv/releases) - [Changelog](https://github.com/astral-sh/uv/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/uv/compare/0.1.23...0.1.24) --- updated-dependencies: - dependency-name: uv dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a2360a4b6..c3d1e3a34 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240311", - "uv==0.1.23", + "uv==0.1.24", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From 2d127d0b8fd88d7c43da84ed7f02ee1fb4ee462e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 26 Mar 2024 10:29:58 +0000 Subject: [PATCH 0160/1003] Simplify deptry setup by using new pep621_dev_dependency_groups option --- lint.mk | 5 +---- pyproject.toml | 4 +++- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/lint.mk b/lint.mk index f4d98eab8..90f69bc62 100644 --- a/lint.mk +++ b/lint.mk @@ -32,10 +32,7 @@ TEMPFILE:= $(shell mktemp) .PHONY: deptry deptry: - uv pip compile --no-deps pyproject.toml > $(TEMPFILE) - mv pyproject.toml pyproject.bak.toml - deptry --requirements-txt=$(TEMPFILE) src/ || (mv pyproject.bak.toml pyproject.toml && exit 1) - mv pyproject.bak.toml pyproject.toml + deptry src/ .PHONY: pylint pylint: diff --git a/pyproject.toml b/pyproject.toml index c3d1e3a34..a8a218900 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,6 @@ dev = [ "sphinxcontrib-spelling==8", "sybil==6.0.3", "types-requests==2.31.0.20240311", - "uv==0.1.24", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", @@ -305,3 +304,6 @@ keep_full_version = true reportUnnecessaryTypeIgnoreComment = true typeCheckingMode = "strict" + +[tool.deptry] +pep621_dev_dependency_groups = ["dev"] From b532172bc81519411663aabcac082f9baaf7c046 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 27 Mar 2024 10:59:39 +0000 Subject: [PATCH 0161/1003] Bump pyright from 1.1.355 to 1.1.356 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.355 to 1.1.356. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.355...v1.1.356) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a8a218900..1411d2cd8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -265,7 +265,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.1.0", "pyproject-fmt==1.7.0", - "pyright==1.1.355", + "pyright==1.1.356", "pyroma==4.2", "pytest==8.1.1", "pytest-cov==5.0.0", From c3e69ce62def5b21c3686b2d42ded047c6f10dd7 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 30 Mar 2024 06:14:12 +0000 Subject: [PATCH 0162/1003] Check wheel contents after creation --- .github/workflows/release.yml | 1 + lint.mk | 2 -- pyproject.toml | 1 + 3 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3f9a139a9..2d92b7124 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -83,6 +83,7 @@ jobs: git checkout "$(git describe --tags "$(git rev-list --tags --max-count=1)")" python -m pip install build python -m build --sdist --wheel --outdir dist/ . + check-wheel-contents dist/*.whl # We use PyPI trusted publishing rather than a PyPI API token. # See https://github.com/pypa/gh-action-pypi-publish/tree/release/v1/?tab=readme-ov-file#trusted-publishing. diff --git a/lint.mk b/lint.mk index 90f69bc62..afd33149f 100644 --- a/lint.mk +++ b/lint.mk @@ -28,8 +28,6 @@ fix-ruff: ruff check --fix . ruff format . -TEMPFILE:= $(shell mktemp) - .PHONY: deptry deptry: deptry src/ diff --git a/pyproject.toml b/pyproject.toml index a8a218900..a7ee2b519 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -255,6 +255,7 @@ dependencies = [ dev = [ "actionlint-py==1.6.27.12", "check-manifest==0.49", + "check-wheel-contents==0.6.0", "deptry==0.15.0", "doc8==1.1.1", "freezegun==1.4.0", From 528bd5cfc825b16759a5219981d54f20acd734b3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 2 Apr 2024 10:33:17 +0000 Subject: [PATCH 0163/1003] Bump ruff from 0.3.4 to 0.3.5 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.3.4 to 0.3.5. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.3.4...v0.3.5) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a4a8fcddc..bfb0fa66b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -271,7 +271,7 @@ dev = [ "pytest==8.1.1", "pytest-cov==5.0.0", "PyYAML==6.0.1", - "ruff==0.3.4", + "ruff==0.3.5", "Sphinx==7.2.6", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", From 0ecb22b6441cc59a00861a00a46d9d81df0927f0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 2 Apr 2024 10:38:10 +0000 Subject: [PATCH 0164/1003] Bump types-requests from 2.31.0.20240311 to 2.31.0.20240402 Bumps [types-requests](https://github.com/python/typeshed) from 2.31.0.20240311 to 2.31.0.20240402. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index bfb0fa66b..4755bde34 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "Sphinx-Substitution-Extensions==2024.2.25", "sphinxcontrib-spelling==8", "sybil==6.0.3", - "types-requests==2.31.0.20240311", + "types-requests==2.31.0.20240402", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From 7c9cb7d8254b1af5a83c78c5f95064d66732dac8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 3 Apr 2024 10:18:29 +0000 Subject: [PATCH 0165/1003] Bump types-requests from 2.31.0.20240402 to 2.31.0.20240403 Bumps [types-requests](https://github.com/python/typeshed) from 2.31.0.20240402 to 2.31.0.20240403. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4755bde34..ae33c9580 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "Sphinx-Substitution-Extensions==2024.2.25", "sphinxcontrib-spelling==8", "sybil==6.0.3", - "types-requests==2.31.0.20240402", + "types-requests==2.31.0.20240403", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From b24d800de702c59b87396de82fa7d5d5aae8d9d4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 4 Apr 2024 10:50:01 +0000 Subject: [PATCH 0166/1003] Bump pyright from 1.1.356 to 1.1.357 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.356 to 1.1.357. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.356...v1.1.357) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ae33c9580..9502aec05 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -266,7 +266,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.1.0", "pyproject-fmt==1.7.0", - "pyright==1.1.356", + "pyright==1.1.357", "pyroma==4.2", "pytest==8.1.1", "pytest-cov==5.0.0", From 8f6993236c7732743f9d39d92ef2c4634dd51e09 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 5 Apr 2024 10:59:29 +0000 Subject: [PATCH 0167/1003] Bump deptry from 0.15.0 to 0.16.0 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.15.0 to 0.16.0. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.15.0...0.16.0) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9502aec05..ace926272 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -256,7 +256,7 @@ dev = [ "actionlint-py==1.6.27.12", "check-manifest==0.49", "check-wheel-contents==0.6.0", - "deptry==0.15.0", + "deptry==0.16.0", "doc8==1.1.1", "freezegun==1.4.0", "furo==2024.1.29", From e8eae1082ece4519d49bd9a25dab6af3d14a0e2d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Apr 2024 10:57:34 +0000 Subject: [PATCH 0168/1003] Bump actionlint-py from 1.6.27.12 to 1.6.27.13 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.6.27.12 to 1.6.27.13. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.6.27.12...v1.6.27.13) --- updated-dependencies: - dependency-name: actionlint-py dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ace926272..7801de827 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -253,7 +253,7 @@ dependencies = [ ] [project.optional-dependencies] dev = [ - "actionlint-py==1.6.27.12", + "actionlint-py==1.6.27.13", "check-manifest==0.49", "check-wheel-contents==0.6.0", "deptry==0.16.0", From ec599db87ff975d9d31b25dbf323fd21af311867 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Apr 2024 11:02:07 +0000 Subject: [PATCH 0169/1003] Bump types-requests from 2.31.0.20240403 to 2.31.0.20240406 Bumps [types-requests](https://github.com/python/typeshed) from 2.31.0.20240403 to 2.31.0.20240406. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7801de827..47c41555a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -277,7 +277,7 @@ dev = [ "Sphinx-Substitution-Extensions==2024.2.25", "sphinxcontrib-spelling==8", "sybil==6.0.3", - "types-requests==2.31.0.20240403", + "types-requests==2.31.0.20240406", "vulture==2.11", "VWS-Python-Mock==2024.2.16", "VWS-Test-Fixtures==2023.3.5", From 6dd51c2fbad2f9e9233d4471c6528a16b04bcfea Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Apr 2024 11:06:52 +0000 Subject: [PATCH 0170/1003] Bump deptry from 0.16.0 to 0.16.1 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.16.0 to 0.16.1. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.16.0...0.16.1) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 47c41555a..55d77f556 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -256,7 +256,7 @@ dev = [ "actionlint-py==1.6.27.13", "check-manifest==0.49", "check-wheel-contents==0.6.0", - "deptry==0.16.0", + "deptry==0.16.1", "doc8==1.1.1", "freezegun==1.4.0", "furo==2024.1.29", From ff81b735ff56cf786e85e61e1c916cac65d43de5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 11 Apr 2024 10:25:24 +0000 Subject: [PATCH 0171/1003] Bump pyright from 1.1.357 to 1.1.358 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.357 to 1.1.358. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.357...v1.1.358) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 55d77f556..058268710 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -266,7 +266,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.1.0", "pyproject-fmt==1.7.0", - "pyright==1.1.357", + "pyright==1.1.358", "pyroma==4.2", "pytest==8.1.1", "pytest-cov==5.0.0", From fc8dd66dd0c89e93ee0854511ffe44b526078b8f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 12 Apr 2024 10:11:56 +0000 Subject: [PATCH 0172/1003] Bump ruff from 0.3.5 to 0.3.7 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.3.5 to 0.3.7. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.3.5...v0.3.7) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 058268710..a2c7ff437 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -271,7 +271,7 @@ dev = [ "pytest==8.1.1", "pytest-cov==5.0.0", "PyYAML==6.0.1", - "ruff==0.3.5", + "ruff==0.3.7", "Sphinx==7.2.6", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", From 8c753b5fde3fc6faf2fa95a8a594c5fa3f1b848e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 17 Apr 2024 10:29:05 +0000 Subject: [PATCH 0173/1003] Bump sphinx from 7.2.6 to 7.3.5 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 7.2.6 to 7.3.5. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v7.2.6...v7.3.5) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a2c7ff437..006b32c52 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -272,7 +272,7 @@ dev = [ "pytest-cov==5.0.0", "PyYAML==6.0.1", "ruff==0.3.7", - "Sphinx==7.2.6", + "Sphinx==7.3.5", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", "sphinxcontrib-spelling==8", From cf35345e1c6182000bcc1027f746b1f6ec518c61 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 18 Apr 2024 10:28:52 +0000 Subject: [PATCH 0174/1003] Bump sphinx from 7.3.5 to 7.3.6 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 7.3.5 to 7.3.6. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v7.3.5...v7.3.6) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 006b32c52..4c3835aa7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -272,7 +272,7 @@ dev = [ "pytest-cov==5.0.0", "PyYAML==6.0.1", "ruff==0.3.7", - "Sphinx==7.3.5", + "Sphinx==7.3.6", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", "sphinxcontrib-spelling==8", From 20f974ab9b497aaf79db6851bda3449b32916444 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 18 Apr 2024 10:33:33 +0000 Subject: [PATCH 0175/1003] Bump pyproject-fmt from 1.7.0 to 1.8.0 Bumps [pyproject-fmt](https://github.com/tox-dev/pyproject-fmt) from 1.7.0 to 1.8.0. - [Release notes](https://github.com/tox-dev/pyproject-fmt/releases) - [Commits](https://github.com/tox-dev/pyproject-fmt/compare/1.7.0...1.8.0) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4c3835aa7..3538eb580 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -265,7 +265,7 @@ dev = [ "pyenchant==3.2.2", "Pygments==2.17.2", "pylint==3.1.0", - "pyproject-fmt==1.7.0", + "pyproject-fmt==1.8.0", "pyright==1.1.358", "pyroma==4.2", "pytest==8.1.1", From c517f8d5f202d2f9f92242849fca1b23ab8146f3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 18 Apr 2024 10:38:16 +0000 Subject: [PATCH 0176/1003] Bump pyright from 1.1.358 to 1.1.359 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.358 to 1.1.359. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.358...v1.1.359) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3538eb580..17dbd5c6a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -266,7 +266,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.1.0", "pyproject-fmt==1.8.0", - "pyright==1.1.358", + "pyright==1.1.359", "pyroma==4.2", "pytest==8.1.1", "pytest-cov==5.0.0", From ae5073448000ec3a98c3eae3554278250ea26da4 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 19 Apr 2024 11:22:38 +0100 Subject: [PATCH 0177/1003] Enforce Google style docstrings with ruff --- pyproject.toml | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 17dbd5c6a..1869814cf 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -187,17 +187,9 @@ ignore = [ "COM812", # Allow our chosen docstring line-style - no one-line summary. "D200", - "D203", "D205", "D212", - "D213", - # It is too much work to make every docstring imperative. - "D401", - # We ignore some docstyle errors which do not apply to Google style - # docstrings. - "D406", - "D407", - "D413", + "D415", # Ruff warns that this conflicts with the formatter. "ISC001", # We have an existing interface to support and so we do not want to change @@ -217,6 +209,9 @@ ignore = [ # is sometimes annoyingly removed. unfixable = ["ERA001"] +[tool.ruff.lint.pydocstyle] +convention = "google" + [tool.ruff.lint.per-file-ignores] "tests/test_*.py" = [ # Do not require tests to have a one-line summary. From f400cc251c4bcde7baa47cb4499087f9b72c0204 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 19 Apr 2024 10:50:00 +0000 Subject: [PATCH 0178/1003] Bump sphinx from 7.3.6 to 7.3.7 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 7.3.6 to 7.3.7. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v7.3.6...v7.3.7) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1869814cf..0d2d9ebe7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -267,7 +267,7 @@ dev = [ "pytest-cov==5.0.0", "PyYAML==6.0.1", "ruff==0.3.7", - "Sphinx==7.3.6", + "Sphinx==7.3.7", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", "sphinxcontrib-spelling==8", From d89582204c811b3b38b03c1db84bf13502433c1b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 19 Apr 2024 10:55:15 +0000 Subject: [PATCH 0179/1003] Bump ruff from 0.3.7 to 0.4.0 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.3.7 to 0.4.0. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.3.7...v0.4.0) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0d2d9ebe7..1fef38a8c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -266,7 +266,7 @@ dev = [ "pytest==8.1.1", "pytest-cov==5.0.0", "PyYAML==6.0.1", - "ruff==0.3.7", + "ruff==0.4.0", "Sphinx==7.3.7", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", From 19b6bbf7de26c749e11102f9c87b6a75d4c751fa Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 19 Apr 2024 13:26:42 +0100 Subject: [PATCH 0180/1003] Check for and resolve Ruff S311 --- pyproject.toml | 2 -- tests/test_vws.py | 6 +++--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 1fef38a8c..261358721 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -200,8 +200,6 @@ ignore = [ "PLR0913", # Allow 'assert' as we use it for tests. "S101", - # Allow simple random numbers as we are not using them for cryptography. - "S311", ] # Do not automatically remove commented out code. diff --git a/tests/test_vws.py b/tests/test_vws.py index 7c148cf29..b49cc42a1 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -6,7 +6,7 @@ import base64 import datetime -import random +import secrets import uuid from typing import TYPE_CHECKING, BinaryIO @@ -506,7 +506,7 @@ def test_update_target( It is possible to update a target. """ old_name = uuid.uuid4().hex - old_width = random.uniform(a=0.01, b=50) + old_width = secrets.choice(seq=range(1, 5000)) / 100 target_id = vws_client.add_target( name=old_name, width=old_width, @@ -523,7 +523,7 @@ def test_update_target( assert query_metadata is None new_name = uuid.uuid4().hex - new_width = random.uniform(a=0.01, b=50) + new_width = secrets.choice(seq=range(1, 5000)) / 100 new_application_metadata = base64.b64encode(b"a").decode("ascii") vws_client.update_target( target_id=target_id, From 5714d894de3ce6b75ba42d07634d0a70c299b7c8 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 19 Apr 2024 13:37:38 +0100 Subject: [PATCH 0181/1003] Check for and resolve Ruff N818 --- CHANGELOG.rst | 2 + pyproject.toml | 3 - src/vws/exceptions/base_exceptions.py | 4 +- src/vws/exceptions/cloud_reco_exceptions.py | 12 +-- src/vws/exceptions/custom_exceptions.py | 6 +- src/vws/exceptions/vws_exceptions.py | 36 ++++---- src/vws/query.py | 52 ++++++------ src/vws/vws.py | 94 ++++++++++----------- tests/test_cloud_reco_exceptions.py | 34 ++++---- tests/test_vws.py | 4 +- tests/test_vws_exceptions.py | 94 +++++++++++---------- 11 files changed, 171 insertions(+), 170 deletions(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index ddd3ed91a..de5765df6 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,8 @@ Changelog Next ---- +* Breaking change: Exception names now end with ``Error``. + 2024.02.19 ------------ diff --git a/pyproject.toml b/pyproject.toml index 1fef38a8c..c4d7fa8a4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -192,9 +192,6 @@ ignore = [ "D415", # Ruff warns that this conflicts with the formatter. "ISC001", - # We have an existing interface to support and so we do not want to change - # exception names. - "N818", # Ignore "too-many-*" errors as they seem to get in the way more than # helping. "PLR0913", diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index 044c2b017..6558242c5 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -11,7 +11,7 @@ from .response import Response -class CloudRecoException(Exception): +class CloudRecoError(Exception): """ Base class for Vuforia Cloud Recognition Web API exceptions. """ @@ -32,7 +32,7 @@ def response(self) -> Response: return self._response -class VWSException(Exception): +class VWSError(Exception): """ Base class for Vuforia Web Services errors. diff --git a/src/vws/exceptions/cloud_reco_exceptions.py b/src/vws/exceptions/cloud_reco_exceptions.py index ef5ab3218..26c6fb097 100644 --- a/src/vws/exceptions/cloud_reco_exceptions.py +++ b/src/vws/exceptions/cloud_reco_exceptions.py @@ -2,38 +2,38 @@ Exceptions which match errors raised by the Vuforia Cloud Recognition Web APIs. """ -from vws.exceptions.base_exceptions import CloudRecoException +from vws.exceptions.base_exceptions import CloudRecoError -class MaxNumResultsOutOfRange(CloudRecoException): +class MaxNumResultsOutOfRangeError(CloudRecoError): """ Exception raised when the ``max_num_results`` given to the Cloud Recognition Web API query endpoint is out of range. """ -class InactiveProject(CloudRecoException): +class InactiveProjectError(CloudRecoError): """ Exception raised when Vuforia returns a response with a result code 'InactiveProject'. """ -class BadImage(CloudRecoException): +class BadImageError(CloudRecoError): """ Exception raised when Vuforia returns a response with a result code 'BadImage'. """ -class AuthenticationFailure(CloudRecoException): +class AuthenticationFailureError(CloudRecoError): """ Exception raised when Vuforia returns a response with a result code 'AuthenticationFailure'. """ -class RequestTimeTooSkewed(CloudRecoException): +class RequestTimeTooSkewedError(CloudRecoError): """ Exception raised when Vuforia returns a response with a result code 'RequestTimeTooSkewed'. diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index 5a1868b5a..1c7790cbf 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -7,7 +7,7 @@ from .response import Response -class OopsAnErrorOccurredPossiblyBadName(Exception): +class OopsAnErrorOccurredPossiblyBadNameError(Exception): """ Exception raised when VWS returns an HTML page which says "Oops, an error occurred". @@ -31,7 +31,7 @@ def response(self) -> Response: return self._response -class RequestEntityTooLarge(Exception): +class RequestEntityTooLargeError(Exception): """ Exception raised when the given image is too large. """ @@ -52,7 +52,7 @@ def response(self) -> Response: return self._response -class TargetProcessingTimeout(Exception): +class TargetProcessingTimeoutError(Exception): """ Exception raised when waiting for a target to be processed times out. """ diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index a43323380..9d00d7518 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -7,10 +7,10 @@ import json from urllib.parse import urlparse -from vws.exceptions.base_exceptions import VWSException +from vws.exceptions.base_exceptions import VWSError -class UnknownTarget(VWSException): +class UnknownTargetError(VWSError): """ Exception raised when Vuforia returns a response with a result code 'UnknownTarget'. @@ -27,21 +27,21 @@ def target_id(self) -> str: return path.split(sep="/", maxsplit=2)[-1] -class Fail(VWSException): +class FailError(VWSError): """ Exception raised when Vuforia returns a response with a result code 'Fail'. """ -class BadImage(VWSException): +class BadImageError(VWSError): """ Exception raised when Vuforia returns a response with a result code 'BadImage'. """ -class AuthenticationFailure(VWSException): +class AuthenticationFailureError(VWSError): """ Exception raised when Vuforia returns a response with a result code 'AuthenticationFailure'. @@ -49,14 +49,14 @@ class AuthenticationFailure(VWSException): # See https://github.com/VWS-Python/vws-python/issues/822. -class RequestQuotaReached(VWSException): # pragma: no cover +class RequestQuotaReachedError(VWSError): # pragma: no cover """ Exception raised when Vuforia returns a response with a result code 'RequestQuotaReached'. """ -class TargetStatusProcessing(VWSException): +class TargetStatusProcessingError(VWSError): """ Exception raised when Vuforia returns a response with a result code 'TargetStatusProcessing'. @@ -74,7 +74,7 @@ def target_id(self) -> str: # This is not simulated by the mock. -class DateRangeError(VWSException): # pragma: no cover +class DateRangeError(VWSError): # pragma: no cover """ Exception raised when Vuforia returns a response with a result code 'DateRangeError'. @@ -82,7 +82,7 @@ class DateRangeError(VWSException): # pragma: no cover # This is not simulated by the mock. -class TargetQuotaReached(VWSException): # pragma: no cover +class TargetQuotaReachedError(VWSError): # pragma: no cover """ Exception raised when Vuforia returns a response with a result code 'TargetQuotaReached'. @@ -90,7 +90,7 @@ class TargetQuotaReached(VWSException): # pragma: no cover # This is not simulated by the mock. -class ProjectSuspended(VWSException): # pragma: no cover +class ProjectSuspendedError(VWSError): # pragma: no cover """ Exception raised when Vuforia returns a response with a result code 'ProjectSuspended'. @@ -98,35 +98,35 @@ class ProjectSuspended(VWSException): # pragma: no cover # This is not simulated by the mock. -class ProjectHasNoAPIAccess(VWSException): # pragma: no cover +class ProjectHasNoAPIAccessError(VWSError): # pragma: no cover """ Exception raised when Vuforia returns a response with a result code 'ProjectHasNoAPIAccess'. """ -class ProjectInactive(VWSException): +class ProjectInactiveError(VWSError): """ Exception raised when Vuforia returns a response with a result code 'ProjectInactive'. """ -class MetadataTooLarge(VWSException): +class MetadataTooLargeError(VWSError): """ Exception raised when Vuforia returns a response with a result code 'MetadataTooLarge'. """ -class RequestTimeTooSkewed(VWSException): +class RequestTimeTooSkewedError(VWSError): """ Exception raised when Vuforia returns a response with a result code 'RequestTimeTooSkewed'. """ -class TargetNameExist(VWSException): +class TargetNameExistError(VWSError): """ Exception raised when Vuforia returns a response with a result code 'TargetNameExist'. @@ -142,14 +142,14 @@ def target_name(self) -> str: return str(request_json["name"]) -class ImageTooLarge(VWSException): +class ImageTooLargeError(VWSError): """ Exception raised when Vuforia returns a response with a result code 'ImageTooLarge'. """ -class TargetStatusNotSuccess(VWSException): +class TargetStatusNotSuccessError(VWSError): """ Exception raised when Vuforia returns a response with a result code 'TargetStatusNotSuccess'. @@ -166,7 +166,7 @@ def target_id(self) -> str: return path.split(sep="/", maxsplit=2)[-1] -class TooManyRequests(VWSException): # pragma: no cover +class TooManyRequestsError(VWSError): # pragma: no cover """ Exception raised when Vuforia returns a response with a result code 'TooManyRequests'. diff --git a/src/vws/query.py b/src/vws/query.py index 8baaaa5a0..ab04781da 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -15,14 +15,14 @@ from vws_auth_tools import authorization_header, rfc_1123_date from vws.exceptions.cloud_reco_exceptions import ( - AuthenticationFailure, - BadImage, - InactiveProject, - MaxNumResultsOutOfRange, - RequestTimeTooSkewed, + AuthenticationFailureError, + BadImageError, + InactiveProjectError, + MaxNumResultsOutOfRangeError, + RequestTimeTooSkewedError, ) from vws.exceptions.custom_exceptions import ( - RequestEntityTooLarge, + RequestEntityTooLargeError, ServerError, ) from vws.exceptions.response import Response @@ -84,21 +84,21 @@ def query( none (return no target_data), all (for all matched targets). Raises: - ~vws.exceptions.cloud_reco_exceptions.AuthenticationFailure: The - client access key pair is not correct. - ~vws.exceptions.cloud_reco_exceptions.MaxNumResultsOutOfRange: + ~vws.exceptions.cloud_reco_exceptions.AuthenticationFailureError: + The client access key pair is not correct. + ~vws.exceptions.cloud_reco_exceptions.MaxNumResultsOutOfRangeError: ``max_num_results`` is not within the range (1, 50). - ~vws.exceptions.cloud_reco_exceptions.InactiveProject: The project - is inactive. - ~vws.exceptions.cloud_reco_exceptions.RequestTimeTooSkewed: There - is an error with the time sent to Vuforia. - ~vws.exceptions.cloud_reco_exceptions.BadImage: There is a problem - with the given image. For example, it must be a JPEG or PNG - file in the grayscale or RGB color space. - ~vws.exceptions.custom_exceptions.RequestEntityTooLarge: The given - image is too large. - ~vws.exceptions.custom_exceptions.ServerError: There is an error - with Vuforia's servers. + ~vws.exceptions.cloud_reco_exceptions.InactiveProjectError: The + project is inactive. + ~vws.exceptions.cloud_reco_exceptions.RequestTimeTooSkewedError: + There is an error with the time sent to Vuforia. + ~vws.exceptions.cloud_reco_exceptions.BadImageError: There is a + problem with the given image. For example, it must be a JPEG or + PNG file in the grayscale or RGB color space. + ~vws.exceptions.custom_exceptions.RequestEntityTooLargeError: The + given image is too large. + ~vws.exceptions.custom_exceptions.ServerError: There is an + error with Vuforia's servers. Returns: An ordered list of target details of matching targets. @@ -152,10 +152,10 @@ def query( ) if response.status_code == HTTPStatus.REQUEST_ENTITY_TOO_LARGE: - raise RequestEntityTooLarge(response=response) + raise RequestEntityTooLargeError(response=response) if "Integer out of range" in response.text: - raise MaxNumResultsOutOfRange(response=response) + raise MaxNumResultsOutOfRangeError(response=response) if ( response.status_code >= HTTPStatus.INTERNAL_SERVER_ERROR @@ -165,10 +165,10 @@ def query( result_code = json.loads(s=response.text)["result_code"] if result_code != "Success": exception = { - "AuthenticationFailure": AuthenticationFailure, - "BadImage": BadImage, - "InactiveProject": InactiveProject, - "RequestTimeTooSkewed": RequestTimeTooSkewed, + "AuthenticationFailure": AuthenticationFailureError, + "BadImage": BadImageError, + "InactiveProject": InactiveProjectError, + "RequestTimeTooSkewed": RequestTimeTooSkewedError, }[result_code] raise exception(response=response) diff --git a/src/vws/vws.py b/src/vws/vws.py index c99e7bef8..082767780 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -16,28 +16,28 @@ from vws_auth_tools import authorization_header, rfc_1123_date from vws.exceptions.custom_exceptions import ( - OopsAnErrorOccurredPossiblyBadName, + OopsAnErrorOccurredPossiblyBadNameError, ServerError, - TargetProcessingTimeout, + TargetProcessingTimeoutError, ) from vws.exceptions.vws_exceptions import ( - AuthenticationFailure, - BadImage, + AuthenticationFailureError, + BadImageError, DateRangeError, - Fail, - ImageTooLarge, - MetadataTooLarge, - ProjectHasNoAPIAccess, - ProjectInactive, - ProjectSuspended, - RequestQuotaReached, - RequestTimeTooSkewed, - TargetNameExist, - TargetQuotaReached, - TargetStatusNotSuccess, - TargetStatusProcessing, - TooManyRequests, - UnknownTarget, + FailError, + ImageTooLargeError, + MetadataTooLargeError, + ProjectHasNoAPIAccessError, + ProjectInactiveError, + ProjectSuspendedError, + RequestQuotaReachedError, + RequestTimeTooSkewedError, + TargetNameExistError, + TargetQuotaReachedError, + TargetStatusNotSuccessError, + TargetStatusProcessingError, + TooManyRequestsError, + UnknownTargetError, ) from vws.reports import ( DatabaseSummaryReport, @@ -194,13 +194,13 @@ def _make_request( ) if "Oops, an error occurred" in response.text: - raise OopsAnErrorOccurredPossiblyBadName(response=response) + raise OopsAnErrorOccurredPossiblyBadNameError(response=response) if ( response.status_code == HTTPStatus.TOO_MANY_REQUESTS ): # pragma: no cover # The Vuforia API returns a 429 response with no JSON body. - raise TooManyRequests(response=response) + raise TooManyRequestsError(response=response) if ( response.status_code >= HTTPStatus.INTERNAL_SERVER_ERROR @@ -213,22 +213,22 @@ def _make_request( return response exception = { - "AuthenticationFailure": AuthenticationFailure, - "BadImage": BadImage, + "AuthenticationFailure": AuthenticationFailureError, + "BadImage": BadImageError, "DateRangeError": DateRangeError, - "Fail": Fail, - "ImageTooLarge": ImageTooLarge, - "MetadataTooLarge": MetadataTooLarge, - "ProjectHasNoAPIAccess": ProjectHasNoAPIAccess, - "ProjectInactive": ProjectInactive, - "ProjectSuspended": ProjectSuspended, - "RequestQuotaReached": RequestQuotaReached, - "RequestTimeTooSkewed": RequestTimeTooSkewed, - "TargetNameExist": TargetNameExist, - "TargetQuotaReached": TargetQuotaReached, - "TargetStatusNotSuccess": TargetStatusNotSuccess, - "TargetStatusProcessing": TargetStatusProcessing, - "UnknownTarget": UnknownTarget, + "Fail": FailError, + "ImageTooLarge": ImageTooLargeError, + "MetadataTooLarge": MetadataTooLargeError, + "ProjectHasNoAPIAccess": ProjectHasNoAPIAccessError, + "ProjectInactive": ProjectInactiveError, + "ProjectSuspended": ProjectSuspendedError, + "RequestQuotaReached": RequestQuotaReachedError, + "RequestTimeTooSkewed": RequestTimeTooSkewedError, + "TargetNameExist": TargetNameExistError, + "TargetQuotaReached": TargetQuotaReachedError, + "TargetStatusNotSuccess": TargetStatusNotSuccessError, + "TargetStatusProcessing": TargetStatusProcessingError, + "UnknownTarget": UnknownTargetError, }[result_code] raise exception(response=response) @@ -386,22 +386,22 @@ def wait_for_target_processed( target to be processed. Raises: - ~vws.exceptions.vws_exceptions.AuthenticationFailure: The secret - key is not correct. - ~vws.exceptions.vws_exceptions.Fail: There was an error with the - request. For example, the given access key does not match a + ~vws.exceptions.vws_exceptions.AuthenticationFailureError: The + secret key is not correct. + ~vws.exceptions.vws_exceptions.FailError: There was an error with + the request. For example, the given access key does not match a known database. - ~vws.exceptions.custom_exceptions.TargetProcessingTimeout: The + ~vws.exceptions.custom_exceptions.TargetProcessingTimeoutError: The target remained in the processing stage for more than ``timeout_seconds`` seconds. - ~vws.exceptions.vws_exceptions.UnknownTarget: The given target ID - does not match a target in the database. - ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an - error with the time sent to Vuforia. + ~vws.exceptions.vws_exceptions.UnknownTargetError: The given target + ID does not match a target in the database. + ~vws.exceptions.vws_exceptions.RequestTimeTooSkewedError: There is + an error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate - limiting access. + ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is + rate limiting access. """ start_time = time.monotonic() while True: @@ -411,7 +411,7 @@ def wait_for_target_processed( elapsed_time = time.monotonic() - start_time if elapsed_time > timeout_seconds: # pragma: no cover - raise TargetProcessingTimeout + raise TargetProcessingTimeoutError time.sleep(seconds_between_requests) diff --git a/tests/test_cloud_reco_exceptions.py b/tests/test_cloud_reco_exceptions.py index ba063dece..4e8a70895 100644 --- a/tests/test_cloud_reco_exceptions.py +++ b/tests/test_cloud_reco_exceptions.py @@ -13,16 +13,16 @@ from mock_vws.database import VuforiaDatabase from mock_vws.states import States from vws import CloudRecoService -from vws.exceptions.base_exceptions import CloudRecoException +from vws.exceptions.base_exceptions import CloudRecoError from vws.exceptions.cloud_reco_exceptions import ( - AuthenticationFailure, - BadImage, - InactiveProject, - MaxNumResultsOutOfRange, - RequestTimeTooSkewed, + AuthenticationFailureError, + BadImageError, + InactiveProjectError, + MaxNumResultsOutOfRangeError, + RequestTimeTooSkewedError, ) from vws.exceptions.custom_exceptions import ( - RequestEntityTooLarge, + RequestEntityTooLargeError, ) if TYPE_CHECKING: @@ -37,7 +37,7 @@ def test_too_many_max_results( A ``MaxNumResultsOutOfRange`` error is raised if the given ``max_num_results`` is out of range. """ - with pytest.raises(MaxNumResultsOutOfRange) as exc: + with pytest.raises(MaxNumResultsOutOfRangeError) as exc: cloud_reco_client.query( image=high_quality_image, max_num_results=51, @@ -58,7 +58,7 @@ def test_image_too_large( A ``RequestEntityTooLarge`` exception is raised if an image which is too large is given. """ - with pytest.raises(RequestEntityTooLarge) as exc: + with pytest.raises(RequestEntityTooLargeError) as exc: cloud_reco_client.query(image=png_too_large) assert ( @@ -71,14 +71,14 @@ def test_cloudrecoexception_inheritance() -> None: CloudRecoService-specific exceptions inherit from CloudRecoException. """ subclasses = [ - MaxNumResultsOutOfRange, - InactiveProject, - BadImage, - AuthenticationFailure, - RequestTimeTooSkewed, + MaxNumResultsOutOfRangeError, + InactiveProjectError, + BadImageError, + AuthenticationFailureError, + RequestTimeTooSkewedError, ] for subclass in subclasses: - assert issubclass(subclass, CloudRecoException) + assert issubclass(subclass, CloudRecoError) def test_authentication_failure(high_quality_image: io.BytesIO) -> None: @@ -94,7 +94,7 @@ def test_authentication_failure(high_quality_image: io.BytesIO) -> None: with MockVWS() as mock: mock.add_database(database=database) - with pytest.raises(AuthenticationFailure) as exc: + with pytest.raises(AuthenticationFailureError) as exc: cloud_reco_client.query(image=high_quality_image) assert exc.value.response.status_code == HTTPStatus.UNAUTHORIZED @@ -113,7 +113,7 @@ def test_inactive_project(high_quality_image: io.BytesIO) -> None: client_secret_key=database.client_secret_key, ) - with pytest.raises(InactiveProject) as exc: + with pytest.raises(InactiveProjectError) as exc: cloud_reco_client.query(image=high_quality_image) assert exc.value.response.status_code == HTTPStatus.FORBIDDEN diff --git a/tests/test_vws.py b/tests/test_vws.py index 7c148cf29..bfc1b7250 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -15,7 +15,7 @@ from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase from vws import VWS, CloudRecoService -from vws.exceptions.custom_exceptions import TargetProcessingTimeout +from vws.exceptions.custom_exceptions import TargetProcessingTimeoutError from vws.reports import ( DatabaseSummaryReport, TargetRecord, @@ -442,7 +442,7 @@ def test_custom_timeout(image: io.BytesIO) -> None: report = vws_client.get_target_summary_report(target_id=target_id) assert report.status == TargetStatuses.PROCESSING - with pytest.raises(TargetProcessingTimeout): + with pytest.raises(TargetProcessingTimeoutError): vws_client.wait_for_target_processed( target_id=target_id, timeout_seconds=0.1, diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 469683f6c..b433c2754 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -12,25 +12,27 @@ from mock_vws.database import VuforiaDatabase from mock_vws.states import States from vws import VWS -from vws.exceptions.base_exceptions import VWSException -from vws.exceptions.custom_exceptions import OopsAnErrorOccurredPossiblyBadName +from vws.exceptions.base_exceptions import VWSError +from vws.exceptions.custom_exceptions import ( + OopsAnErrorOccurredPossiblyBadNameError, +) from vws.exceptions.vws_exceptions import ( - AuthenticationFailure, - BadImage, + AuthenticationFailureError, + BadImageError, DateRangeError, - Fail, - ImageTooLarge, - MetadataTooLarge, - ProjectHasNoAPIAccess, - ProjectInactive, - ProjectSuspended, - RequestQuotaReached, - RequestTimeTooSkewed, - TargetNameExist, - TargetQuotaReached, - TargetStatusNotSuccess, - TargetStatusProcessing, - UnknownTarget, + FailError, + ImageTooLargeError, + MetadataTooLargeError, + ProjectHasNoAPIAccessError, + ProjectInactiveError, + ProjectSuspendedError, + RequestQuotaReachedError, + RequestTimeTooSkewedError, + TargetNameExistError, + TargetQuotaReachedError, + TargetStatusNotSuccessError, + TargetStatusProcessingError, + UnknownTargetError, ) @@ -42,7 +44,7 @@ def test_image_too_large( When giving an image which is too large, an ``ImageTooLarge`` exception is raised. """ - with pytest.raises(ImageTooLarge) as exc: + with pytest.raises(ImageTooLargeError) as exc: vws_client.add_target( name="x", width=1, @@ -60,7 +62,7 @@ def test_invalid_given_id(vws_client: VWS) -> None: causes an ``UnknownTarget`` exception to be raised. """ target_id = "12345abc" - with pytest.raises(UnknownTarget) as exc: + with pytest.raises(UnknownTargetError) as exc: vws_client.delete_target(target_id=target_id) assert exc.value.response.status_code == HTTPStatus.NOT_FOUND assert exc.value.target_id == target_id @@ -73,7 +75,7 @@ def test_add_bad_name(vws_client: VWS, high_quality_image: io.BytesIO) -> None: """ max_char_value = 65535 bad_name = chr(max_char_value + 1) - with pytest.raises(OopsAnErrorOccurredPossiblyBadName) as exc: + with pytest.raises(OopsAnErrorOccurredPossiblyBadNameError) as exc: vws_client.add_target( name=bad_name, width=1, @@ -102,7 +104,7 @@ def test_fail(high_quality_image: io.BytesIO) -> None: server_secret_key=uuid.uuid4().hex, ) - with pytest.raises(Fail) as exc: + with pytest.raises(FailError) as exc: vws_client.add_target( name="x", width=1, @@ -119,7 +121,7 @@ def test_bad_image(vws_client: VWS) -> None: A ``BadImage`` exception is raised when a non-image is given. """ not_an_image = io.BytesIO(b"Not an image") - with pytest.raises(BadImage) as exc: + with pytest.raises(BadImageError) as exc: vws_client.add_target( name="x", width=1, @@ -146,7 +148,7 @@ def test_target_name_exist( active_flag=True, application_metadata=None, ) - with pytest.raises(TargetNameExist) as exc: + with pytest.raises(TargetNameExistError) as exc: vws_client.add_target( name="x", width=1, @@ -172,7 +174,7 @@ def test_project_inactive(high_quality_image: io.BytesIO) -> None: server_secret_key=database.server_secret_key, ) - with pytest.raises(ProjectInactive) as exc: + with pytest.raises(ProjectInactiveError) as exc: vws_client.add_target( name="x", width=1, @@ -200,7 +202,7 @@ def test_target_status_processing( application_metadata=None, ) - with pytest.raises(TargetStatusProcessing) as exc: + with pytest.raises(TargetStatusProcessingError) as exc: vws_client.delete_target(target_id=target_id) assert exc.value.response.status_code == HTTPStatus.FORBIDDEN @@ -215,7 +217,7 @@ def test_metadata_too_large( A ``MetadataTooLarge`` exception is raised if the metadata given is too large. """ - with pytest.raises(MetadataTooLarge) as exc: + with pytest.raises(MetadataTooLargeError) as exc: vws_client.add_target( name="x", width=1, @@ -255,7 +257,7 @@ def test_request_time_too_skewed( # >= 1 ticks are acceptable. with ( freeze_time(auto_tick_seconds=time_difference_from_now), - pytest.raises(RequestTimeTooSkewed) as exc, + pytest.raises(RequestTimeTooSkewedError) as exc, ): vws_client.get_target_record(target_id=target_id) @@ -278,7 +280,7 @@ def test_authentication_failure(high_quality_image: io.BytesIO) -> None: with MockVWS() as mock: mock.add_database(database=database) - with pytest.raises(AuthenticationFailure) as exc: + with pytest.raises(AuthenticationFailureError) as exc: vws_client.add_target( name="x", width=1, @@ -306,7 +308,7 @@ def test_target_status_not_success( application_metadata=None, ) - with pytest.raises(TargetStatusNotSuccess) as exc: + with pytest.raises(TargetStatusNotSuccessError) as exc: vws_client.update_target(target_id=target_id) assert exc.value.response.status_code == HTTPStatus.FORBIDDEN @@ -318,25 +320,25 @@ def test_vwsexception_inheritance() -> None: VWS-related exceptions should inherit from VWSException. """ subclasses = [ - AuthenticationFailure, - BadImage, + AuthenticationFailureError, + BadImageError, DateRangeError, - Fail, - ImageTooLarge, - MetadataTooLarge, - ProjectInactive, - ProjectHasNoAPIAccess, - ProjectSuspended, - RequestQuotaReached, - RequestTimeTooSkewed, - TargetNameExist, - TargetQuotaReached, - TargetStatusNotSuccess, - TargetStatusProcessing, - UnknownTarget, + FailError, + ImageTooLargeError, + MetadataTooLargeError, + ProjectInactiveError, + ProjectHasNoAPIAccessError, + ProjectSuspendedError, + RequestQuotaReachedError, + RequestTimeTooSkewedError, + TargetNameExistError, + TargetQuotaReachedError, + TargetStatusNotSuccessError, + TargetStatusProcessingError, + UnknownTargetError, ] for subclass in subclasses: - assert issubclass(subclass, VWSException) + assert issubclass(subclass, VWSError) def test_base_exception( @@ -346,7 +348,7 @@ def test_base_exception( """ ``VWSException``s has a response property. """ - with pytest.raises(VWSException) as exc: + with pytest.raises(VWSError) as exc: vws_client.get_target_record(target_id="a") assert exc.value.response.status_code == HTTPStatus.NOT_FOUND From 2bdf3b8a5623d02170d6a93db416b997bbce872e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 19 Apr 2024 13:49:51 +0100 Subject: [PATCH 0182/1003] Fix docs references --- spelling_private_dict.txt | 1 + src/vws/vws.py | 207 +++++++++++++++++++------------------- 2 files changed, 104 insertions(+), 104 deletions(-) diff --git a/spelling_private_dict.txt b/spelling_private_dict.txt index a11d546a6..43f9fd5b1 100644 --- a/spelling_private_dict.txt +++ b/spelling_private_dict.txt @@ -23,6 +23,7 @@ TooManyRequests Ubuntu UnknownTarget OopsAnErrorOccurredPossiblyBadName +OopsAnErrorOccurredPossiblyBadNameError admin api args diff --git a/src/vws/vws.py b/src/vws/vws.py index 082767780..1fdc6465a 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -172,14 +172,14 @@ def _make_request( The response to the request made by `requests`. Raises: - ~vws.exceptions.OopsAnErrorOccurredPossiblyBadName: Vuforia returns - an HTML page with the text "Oops, an error occurred". This has - been seen to happen when the given name includes a bad + ~vws.exceptions.OopsAnErrorOccurredPossiblyBadNameError: Vuforia + returns an HTML page with the text "Oops, an error occurred". + This has been seen to happen when the given name includes a bad character. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate - limiting access. + ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is + rate limiting access. json.decoder.JSONDecodeError: The server did not respond with valid JSON. This may happen if the server address is not a valid Vuforia server. @@ -263,34 +263,33 @@ def add_target( The target ID of the new target. Raises: - ~vws.exceptions.vws_exceptions.AuthenticationFailure: The secret - key is not correct. - ~vws.exceptions.vws_exceptions.BadImage: There is a problem with - the given image. - For example, it must be a JPEG or PNG file in the grayscale or - RGB color space. - ~vws.exceptions.vws_exceptions.Fail: There was an error with the - request. For example, the given access key does not match a + ~vws.exceptions.vws_exceptions.AuthenticationFailureError: The + secret key is not correct. + ~vws.exceptions.vws_exceptions.BadImageError: There is a problem + with the given image. For example, it must be a JPEG or PNG + file in the grayscale or RGB color space. + ~vws.exceptions.vws_exceptions.FailError: There was an error with + the request. For example, the given access key does not match a known database. - ~vws.exceptions.vws_exceptions.MetadataTooLarge: The given metadata - is too large. The maximum size is 1 MB of data when Base64 - encoded. - ~vws.exceptions.vws_exceptions.ImageTooLarge: The given image is - too large. - ~vws.exceptions.vws_exceptions.TargetNameExist: A target with the - given ``name`` already exists. - ~vws.exceptions.vws_exceptions.ProjectInactive: The project is + ~vws.exceptions.vws_exceptions.MetadataTooLargeError: The given + metadata is too large. The maximum size is 1 MB of data when + Base64 encoded. + ~vws.exceptions.vws_exceptions.ImageTooLargeError: The given image + is too large. + ~vws.exceptions.vws_exceptions.TargetNameExistError: A target with + the given ``name`` already exists. + ~vws.exceptions.vws_exceptions.ProjectInactiveError: The project is inactive. - ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an - error with the time sent to Vuforia. - ~vws.exceptions.custom_exceptions.OopsAnErrorOccurredPossiblyBadName: + ~vws.exceptions.vws_exceptions.RequestTimeTooSkewedError: There is + an error with the time sent to Vuforia. + ~vws.exceptions.custom_exceptions.OopsAnErrorOccurredPossiblyBadNameError: Vuforia returns an HTML page with the text "Oops, an error occurred". This has been seen to happen when the given name includes a bad character. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate - limiting access. + ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is + rate limiting access. """ image_data = _get_image_data(image=image) image_data_encoded = base64.b64encode(image_data).decode("ascii") @@ -328,19 +327,19 @@ def get_target_record(self, target_id: str) -> TargetStatusAndRecord: Response details of a target from Vuforia. Raises: - ~vws.exceptions.vws_exceptions.AuthenticationFailure: The secret - key is not correct. - ~vws.exceptions.vws_exceptions.Fail: There was an error with the - request. For example, the given access key does not match a + ~vws.exceptions.vws_exceptions.AuthenticationFailureError: The + secret key is not correct. + ~vws.exceptions.vws_exceptions.FailError: There was an error with + the request. For example, the given access key does not match a known database. - ~vws.exceptions.vws_exceptions.UnknownTarget: The given target ID - does not match a target in the database. - ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an - error with the time sent to Vuforia. + ~vws.exceptions.vws_exceptions.UnknownTargetError: The given target + ID does not match a target in the database. + ~vws.exceptions.vws_exceptions.RequestTimeTooSkewedError: There is + an error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate - limiting access. + ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is + rate limiting access. """ response = self._make_request( method=HTTPMethod.GET, @@ -426,17 +425,17 @@ def list_targets(self) -> list[str]: The IDs of all targets in the database. Raises: - ~vws.exceptions.vws_exceptions.AuthenticationFailure: The secret - key is not correct. - ~vws.exceptions.vws_exceptions.Fail: There was an error with the - request. For example, the given access key does not match a + ~vws.exceptions.vws_exceptions.AuthenticationFailureError: The + secret key is not correct. + ~vws.exceptions.vws_exceptions.FailError: There was an error with + the request. For example, the given access key does not match a known database. - ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an - error with the time sent to Vuforia. + ~vws.exceptions.vws_exceptions.RequestTimeTooSkewedError: There is + an error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate - limiting access. + ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is + rate limiting access. """ response = self._make_request( method=HTTPMethod.GET, @@ -461,19 +460,19 @@ def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: Details of the target. Raises: - ~vws.exceptions.vws_exceptions.AuthenticationFailure: The secret - key is not correct. - ~vws.exceptions.vws_exceptions.Fail: There was an error with the - request. For example, the given access key does not match a + ~vws.exceptions.vws_exceptions.AuthenticationFailureError: The + secret key is not correct. + ~vws.exceptions.vws_exceptions.FailError: There was an error with + the request. For example, the given access key does not match a known database. - ~vws.exceptions.vws_exceptions.UnknownTarget: The given target ID - does not match a target in the database. - ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an - error with the time sent to Vuforia. + ~vws.exceptions.vws_exceptions.UnknownTargetError: The given target + ID does not match a target in the database. + ~vws.exceptions.vws_exceptions.RequestTimeTooSkewedError: There is + an error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate - limiting access. + ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is + rate limiting access. """ response = self._make_request( method=HTTPMethod.GET, @@ -506,17 +505,17 @@ def get_database_summary_report(self) -> DatabaseSummaryReport: Details of the database. Raises: - ~vws.exceptions.vws_exceptions.AuthenticationFailure: The secret - key is not correct. - ~vws.exceptions.vws_exceptions.Fail: There was an error with the - request. For example, the given access key does not match a + ~vws.exceptions.vws_exceptions.AuthenticationFailureError: The + secret key is not correct. + ~vws.exceptions.vws_exceptions.FailError: There was an error with + the request. For example, the given access key does not match a known database. - ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an - error with the time sent to Vuforia. + ~vws.exceptions.vws_exceptions.RequestTimeTooSkewedError: There is + an error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate - limiting access. + ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is + rate limiting access. """ response = self._make_request( method=HTTPMethod.GET, @@ -552,21 +551,21 @@ def delete_target(self, target_id: str) -> None: target_id: The ID of the target to delete. Raises: - ~vws.exceptions.vws_exceptions.AuthenticationFailure: The secret - key is not correct. - ~vws.exceptions.vws_exceptions.Fail: There was an error with the - request. For example, the given access key does not match a + ~vws.exceptions.vws_exceptions.AuthenticationFailureError: The + secret key is not correct. + ~vws.exceptions.vws_exceptions.FailError: There was an error with + the request. For example, the given access key does not match a known database. - ~vws.exceptions.vws_exceptions.UnknownTarget: The given target ID - does not match a target in the database. - ~vws.exceptions.vws_exceptions.TargetStatusProcessing: The given - target is in the processing state. - ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an - error with the time sent to Vuforia. + ~vws.exceptions.vws_exceptions.UnknownTargetError: The given target + ID does not match a target in the database. + ~vws.exceptions.vws_exceptions.TargetStatusProcessingError: The + given target is in the processing state. + ~vws.exceptions.vws_exceptions.RequestTimeTooSkewedError: There is + an error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate - limiting access. + ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is + rate limiting access. """ self._make_request( method=HTTPMethod.DELETE, @@ -589,21 +588,21 @@ def get_duplicate_targets(self, target_id: str) -> list[str]: The target IDs of duplicate targets. Raises: - ~vws.exceptions.vws_exceptions.AuthenticationFailure: The secret - key is not correct. - ~vws.exceptions.vws_exceptions.Fail: There was an error with the - request. For example, the given access key does not match a + ~vws.exceptions.vws_exceptions.AuthenticationFailureError: The + secret key is not correct. + ~vws.exceptions.vws_exceptions.FailError: There was an error with + the request. For example, the given access key does not match a known database. - ~vws.exceptions.vws_exceptions.UnknownTarget: The given target ID - does not match a target in the database. - ~vws.exceptions.vws_exceptions.ProjectInactive: The project is + ~vws.exceptions.vws_exceptions.UnknownTargetError: The given target + ID does not match a target in the database. + ~vws.exceptions.vws_exceptions.ProjectInactiveError: The project is inactive. - ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an - error with the time sent to Vuforia. + ~vws.exceptions.vws_exceptions.RequestTimeTooSkewedError: There is + an error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate - limiting access. + ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is + rate limiting access. """ response = self._make_request( method=HTTPMethod.GET, @@ -644,29 +643,29 @@ def update_target( Giving ``None`` will not change the application metadata. Raises: - ~vws.exceptions.vws_exceptions.AuthenticationFailure: The secret - key is not correct. - ~vws.exceptions.vws_exceptions.BadImage: There is a problem with - the given image. For example, it must be a JPEG or PNG file in - the grayscale or RGB color space. - ~vws.exceptions.vws_exceptions.Fail: There was an error with the - request. For example, the given access key does not match a + ~vws.exceptions.vws_exceptions.AuthenticationFailureError: The + secret key is not correct. + ~vws.exceptions.vws_exceptions.BadImageError: There is a problem + with the given image. For example, it must be a JPEG or PNG + file in the grayscale or RGB color space. + ~vws.exceptions.vws_exceptions.FailError: There was an error with + the request. For example, the given access key does not match a known database. - ~vws.exceptions.vws_exceptions.MetadataTooLarge: The given metadata - is too large. The maximum size is 1 MB of data when Base64 - encoded. - ~vws.exceptions.vws_exceptions.ImageTooLarge: The given image is - too large. - ~vws.exceptions.vws_exceptions.TargetNameExist: A target with the - given ``name`` already exists. - ~vws.exceptions.vws_exceptions.ProjectInactive: The project is + ~vws.exceptions.vws_exceptions.MetadataTooLargeError: The given + metadata is too large. The maximum size is 1 MB of data when + Base64 encoded. + ~vws.exceptions.vws_exceptions.ImageTooLargeError: The given image + is too large. + ~vws.exceptions.vws_exceptions.TargetNameExistError: A target with + the given ``name`` already exists. + ~vws.exceptions.vws_exceptions.ProjectInactiveError: The project is inactive. - ~vws.exceptions.vws_exceptions.RequestTimeTooSkewed: There is an - error with the time sent to Vuforia. + ~vws.exceptions.vws_exceptions.RequestTimeTooSkewedError: There is + an error with the time sent to Vuforia. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. - ~vws.exceptions.vws_exceptions.TooManyRequests: Vuforia is rate - limiting access. + ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is + rate limiting access. """ data: dict[str, str | bool | float | int] = {} From 40733b1fda19f4596848d5b31d22d688d58e1bee Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 22 Apr 2024 10:21:55 +0000 Subject: [PATCH 0183/1003] Bump ruff from 0.4.0 to 0.4.1 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.4.0 to 0.4.1. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.4.0...v0.4.1) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f11861395..7c2a796d1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -261,7 +261,7 @@ dev = [ "pytest==8.1.1", "pytest-cov==5.0.0", "PyYAML==6.0.1", - "ruff==0.4.0", + "ruff==0.4.1", "Sphinx==7.3.7", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", From 98aa5e40e7f9fa3b42f7c35a647a40e0ae39f227 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 23 Apr 2024 10:19:07 +0000 Subject: [PATCH 0184/1003] Bump sybil from 6.0.3 to 6.1.0 Bumps [sybil](https://github.com/simplistix/sybil) from 6.0.3 to 6.1.0. - [Changelog](https://github.com/simplistix/sybil/blob/master/CHANGELOG.rst) - [Commits](https://github.com/simplistix/sybil/compare/6.0.3...6.1.0) --- updated-dependencies: - dependency-name: sybil dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7c2a796d1..8d6bf37a5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -266,7 +266,7 @@ dev = [ "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", "sphinxcontrib-spelling==8", - "sybil==6.0.3", + "sybil==6.1.0", "types-requests==2.31.0.20240406", "vulture==2.11", "VWS-Python-Mock==2024.2.16", From 4f8576377aed938d6629b67c83b8f4e0c9b8b49f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 24 Apr 2024 10:15:18 +0000 Subject: [PATCH 0185/1003] Bump freezegun from 1.4.0 to 1.5.0 Bumps [freezegun](https://github.com/spulec/freezegun) from 1.4.0 to 1.5.0. - [Release notes](https://github.com/spulec/freezegun/releases) - [Changelog](https://github.com/spulec/freezegun/blob/master/CHANGELOG) - [Commits](https://github.com/spulec/freezegun/compare/1.4.0...1.5.0) --- updated-dependencies: - dependency-name: freezegun dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8d6bf37a5..be73babf2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -248,7 +248,7 @@ dev = [ "check-wheel-contents==0.6.0", "deptry==0.16.1", "doc8==1.1.1", - "freezegun==1.4.0", + "freezegun==1.5.0", "furo==2024.1.29", "mypy==1.9.0", "pydocstyle==6.3", From 303d0d614524aecff0694321ec0b26e63c606717 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 25 Apr 2024 10:55:59 +0000 Subject: [PATCH 0186/1003] Bump mypy from 1.9.0 to 1.10.0 Bumps [mypy](https://github.com/python/mypy) from 1.9.0 to 1.10.0. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/1.9.0...v1.10.0) --- updated-dependencies: - dependency-name: mypy dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index be73babf2..1789fc261 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -250,7 +250,7 @@ dev = [ "doc8==1.1.1", "freezegun==1.5.0", "furo==2024.1.29", - "mypy==1.9.0", + "mypy==1.10.0", "pydocstyle==6.3", "pyenchant==3.2.2", "Pygments==2.17.2", From 61e6cbef4a5f2726579cb5878c3364f9eb9bdba0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 25 Apr 2024 11:00:17 +0000 Subject: [PATCH 0187/1003] Bump pyright from 1.1.359 to 1.1.360 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.359 to 1.1.360. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.359...v1.1.360) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1789fc261..20eb9e42c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -256,7 +256,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.1.0", "pyproject-fmt==1.8.0", - "pyright==1.1.359", + "pyright==1.1.360", "pyroma==4.2", "pytest==8.1.1", "pytest-cov==5.0.0", From ac156dcff2ae29bcc8c7c4a34407468d5003e79b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 26 Apr 2024 10:36:47 +0000 Subject: [PATCH 0188/1003] Bump ruff from 0.4.1 to 0.4.2 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.4.1 to 0.4.2. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.4.1...v0.4.2) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 20eb9e42c..4717832b3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -261,7 +261,7 @@ dev = [ "pytest==8.1.1", "pytest-cov==5.0.0", "PyYAML==6.0.1", - "ruff==0.4.1", + "ruff==0.4.2", "Sphinx==7.3.7", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", From bad4568fd71d74031c4bfb4bd4cdbc8c8f3cd92a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 29 Apr 2024 10:28:09 +0000 Subject: [PATCH 0189/1003] Bump furo from 2024.1.29 to 2024.4.27 Bumps [furo](https://github.com/pradyunsg/furo) from 2024.1.29 to 2024.4.27. - [Release notes](https://github.com/pradyunsg/furo/releases) - [Changelog](https://github.com/pradyunsg/furo/blob/main/docs/changelog.md) - [Commits](https://github.com/pradyunsg/furo/compare/2024.01.29...2024.04.27) --- updated-dependencies: - dependency-name: furo dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4717832b3..b0d0f1d96 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -249,7 +249,7 @@ dev = [ "deptry==0.16.1", "doc8==1.1.1", "freezegun==1.5.0", - "furo==2024.1.29", + "furo==2024.4.27", "mypy==1.10.0", "pydocstyle==6.3", "pyenchant==3.2.2", From cda530e81bc3716fa4e52694594bb90c1f7b9c17 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 29 Apr 2024 10:32:49 +0000 Subject: [PATCH 0190/1003] Bump pytest from 8.1.1 to 8.2.0 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.1.1 to 8.2.0. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.1.1...8.2.0) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b0d0f1d96..8ff9a83c7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -258,7 +258,7 @@ dev = [ "pyproject-fmt==1.8.0", "pyright==1.1.360", "pyroma==4.2", - "pytest==8.1.1", + "pytest==8.2.0", "pytest-cov==5.0.0", "PyYAML==6.0.1", "ruff==0.4.2", From 07aecb2a0a003ef1ba8fa83512233c37b0fa55be Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 2 May 2024 10:28:38 +0000 Subject: [PATCH 0191/1003] Bump pyright from 1.1.360 to 1.1.361 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.360 to 1.1.361. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.360...v1.1.361) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8ff9a83c7..08d96dc5a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -256,7 +256,7 @@ dev = [ "Pygments==2.17.2", "pylint==3.1.0", "pyproject-fmt==1.8.0", - "pyright==1.1.360", + "pyright==1.1.361", "pyroma==4.2", "pytest==8.2.0", "pytest-cov==5.0.0", From 208d3892db3ce7e54c2d55f14513167a0cff488b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 6 May 2024 10:21:09 +0000 Subject: [PATCH 0192/1003] Bump pygments from 2.17.2 to 2.18.0 Bumps [pygments](https://github.com/pygments/pygments) from 2.17.2 to 2.18.0. - [Release notes](https://github.com/pygments/pygments/releases) - [Changelog](https://github.com/pygments/pygments/blob/master/CHANGES) - [Commits](https://github.com/pygments/pygments/compare/2.17.2...2.18.0) --- updated-dependencies: - dependency-name: pygments dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 08d96dc5a..d03fc8d5b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -253,7 +253,7 @@ dev = [ "mypy==1.10.0", "pydocstyle==6.3", "pyenchant==3.2.2", - "Pygments==2.17.2", + "Pygments==2.18.0", "pylint==3.1.0", "pyproject-fmt==1.8.0", "pyright==1.1.361", From 751787afcd8cc29ab86386eb1dca8eefc1b139fe Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 6 May 2024 10:27:18 +0000 Subject: [PATCH 0193/1003] Bump ruff from 0.4.2 to 0.4.3 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.4.2 to 0.4.3. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.4.2...v0.4.3) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d03fc8d5b..9ee5c1b01 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -261,7 +261,7 @@ dev = [ "pytest==8.2.0", "pytest-cov==5.0.0", "PyYAML==6.0.1", - "ruff==0.4.2", + "ruff==0.4.3", "Sphinx==7.3.7", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", From be49571e6a5460608a91f550cb8ee626e86fc685 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 7 May 2024 10:13:47 +0000 Subject: [PATCH 0194/1003] Bump furo from 2024.4.27 to 2024.5.6 Bumps [furo](https://github.com/pradyunsg/furo) from 2024.4.27 to 2024.5.6. - [Release notes](https://github.com/pradyunsg/furo/releases) - [Changelog](https://github.com/pradyunsg/furo/blob/main/docs/changelog.md) - [Commits](https://github.com/pradyunsg/furo/compare/2024.04.27...2024.05.06) --- updated-dependencies: - dependency-name: furo dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9ee5c1b01..fd8f6c876 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -249,7 +249,7 @@ dev = [ "deptry==0.16.1", "doc8==1.1.1", "freezegun==1.5.0", - "furo==2024.4.27", + "furo==2024.5.6", "mypy==1.10.0", "pydocstyle==6.3", "pyenchant==3.2.2", From 537593b432e64cfa7c18b0dc21887574f2d902af Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 8 May 2024 10:06:48 +0000 Subject: [PATCH 0195/1003] Bump pyright from 1.1.361 to 1.1.362 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.361 to 1.1.362. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.361...v1.1.362) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index fd8f6c876..6d684b470 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -256,7 +256,7 @@ dev = [ "Pygments==2.18.0", "pylint==3.1.0", "pyproject-fmt==1.8.0", - "pyright==1.1.361", + "pyright==1.1.362", "pyroma==4.2", "pytest==8.2.0", "pytest-cov==5.0.0", From 8fcffa31889b1cf69b4d8fbce10b7abda4fa0c39 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 9 May 2024 10:30:26 +0000 Subject: [PATCH 0196/1003] Bump sybil from 6.1.0 to 6.1.1 Bumps [sybil](https://github.com/simplistix/sybil) from 6.1.0 to 6.1.1. - [Changelog](https://github.com/simplistix/sybil/blob/master/CHANGELOG.rst) - [Commits](https://github.com/simplistix/sybil/compare/6.1.0...6.1.1) --- updated-dependencies: - dependency-name: sybil dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6d684b470..a20d01f4f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -266,7 +266,7 @@ dev = [ "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", "sphinxcontrib-spelling==8", - "sybil==6.1.0", + "sybil==6.1.1", "types-requests==2.31.0.20240406", "vulture==2.11", "VWS-Python-Mock==2024.2.16", From 9c800e8832adc4c4e7a52c40eff9b454fde8c9d2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 10 May 2024 10:30:07 +0000 Subject: [PATCH 0197/1003] Bump ruff from 0.4.3 to 0.4.4 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.4.3 to 0.4.4. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.4.3...v0.4.4) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a20d01f4f..1f4b3059e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -261,7 +261,7 @@ dev = [ "pytest==8.2.0", "pytest-cov==5.0.0", "PyYAML==6.0.1", - "ruff==0.4.3", + "ruff==0.4.4", "Sphinx==7.3.7", "sphinx-prompt==1.8", "Sphinx-Substitution-Extensions==2024.2.25", From 87fe3ed0a7512aa4bcef0c0135a6a6be18917b4a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 May 2024 11:03:37 +0000 Subject: [PATCH 0198/1003] Bump freezegun from 1.5.0 to 1.5.1 Bumps [freezegun](https://github.com/spulec/freezegun) from 1.5.0 to 1.5.1. - [Release notes](https://github.com/spulec/freezegun/releases) - [Changelog](https://github.com/spulec/freezegun/blob/master/CHANGELOG) - [Commits](https://github.com/spulec/freezegun/compare/1.5.0...1.5.1) --- updated-dependencies: - dependency-name: freezegun dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1f4b3059e..92487d3fb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -248,7 +248,7 @@ dev = [ "check-wheel-contents==0.6.0", "deptry==0.16.1", "doc8==1.1.1", - "freezegun==1.5.0", + "freezegun==1.5.1", "furo==2024.5.6", "mypy==1.10.0", "pydocstyle==6.3", From cde8a0815f1b208eca6007181a586582dfa1e029 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 14 May 2024 19:55:51 +0000 Subject: [PATCH 0199/1003] Bump pylint from 3.1.0 to 3.2.0 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.1.0 to 3.2.0. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.1.0...v3.2.0) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 92487d3fb..146476a0e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -254,7 +254,7 @@ dev = [ "pydocstyle==6.3", "pyenchant==3.2.2", "Pygments==2.18.0", - "pylint==3.1.0", + "pylint==3.2.0", "pyproject-fmt==1.8.0", "pyright==1.1.362", "pyroma==4.2", From 039e3487bf2a58492819ef2687c2f5afdcc2ef47 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 15 May 2024 10:59:25 +0000 Subject: [PATCH 0200/1003] Bump pyright from 1.1.362 to 1.1.363 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.362 to 1.1.363. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.362...v1.1.363) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 146476a0e..20d9c3044 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -256,7 +256,7 @@ dev = [ "Pygments==2.18.0", "pylint==3.2.0", "pyproject-fmt==1.8.0", - "pyright==1.1.362", + "pyright==1.1.363", "pyroma==4.2", "pytest==8.2.0", "pytest-cov==5.0.0", From 3931579463726f311a7ef555f650e89c5dfd87ba Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 15 May 2024 11:10:12 +0000 Subject: [PATCH 0201/1003] Bump pyproject-fmt from 1.8.0 to 2.1.1 Bumps [pyproject-fmt](https://github.com/tox-dev/pyproject-fmt) from 1.8.0 to 2.1.1. - [Release notes](https://github.com/tox-dev/pyproject-fmt/releases) - [Commits](https://github.com/tox-dev/pyproject-fmt/compare/1.8.0...2.1.1) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 20d9c3044..994a66162 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -255,7 +255,7 @@ dev = [ "pyenchant==3.2.2", "Pygments==2.18.0", "pylint==3.2.0", - "pyproject-fmt==1.8.0", + "pyproject-fmt==2.1.1", "pyright==1.1.363", "pyroma==4.2", "pytest==8.2.0", From 2a250c0deed516d2633ceb09e4c8eb47307f1d89 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 16 May 2024 09:35:49 +0100 Subject: [PATCH 0202/1003] Use pyproject-fmt v2 formatting --- pyproject.toml | 456 +++++++++++++++++++++++++------------------------ 1 file changed, 231 insertions(+), 225 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 994a66162..25ecfe5e9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,229 +1,25 @@ -[tool.pylint] - - [tool.pylint.'MASTER'] - - # Pickle collected data for later comparisons. - persistent = true - - # Use multiple processes to speed up Pylint. - jobs = 0 - - # List of plugins (as comma separated values of python modules names) to load, - # usually to register additional checkers. - # See https://chezsoi.org/lucas/blog/pylint-strict-base-configuration.html. - # We do not use the plugins: - # - pylint.extensions.code_style - # - pylint.extensions.magic_value - # - pylint.extensions.while_used - # as they seemed to get in the way. - load-plugins = [ - 'pylint.extensions.bad_builtin', - 'pylint.extensions.comparison_placement', - 'pylint.extensions.consider_refactoring_into_while_condition', - 'pylint.extensions.docparams', - 'pylint.extensions.dunder', - 'pylint.extensions.eq_without_hash', - 'pylint.extensions.for_any_all', - 'pylint.extensions.mccabe', - 'pylint.extensions.no_self_use', - 'pylint.extensions.overlapping_exceptions', - 'pylint.extensions.private_import', - 'pylint.extensions.redefined_loop_name', - 'pylint.extensions.redefined_variable_type', - 'pylint.extensions.set_membership', - 'pylint.extensions.typing', - ] - - # Allow loading of arbitrary C extensions. Extensions are imported into the - # active Python interpreter and may run arbitrary code. - unsafe-load-any-extension = false - - [tool.pylint.'MESSAGES CONTROL'] - - # Enable the message, report, category or checker with the given id(s). You can - # either give multiple identifier separated by comma (,) or put this option - # multiple time (only on the command line, not in the configuration file where - # it should appear only once). See also the "--disable" option for examples. - enable = [ - 'bad-inline-option', - 'deprecated-pragma', - 'file-ignored', - 'spelling', - 'use-symbolic-message-instead', - 'useless-suppression', - ] - - # Disable the message, report, category or checker with the given id(s). You - # can either give multiple identifiers separated by comma (,) or put this - # option multiple times (only on the command line, not in the configuration - # file where it should appear only once).You can also use "--disable=all" to - # disable everything first and then reenable specific checks. For example, if - # you want to run only the similarities checker, you can use "--disable=all - # --enable=similarities". If you want to run only the classes checker, but have - # no Warning level messages displayed, use"--disable=all --enable=classes - # --disable=W" - - disable = [ - 'too-few-public-methods', - 'too-many-locals', - 'too-many-arguments', - 'too-many-instance-attributes', - 'too-many-return-statements', - 'too-many-lines', - 'locally-disabled', - # Let ruff handle long lines - 'line-too-long', - # Let ruff handle unused imports - 'unused-import', - # Let ruff deal with sorting - 'ungrouped-imports', - # We don't need everything to be documented because of mypy - 'missing-type-doc', - 'missing-return-type-doc', - # Too difficult to please - 'duplicate-code', - # Let ruff handle imports - 'wrong-import-order', - # mypy does not want untyped parameters. - 'useless-type-doc', - ] - - [tool.pylint.'FORMAT'] - - # Allow the body of an if to be on the same line as the test if there is no - # else. - single-line-if-stmt = false - - [tool.pylint.'SPELLING'] - - # Spelling dictionary name. Available dictionaries: none. To make it working - # install python-enchant package. - spelling-dict = 'en_US' - - # A path to a file that contains private dictionary; one word per line. - spelling-private-dict-file = 'spelling_private_dict.txt' - - # Tells whether to store unknown words to indicated private dictionary in - # --spelling-private-dict-file option instead of raising a message. - spelling-store-unknown-words = 'no' - -[tool.coverage.run] - -branch = true - -[tool.coverage.report] -exclude_also = ["if TYPE_CHECKING:"] - -[tool.pytest.ini_options] - -xfail_strict = true -log_cli = true - -[tool.check-manifest] - -ignore = [ - "*.enc", - "readthedocs.yaml", - "CHANGELOG.rst", - "CODE_OF_CONDUCT.rst", - "CONTRIBUTING.rst", - "LICENSE", - "Makefile", - "ci", - "ci/**", - "codecov.yaml", - "doc8.ini", - "docs", - "docs/**", - ".git_archival.txt", - "spelling_private_dict.txt", - "tests", - "tests-pylintrc", - "tests/**", - "vuforia_secrets.env.example", - "lint.mk", -] - -[tool.doc8] - -max_line_length = 2000 -ignore_path = [ - "./.eggs", - "./docs/build", - "./docs/build/spelling/output.txt", - "./node_modules", - "./src/*.egg-info/", - "./src/*/_setuptools_scm_version.txt", -] - -[tool.mypy] - -strict = true - [build-system] build-backend = "setuptools.build_meta" requires = [ "pip", "setuptools", - "setuptools_scm[toml]>=7.1", + "setuptools-scm[toml]>=7.1", "wheel", ] -[tool.distutils.bdist_wheel] -universal = true - -[tool.ruff] -line-length = 79 - -[tool.ruff.lint] -select = ["ALL"] - -ignore = [ - # We do not annotate the type of 'self'. - "ANN101", - # We are happy to manage our own "complexity". - "C901", - # Ruff warns that this conflicts with the formatter. - "COM812", - # Allow our chosen docstring line-style - no one-line summary. - "D200", - "D205", - "D212", - "D415", - # Ruff warns that this conflicts with the formatter. - "ISC001", - # Ignore "too-many-*" errors as they seem to get in the way more than - # helping. - "PLR0913", - # Allow 'assert' as we use it for tests. - "S101", -] - -# Do not automatically remove commented out code. -# We comment out code during development, and with VSCode auto-save, this code -# is sometimes annoyingly removed. -unfixable = ["ERA001"] - -[tool.ruff.lint.pydocstyle] -convention = "google" - -[tool.ruff.lint.per-file-ignores] -"tests/test_*.py" = [ - # Do not require tests to have a one-line summary. - "D205", -] - [project] name = "vws-python" description = "Interact with the Vuforia Web Services (VWS) API." -readme = { file = "README.rst", content-type = "text/x-rst"} +readme = { file = "README.rst", content-type = "text/x-rst" } keywords = [ "client", "vuforia", "vws", ] license = { file = "LICENSE" } -authors = [ { name = "Adam Dangoor", email = "adamdangoor@gmail.com"} ] +authors = [ + { name = "Adam Dangoor", email = "adamdangoor@gmail.com" }, +] requires-python = ">=3.12" classifiers = [ "Development Status :: 5 - Production/Stable", @@ -239,10 +35,9 @@ dynamic = [ dependencies = [ "requests", "urllib3", - "VWS-Auth-Tools", + "vws-auth-tools", ] -[project.optional-dependencies] -dev = [ +optional-dependencies.dev = [ "actionlint-py==1.6.27.13", "check-manifest==0.49", "check-wheel-contents==0.6.0", @@ -253,48 +48,259 @@ dev = [ "mypy==1.10.0", "pydocstyle==6.3", "pyenchant==3.2.2", - "Pygments==2.18.0", + "pygments==2.18.0", "pylint==3.2.0", "pyproject-fmt==2.1.1", "pyright==1.1.363", "pyroma==4.2", "pytest==8.2.0", "pytest-cov==5.0.0", - "PyYAML==6.0.1", + "pyyaml==6.0.1", "ruff==0.4.4", - "Sphinx==7.3.7", + "sphinx==7.3.7", "sphinx-prompt==1.8", - "Sphinx-Substitution-Extensions==2024.2.25", + "sphinx-substitution-extensions==2024.2.25", "sphinxcontrib-spelling==8", "sybil==6.1.1", "types-requests==2.31.0.20240406", "vulture==2.11", - "VWS-Python-Mock==2024.2.16", - "VWS-Test-Fixtures==2023.3.5", + "vws-python-mock==2024.2.16", + "vws-test-fixtures==2023.3.5", ] -[project.urls] -Documentation = "https://vws-python.readthedocs.io/en/latest/" -Source = "https://github.com/VWS-Python/vws-python" +urls.Documentation = "https://vws-python.readthedocs.io/en/latest/" +urls.Source = "https://github.com/VWS-Python/vws-python" [tool.setuptools] zip-safe = false [tool.setuptools.packages.find] -where = ["src"] +where = [ + "src", +] [tool.setuptools.package-data] -vws = ["py.typed"] +vws = [ + "py.typed", +] + +[tool.distutils.bdist_wheel] +universal = true [tool.setuptools_scm] +[tool.ruff] +line-length = 79 + +lint.select = [ + "ALL", +] +lint.per-file-ignores."tests/test_*.py" = [ + # Do not require tests to have a one-line summary. + "D205", +] + +# Do not automatically remove commented out code. +# We comment out code during development, and with VSCode auto-save, this code +# is sometimes annoyingly removed. +lint.unfixable = [ + "ERA001", +] +lint.pydocstyle.convention = "google" +lint.ignore = [ + # We do not annotate the type of 'self'. + "ANN101", + # We are happy to manage our own "complexity". + "C901", + # Ruff warns that this conflicts with the formatter. + "COM812", + # Allow our chosen docstring line-style - no one-line summary. + "D200", + "D205", + "D212", + "D415", + # Ruff warns that this conflicts with the formatter. + "ISC001", + # Ignore "too-many-*" errors as they seem to get in the way more than + # helping. + "PLR0913", + # Allow 'assert' as we use it for tests. + "S101", +] + +[tool.pylint] + +[tool.pylint.'MASTER'] + +# Pickle collected data for later comparisons. +persistent = true + +# Use multiple processes to speed up Pylint. +jobs = 0 + +# List of plugins (as comma separated values of python modules names) to load, +# usually to register additional checkers. +# See https://chezsoi.org/lucas/blog/pylint-strict-base-configuration.html. +# We do not use the plugins: +# - pylint.extensions.code_style +# - pylint.extensions.magic_value +# - pylint.extensions.while_used +# as they seemed to get in the way. +load-plugins = [ + 'pylint.extensions.bad_builtin', + 'pylint.extensions.comparison_placement', + 'pylint.extensions.consider_refactoring_into_while_condition', + 'pylint.extensions.docparams', + 'pylint.extensions.dunder', + 'pylint.extensions.eq_without_hash', + 'pylint.extensions.for_any_all', + 'pylint.extensions.mccabe', + 'pylint.extensions.no_self_use', + 'pylint.extensions.overlapping_exceptions', + 'pylint.extensions.private_import', + 'pylint.extensions.redefined_loop_name', + 'pylint.extensions.redefined_variable_type', + 'pylint.extensions.set_membership', + 'pylint.extensions.typing', +] + +# Allow loading of arbitrary C extensions. Extensions are imported into the +# active Python interpreter and may run arbitrary code. +unsafe-load-any-extension = false + +[tool.pylint.'MESSAGES CONTROL'] + +# Enable the message, report, category or checker with the given id(s). You can +# either give multiple identifier separated by comma (,) or put this option +# multiple time (only on the command line, not in the configuration file where +# it should appear only once). See also the "--disable" option for examples. +enable = [ + 'bad-inline-option', + 'deprecated-pragma', + 'file-ignored', + 'spelling', + 'use-symbolic-message-instead', + 'useless-suppression', +] + +# Disable the message, report, category or checker with the given id(s). You +# can either give multiple identifiers separated by comma (,) or put this +# option multiple times (only on the command line, not in the configuration +# file where it should appear only once).You can also use "--disable=all" to +# disable everything first and then reenable specific checks. For example, if +# you want to run only the similarities checker, you can use "--disable=all +# --enable=similarities". If you want to run only the classes checker, but have +# no Warning level messages displayed, use"--disable=all --enable=classes +# --disable=W" + +disable = [ + 'too-few-public-methods', + 'too-many-locals', + 'too-many-arguments', + 'too-many-instance-attributes', + 'too-many-return-statements', + 'too-many-lines', + 'locally-disabled', + # Let ruff handle long lines + 'line-too-long', + # Let ruff handle unused imports + 'unused-import', + # Let ruff deal with sorting + 'ungrouped-imports', + # We don't need everything to be documented because of mypy + 'missing-type-doc', + 'missing-return-type-doc', + # Too difficult to please + 'duplicate-code', + # Let ruff handle imports + 'wrong-import-order', + # mypy does not want untyped parameters. + 'useless-type-doc', +] + +[tool.pylint.'FORMAT'] + +# Allow the body of an if to be on the same line as the test if there is no +# else. +single-line-if-stmt = false + +[tool.pylint.'SPELLING'] + +# Spelling dictionary name. Available dictionaries: none. To make it working +# install python-enchant package. +spelling-dict = 'en_US' + +# A path to a file that contains private dictionary; one word per line. +spelling-private-dict-file = 'spelling_private_dict.txt' + +# Tells whether to store unknown words to indicated private dictionary in +# --spelling-private-dict-file option instead of raising a message. +spelling-store-unknown-words = 'no' + +[tool.check-manifest] + +ignore = [ + "*.enc", + "readthedocs.yaml", + "CHANGELOG.rst", + "CODE_OF_CONDUCT.rst", + "CONTRIBUTING.rst", + "LICENSE", + "Makefile", + "ci", + "ci/**", + "codecov.yaml", + "doc8.ini", + "docs", + "docs/**", + ".git_archival.txt", + "spelling_private_dict.txt", + "tests", + "tests-pylintrc", + "tests/**", + "vuforia_secrets.env.example", + "lint.mk", +] + +[tool.deptry] +pep621_dev_dependency_groups = [ + "dev", +] + [tool.pyproject-fmt] indent = 4 keep_full_version = true +[tool.pytest.ini_options] + +xfail_strict = true +log_cli = true + +[tool.coverage.run] + +branch = true + +[tool.coverage.report] +exclude_also = [ + "if TYPE_CHECKING:", +] + +[tool.mypy] + +strict = true + [tool.pyright] reportUnnecessaryTypeIgnoreComment = true typeCheckingMode = "strict" -[tool.deptry] -pep621_dev_dependency_groups = ["dev"] +[tool.doc8] + +max_line_length = 2000 +ignore_path = [ + "./.eggs", + "./docs/build", + "./docs/build/spelling/output.txt", + "./node_modules", + "./src/*.egg-info/", + "./src/*/_setuptools_scm_version.txt", +] From 4d72103507aa693c097cccb918ff58cafe70ee35 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 19 May 2024 20:02:31 +0100 Subject: [PATCH 0203/1003] Switch from custom lint setup with Make to pre-commit --- .github/workflows/ci.yml | 7 +- .pre-commit-config.yaml | 142 +++++++++++++++++++++++++++++++++++ Makefile | 24 ------ docs/source/contributing.rst | 21 ++++-- lint.mk | 69 ----------------- pyproject.toml | 2 + 6 files changed, 163 insertions(+), 102 deletions(-) create mode 100644 .pre-commit-config.yaml delete mode 100644 lint.mk diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 2a1fd129d..ad86deb1b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -37,7 +37,9 @@ jobs: - name: "Lint" run: | - make lint + pre-commit run --all-files --hook-stage commit --verbose + pre-commit run --all-files --hook-stage push --verbose + pre-commit run --all-files --hook-stage manual --verbose - name: "Run tests" run: | @@ -50,3 +52,6 @@ jobs: with: fail_ci_if_error: true token: ${{ secrets.CODECOV_TOKEN }} + + - uses: pre-commit-ci/lite-action@v1.0.2 + if: always() diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 000000000..ac3dab718 --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,142 @@ +# See https://pre-commit.com for more information +# See https://pre-commit.com/hooks.html for more hooks +repos: +- repo: https://github.com/pre-commit/pre-commit-hooks + rev: v3.2.0 + hooks: + - id: trailing-whitespace + - id: end-of-file-fixer + - id: check-yaml + - id: check-added-large-files +- repo: local + hooks: + - id: actionlint + name: actionlint + entry: actionlint + language: system + pass_filenames: false + types: [yaml] + + - id: mypy + name: mypy + stages: [push] + entry: mypy . + language: system + types: [python, toml] + pass_filenames: false + + - id: check-manifest + name: check-manifest + stages: [push] + entry: check-manifest . + language: system + pass_filenames: false + + - id: pyright + name: pyright + stages: [push] + entry: pyright . + language: system + types: [python, toml] + pass_filenames: false + + - id: vulture + name: vulture + entry: vulture --min-confidence 100 --exclude .eggs + language: system + types: [python] + + - id: pyroma + name: pyroma + entry: pyroma --min 10 . + language: system + pass_filenames: false + types: [toml] + + - id: deptry + name: deptry + entry: deptry src/ + language: system + pass_filenames: false + + - id: pylint + name: pylint + entry: pylint *.py src/ tests/ docs/ + language: system + stages: [manual] + pass_filenames: false + + - id: ruff-check + name: Ruff check + entry: ruff check + language: system + types: [python] + + - id: ruff-format-check + name: Ruff format check + entry: ruff format --check + language: system + types: [python] + + - id: ruff-check-fix + name: Ruff check fix + entry: ruff check --fix + language: system + types: [python] + + - id: ruff-format-fix + name: Ruff format + entry: ruff format + language: system + types: [python] + + - id: doc8 + name: doc8 + entry: doc8 + language: system + types: [rst] + + - id: pyproject-fmt-check + name: pyproject-fmt check + entry: pyproject-fmt --check + language: system + types: [toml] + files: pyproject.toml + + - id: pyproject-fmt-fix + name: pyproject-fmt + entry: pyproject-fmt + language: system + types: [toml] + files: pyproject.toml + + - id: linkcheck + name: linkcheck + entry: make -C docs/ linkcheck SPHINXOPTS=-W + language: system + types: [rst] + stages: [manual] + pass_filenames: false + + - id: spelling + name: spelling + entry: make -C docs/ spelling SPHINXOPTS=-W + language: system + types: [rst] + stages: [manual] + pass_filenames: false + + - id: docs + name: Build Documentation + entry: make docs + language: system + stages: [manual] + pass_filenames: false + + - id: pyright-verifytypes + name: pyright-verifytypes + stages: [push] + entry: pyright --verifytypes vws + language: system + pass_filenames: false + types: [python] diff --git a/Makefile b/Makefile index 71db4ef0b..216a25740 100644 --- a/Makefile +++ b/Makefile @@ -1,32 +1,8 @@ SHELL := /bin/bash -euxo pipefail -include lint.mk - # Treat Sphinx warnings as errors SPHINXOPTS := -W -.PHONY: lint -lint: \ - actionlint \ - check-manifest \ - deptry \ - doc8 \ - linkcheck \ - mypy \ - ruff \ - pyproject-fmt \ - pyright \ - pyright-verifytypes \ - pyroma \ - spelling \ - vulture \ - pylint - -.PHONY: fix-lint -fix-lint: \ - fix-pyproject-fmt \ - fix-ruff - .PHONY: docs docs: make -C docs clean html SPHINXOPTS=$(SPHINXOPTS) diff --git a/docs/source/contributing.rst b/docs/source/contributing.rst index ca559e843..2fa6203ce 100644 --- a/docs/source/contributing.rst +++ b/docs/source/contributing.rst @@ -15,7 +15,7 @@ Install Python dependencies in a virtual environment. pip install --editable '.[dev]' Spell checking requires ``enchant``. -This can be installed on macOS, for example, with `Homebrew `__: +This can be installed on macOS, for example, with `Homebrew`_: .. prompt:: bash @@ -27,20 +27,25 @@ and on Ubuntu with ``apt``: apt-get install -y enchant -Linting -------- - -Run lint tools: +Install ``pre-commit`` hooks: .. prompt:: bash - make lint + pre-commit install + pre-commit install --hook-type pre-push -To fix some lint errors, run the following: +Linting +------- + +Run lint tools either by committing, or with: .. prompt:: bash - make fix-lint + pre-commit run --all-files --hook-stage commit --verbose + pre-commit run --all-files --hook-stage push --verbose + pre-commit run --all-files --hook-stage manual --verbose + +.. _Homebrew: https://brew.sh Running tests ------------- diff --git a/lint.mk b/lint.mk deleted file mode 100644 index afd33149f..000000000 --- a/lint.mk +++ /dev/null @@ -1,69 +0,0 @@ -# Make commands for linting - -SHELL := /bin/bash -euxo pipefail - -.PHONY: actionlint -actionlint: - actionlint - -.PHONY: mypy -mypy: - mypy . - -.PHONY: check-manifest -check-manifest: - check-manifest . - -.PHONY: doc8 -doc8: - doc8 . - -.PHONY: ruff -ruff: - ruff check . - ruff format --check . - -.PHONY: fix-ruff -fix-ruff: - ruff check --fix . - ruff format . - -.PHONY: deptry -deptry: - deptry src/ - -.PHONY: pylint -pylint: - pylint *.py src/ tests/ docs/ - -.PHONY: pyroma -pyroma: - pyroma --min 10 . - -.PHONY: pyright -pyright: - pyright . - -.PHONY: pyright-verifytypes -pyright-verifytypes: - pyright --verifytypes vws - -.PHONY: vulture -vulture: - vulture --min-confidence 100 --exclude _vendor --exclude .eggs . - -.PHONY: linkcheck -linkcheck: - $(MAKE) -C docs/ linkcheck SPHINXOPTS=$(SPHINXOPTS) - -.PHONY: pyproject-fmt - pyproject-fmt: - pyproject-fmt --check pyproject.toml - - .PHONY: fix-pyproject-fmt - fix-pyproject-fmt: - pyproject-fmt pyproject.toml - -.PHONY: spelling -spelling: - $(MAKE) -C docs/ spelling SPHINXOPTS=$(SPHINXOPTS) diff --git a/pyproject.toml b/pyproject.toml index 25ecfe5e9..9b725d034 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -46,6 +46,7 @@ optional-dependencies.dev = [ "freezegun==1.5.1", "furo==2024.5.6", "mypy==1.10.0", + "pre-commit==3.7.1", "pydocstyle==6.3", "pyenchant==3.2.2", "pygments==2.18.0", @@ -240,6 +241,7 @@ spelling-store-unknown-words = 'no' ignore = [ "*.enc", + ".pre-commit-config.yaml", "readthedocs.yaml", "CHANGELOG.rst", "CODE_OF_CONDUCT.rst", From 5ea56a72c5c30ca46343e857979cc4a55aa78a22 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Sun, 19 May 2024 19:07:11 +0000 Subject: [PATCH 0204/1003] [pre-commit.ci lite] apply automatic fixes --- LICENSE | 1 - 1 file changed, 1 deletion(-) diff --git a/LICENSE b/LICENSE index 69f733fdf..ef26969f8 100644 --- a/LICENSE +++ b/LICENSE @@ -17,4 +17,3 @@ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - From a0b0bc26033e09f76df80fc3b790525a192a9cdc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 20 May 2024 10:26:02 +0000 Subject: [PATCH 0205/1003] Bump pytest from 8.2.0 to 8.2.1 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.2.0 to 8.2.1. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.2.0...8.2.1) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9b725d034..cd39e2fa5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pyproject-fmt==2.1.1", "pyright==1.1.363", "pyroma==4.2", - "pytest==8.2.0", + "pytest==8.2.1", "pytest-cov==5.0.0", "pyyaml==6.0.1", "ruff==0.4.4", From 13bfaad9ebb3084effbcd7300cd2f8ad71736a80 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 20 May 2024 10:30:04 +0000 Subject: [PATCH 0206/1003] Bump pylint from 3.2.0 to 3.2.2 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.2.0 to 3.2.2. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.2.0...v3.2.2) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index cd39e2fa5..1f6f2d80f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -50,7 +50,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pyenchant==3.2.2", "pygments==2.18.0", - "pylint==3.2.0", + "pylint==3.2.2", "pyproject-fmt==2.1.1", "pyright==1.1.363", "pyroma==4.2", From 61d5fc7acbd52eefc8d8624e7bfc8d390778f9f0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 20 May 2024 10:34:30 +0000 Subject: [PATCH 0207/1003] Bump actionlint-py from 1.6.27.13 to 1.7.0.14 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.6.27.13 to 1.7.0.14. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.6.27.13...v1.7.0.14) --- updated-dependencies: - dependency-name: actionlint-py dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1f6f2d80f..d8f780ccc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -38,7 +38,7 @@ dependencies = [ "vws-auth-tools", ] optional-dependencies.dev = [ - "actionlint-py==1.6.27.13", + "actionlint-py==1.7.0.14", "check-manifest==0.49", "check-wheel-contents==0.6.0", "deptry==0.16.1", From cc1f7db3d4a0a41ca1b5692332e88f8a07f199b0 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 21 May 2024 06:05:18 +0100 Subject: [PATCH 0208/1003] Empty for CI From 2137b0220643620f272d6aaf958629976c378794 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 21 May 2024 07:39:31 +0100 Subject: [PATCH 0209/1003] Empty for CI From eb3871f268157904ca45a3b0871fd8d938a30a50 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 21 May 2024 10:37:28 +0000 Subject: [PATCH 0210/1003] --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d8f780ccc..344f59cc2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -63,7 +63,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2024.2.25", "sphinxcontrib-spelling==8", "sybil==6.1.1", - "types-requests==2.31.0.20240406", + "types-requests==2.32.0.20240521", "vulture==2.11", "vws-python-mock==2024.2.16", "vws-test-fixtures==2023.3.5", From 1c0078e7507bc96ae5614fd1294e03ff8ff5f890 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 21 May 2024 10:42:16 +0000 Subject: [PATCH 0211/1003] --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 344f59cc2..3fba084ef 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pyenchant==3.2.2", "pygments==2.18.0", "pylint==3.2.2", - "pyproject-fmt==2.1.1", + "pyproject-fmt==2.1.3", "pyright==1.1.363", "pyroma==4.2", "pytest==8.2.1", From 4f008d9a16926bb11dc84d51de767533d3a72905 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 22 May 2024 09:38:19 +0100 Subject: [PATCH 0212/1003] Empty for CI From cb8f065a3626377c7207a7bc173cfd6feddd4c38 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Wed, 22 May 2024 08:39:24 +0000 Subject: [PATCH 0213/1003] [pre-commit.ci lite] apply automatic fixes --- pyproject.toml | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 3fba084ef..b0ca1d1cc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -95,18 +95,6 @@ line-length = 79 lint.select = [ "ALL", ] -lint.per-file-ignores."tests/test_*.py" = [ - # Do not require tests to have a one-line summary. - "D205", -] - -# Do not automatically remove commented out code. -# We comment out code during development, and with VSCode auto-save, this code -# is sometimes annoyingly removed. -lint.unfixable = [ - "ERA001", -] -lint.pydocstyle.convention = "google" lint.ignore = [ # We do not annotate the type of 'self'. "ANN101", @@ -128,6 +116,19 @@ lint.ignore = [ "S101", ] +lint.per-file-ignores."tests/test_*.py" = [ + # Do not require tests to have a one-line summary. + "D205", +] + +# Do not automatically remove commented out code. +# We comment out code during development, and with VSCode auto-save, this code +# is sometimes annoyingly removed. +lint.unfixable = [ + "ERA001", +] +lint.pydocstyle.convention = "google" + [tool.pylint] [tool.pylint.'MASTER'] From 24b5475f30dfd0c8726c3beaebf77d88e38a9846 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 22 May 2024 11:03:54 +0000 Subject: [PATCH 0214/1003] --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b0ca1d1cc..d59edc077 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.2", "pyproject-fmt==2.1.3", - "pyright==1.1.363", + "pyright==1.1.364", "pyroma==4.2", "pytest==8.2.1", "pytest-cov==5.0.0", From 75ce789202311b621bd3ed5b8673bb57e85ac59d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 23 May 2024 10:35:23 +0000 Subject: [PATCH 0215/1003] Bump types-requests from 2.32.0.20240521 to 2.32.0.20240523 Bumps [types-requests](https://github.com/python/typeshed) from 2.32.0.20240521 to 2.32.0.20240523. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d59edc077..61e1c54b0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -63,7 +63,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2024.2.25", "sphinxcontrib-spelling==8", "sybil==6.1.1", - "types-requests==2.32.0.20240521", + "types-requests==2.32.0.20240523", "vulture==2.11", "vws-python-mock==2024.2.16", "vws-test-fixtures==2023.3.5", From cb5746f93d301554d93bc418e1c9f48d7b9a0a96 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 23 May 2024 10:40:41 +0000 Subject: [PATCH 0216/1003] Bump ruff from 0.4.4 to 0.4.5 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.4.4 to 0.4.5. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.4.4...v0.4.5) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 61e1c54b0..4f7e572eb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pytest==8.2.1", "pytest-cov==5.0.0", "pyyaml==6.0.1", - "ruff==0.4.4", + "ruff==0.4.5", "sphinx==7.3.7", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", From c4fa0fadd6397cf34544ec9618f0c29d8bd67309 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 24 May 2024 20:45:32 +0100 Subject: [PATCH 0217/1003] Use types_or for better pre-commit matching --- .pre-commit-config.yaml | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ac3dab718..e1e1459b8 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -15,14 +15,14 @@ repos: entry: actionlint language: system pass_filenames: false - types: [yaml] + types_or: [yaml] - id: mypy name: mypy stages: [push] entry: mypy . language: system - types: [python, toml] + types_or: [python, toml] pass_filenames: false - id: check-manifest @@ -37,21 +37,21 @@ repos: stages: [push] entry: pyright . language: system - types: [python, toml] + types_or: [python, toml] pass_filenames: false - id: vulture name: vulture entry: vulture --min-confidence 100 --exclude .eggs language: system - types: [python] + types_or: [python] - id: pyroma name: pyroma entry: pyroma --min 10 . language: system pass_filenames: false - types: [toml] + types_or: [toml] - id: deptry name: deptry @@ -70,51 +70,51 @@ repos: name: Ruff check entry: ruff check language: system - types: [python] + types_or: [python] - id: ruff-format-check name: Ruff format check entry: ruff format --check language: system - types: [python] + types_or: [python] - id: ruff-check-fix name: Ruff check fix entry: ruff check --fix language: system - types: [python] + types_or: [python] - id: ruff-format-fix name: Ruff format entry: ruff format language: system - types: [python] + types_or: [python] - id: doc8 name: doc8 entry: doc8 language: system - types: [rst] + types_or: [rst] - id: pyproject-fmt-check name: pyproject-fmt check entry: pyproject-fmt --check language: system - types: [toml] + types_or: [toml] files: pyproject.toml - id: pyproject-fmt-fix name: pyproject-fmt entry: pyproject-fmt language: system - types: [toml] + types_or: [toml] files: pyproject.toml - id: linkcheck name: linkcheck entry: make -C docs/ linkcheck SPHINXOPTS=-W language: system - types: [rst] + types_or: [rst] stages: [manual] pass_filenames: false @@ -122,7 +122,7 @@ repos: name: spelling entry: make -C docs/ spelling SPHINXOPTS=-W language: system - types: [rst] + types_or: [rst] stages: [manual] pass_filenames: false @@ -139,4 +139,4 @@ repos: entry: pyright --verifytypes vws language: system pass_filenames: false - types: [python] + types_or: [python] From eefd21b97cb551e93255ef0177932dda88ada16c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 27 May 2024 11:14:15 +0100 Subject: [PATCH 0218/1003] Add more pre-commit hooks --- .pre-commit-config.yaml | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index e1e1459b8..5bc8f6fa5 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -2,12 +2,21 @@ # See https://pre-commit.com/hooks.html for more hooks repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v3.2.0 + rev: v4.6.0 hooks: - - id: trailing-whitespace - - id: end-of-file-fixer - - id: check-yaml - id: check-added-large-files + - id: check-case-conflict + - id: check-executables-have-shebangs + - id: check-merge-conflict + - id: check-shebang-scripts-are-executable + - id: check-symlinks + - id: check-toml + - id: check-vcs-permalinks + - id: check-yaml + - id: end-of-file-fixer + - id: file-contents-sorter + files: spelling_private_dict\.txt$ + - id: trailing-whitespace - repo: local hooks: - id: actionlint From 4d3da9aa83bd2d991d8c23dbbe1c505b609a12ab Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Mon, 27 May 2024 10:15:32 +0000 Subject: [PATCH 0219/1003] [pre-commit.ci lite] apply automatic fixes --- spelling_private_dict.txt | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/spelling_private_dict.txt b/spelling_private_dict.txt index 43f9fd5b1..cdec61d5d 100644 --- a/spelling_private_dict.txt +++ b/spelling_private_dict.txt @@ -1,4 +1,3 @@ - AuthenticationFailure BadImage ConnectionErrorPossiblyImageTooLarge @@ -9,6 +8,8 @@ JSONDecodeError MatchProcessing MaxNumResultsOutOfRange MetadataTooLarge +OopsAnErrorOccurredPossiblyBadName +OopsAnErrorOccurredPossiblyBadNameError ProjectHasNoAPIAccess ProjectInactive ProjectSuspended @@ -22,8 +23,6 @@ TargetStatusProcessing TooManyRequests Ubuntu UnknownTarget -OopsAnErrorOccurredPossiblyBadName -OopsAnErrorOccurredPossiblyBadNameError admin api args From eb4ef71c39095515251584d072083a76d58e3c5c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 27 May 2024 16:42:20 +0100 Subject: [PATCH 0220/1003] Simplify pre-commit install process --- .pre-commit-config.yaml | 1 + docs/source/contributing.rst | 1 - 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 5bc8f6fa5..ab6ded914 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,5 +1,6 @@ # See https://pre-commit.com for more information # See https://pre-commit.com/hooks.html for more hooks +default_install_hook_types: [pre-commit, pre-push, commit-msg] repos: - repo: https://github.com/pre-commit/pre-commit-hooks rev: v4.6.0 diff --git a/docs/source/contributing.rst b/docs/source/contributing.rst index 2fa6203ce..d8e8b5af9 100644 --- a/docs/source/contributing.rst +++ b/docs/source/contributing.rst @@ -32,7 +32,6 @@ Install ``pre-commit`` hooks: .. prompt:: bash pre-commit install - pre-commit install --hook-type pre-push Linting ------- From de339c96dc635113f599886a74d90d597eb47bc8 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 27 May 2024 17:13:07 +0100 Subject: [PATCH 0221/1003] Add interrogate tool --- .pre-commit-config.yaml | 6 ++++++ pyproject.toml | 5 +++++ 2 files changed, 11 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ab6ded914..7a1b35bfa 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -106,6 +106,12 @@ repos: language: system types_or: [rst] + - id: interrogate + name: interrogate + entry: interrogate src/ tests/ ci/ + language: system + types_or: [python] + - id: pyproject-fmt-check name: pyproject-fmt check entry: pyproject-fmt --check diff --git a/pyproject.toml b/pyproject.toml index 4f7e572eb..7463c48c4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -296,6 +296,11 @@ strict = true reportUnnecessaryTypeIgnoreComment = true typeCheckingMode = "strict" +[tool.interrogate] +fail-under = 100 +omit-covered-files = true +verbose = 2 + [tool.doc8] max_line_length = 2000 From 27d2e6fdbe4644e281f5aeae5fd2d0195e0f0590 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 27 May 2024 17:19:06 +0100 Subject: [PATCH 0222/1003] Add interrogate tool requirement --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index 7463c48c4..81ff8b2c1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -45,6 +45,7 @@ optional-dependencies.dev = [ "doc8==1.1.1", "freezegun==1.5.1", "furo==2024.5.6", + "interrogate==1.7.0", "mypy==1.10.0", "pre-commit==3.7.1", "pydocstyle==6.3", From 30d1a9b8b9059153882d9941732a8d13f424ae13 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 27 May 2024 17:23:49 +0100 Subject: [PATCH 0223/1003] Add interrogate tool requirement --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 7a1b35bfa..dcd811506 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -108,7 +108,7 @@ repos: - id: interrogate name: interrogate - entry: interrogate src/ tests/ ci/ + entry: interrogate src/ tests/ language: system types_or: [python] From 7bb858aa33cdae1d12f564cec6d8c5a1c5f8773c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 27 May 2024 17:32:29 +0100 Subject: [PATCH 0224/1003] Add missing docstrings --- src/vws/query.py | 1 + src/vws/vws.py | 1 + 2 files changed, 2 insertions(+) diff --git a/src/vws/query.py b/src/vws/query.py index ab04781da..91e3eff9d 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -31,6 +31,7 @@ def _get_image_data(image: BinaryIO) -> bytes: + """Get the data of an image file.""" original_tell = image.tell() image.seek(0) image_data = image.read() diff --git a/src/vws/vws.py b/src/vws/vws.py index 1fdc6465a..2d76b0f88 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -54,6 +54,7 @@ def _get_image_data(image: BinaryIO) -> bytes: + """Get the data of an image file.""" original_tell = image.tell() image.seek(0) image_data = image.read() From 190688d46aea516866ecdb009ff4c2ef1415af04 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 27 May 2024 17:36:09 +0100 Subject: [PATCH 0225/1003] Limit interrogate files run against in pre-commit --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index dcd811506..40e612a80 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -108,7 +108,7 @@ repos: - id: interrogate name: interrogate - entry: interrogate src/ tests/ + entry: interrogate language: system types_or: [python] From 41fb2ef76da3aafac303ad69e93b157fb49288f9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 29 May 2024 10:26:07 +0000 Subject: [PATCH 0226/1003] Bump actionlint-py from 1.7.0.14 to 1.7.1.15 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.7.0.14 to 1.7.1.15. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.7.0.14...v1.7.1.15) --- updated-dependencies: - dependency-name: actionlint-py dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 81ff8b2c1..af14aea91 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -38,7 +38,7 @@ dependencies = [ "vws-auth-tools", ] optional-dependencies.dev = [ - "actionlint-py==1.7.0.14", + "actionlint-py==1.7.1.15", "check-manifest==0.49", "check-wheel-contents==0.6.0", "deptry==0.16.1", From b630c114a4dd83e7097d77de0c65801ce0272834 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 29 May 2024 10:31:12 +0000 Subject: [PATCH 0227/1003] Bump pyright from 1.1.364 to 1.1.365 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.364 to 1.1.365. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.364...v1.1.365) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index af14aea91..0a7b98dc1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.2", "pyproject-fmt==2.1.3", - "pyright==1.1.364", + "pyright==1.1.365", "pyroma==4.2", "pytest==8.2.1", "pytest-cov==5.0.0", From fe57be120ae23b7773598c8774ae3dc85539f1eb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 29 May 2024 10:36:14 +0000 Subject: [PATCH 0228/1003] Bump ruff from 0.4.5 to 0.4.6 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.4.5 to 0.4.6. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.4.5...v0.4.6) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0a7b98dc1..492bb5484 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pytest==8.2.1", "pytest-cov==5.0.0", "pyyaml==6.0.1", - "ruff==0.4.5", + "ruff==0.4.6", "sphinx==7.3.7", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", From dd119f487bdb8ea2479c9cbd52bbae83e8001ae0 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 29 May 2024 18:03:15 +0100 Subject: [PATCH 0229/1003] Use a timeout when making a request to the VWS API --- CHANGELOG.rst | 1 + src/vws/query.py | 2 +- src/vws/vws.py | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index de5765df6..c628649be 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -5,6 +5,7 @@ Next ---- * Breaking change: Exception names now end with ``Error``. +* Use a timeout (30 seconds) when making requests to the VWS API. 2024.02.19 ------------ diff --git a/src/vws/query.py b/src/vws/query.py index 91e3eff9d..db05fd7f5 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -142,7 +142,7 @@ def query( headers=headers, data=content, # We should make the timeout customizable. - timeout=None, + timeout=30, ) response = Response( text=requests_response.text, diff --git a/src/vws/vws.py b/src/vws/vws.py index 2d76b0f88..54a1d51cc 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -115,7 +115,7 @@ def _target_api_request( headers=headers, data=content, # We should make the timeout customizable. - timeout=None, + timeout=30, ) return Response( From 581b5a3b06169f4e205ffb0ee7c16ac3274a6225 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 3 Jun 2024 10:05:56 +0000 Subject: [PATCH 0230/1003] Bump ruff from 0.4.6 to 0.4.7 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.4.6 to 0.4.7. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.4.6...v0.4.7) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 492bb5484..fd185c8c2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pytest==8.2.1", "pytest-cov==5.0.0", "pyyaml==6.0.1", - "ruff==0.4.6", + "ruff==0.4.7", "sphinx==7.3.7", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", From bec3a8f679542a86acb213b5a6820de079eb7a51 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 3 Jun 2024 10:10:49 +0000 Subject: [PATCH 0231/1003] Bump types-requests from 2.32.0.20240523 to 2.32.0.20240602 Bumps [types-requests](https://github.com/python/typeshed) from 2.32.0.20240523 to 2.32.0.20240602. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index fd185c8c2..9f04ba048 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -64,7 +64,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2024.2.25", "sphinxcontrib-spelling==8", "sybil==6.1.1", - "types-requests==2.32.0.20240523", + "types-requests==2.32.0.20240602", "vulture==2.11", "vws-python-mock==2024.2.16", "vws-test-fixtures==2023.3.5", From 838d651fe8163ce0605434bed1e3ee616c8d872f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 5 Jun 2024 10:09:01 +0000 Subject: [PATCH 0232/1003] Bump pytest from 8.2.1 to 8.2.2 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.2.1 to 8.2.2. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.2.1...8.2.2) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9f04ba048..99a09d070 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pyproject-fmt==2.1.3", "pyright==1.1.365", "pyroma==4.2", - "pytest==8.2.1", + "pytest==8.2.2", "pytest-cov==5.0.0", "pyyaml==6.0.1", "ruff==0.4.7", From 3cb3dad15199ecc0a33b8f12792e33fc1d4bcccb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 6 Jun 2024 10:37:02 +0000 Subject: [PATCH 0233/1003] Bump ruff from 0.4.7 to 0.4.8 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.4.7 to 0.4.8. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.4.7...v0.4.8) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 99a09d070..4b4a33037 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pytest==8.2.2", "pytest-cov==5.0.0", "pyyaml==6.0.1", - "ruff==0.4.7", + "ruff==0.4.8", "sphinx==7.3.7", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", From 00524ea14ca8850f4c55dd0c619da6f7736cab4b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 6 Jun 2024 10:42:29 +0000 Subject: [PATCH 0234/1003] Bump pyright from 1.1.365 to 1.1.366 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.365 to 1.1.366. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.365...v1.1.366) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4b4a33037..b03e458f7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.2", "pyproject-fmt==2.1.3", - "pyright==1.1.365", + "pyright==1.1.366", "pyroma==4.2", "pytest==8.2.2", "pytest-cov==5.0.0", From c356487d131cf2d357234426fd727c87ad235358 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 7 Jun 2024 10:23:08 +0000 Subject: [PATCH 0235/1003] Bump pylint from 3.2.2 to 3.2.3 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.2.2 to 3.2.3. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.2.2...v3.2.3) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b03e458f7..97cc44b06 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pyenchant==3.2.2", "pygments==2.18.0", - "pylint==3.2.2", + "pylint==3.2.3", "pyproject-fmt==2.1.3", "pyright==1.1.366", "pyroma==4.2", From b10ed85595fd3eb4cce902f8eea117af7e80d187 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 11 Jun 2024 09:13:57 +0100 Subject: [PATCH 0236/1003] Update VWS links to work again --- src/vws/exceptions/base_exceptions.py | 2 +- src/vws/exceptions/custom_exceptions.py | 2 +- src/vws/exceptions/vws_exceptions.py | 2 +- src/vws/query.py | 2 +- src/vws/reports.py | 12 ++++++------ src/vws/vws.py | 18 +++++++++--------- 6 files changed, 19 insertions(+), 19 deletions(-) diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index 6558242c5..13a995fbd 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -37,7 +37,7 @@ class VWSError(Exception): Base class for Vuforia Web Services errors. These errors are defined at - https://library.vuforia.com/web-api/cloud-targets-web-services-api#result-codes. + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#result-codes. """ def __init__(self, response: Response) -> None: diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index 1c7790cbf..33f98187c 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -1,6 +1,6 @@ """ Exceptions which do not map to errors at -https://library.vuforia.com/web-api/cloud-targets-web-services-api#result-codes +https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#result-codes or simple errors given by the cloud recognition service. """ diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index 9d00d7518..f626aeee6 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -1,7 +1,7 @@ """ Exception raised when Vuforia returns a response with a result code matching one of those documented at -https://library.vuforia.com/web-api/cloud-targets-web-services-api#result-codes. +https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#result-codes. """ import json diff --git a/src/vws/query.py b/src/vws/query.py index db05fd7f5..cb86373da 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -72,7 +72,7 @@ def query( Use the Vuforia Web Query API to make an Image Recognition Query. See - https://library.vuforia.com/web-api/vuforia-query-web-api + https://developer.vuforia.com/library/web-api/vuforia-query-web-api for parameter details. Args: diff --git a/src/vws/reports.py b/src/vws/reports.py index 479690cdd..2784ff078 100644 --- a/src/vws/reports.py +++ b/src/vws/reports.py @@ -13,7 +13,7 @@ class DatabaseSummaryReport: A database summary report. See - https://library.vuforia.com/web-api/cloud-targets-web-services-api#summary-report. + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#summary-report. """ active_images: int @@ -34,7 +34,7 @@ class TargetStatuses(Enum): """Constants representing VWS target statuses. See the 'status' field in - https://library.vuforia.com/web-api/cloud-targets-web-services-api#target-record + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#target-record """ PROCESSING = "processing" @@ -48,7 +48,7 @@ class TargetSummaryReport: A target summary report. See - https://library.vuforia.com/web-api/cloud-targets-web-services-api#summary-report. + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#summary-report. """ status: TargetStatuses @@ -68,7 +68,7 @@ class TargetRecord: A target record. See - https://library.vuforia.com/web-api/cloud-targets-web-services-api#target-record. + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#target-record. """ target_id: str @@ -96,7 +96,7 @@ class QueryResult: One query match result. See - https://library.vuforia.com/web-api/vuforia-query-web-api. + https://developer.vuforia.com/library/web-api/vuforia-query-web-api. """ target_id: str @@ -109,7 +109,7 @@ class TargetStatusAndRecord: The target status and a target record. See - https://library.vuforia.com/web-api/cloud-targets-web-services-api#target-record. + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#target-record. """ status: TargetStatuses diff --git a/src/vws/vws.py b/src/vws/vws.py index 54a1d51cc..30d2638b9 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -167,7 +167,7 @@ def _make_request( request_path: The path to the endpoint which will be used in the request. expected_result_code: See - https://library.vuforia.com/web-api/cloud-targets-web-services-api#result-codes + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#result-codes Returns: The response to the request made by `requests`. @@ -247,7 +247,7 @@ def add_target( Add a target to a Vuforia Web Services database. See - https://library.vuforia.com/web-api/cloud-targets-web-services-api#add + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#add for parameter details. Args: @@ -319,7 +319,7 @@ def get_target_record(self, target_id: str) -> TargetStatusAndRecord: Get a given target's target record from the Target Management System. See - https://library.vuforia.com/web-api/cloud-targets-web-services-api#target-record. + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#target-record. Args: target_id: The ID of the target to get details of. @@ -420,7 +420,7 @@ def list_targets(self) -> list[str]: List target IDs. See - https://library.vuforia.com/web-api/cloud-targets-web-services-api#details-list. + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#details-list. Returns: The IDs of all targets in the database. @@ -452,7 +452,7 @@ def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: Get a summary report for a target. See - https://library.vuforia.com/web-api/cloud-targets-web-services-api#summary-report. + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#summary-report. Args: target_id: The ID of the target to get a summary report for. @@ -500,7 +500,7 @@ def get_database_summary_report(self) -> DatabaseSummaryReport: Get a summary report for the database. See - https://library.vuforia.com/web-api/cloud-targets-web-services-api#summary-report. + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#summary-report. Returns: Details of the database. @@ -546,7 +546,7 @@ def delete_target(self, target_id: str) -> None: Delete a given target. See - https://library.vuforia.com/web-api/cloud-targets-web-services-api#delete. + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#delete. Args: target_id: The ID of the target to delete. @@ -580,7 +580,7 @@ def get_duplicate_targets(self, target_id: str) -> list[str]: Get targets which may be considered duplicates of a given target. See - https://library.vuforia.com/web-api/cloud-targets-web-services-api#check. + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#check. Args: target_id: The ID of the target to delete. @@ -627,7 +627,7 @@ def update_target( Add a target to a Vuforia Web Services database. See - https://library.vuforia.com/web-api/cloud-targets-web-services-api#add + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#add for parameter details. Args: From d5e13932e943aa184edd2dfd8ecf1f176234f70b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 12 Jun 2024 10:37:14 +0000 Subject: [PATCH 0237/1003] Bump pyright from 1.1.366 to 1.1.367 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.366 to 1.1.367. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.366...v1.1.367) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 97cc44b06..2aaaab0f9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.3", "pyproject-fmt==2.1.3", - "pyright==1.1.366", + "pyright==1.1.367", "pyroma==4.2", "pytest==8.2.2", "pytest-cov==5.0.0", From 9e9a93edf2277b5b4deb9520cc2e8015709a1b28 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 17 Jun 2024 10:25:20 +0000 Subject: [PATCH 0238/1003] Bump ruff from 0.4.8 to 0.4.9 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.4.8 to 0.4.9. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.4.8...v0.4.9) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2aaaab0f9..ae1210943 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pytest==8.2.2", "pytest-cov==5.0.0", "pyyaml==6.0.1", - "ruff==0.4.8", + "ruff==0.4.9", "sphinx==7.3.7", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", From 5e039c659abc08901b3afc743e952753bb8232bc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 19 Jun 2024 10:29:42 +0000 Subject: [PATCH 0239/1003] Bump pyright from 1.1.367 to 1.1.368 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.367 to 1.1.368. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.367...v1.1.368) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ae1210943..aee9c6133 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.3", "pyproject-fmt==2.1.3", - "pyright==1.1.367", + "pyright==1.1.368", "pyroma==4.2", "pytest==8.2.2", "pytest-cov==5.0.0", From e52331013d9034514b10dfc4294f3f731254d897 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 21 Jun 2024 10:13:16 +0000 Subject: [PATCH 0240/1003] Bump ruff from 0.4.9 to 0.4.10 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.4.9 to 0.4.10. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.4.9...v0.4.10) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index aee9c6133..2ea433be4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pytest==8.2.2", "pytest-cov==5.0.0", "pyyaml==6.0.1", - "ruff==0.4.9", + "ruff==0.4.10", "sphinx==7.3.7", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", From 1fea6b64c0d353349df9d8c1beff9aefc16fdfa3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Jun 2024 10:55:46 +0000 Subject: [PATCH 0241/1003] Bump types-requests from 2.32.0.20240602 to 2.32.0.20240622 Bumps [types-requests](https://github.com/python/typeshed) from 2.32.0.20240602 to 2.32.0.20240622. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2ea433be4..5ce6e4829 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -64,7 +64,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2024.2.25", "sphinxcontrib-spelling==8", "sybil==6.1.1", - "types-requests==2.32.0.20240602", + "types-requests==2.32.0.20240622", "vulture==2.11", "vws-python-mock==2024.2.16", "vws-test-fixtures==2023.3.5", From d2a9698f0ca0d95deab8aeaffb66f76184e2ff3e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 25 Jun 2024 10:25:52 +0000 Subject: [PATCH 0242/1003] Bump mypy from 1.10.0 to 1.10.1 Bumps [mypy](https://github.com/python/mypy) from 1.10.0 to 1.10.1. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.10.0...v1.10.1) --- updated-dependencies: - dependency-name: mypy dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5ce6e4829..0d834bdff 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -46,7 +46,7 @@ optional-dependencies.dev = [ "freezegun==1.5.1", "furo==2024.5.6", "interrogate==1.7.0", - "mypy==1.10.0", + "mypy==1.10.1", "pre-commit==3.7.1", "pydocstyle==6.3", "pyenchant==3.2.2", From b5330d91339f535724d6caa6e0804815ec39470d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 26 Jun 2024 10:53:11 +0000 Subject: [PATCH 0243/1003] Bump pylint from 3.2.3 to 3.2.4 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.2.3 to 3.2.4. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.2.3...v3.2.4) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0d834bdff..4587f38b9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pyenchant==3.2.2", "pygments==2.18.0", - "pylint==3.2.3", + "pylint==3.2.4", "pyproject-fmt==2.1.3", "pyright==1.1.368", "pyroma==4.2", From 65576690297a0024dd3d5fed4bddc20ad7cecdeb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 28 Jun 2024 10:39:33 +0000 Subject: [PATCH 0244/1003] Bump ruff from 0.4.10 to 0.5.0 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.4.10 to 0.5.0. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/v0.4.10...0.5.0) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4587f38b9..2c23d4acd 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pytest==8.2.2", "pytest-cov==5.0.0", "pyyaml==6.0.1", - "ruff==0.4.10", + "ruff==0.5.0", "sphinx==7.3.7", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", From 62575fa03f36cd8ac131475e1184a4f595e92604 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 28 Jun 2024 11:20:17 +0000 Subject: [PATCH 0245/1003] Bump pyright from 1.1.368 to 1.1.369 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.368 to 1.1.369. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.368...v1.1.369) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2c23d4acd..549f372bc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.4", "pyproject-fmt==2.1.3", - "pyright==1.1.368", + "pyright==1.1.369", "pyroma==4.2", "pytest==8.2.2", "pytest-cov==5.0.0", From 05d69fc22ea6873a954824172409d23cb516dbbc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 1 Jul 2024 10:26:02 +0000 Subject: [PATCH 0246/1003] Bump pylint from 3.2.4 to 3.2.5 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.2.4 to 3.2.5. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.2.4...v3.2.5) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 549f372bc..fc89a68e7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pyenchant==3.2.2", "pygments==2.18.0", - "pylint==3.2.4", + "pylint==3.2.5", "pyproject-fmt==2.1.3", "pyright==1.1.369", "pyroma==4.2", From 75feb5a5a6bb4806573a49be43d9c792f098fac7 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 2 Jul 2024 14:15:02 +0100 Subject: [PATCH 0247/1003] Install check-wheel-contents before attempting to use it in release process --- .github/workflows/release.yml | 2 +- pyproject.toml | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 2d92b7124..237858d8b 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -81,7 +81,7 @@ jobs: # Checkout the latest tag - the one we just created. git fetch --tags git checkout "$(git describe --tags "$(git rev-list --tags --max-count=1)")" - python -m pip install build + python -m pip install build check-wheel-contents python -m build --sdist --wheel --outdir dist/ . check-wheel-contents dist/*.whl diff --git a/pyproject.toml b/pyproject.toml index fc89a68e7..f9805b24b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -40,7 +40,6 @@ dependencies = [ optional-dependencies.dev = [ "actionlint-py==1.7.1.15", "check-manifest==0.49", - "check-wheel-contents==0.6.0", "deptry==0.16.1", "doc8==1.1.1", "freezegun==1.5.1", From c805b4a99608a84483ff313fac9dc76eec293a47 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 2 Jul 2024 13:28:34 +0000 Subject: [PATCH 0248/1003] Bump vws-python-mock from 2024.2.16 to 2024.7.2.1 Bumps [vws-python-mock](https://github.com/VWS-Python/vws-python-mock) from 2024.2.16 to 2024.7.2.1. - [Release notes](https://github.com/VWS-Python/vws-python-mock/releases) - [Changelog](https://github.com/VWS-Python/vws-python-mock/blob/main/CHANGELOG.rst) - [Commits](https://github.com/VWS-Python/vws-python-mock/compare/2024.02.16...2024.07.02.1) --- updated-dependencies: - dependency-name: vws-python-mock dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f9805b24b..d15ae4691 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -65,7 +65,7 @@ optional-dependencies.dev = [ "sybil==6.1.1", "types-requests==2.32.0.20240622", "vulture==2.11", - "vws-python-mock==2024.2.16", + "vws-python-mock==2024.7.2.1", "vws-test-fixtures==2023.3.5", ] urls.Documentation = "https://vws-python.readthedocs.io/en/latest/" From 84f7028075f72774c46770769ab48ec63b3853e8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 3 Jul 2024 11:03:34 +0000 Subject: [PATCH 0249/1003] Bump pyright from 1.1.369 to 1.1.370 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.369 to 1.1.370. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.369...v1.1.370) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d15ae4691..e5b31bf2b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.5", "pyproject-fmt==2.1.3", - "pyright==1.1.369", + "pyright==1.1.370", "pyroma==4.2", "pytest==8.2.2", "pytest-cov==5.0.0", From 85e8a7c8c8b1fe4869a98f38059bb158c17cff51 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 3 Jul 2024 11:07:56 +0000 Subject: [PATCH 0250/1003] Bump pyproject-fmt from 2.1.3 to 2.1.4 Bumps [pyproject-fmt](https://github.com/tox-dev/pyproject-fmt) from 2.1.3 to 2.1.4. - [Release notes](https://github.com/tox-dev/pyproject-fmt/releases) - [Commits](https://github.com/tox-dev/pyproject-fmt/compare/2.1.3...2.1.4) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e5b31bf2b..a21209cb7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pyenchant==3.2.2", "pygments==2.18.0", "pylint==3.2.5", - "pyproject-fmt==2.1.3", + "pyproject-fmt==2.1.4", "pyright==1.1.370", "pyroma==4.2", "pytest==8.2.2", From f0b363641794219ee86e8941d715d9589da04abf Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Jul 2024 10:58:46 +0000 Subject: [PATCH 0251/1003] Bump deptry from 0.16.1 to 0.16.2 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.16.1 to 0.16.2. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.16.1...0.16.2) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a21209cb7..6f17b9faa 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -40,7 +40,7 @@ dependencies = [ optional-dependencies.dev = [ "actionlint-py==1.7.1.15", "check-manifest==0.49", - "deptry==0.16.1", + "deptry==0.16.2", "doc8==1.1.1", "freezegun==1.5.1", "furo==2024.5.6", From 4b4c2286d831b3bb7e6c35e94c9467856f577007 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Jul 2024 11:03:38 +0000 Subject: [PATCH 0252/1003] Bump ruff from 0.5.0 to 0.5.1 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.5.0 to 0.5.1. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.5.0...0.5.1) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6f17b9faa..73010680c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pytest==8.2.2", "pytest-cov==5.0.0", "pyyaml==6.0.1", - "ruff==0.5.0", + "ruff==0.5.1", "sphinx==7.3.7", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", From 12d5b47eb6369d842c972970ac849a171d21e63e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 10 Jul 2024 10:08:52 +0000 Subject: [PATCH 0253/1003] Bump pyright from 1.1.370 to 1.1.371 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.370 to 1.1.371. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.370...v1.1.371) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 73010680c..fab59ba58 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.5", "pyproject-fmt==2.1.4", - "pyright==1.1.370", + "pyright==1.1.371", "pyroma==4.2", "pytest==8.2.2", "pytest-cov==5.0.0", From 8dacba61aa71a58f10dddfe14b4b64778bbaf443 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 12 Jul 2024 10:30:49 +0000 Subject: [PATCH 0254/1003] Bump types-requests from 2.32.0.20240622 to 2.32.0.20240712 Bumps [types-requests](https://github.com/python/typeshed) from 2.32.0.20240622 to 2.32.0.20240712. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index fab59ba58..5285b75ba 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -63,7 +63,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2024.2.25", "sphinxcontrib-spelling==8", "sybil==6.1.1", - "types-requests==2.32.0.20240622", + "types-requests==2.32.0.20240712", "vulture==2.11", "vws-python-mock==2024.7.2.1", "vws-test-fixtures==2023.3.5", From 5543b810235628557bec10e29100060ac32dbf65 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 13 Jul 2024 17:14:02 +0100 Subject: [PATCH 0255/1003] Use more common way of encoding bytes - for readability --- src/vws/vws.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/vws/vws.py b/src/vws/vws.py index 30d2638b9..dd3bbf239 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -293,7 +293,9 @@ def add_target( rate limiting access. """ image_data = _get_image_data(image=image) - image_data_encoded = base64.b64encode(image_data).decode("ascii") + image_data_encoded = base64.b64encode(s=image_data).decode( + encoding="ascii", + ) data = { "name": name, @@ -303,7 +305,7 @@ def add_target( "application_metadata": application_metadata, } - content = bytes(json.dumps(data), encoding="utf-8") + content = json.dumps(obj=data).encode(encoding="utf-8") response = self._make_request( method=HTTPMethod.POST, @@ -687,7 +689,7 @@ def update_target( if application_metadata is not None: data["application_metadata"] = application_metadata - content = bytes(json.dumps(data), encoding="utf-8") + content = json.dumps(obj=data).encode(encoding="utf-8") self._make_request( method=HTTPMethod.PUT, From 8b916a92734309e9b70521d25114017c714bbf78 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 13 Jul 2024 21:57:56 +0100 Subject: [PATCH 0256/1003] Fix reference errors in update_target docs --- src/vws/vws.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vws/vws.py b/src/vws/vws.py index dd3bbf239..03a23f5c1 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -626,14 +626,14 @@ def update_target( application_metadata: str | None = None, ) -> None: """ - Add a target to a Vuforia Web Services database. + Update a target in a Vuforia Web Services database. See - https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#add + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#update for parameter details. Args: - target_id: The ID of the target to get details of. + target_id: The ID of the target to update. name: The name of the target. width: The width of the target. image: The image of the target. From d1eb5570c1be3cbe396fb7c81196941eb79fc858 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 15 Jul 2024 10:37:03 +0000 Subject: [PATCH 0257/1003] Bump ruff from 0.5.1 to 0.5.2 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.5.1 to 0.5.2. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.5.1...0.5.2) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5285b75ba..cbb05e19a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pytest==8.2.2", "pytest-cov==5.0.0", "pyyaml==6.0.1", - "ruff==0.5.1", + "ruff==0.5.2", "sphinx==7.3.7", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", From 73bb66ef4a5227a365bce1e826db18769df108ba Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 15 Jul 2024 10:41:45 +0000 Subject: [PATCH 0258/1003] Bump sphinx from 7.3.7 to 7.4.1 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 7.3.7 to 7.4.1. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v7.3.7...v7.4.1) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index cbb05e19a..d865924e6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pytest-cov==5.0.0", "pyyaml==6.0.1", "ruff==0.5.2", - "sphinx==7.3.7", + "sphinx==7.4.1", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", "sphinxcontrib-spelling==8", From 3f2e5ec2e6c1ac34697e88afbb3000ac4e69e8ea Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 15 Jul 2024 18:15:45 +0100 Subject: [PATCH 0259/1003] Rename internal 'content' argument name to match requests --- src/vws/vws.py | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/src/vws/vws.py b/src/vws/vws.py index 03a23f5c1..8b1c3b7fc 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -66,7 +66,7 @@ def _target_api_request( server_access_key: str, server_secret_key: str, method: str, - content: bytes, + data: bytes, request_path: str, base_vws_url: str, ) -> Response: @@ -80,7 +80,7 @@ def _target_api_request( server_access_key: A VWS server access key. server_secret_key: A VWS server secret key. method: The HTTP method which will be used in the request. - content: The request body which will be used in the request. + data: The request body which will be used in the request. request_path: The path to the endpoint which will be used in the request. base_vws_url: The base URL for the VWS API. @@ -95,7 +95,7 @@ def _target_api_request( access_key=server_access_key, secret_key=server_secret_key, method=method, - content=content, + content=data, content_type=content_type, date=date_string, request_path=request_path, @@ -113,7 +113,7 @@ def _target_api_request( method=method, url=url, headers=headers, - data=content, + data=data, # We should make the timeout customizable. timeout=30, ) @@ -151,7 +151,7 @@ def __init__( def _make_request( self, method: str, - content: bytes, + data: bytes, request_path: str, expected_result_code: str, ) -> Response: @@ -163,7 +163,7 @@ def _make_request( Args: method: The HTTP method which will be used in the request. - content: The request body which will be used in the request. + data: The request body which will be used in the request. request_path: The path to the endpoint which will be used in the request. expected_result_code: See @@ -189,7 +189,7 @@ def _make_request( server_access_key=self._server_access_key, server_secret_key=self._server_secret_key, method=method, - content=content, + data=data, request_path=request_path, base_vws_url=self._base_vws_url, ) @@ -309,7 +309,7 @@ def add_target( response = self._make_request( method=HTTPMethod.POST, - content=content, + data=content, request_path="/targets", expected_result_code="TargetCreated", ) @@ -346,7 +346,7 @@ def get_target_record(self, target_id: str) -> TargetStatusAndRecord: """ response = self._make_request( method=HTTPMethod.GET, - content=b"", + data=b"", request_path=f"/targets/{target_id}", expected_result_code="Success", ) @@ -442,7 +442,7 @@ def list_targets(self) -> list[str]: """ response = self._make_request( method=HTTPMethod.GET, - content=b"", + data=b"", request_path="/targets", expected_result_code="Success", ) @@ -479,7 +479,7 @@ def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: """ response = self._make_request( method=HTTPMethod.GET, - content=b"", + data=b"", request_path=f"/summary/{target_id}", expected_result_code="Success", ) @@ -522,7 +522,7 @@ def get_database_summary_report(self) -> DatabaseSummaryReport: """ response = self._make_request( method=HTTPMethod.GET, - content=b"", + data=b"", request_path="/summary", expected_result_code="Success", ) @@ -572,7 +572,7 @@ def delete_target(self, target_id: str) -> None: """ self._make_request( method=HTTPMethod.DELETE, - content=b"", + data=b"", request_path=f"/targets/{target_id}", expected_result_code="Success", ) @@ -609,7 +609,7 @@ def get_duplicate_targets(self, target_id: str) -> list[str]: """ response = self._make_request( method=HTTPMethod.GET, - content=b"", + data=b"", request_path=f"/duplicates/{target_id}", expected_result_code="Success", ) @@ -693,7 +693,7 @@ def update_target( self._make_request( method=HTTPMethod.PUT, - content=content, + data=content, request_path=f"/targets/{target_id}", expected_result_code="Success", ) From 4766111942ff5cd95b4e5c19f450d62e14ce2da7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 16 Jul 2024 10:39:15 +0000 Subject: [PATCH 0260/1003] Bump sphinx from 7.4.1 to 7.4.4 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 7.4.1 to 7.4.4. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v7.4.1...v7.4.4) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d865924e6..efc783a17 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pytest-cov==5.0.0", "pyyaml==6.0.1", "ruff==0.5.2", - "sphinx==7.4.1", + "sphinx==7.4.4", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", "sphinxcontrib-spelling==8", From d9cd52c0cae1de82fdf8df7a520ae6d9d77fcb3b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 16 Jul 2024 10:43:57 +0000 Subject: [PATCH 0261/1003] Bump vws-python-mock from 2024.7.2.1 to 2024.7.15 Bumps [vws-python-mock](https://github.com/VWS-Python/vws-python-mock) from 2024.7.2.1 to 2024.7.15. - [Release notes](https://github.com/VWS-Python/vws-python-mock/releases) - [Changelog](https://github.com/VWS-Python/vws-python-mock/blob/main/CHANGELOG.rst) - [Commits](https://github.com/VWS-Python/vws-python-mock/compare/2024.07.02.1...2024.07.15) --- updated-dependencies: - dependency-name: vws-python-mock dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index efc783a17..7d63025c7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -65,7 +65,7 @@ optional-dependencies.dev = [ "sybil==6.1.1", "types-requests==2.32.0.20240712", "vulture==2.11", - "vws-python-mock==2024.7.2.1", + "vws-python-mock==2024.7.15", "vws-test-fixtures==2023.3.5", ] urls.Documentation = "https://vws-python.readthedocs.io/en/latest/" From 416795d6dd668060c72079d041a1c2113f15f2e2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 17 Jul 2024 11:03:08 +0000 Subject: [PATCH 0262/1003] Bump sphinx from 7.4.4 to 7.4.5 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 7.4.4 to 7.4.5. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v7.4.4...v7.4.5) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7d63025c7..860450181 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pytest-cov==5.0.0", "pyyaml==6.0.1", "ruff==0.5.2", - "sphinx==7.4.4", + "sphinx==7.4.5", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", "sphinxcontrib-spelling==8", From e83040c5c8e8c3b2dc539b9e685a9723bc92d18f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 17 Jul 2024 11:07:44 +0000 Subject: [PATCH 0263/1003] Bump pyright from 1.1.371 to 1.1.372 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.371 to 1.1.372. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.371...v1.1.372) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 860450181..e29c23c6d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.5", "pyproject-fmt==2.1.4", - "pyright==1.1.371", + "pyright==1.1.372", "pyroma==4.2", "pytest==8.2.2", "pytest-cov==5.0.0", From 16ab55dedab73e36c242569cbe66b7022388da5c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 18 Jul 2024 10:53:41 +0000 Subject: [PATCH 0264/1003] Bump furo from 2024.5.6 to 2024.7.18 Bumps [furo](https://github.com/pradyunsg/furo) from 2024.5.6 to 2024.7.18. - [Release notes](https://github.com/pradyunsg/furo/releases) - [Changelog](https://github.com/pradyunsg/furo/blob/main/docs/changelog.md) - [Commits](https://github.com/pradyunsg/furo/compare/2024.05.06...2024.07.18) --- updated-dependencies: - dependency-name: furo dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e29c23c6d..dcaeaaf88 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "deptry==0.16.2", "doc8==1.1.1", "freezegun==1.5.1", - "furo==2024.5.6", + "furo==2024.7.18", "interrogate==1.7.0", "mypy==1.10.1", "pre-commit==3.7.1", From 0f885f0ef06faee757336565fa7322e75c9c483c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 19 Jul 2024 10:14:20 +0000 Subject: [PATCH 0265/1003] Bump sphinx from 7.4.5 to 7.4.6 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 7.4.5 to 7.4.6. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v7.4.5...v7.4.6) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index dcaeaaf88..01aeb4576 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pytest-cov==5.0.0", "pyyaml==6.0.1", "ruff==0.5.2", - "sphinx==7.4.5", + "sphinx==7.4.6", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", "sphinxcontrib-spelling==8", From fcfebe8ecac40fafdcd207409cd48bb7c6e8ac9f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 19 Jul 2024 10:19:07 +0000 Subject: [PATCH 0266/1003] Bump ruff from 0.5.2 to 0.5.3 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.5.2 to 0.5.3. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.5.2...0.5.3) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 01aeb4576..177ecd24a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pytest==8.2.2", "pytest-cov==5.0.0", "pyyaml==6.0.1", - "ruff==0.5.2", + "ruff==0.5.3", "sphinx==7.4.6", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", From 1dcfc2a49a09b5a98e3e05186dc2567fc3cb3162 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 22 Jul 2024 10:42:30 +0000 Subject: [PATCH 0267/1003] Bump ruff from 0.5.3 to 0.5.4 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.5.3 to 0.5.4. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.5.3...0.5.4) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 177ecd24a..611713390 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pytest==8.2.2", "pytest-cov==5.0.0", "pyyaml==6.0.1", - "ruff==0.5.3", + "ruff==0.5.4", "sphinx==7.4.6", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", From 5569e8367692a2959e70648a10591383c3393b54 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 22 Jul 2024 10:46:54 +0000 Subject: [PATCH 0268/1003] Bump deptry from 0.16.2 to 0.17.0 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.16.2 to 0.17.0. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.16.2...0.17.0) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 611713390..31603d3b7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -40,7 +40,7 @@ dependencies = [ optional-dependencies.dev = [ "actionlint-py==1.7.1.15", "check-manifest==0.49", - "deptry==0.16.2", + "deptry==0.17.0", "doc8==1.1.1", "freezegun==1.5.1", "furo==2024.7.18", From ba2f5675b233193b2ee7e67e7106df32ad812832 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 22 Jul 2024 10:51:37 +0000 Subject: [PATCH 0269/1003] Bump pylint from 3.2.5 to 3.2.6 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.2.5 to 3.2.6. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.2.5...v3.2.6) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 31603d3b7..4124a8348 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -50,7 +50,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pyenchant==3.2.2", "pygments==2.18.0", - "pylint==3.2.5", + "pylint==3.2.6", "pyproject-fmt==2.1.4", "pyright==1.1.372", "pyroma==4.2", From 5196a9c42d8d84807ed73a7d3d6fd2701f78c9c1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 22 Jul 2024 10:56:03 +0000 Subject: [PATCH 0270/1003] Bump sphinx from 7.4.6 to 7.4.7 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 7.4.6 to 7.4.7. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v7.4.6...v7.4.7) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4124a8348..f0eab5e80 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pytest-cov==5.0.0", "pyyaml==6.0.1", "ruff==0.5.4", - "sphinx==7.4.6", + "sphinx==7.4.7", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", "sphinxcontrib-spelling==8", From b9f3959290f7a5916d4cc8c63df0537670196320 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 22 Jul 2024 11:00:42 +0000 Subject: [PATCH 0271/1003] Bump pytest from 8.2.2 to 8.3.1 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.2.2 to 8.3.1. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.2.2...8.3.1) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f0eab5e80..9041c88c6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pyproject-fmt==2.1.4", "pyright==1.1.372", "pyroma==4.2", - "pytest==8.2.2", + "pytest==8.3.1", "pytest-cov==5.0.0", "pyyaml==6.0.1", "ruff==0.5.4", From 9212bf7dfacfbf7496e0b9b1c82e99485bc0297e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 22 Jul 2024 11:05:44 +0000 Subject: [PATCH 0272/1003] Bump mypy from 1.10.1 to 1.11.0 Bumps [mypy](https://github.com/python/mypy) from 1.10.1 to 1.11.0. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.10.1...v1.11) --- updated-dependencies: - dependency-name: mypy dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9041c88c6..4a58bc6b7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -45,7 +45,7 @@ optional-dependencies.dev = [ "freezegun==1.5.1", "furo==2024.7.18", "interrogate==1.7.0", - "mypy==1.10.1", + "mypy==1.11.0", "pre-commit==3.7.1", "pydocstyle==6.3", "pyenchant==3.2.2", From 340c7c7dd5e135102362c66b419f3db2bfc887f2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 24 Jul 2024 10:25:05 +0000 Subject: [PATCH 0273/1003] Bump pyright from 1.1.372 to 1.1.373 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.372 to 1.1.373. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.372...v1.1.373) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4a58bc6b7..d5713249d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.6", "pyproject-fmt==2.1.4", - "pyright==1.1.372", + "pyright==1.1.373", "pyroma==4.2", "pytest==8.3.1", "pytest-cov==5.0.0", From ce2a1e65962d0c64195eb1f136c4dbe06a337c7f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 26 Jul 2024 10:25:07 +0000 Subject: [PATCH 0274/1003] Bump ruff from 0.5.4 to 0.5.5 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.5.4 to 0.5.5. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.5.4...0.5.5) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d5713249d..35abcd163 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pytest==8.3.1", "pytest-cov==5.0.0", "pyyaml==6.0.1", - "ruff==0.5.4", + "ruff==0.5.5", "sphinx==7.4.7", "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", From aff714381dab2ac484cb6488faca306734f6895f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 26 Jul 2024 10:30:09 +0000 Subject: [PATCH 0275/1003] Bump pytest from 8.3.1 to 8.3.2 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.3.1 to 8.3.2. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.3.1...8.3.2) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 35abcd163..c247c1798 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pyproject-fmt==2.1.4", "pyright==1.1.373", "pyroma==4.2", - "pytest==8.3.1", + "pytest==8.3.2", "pytest-cov==5.0.0", "pyyaml==6.0.1", "ruff==0.5.5", From 225b0dc955484152108b6e153b09a8876cb7829e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 29 Jul 2024 10:37:26 +0000 Subject: [PATCH 0276/1003] Bump pre-commit from 3.7.1 to 3.8.0 Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 3.7.1 to 3.8.0. - [Release notes](https://github.com/pre-commit/pre-commit/releases) - [Changelog](https://github.com/pre-commit/pre-commit/blob/main/CHANGELOG.md) - [Commits](https://github.com/pre-commit/pre-commit/compare/v3.7.1...v3.8.0) --- updated-dependencies: - dependency-name: pre-commit dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c247c1798..2c5fa9a76 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -46,7 +46,7 @@ optional-dependencies.dev = [ "furo==2024.7.18", "interrogate==1.7.0", "mypy==1.11.0", - "pre-commit==3.7.1", + "pre-commit==3.8.0", "pydocstyle==6.3", "pyenchant==3.2.2", "pygments==2.18.0", From 110c352670a72381bb9e8b3f9b312b41bf616c5b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 31 Jul 2024 10:30:43 +0000 Subject: [PATCH 0277/1003] Bump mypy from 1.11.0 to 1.11.1 Bumps [mypy](https://github.com/python/mypy) from 1.11.0 to 1.11.1. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.11...v1.11.1) --- updated-dependencies: - dependency-name: mypy dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2c5fa9a76..4adea5f26 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -45,7 +45,7 @@ optional-dependencies.dev = [ "freezegun==1.5.1", "furo==2024.7.18", "interrogate==1.7.0", - "mypy==1.11.0", + "mypy==1.11.1", "pre-commit==3.8.0", "pydocstyle==6.3", "pyenchant==3.2.2", From 9912cee7106246de8f4e7b942d1f92e0724a2ab4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 31 Jul 2024 10:35:35 +0000 Subject: [PATCH 0278/1003] Bump deptry from 0.17.0 to 0.18.0 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.17.0 to 0.18.0. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.17.0...0.18.0) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4adea5f26..ab38adbe3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -40,7 +40,7 @@ dependencies = [ optional-dependencies.dev = [ "actionlint-py==1.7.1.15", "check-manifest==0.49", - "deptry==0.17.0", + "deptry==0.18.0", "doc8==1.1.1", "freezegun==1.5.1", "furo==2024.7.18", From 804cb86c6fba4207724f27365a75d76fc043bd77 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 31 Jul 2024 10:40:00 +0000 Subject: [PATCH 0279/1003] Bump pyright from 1.1.373 to 1.1.374 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.373 to 1.1.374. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.373...v1.1.374) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ab38adbe3..40a25ee5d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.6", "pyproject-fmt==2.1.4", - "pyright==1.1.373", + "pyright==1.1.374", "pyroma==4.2", "pytest==8.3.2", "pytest-cov==5.0.0", From c980e85adeb7f5d21c1c86ac5529fd2b6491821f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 31 Jul 2024 10:45:10 +0000 Subject: [PATCH 0280/1003] Bump pyproject-fmt from 2.1.4 to 2.2.0 Bumps [pyproject-fmt](https://github.com/tox-dev/pyproject-fmt) from 2.1.4 to 2.2.0. - [Release notes](https://github.com/tox-dev/pyproject-fmt/releases) - [Commits](https://github.com/tox-dev/pyproject-fmt/compare/2.1.4...2.2.0) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 40a25ee5d..eb737fd7b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pyenchant==3.2.2", "pygments==2.18.0", "pylint==3.2.6", - "pyproject-fmt==2.1.4", + "pyproject-fmt==2.2.0", "pyright==1.1.374", "pyroma==4.2", "pytest==8.3.2", From 18e306a4aae363914f8a4b7efd7f4d29b3daab59 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 31 Jul 2024 15:30:56 +0100 Subject: [PATCH 0281/1003] Skip system Python checks in pre-commit CI --- .pre-commit-config.yaml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 40e612a80..81166ec44 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,5 +1,31 @@ # See https://pre-commit.com for more information # See https://pre-commit.com/hooks.html for more hooks + +ci: + # We use system Python, with required dependencies specified in pyproject.toml. + # We therefore cannot use those dependencies in pre-commit CI. + skip: + - actionlint + - mypy + - check-manifest + - pyright + - vulture + - pyroma + - deptry + - pylint + - ruff-check + - ruff-format-check + - ruff-check-fix + - ruff-format-fix + - doc8 + - interrogate + - pyproject-fmt-check + - pyproject-fmt-fix + - linkcheck + - spelling + - docs + - pyright-verifytypes + default_install_hook_types: [pre-commit, pre-push, commit-msg] repos: - repo: https://github.com/pre-commit/pre-commit-hooks From 39b0fe6127c4128da2956693b7f8fecc5e2c59dc Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 1 Aug 2024 11:18:59 +0100 Subject: [PATCH 0282/1003] Remove sphinx-prompt dependency It is no longer needed for my purposes, and it is not yet supported on Sphinx 8. --- docs/source/conf.py | 1 - docs/source/contributing.rst | 34 ++++++++++++++++----------------- docs/source/index.rst | 8 ++++---- docs/source/release-process.rst | 4 ++-- pyproject.toml | 1 - 5 files changed, 23 insertions(+), 25 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index d6ecf811c..99e3e3b85 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -15,7 +15,6 @@ "sphinx.ext.autodoc", "sphinx.ext.intersphinx", "sphinx.ext.napoleon", - "sphinx-prompt", "sphinx_substitution_extensions", "sphinxcontrib.spelling", ] diff --git a/docs/source/contributing.rst b/docs/source/contributing.rst index d8e8b5af9..2a61da727 100644 --- a/docs/source/contributing.rst +++ b/docs/source/contributing.rst @@ -10,39 +10,39 @@ Install contribution dependencies Install Python dependencies in a virtual environment. -.. prompt:: bash +.. code-block:: console - pip install --editable '.[dev]' + $ pip install --editable '.[dev]' Spell checking requires ``enchant``. This can be installed on macOS, for example, with `Homebrew`_: -.. prompt:: bash +.. code-block:: console - brew install enchant + $ brew install enchant and on Ubuntu with ``apt``: -.. prompt:: bash +.. code-block:: console - apt-get install -y enchant + $ apt-get install -y enchant Install ``pre-commit`` hooks: -.. prompt:: bash +.. code-block:: console - pre-commit install + $ pre-commit install Linting ------- Run lint tools either by committing, or with: -.. prompt:: bash +.. code-block:: console - pre-commit run --all-files --hook-stage commit --verbose - pre-commit run --all-files --hook-stage push --verbose - pre-commit run --all-files --hook-stage manual --verbose + $ pre-commit run --all-files --hook-stage commit --verbose + $ pre-commit run --all-files --hook-stage push --verbose + $ pre-commit run --all-files --hook-stage manual --verbose .. _Homebrew: https://brew.sh @@ -51,9 +51,9 @@ Running tests Run ``pytest``: -.. prompt:: bash +.. code-block:: console - pytest + $ pytest Documentation ------------- @@ -62,10 +62,10 @@ Documentation is built on Read the Docs. Run the following commands to build and view documentation locally: -.. prompt:: bash +.. code-block:: console - make docs - make open-docs + $ make docs + $ make open-docs Continuous integration ---------------------- diff --git a/docs/source/index.rst b/docs/source/index.rst index 630355629..287ce7df1 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -4,9 +4,9 @@ Installation ------------ -.. prompt:: bash +.. code-block:: console - pip3 install vws-python + $ pip install vws-python This is tested on Python 3.8+. Get in touch with ``adamdangoor@gmail.com`` if you would like to use this with another language. @@ -90,9 +90,9 @@ Testing To write unit tests for code which uses this library, without using your Vuforia quota, you can use the `VWS Python Mock`_ tool: -.. prompt:: bash +.. code-block:: console - pip3 install vws-python-mock + $ pip install vws-python-mock .. clear-namespace diff --git a/docs/source/release-process.rst b/docs/source/release-process.rst index d947f9fd3..0c662f553 100644 --- a/docs/source/release-process.rst +++ b/docs/source/release-process.rst @@ -14,9 +14,9 @@ Perform a Release #. Perform a release: - .. prompt:: bash + .. code-block:: console :substitutions: - gh workflow run release.yml --repo |github-owner|/|github-repository| + $ gh workflow run release.yml --repo |github-owner|/|github-repository| .. _Install GitHub CLI: https://cli.github.com/ diff --git a/pyproject.toml b/pyproject.toml index eb737fd7b..50839b4e9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,6 @@ optional-dependencies.dev = [ "pyyaml==6.0.1", "ruff==0.5.5", "sphinx==7.4.7", - "sphinx-prompt==1.8", "sphinx-substitution-extensions==2024.2.25", "sphinxcontrib-spelling==8", "sybil==6.1.1", From 35252f6a74eecac9ad3f167849680f599c617218 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 1 Aug 2024 11:03:54 +0000 Subject: [PATCH 0283/1003] Bump pyproject-fmt from 2.2.0 to 2.2.1 Bumps [pyproject-fmt](https://github.com/tox-dev/pyproject-fmt) from 2.2.0 to 2.2.1. - [Release notes](https://github.com/tox-dev/pyproject-fmt/releases) - [Commits](https://github.com/tox-dev/pyproject-fmt/compare/2.2.0...2.2.1) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 50839b4e9..9a77de7e1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pyenchant==3.2.2", "pygments==2.18.0", "pylint==3.2.6", - "pyproject-fmt==2.2.0", + "pyproject-fmt==2.2.1", "pyright==1.1.374", "pyroma==4.2", "pytest==8.3.2", From 4f4ece131405e0a7b4a767497906d4692612a8a7 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 1 Aug 2024 13:42:39 +0100 Subject: [PATCH 0284/1003] Use sphinx-copybutton to add a copy button to documentation code blocks --- docs/source/conf.py | 5 +++++ pyproject.toml | 1 + 2 files changed, 6 insertions(+) diff --git a/docs/source/conf.py b/docs/source/conf.py index 99e3e3b85..3d3152128 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -12,6 +12,7 @@ author = "Adam Dangoor" extensions = [ + "sphinx_copybutton", "sphinx.ext.autodoc", "sphinx.ext.intersphinx", "sphinx.ext.napoleon", @@ -26,6 +27,10 @@ year = datetime.datetime.now(tz=datetime.UTC).year project_copyright = f"{year}, {author}" +# Exclude the prompt from copied code with sphinx_copybutton. + # https://sphinx-copybutton.readthedocs.io/en/latest/use.html#automatic-exclusion-of-prompts-from-the-copies. + copybutton_exclude = ".linenos, .gp" + # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the # built documents. diff --git a/pyproject.toml b/pyproject.toml index 9a77de7e1..4a54bcafa 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,6 +59,7 @@ optional-dependencies.dev = [ "pyyaml==6.0.1", "ruff==0.5.5", "sphinx==7.4.7", + "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.2.25", "sphinxcontrib-spelling==8", "sybil==6.1.1", From f6eec6ef5f4281306e10ab1b61114cc7bed5bf66 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 1 Aug 2024 13:46:08 +0100 Subject: [PATCH 0285/1003] Fix indentation issue --- docs/source/conf.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 3d3152128..70ad3a80b 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -28,8 +28,8 @@ project_copyright = f"{year}, {author}" # Exclude the prompt from copied code with sphinx_copybutton. - # https://sphinx-copybutton.readthedocs.io/en/latest/use.html#automatic-exclusion-of-prompts-from-the-copies. - copybutton_exclude = ".linenos, .gp" +# https://sphinx-copybutton.readthedocs.io/en/latest/use.html#automatic-exclusion-of-prompts-from-the-copies. +copybutton_exclude = ".linenos, .gp" # The version info for the project you're documenting, acts as replacement for # |version| and |release|, also used in various other places throughout the From fa54b422b58dfddf9d0eff091eda63b6a0083aee Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 5 Aug 2024 10:21:20 +0000 Subject: [PATCH 0286/1003] Bump ruff from 0.5.5 to 0.5.6 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.5.5 to 0.5.6. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.5.5...0.5.6) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4a54bcafa..2b14a75ee 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pytest==8.3.2", "pytest-cov==5.0.0", "pyyaml==6.0.1", - "ruff==0.5.5", + "ruff==0.5.6", "sphinx==7.4.7", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.2.25", From 6ec53a7fdea138210e8c0b4785e08c7d810e2f83 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 6 Aug 2024 10:35:06 +0000 Subject: [PATCH 0287/1003] Bump furo from 2024.7.18 to 2024.8.6 Bumps [furo](https://github.com/pradyunsg/furo) from 2024.7.18 to 2024.8.6. - [Release notes](https://github.com/pradyunsg/furo/releases) - [Changelog](https://github.com/pradyunsg/furo/blob/main/docs/changelog.md) - [Commits](https://github.com/pradyunsg/furo/compare/2024.07.18...2024.08.06) --- updated-dependencies: - dependency-name: furo dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2b14a75ee..e72d6e295 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "deptry==0.18.0", "doc8==1.1.1", "freezegun==1.5.1", - "furo==2024.7.18", + "furo==2024.8.6", "interrogate==1.7.0", "mypy==1.11.1", "pre-commit==3.8.0", From 00415a9541b81c25f5d8971b22c44d8d2704c3fd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 6 Aug 2024 14:30:05 +0000 Subject: [PATCH 0288/1003] Bump sphinx-substitution-extensions from 2024.2.25 to 2024.8.6 Bumps [sphinx-substitution-extensions](https://github.com/adamtheturtle/sphinx-substitution-extensions) from 2024.2.25 to 2024.8.6. - [Release notes](https://github.com/adamtheturtle/sphinx-substitution-extensions/releases) - [Changelog](https://github.com/adamtheturtle/sphinx-substitution-extensions/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/sphinx-substitution-extensions/compare/2024.02.25...2024.08.06) --- updated-dependencies: - dependency-name: sphinx-substitution-extensions dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e72d6e295..edf95fe21 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ optional-dependencies.dev = [ "ruff==0.5.6", "sphinx==7.4.7", "sphinx-copybutton==0.5.2", - "sphinx-substitution-extensions==2024.2.25", + "sphinx-substitution-extensions==2024.8.6", "sphinxcontrib-spelling==8", "sybil==6.1.1", "types-requests==2.32.0.20240712", From c31a01ac4beaa596e3c2259e44b782237e039dde Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 6 Aug 2024 14:37:40 +0000 Subject: [PATCH 0289/1003] Bump sphinx from 7.4.7 to 8.0.2 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 7.4.7 to 8.0.2. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v7.4.7...v8.0.2) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index edf95fe21..71356a1b0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pytest-cov==5.0.0", "pyyaml==6.0.1", "ruff==0.5.6", - "sphinx==7.4.7", + "sphinx==8.0.2", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", "sphinxcontrib-spelling==8", From 31150f72406a65f8e12da2ec54e757a44d0aeb8c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 7 Aug 2024 10:12:12 +0000 Subject: [PATCH 0290/1003] Bump pyright from 1.1.374 to 1.1.375 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.374 to 1.1.375. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.374...v1.1.375) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 71356a1b0..4c2b1abbe 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.6", "pyproject-fmt==2.2.1", - "pyright==1.1.374", + "pyright==1.1.375", "pyroma==4.2", "pytest==8.3.2", "pytest-cov==5.0.0", From 6ca3b8871a0680b4df71f665a9375ee40d50fa6b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 7 Aug 2024 10:21:00 +0000 Subject: [PATCH 0291/1003] Bump pyyaml from 6.0.1 to 6.0.2 Bumps [pyyaml](https://github.com/yaml/pyyaml) from 6.0.1 to 6.0.2. - [Release notes](https://github.com/yaml/pyyaml/releases) - [Changelog](https://github.com/yaml/pyyaml/blob/main/CHANGES) - [Commits](https://github.com/yaml/pyyaml/compare/6.0.1...6.0.2) --- updated-dependencies: - dependency-name: pyyaml dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4c2b1abbe..dd75a9301 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pyroma==4.2", "pytest==8.3.2", "pytest-cov==5.0.0", - "pyyaml==6.0.1", + "pyyaml==6.0.2", "ruff==0.5.6", "sphinx==8.0.2", "sphinx-copybutton==0.5.2", From 5d5218572d5a398f418e17b957fffb69f7e547b1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 8 Aug 2024 11:03:54 +0000 Subject: [PATCH 0292/1003] Bump deptry from 0.18.0 to 0.19.0 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.18.0 to 0.19.0. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.18.0...0.19.0) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index dd75a9301..79145926b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -40,7 +40,7 @@ dependencies = [ optional-dependencies.dev = [ "actionlint-py==1.7.1.15", "check-manifest==0.49", - "deptry==0.18.0", + "deptry==0.19.0", "doc8==1.1.1", "freezegun==1.5.1", "furo==2024.8.6", From 48469d1f619d2308ece9642edf68374d9d93f543 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 9 Aug 2024 10:57:16 +0000 Subject: [PATCH 0293/1003] Bump ruff from 0.5.6 to 0.5.7 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.5.6 to 0.5.7. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.5.6...0.5.7) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 79145926b..0738f15a0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pytest==8.3.2", "pytest-cov==5.0.0", "pyyaml==6.0.2", - "ruff==0.5.6", + "ruff==0.5.7", "sphinx==8.0.2", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", From 365c18b06df5bb5ab5c4a5402f01e5ccf70ac103 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 12 Aug 2024 10:35:17 +0000 Subject: [PATCH 0294/1003] Bump deptry from 0.19.0 to 0.19.1 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.19.0 to 0.19.1. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.19.0...0.19.1) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0738f15a0..d8a12eeb9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -40,7 +40,7 @@ dependencies = [ optional-dependencies.dev = [ "actionlint-py==1.7.1.15", "check-manifest==0.49", - "deptry==0.19.0", + "deptry==0.19.1", "doc8==1.1.1", "freezegun==1.5.1", "furo==2024.8.6", From 9763c2a4d2da01623ccfa1263acdb65897f7a9ed Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 14 Aug 2024 10:10:23 +0000 Subject: [PATCH 0295/1003] Bump pyright from 1.1.375 to 1.1.376 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.375 to 1.1.376. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.375...v1.1.376) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d8a12eeb9..85c838fa9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.6", "pyproject-fmt==2.2.1", - "pyright==1.1.375", + "pyright==1.1.376", "pyroma==4.2", "pytest==8.3.2", "pytest-cov==5.0.0", From cadd1334dca93ba43b8db449f81a677c86ae696c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 16 Aug 2024 10:23:46 +0000 Subject: [PATCH 0296/1003] Bump ruff from 0.5.7 to 0.6.0 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.5.7 to 0.6.0. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.5.7...0.6.0) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 85c838fa9..362df3f48 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pytest==8.3.2", "pytest-cov==5.0.0", "pyyaml==6.0.2", - "ruff==0.5.7", + "ruff==0.6.0", "sphinx==8.0.2", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", From 6e371f5529b644ce6e93c676d5c92d55cbc80ab0 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Sat, 17 Aug 2024 07:03:29 +0000 Subject: [PATCH 0297/1003] [pre-commit.ci lite] apply automatic fixes --- tests/conftest.py | 7 ++++--- tests/test_cloud_reco_exceptions.py | 1 + tests/test_query.py | 1 + tests/test_vws.py | 1 + tests/test_vws_exceptions.py | 1 + 5 files changed, 8 insertions(+), 3 deletions(-) diff --git a/tests/conftest.py b/tests/conftest.py index ac8181bd7..c9498943f 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -10,6 +10,7 @@ import pytest from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase + from vws import VWS, CloudRecoService if TYPE_CHECKING: @@ -28,7 +29,7 @@ def mock_database() -> Generator[VuforiaDatabase, None, None]: yield database -@pytest.fixture() +@pytest.fixture def vws_client(_mock_database: VuforiaDatabase) -> VWS: """ A VWS client which connects to a mock database. @@ -39,7 +40,7 @@ def vws_client(_mock_database: VuforiaDatabase) -> VWS: ) -@pytest.fixture() +@pytest.fixture def cloud_reco_client(_mock_database: VuforiaDatabase) -> CloudRecoService: """ A ``CloudRecoService`` client which connects to a mock database. @@ -50,7 +51,7 @@ def cloud_reco_client(_mock_database: VuforiaDatabase) -> CloudRecoService: ) -@pytest.fixture() +@pytest.fixture def image_file( high_quality_image: io.BytesIO, tmp_path: Path, diff --git a/tests/test_cloud_reco_exceptions.py b/tests/test_cloud_reco_exceptions.py index 4e8a70895..69c4e49a4 100644 --- a/tests/test_cloud_reco_exceptions.py +++ b/tests/test_cloud_reco_exceptions.py @@ -12,6 +12,7 @@ from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase from mock_vws.states import States + from vws import CloudRecoService from vws.exceptions.base_exceptions import CloudRecoError from vws.exceptions.cloud_reco_exceptions import ( diff --git a/tests/test_query.py b/tests/test_query.py index 0a4357db5..50bf39d98 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -9,6 +9,7 @@ from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase + from vws import VWS, CloudRecoService from vws.include_target_data import CloudRecoIncludeTargetData diff --git a/tests/test_vws.py b/tests/test_vws.py index 28363c77e..28c026bf7 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -14,6 +14,7 @@ from freezegun import freeze_time from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase + from vws import VWS, CloudRecoService from vws.exceptions.custom_exceptions import TargetProcessingTimeoutError from vws.reports import ( diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index b433c2754..65bea0ab2 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -11,6 +11,7 @@ from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase from mock_vws.states import States + from vws import VWS from vws.exceptions.base_exceptions import VWSError from vws.exceptions.custom_exceptions import ( From de8830108ecc4c5f33916a2085831f2c38024432 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 19 Aug 2024 10:10:22 +0000 Subject: [PATCH 0298/1003] Bump ruff from 0.6.0 to 0.6.1 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.6.0 to 0.6.1. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.6.0...0.6.1) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 362df3f48..c9982c925 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pytest==8.3.2", "pytest-cov==5.0.0", "pyyaml==6.0.2", - "ruff==0.6.0", + "ruff==0.6.1", "sphinx==8.0.2", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", From 0c9aac792007eb5d51529e66c1219c3cf5bc7e90 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 21 Aug 2024 10:16:19 +0000 Subject: [PATCH 0299/1003] Bump pyright from 1.1.376 to 1.1.377 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.376 to 1.1.377. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.376...v1.1.377) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c9982c925..e861c370b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.6", "pyproject-fmt==2.2.1", - "pyright==1.1.376", + "pyright==1.1.377", "pyroma==4.2", "pytest==8.3.2", "pytest-cov==5.0.0", From 32bfbac257178a720777bbd0fc5c3c3628ff1c29 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 21 Aug 2024 21:24:12 +0100 Subject: [PATCH 0300/1003] Use typeguard to check pytest fixture/parametrization types --- pyproject.toml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index e861c370b..6ba171204 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -67,6 +67,7 @@ optional-dependencies.dev = [ "vulture==2.11", "vws-python-mock==2024.7.15", "vws-test-fixtures==2023.3.5", + "typeguard==4.3.0", ] urls.Documentation = "https://vws-python.readthedocs.io/en/latest/" urls.Source = "https://github.com/VWS-Python/vws-python" @@ -277,6 +278,9 @@ keep_full_version = true xfail_strict = true log_cli = true +typeguard-packages = """ +tests +""" [tool.coverage.run] From 3f18f33a5a51b5e569c11c6248064e2e11f23672 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Wed, 21 Aug 2024 20:25:19 +0000 Subject: [PATCH 0301/1003] [pre-commit.ci lite] apply automatic fixes --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6ba171204..9cd6e9cbb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -63,11 +63,11 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2024.8.6", "sphinxcontrib-spelling==8", "sybil==6.1.1", + "typeguard==4.3.0", "types-requests==2.32.0.20240712", "vulture==2.11", "vws-python-mock==2024.7.15", "vws-test-fixtures==2023.3.5", - "typeguard==4.3.0", ] urls.Documentation = "https://vws-python.readthedocs.io/en/latest/" urls.Source = "https://github.com/VWS-Python/vws-python" From e1f3152cfe51d46d43e4881b032747f9b9d0b3c9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 23 Aug 2024 10:41:10 +0000 Subject: [PATCH 0302/1003] Bump ruff from 0.6.1 to 0.6.2 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.6.1 to 0.6.2. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.6.1...0.6.2) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9cd6e9cbb..663ebadb0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pytest==8.3.2", "pytest-cov==5.0.0", "pyyaml==6.0.2", - "ruff==0.6.1", + "ruff==0.6.2", "sphinx==8.0.2", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", From dab3a2b7e57ffcd6e502cab332b6b9f9ebb3e52a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 26 Aug 2024 10:45:09 +0000 Subject: [PATCH 0303/1003] Bump mypy from 1.11.1 to 1.11.2 Bumps [mypy](https://github.com/python/mypy) from 1.11.1 to 1.11.2. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.11.1...v1.11.2) --- updated-dependencies: - dependency-name: mypy dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 663ebadb0..1422b7bf2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -45,7 +45,7 @@ optional-dependencies.dev = [ "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", - "mypy==1.11.1", + "mypy==1.11.2", "pre-commit==3.8.0", "pydocstyle==6.3", "pyenchant==3.2.2", From 008971880a7cbc8fdc6d28975443a53295722fe4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 28 Aug 2024 10:44:27 +0000 Subject: [PATCH 0304/1003] Bump deptry from 0.19.1 to 0.20.0 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.19.1 to 0.20.0. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.19.1...0.20.0) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1422b7bf2..00805221c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -40,7 +40,7 @@ dependencies = [ optional-dependencies.dev = [ "actionlint-py==1.7.1.15", "check-manifest==0.49", - "deptry==0.19.1", + "deptry==0.20.0", "doc8==1.1.1", "freezegun==1.5.1", "furo==2024.8.6", From 58909f876b9622c36afad293c2f1fe1e1cfbd9cd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 29 Aug 2024 10:10:26 +0000 Subject: [PATCH 0305/1003] Bump pyright from 1.1.377 to 1.1.378 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.377 to 1.1.378. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.377...v1.1.378) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 00805221c..46e4e3fff 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.6", "pyproject-fmt==2.2.1", - "pyright==1.1.377", + "pyright==1.1.378", "pyroma==4.2", "pytest==8.3.2", "pytest-cov==5.0.0", From f1189c89de014a4be26309f540036f5dce3297e6 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 29 Aug 2024 13:53:56 +0100 Subject: [PATCH 0306/1003] Run beartype on all tests --- conftest.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/conftest.py b/conftest.py index 881a76db2..1bbad0e64 100644 --- a/conftest.py +++ b/conftest.py @@ -2,6 +2,8 @@ from doctest import ELLIPSIS +import pytest +from beartype import beartype from sybil import Sybil from sybil.parsers.rest import ( ClearNamespaceParser, @@ -9,6 +11,16 @@ PythonCodeBlockParser, ) + +def pytest_collection_modifyitems(items: list[pytest.Item]) -> None: + """ + Apply the beartype decorator to all collected test functions. + """ + for item in items: + if isinstance(item, pytest.Function): + item.obj = beartype(obj=item.obj) + + pytest_collect_file = Sybil( parsers=[ ClearNamespaceParser(), From bdd5c8e953a56c754d874bf23995d0f951c381d7 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 29 Aug 2024 14:29:08 +0100 Subject: [PATCH 0307/1003] Update image type to reflect reality --- CHANGELOG.rst | 1 + src/vws/query.py | 9 +++++--- src/vws/vws.py | 9 ++++---- tests/conftest.py | 4 ++-- tests/test_cloud_reco_exceptions.py | 12 +++++++---- tests/test_query.py | 18 ++++++++-------- tests/test_vws.py | 32 ++++++++++++++--------------- tests/test_vws_exceptions.py | 28 +++++++++++++++---------- 8 files changed, 64 insertions(+), 49 deletions(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index c628649be..883b5f4e3 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -6,6 +6,7 @@ Next * Breaking change: Exception names now end with ``Error``. * Use a timeout (30 seconds) when making requests to the VWS API. +* Type hint changes: images are now ``io.BytesIO`` instances or ``io.BufferedRandom``. 2024.02.19 ------------ diff --git a/src/vws/query.py b/src/vws/query.py index cb86373da..aeba29922 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -7,7 +7,7 @@ import datetime import json from http import HTTPMethod, HTTPStatus -from typing import Any, BinaryIO +from typing import TYPE_CHECKING, Any from urllib.parse import urljoin import requests @@ -29,8 +29,11 @@ from vws.include_target_data import CloudRecoIncludeTargetData from vws.reports import QueryResult, TargetData +if TYPE_CHECKING: + from io import BufferedRandom, BytesIO -def _get_image_data(image: BinaryIO) -> bytes: + +def _get_image_data(image: BytesIO | BufferedRandom) -> bytes: """Get the data of an image file.""" original_tell = image.tell() image.seek(0) @@ -62,7 +65,7 @@ def __init__( def query( self, - image: BinaryIO, + image: BytesIO | BufferedRandom, max_num_results: int = 1, include_target_data: CloudRecoIncludeTargetData = ( CloudRecoIncludeTargetData.TOP diff --git a/src/vws/vws.py b/src/vws/vws.py index 8b1c3b7fc..52bd4b577 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -9,7 +9,7 @@ import time from datetime import date from http import HTTPMethod, HTTPStatus -from typing import TYPE_CHECKING, BinaryIO +from typing import TYPE_CHECKING from urllib.parse import urljoin import requests @@ -51,9 +51,10 @@ if TYPE_CHECKING: import io + from io import BufferedRandom, BytesIO -def _get_image_data(image: BinaryIO) -> bytes: +def _get_image_data(image: BytesIO | BufferedRandom) -> bytes: """Get the data of an image file.""" original_tell = image.tell() image.seek(0) @@ -238,7 +239,7 @@ def add_target( self, name: str, width: float, - image: BinaryIO, + image: BytesIO | BufferedRandom, application_metadata: str | None, *, active_flag: bool, @@ -621,7 +622,7 @@ def update_target( target_id: str, name: str | None = None, width: float | None = None, - image: io.BytesIO | None = None, + image: io.BytesIO | io.BufferedRandom | None = None, active_flag: bool | None = None, application_metadata: str | None = None, ) -> None: diff --git a/tests/conftest.py b/tests/conftest.py index c9498943f..81c976346 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -5,7 +5,7 @@ from __future__ import annotations import io -from typing import TYPE_CHECKING, BinaryIO +from typing import TYPE_CHECKING import pytest from mock_vws import MockVWS @@ -68,7 +68,7 @@ def image_file( @pytest.fixture(params=["high_quality_image", "image_file"]) def image( request: pytest.FixtureRequest, -) -> BinaryIO: +) -> io.BytesIO | io.BufferedRandom: """An image in any of the types that the API accepts.""" result = request.getfixturevalue(request.param) assert isinstance(result, io.BytesIO | io.BufferedRandom) diff --git a/tests/test_cloud_reco_exceptions.py b/tests/test_cloud_reco_exceptions.py index 69c4e49a4..cb5263c19 100644 --- a/tests/test_cloud_reco_exceptions.py +++ b/tests/test_cloud_reco_exceptions.py @@ -32,7 +32,7 @@ def test_too_many_max_results( cloud_reco_client: CloudRecoService, - high_quality_image: io.BytesIO, + high_quality_image: io.BytesIO | io.BufferedRandom, ) -> None: """ A ``MaxNumResultsOutOfRange`` error is raised if the given @@ -53,7 +53,7 @@ def test_too_many_max_results( def test_image_too_large( cloud_reco_client: CloudRecoService, - png_too_large: io.BytesIO, + png_too_large: io.BytesIO | io.BufferedRandom, ) -> None: """ A ``RequestEntityTooLarge`` exception is raised if an image which is too @@ -82,7 +82,9 @@ def test_cloudrecoexception_inheritance() -> None: assert issubclass(subclass, CloudRecoError) -def test_authentication_failure(high_quality_image: io.BytesIO) -> None: +def test_authentication_failure( + high_quality_image: io.BytesIO | io.BufferedRandom, +) -> None: """ An ``AuthenticationFailure`` exception is raised when the client access key exists but the client secret key is incorrect. @@ -101,7 +103,9 @@ def test_authentication_failure(high_quality_image: io.BytesIO) -> None: assert exc.value.response.status_code == HTTPStatus.UNAUTHORIZED -def test_inactive_project(high_quality_image: io.BytesIO) -> None: +def test_inactive_project( + high_quality_image: io.BytesIO | io.BufferedRandom, +) -> None: """ An ``InactiveProject`` exception is raised when querying an inactive database. diff --git a/tests/test_query.py b/tests/test_query.py index 50bf39d98..fadebda20 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -25,7 +25,7 @@ class TestQuery: @staticmethod def test_no_matches( cloud_reco_client: CloudRecoService, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ An empty list is returned if there are no matches. @@ -37,7 +37,7 @@ def test_no_matches( def test_match( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ Details of matching targets are returned. @@ -60,7 +60,7 @@ class TestCustomBaseVWQURL: """ @staticmethod - def test_custom_base_url(image: io.BytesIO) -> None: + def test_custom_base_url(image: io.BytesIO | io.BufferedRandom) -> None: """ It is possible to use query a target to a database under a custom VWQ URL. @@ -105,7 +105,7 @@ class TestMaxNumResults: def test_default( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ By default the maximum number of results is 1. @@ -133,7 +133,7 @@ def test_default( def test_custom( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ It is possible to set a custom ``max_num_results``. @@ -179,7 +179,7 @@ class TestIncludeTargetData: def test_default( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ By default, target data is only returned in the top match. @@ -211,7 +211,7 @@ def test_default( def test_top( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ When ``CloudRecoIncludeTargetData.TOP`` is given, target data is only @@ -245,7 +245,7 @@ def test_top( def test_none( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ When ``CloudRecoIncludeTargetData.NONE`` is given, target data is not @@ -279,7 +279,7 @@ def test_none( def test_all( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ When ``CloudRecoIncludeTargetData.ALL`` is given, target data is diff --git a/tests/test_vws.py b/tests/test_vws.py index 28c026bf7..7d430d824 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -8,7 +8,7 @@ import datetime import secrets import uuid -from typing import TYPE_CHECKING, BinaryIO +from typing import TYPE_CHECKING import pytest from freezegun import freeze_time @@ -38,7 +38,7 @@ class TestAddTarget: @pytest.mark.parametrize("active_flag", [True, False]) def test_add_target( vws_client: VWS, - image: BinaryIO, + image: io.BytesIO | io.BufferedRandom, application_metadata: bytes | None, cloud_reco_client: CloudRecoService, *, @@ -82,7 +82,7 @@ def test_add_target( @staticmethod def test_add_two_targets( vws_client: VWS, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ No exception is raised when adding two targets with different names. @@ -105,7 +105,7 @@ class TestCustomBaseVWSURL: """ @staticmethod - def test_custom_base_url(image: io.BytesIO) -> None: + def test_custom_base_url(image: io.BytesIO | io.BufferedRandom) -> None: """ It is possible to use add a target to a database under a custom VWS URL. @@ -137,7 +137,7 @@ class TestListTargets: @staticmethod def test_list_targets( vws_client: VWS, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ It is possible to get a list of target IDs. @@ -167,7 +167,7 @@ class TestDelete: @staticmethod def test_delete_target( vws_client: VWS, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ It is possible to delete a target. @@ -194,7 +194,7 @@ class TestGetTargetSummaryReport: @staticmethod def test_get_target_summary_report( vws_client: VWS, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ Details of a target are returned by ``get_target_summary_report``. @@ -263,7 +263,7 @@ class TestGetTargetRecord: @staticmethod def test_get_target_record( vws_client: VWS, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ Details of a target are returned by ``get_target_record``. @@ -298,7 +298,7 @@ class TestWaitForTargetProcessed: @staticmethod def test_wait_for_target_processed( vws_client: VWS, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ It is possible to wait until a target is processed. @@ -318,7 +318,7 @@ def test_wait_for_target_processed( @staticmethod def test_default_seconds_between_requests( - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ By default, 0.2 seconds are waited between polling requests. @@ -370,7 +370,7 @@ def test_default_seconds_between_requests( @staticmethod def test_custom_seconds_between_requests( - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ It is possible to customize the time waited between polling requests. @@ -421,7 +421,7 @@ def test_custom_seconds_between_requests( assert report.request_usage == expected_requests @staticmethod - def test_custom_timeout(image: io.BytesIO) -> None: + def test_custom_timeout(image: io.BytesIO | io.BufferedRandom) -> None: """ It is possible to set a maximum timeout. """ @@ -465,7 +465,7 @@ class TestGetDuplicateTargets: @staticmethod def test_get_duplicate_targets( vws_client: VWS, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ It is possible to get the IDs of similar targets. @@ -499,8 +499,8 @@ class TestUpdateTarget: @staticmethod def test_update_target( vws_client: VWS, - image: io.BytesIO, - different_high_quality_image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, + different_high_quality_image: io.BytesIO | io.BufferedRandom, cloud_reco_client: CloudRecoService, ) -> None: """ @@ -558,7 +558,7 @@ def test_update_target( @staticmethod def test_no_fields_given( vws_client: VWS, - image: io.BytesIO, + image: io.BytesIO | io.BufferedRandom, ) -> None: """ It is possible to give no update fields. diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 65bea0ab2..4f5e15ef2 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -39,7 +39,7 @@ def test_image_too_large( vws_client: VWS, - png_too_large: io.BytesIO, + png_too_large: io.BytesIO | io.BufferedRandom, ) -> None: """ When giving an image which is too large, an ``ImageTooLarge`` exception is @@ -69,7 +69,9 @@ def test_invalid_given_id(vws_client: VWS) -> None: assert exc.value.target_id == target_id -def test_add_bad_name(vws_client: VWS, high_quality_image: io.BytesIO) -> None: +def test_add_bad_name( + vws_client: VWS, high_quality_image: io.BytesIO | io.BufferedRandom +) -> None: """ When a name with a bad character is given, an ``OopsAnErrorOccurredPossiblyBadName`` exception is raised. @@ -95,7 +97,7 @@ def test_request_quota_reached() -> None: """ -def test_fail(high_quality_image: io.BytesIO) -> None: +def test_fail(high_quality_image: io.BytesIO | io.BufferedRandom) -> None: """ A ``Fail`` exception is raised when the server access key does not exist. """ @@ -136,7 +138,7 @@ def test_bad_image(vws_client: VWS) -> None: def test_target_name_exist( vws_client: VWS, - high_quality_image: io.BytesIO, + high_quality_image: io.BytesIO | io.BufferedRandom, ) -> None: """ A ``TargetNameExist`` exception is raised after adding two targets with @@ -162,7 +164,9 @@ def test_target_name_exist( assert exc.value.target_name == "x" -def test_project_inactive(high_quality_image: io.BytesIO) -> None: +def test_project_inactive( + high_quality_image: io.BytesIO | io.BufferedRandom, +) -> None: """ A ``ProjectInactive`` exception is raised if adding a target to an inactive database. @@ -189,7 +193,7 @@ def test_project_inactive(high_quality_image: io.BytesIO) -> None: def test_target_status_processing( vws_client: VWS, - high_quality_image: io.BytesIO, + high_quality_image: io.BytesIO | io.BufferedRandom, ) -> None: """ A ``TargetStatusProcessing`` exception is raised if trying to delete a @@ -212,7 +216,7 @@ def test_target_status_processing( def test_metadata_too_large( vws_client: VWS, - high_quality_image: io.BytesIO, + high_quality_image: io.BytesIO | io.BufferedRandom, ) -> None: """ A ``MetadataTooLarge`` exception is raised if the metadata given is too @@ -232,7 +236,7 @@ def test_metadata_too_large( def test_request_time_too_skewed( vws_client: VWS, - high_quality_image: io.BytesIO, + high_quality_image: io.BytesIO | io.BufferedRandom, ) -> None: """ A ``RequestTimeTooSkewed`` exception is raised when the request time is @@ -265,7 +269,9 @@ def test_request_time_too_skewed( assert exc.value.response.status_code == HTTPStatus.FORBIDDEN -def test_authentication_failure(high_quality_image: io.BytesIO) -> None: +def test_authentication_failure( + high_quality_image: io.BytesIO | io.BufferedRandom, +) -> None: """ An ``AuthenticationFailure`` exception is raised when the server access key exists but the server secret key is incorrect, or when a client key is @@ -295,7 +301,7 @@ def test_authentication_failure(high_quality_image: io.BytesIO) -> None: def test_target_status_not_success( vws_client: VWS, - high_quality_image: io.BytesIO, + high_quality_image: io.BytesIO | io.BufferedRandom, ) -> None: """ A ``TargetStatusNotSuccess`` exception is raised when updating a target @@ -344,7 +350,7 @@ def test_vwsexception_inheritance() -> None: def test_base_exception( vws_client: VWS, - high_quality_image: io.BytesIO, + high_quality_image: io.BytesIO | io.BufferedRandom, ) -> None: """ ``VWSException``s has a response property. From a263257ff1214df17e75d29a89d5eac0930f21c1 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 29 Aug 2024 14:39:53 +0100 Subject: [PATCH 0308/1003] Ignore missing intersphinx references --- docs/source/conf.py | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/source/conf.py b/docs/source/conf.py index 70ad3a80b..18c4a0e78 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -62,6 +62,7 @@ "python": ("https://docs.python.org/3.12", None), } nitpicky = True +nitpick_ignore = (("py:class", "BytesIO"), ("py:class", "BufferedRandom")) warning_is_error = True autoclass_content = "both" From 76e4aaa3fabd7662d1de2a303d0ab0a985d0180e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 29 Aug 2024 22:19:53 +0100 Subject: [PATCH 0309/1003] Remove from __future__ import annotations This conflicts with beartype and just isn't necessary. --- docs/source/conf.py | 7 ++++++- src/vws/exceptions/base_exceptions.py | 7 +------ src/vws/query.py | 8 ++------ src/vws/vws.py | 9 ++------- tests/conftest.py | 9 ++------- tests/test_cloud_reco_exceptions.py | 7 +------ tests/test_query.py | 7 +------ tests/test_vws.py | 7 +------ 8 files changed, 16 insertions(+), 45 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 18c4a0e78..c18eb170d 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -62,7 +62,12 @@ "python": ("https://docs.python.org/3.12", None), } nitpicky = True -nitpick_ignore = (("py:class", "BytesIO"), ("py:class", "BufferedRandom")) +nitpick_ignore = ( + ("py:class", "BytesIO"), + ("py:class", "BufferedRandom"), + ("py:class", "_io.BytesIO"), + ("py:class", "_io.BufferedRandom"), +) warning_is_error = True autoclass_content = "both" diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index 13a995fbd..907d74731 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -3,12 +3,7 @@ Cloud Recognition Web API. """ -from __future__ import annotations - -from typing import TYPE_CHECKING - -if TYPE_CHECKING: - from .response import Response +from .response import Response class CloudRecoError(Exception): diff --git a/src/vws/query.py b/src/vws/query.py index aeba29922..c0e6b89bd 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -2,12 +2,11 @@ Tools for interacting with the Vuforia Cloud Recognition Web APIs. """ -from __future__ import annotations - import datetime import json from http import HTTPMethod, HTTPStatus -from typing import TYPE_CHECKING, Any +from io import BufferedRandom, BytesIO +from typing import Any from urllib.parse import urljoin import requests @@ -29,9 +28,6 @@ from vws.include_target_data import CloudRecoIncludeTargetData from vws.reports import QueryResult, TargetData -if TYPE_CHECKING: - from io import BufferedRandom, BytesIO - def _get_image_data(image: BytesIO | BufferedRandom) -> bytes: """Get the data of an image file.""" diff --git a/src/vws/vws.py b/src/vws/vws.py index 52bd4b577..1ec660253 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -2,14 +2,13 @@ Tools for interacting with Vuforia APIs. """ -from __future__ import annotations - import base64 +import io import json import time from datetime import date from http import HTTPMethod, HTTPStatus -from typing import TYPE_CHECKING +from io import BufferedRandom, BytesIO from urllib.parse import urljoin import requests @@ -49,10 +48,6 @@ from .exceptions.response import Response -if TYPE_CHECKING: - import io - from io import BufferedRandom, BytesIO - def _get_image_data(image: BytesIO | BufferedRandom) -> bytes: """Get the data of an image file.""" diff --git a/tests/conftest.py b/tests/conftest.py index 81c976346..e359e4a82 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -2,10 +2,9 @@ Configuration, plugins and fixtures for `pytest`. """ -from __future__ import annotations - import io -from typing import TYPE_CHECKING +from collections.abc import Generator +from pathlib import Path import pytest from mock_vws import MockVWS @@ -13,10 +12,6 @@ from vws import VWS, CloudRecoService -if TYPE_CHECKING: - from collections.abc import Generator - from pathlib import Path - @pytest.fixture(name="_mock_database") def mock_database() -> Generator[VuforiaDatabase, None, None]: diff --git a/tests/test_cloud_reco_exceptions.py b/tests/test_cloud_reco_exceptions.py index cb5263c19..1de69180e 100644 --- a/tests/test_cloud_reco_exceptions.py +++ b/tests/test_cloud_reco_exceptions.py @@ -2,11 +2,9 @@ Tests for exceptions raised when using the CloudRecoService. """ -from __future__ import annotations - +import io import uuid from http import HTTPStatus -from typing import TYPE_CHECKING import pytest from mock_vws import MockVWS @@ -26,9 +24,6 @@ RequestEntityTooLargeError, ) -if TYPE_CHECKING: - import io - def test_too_many_max_results( cloud_reco_client: CloudRecoService, diff --git a/tests/test_query.py b/tests/test_query.py index fadebda20..4a3df25cb 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -2,10 +2,8 @@ Tests for the ``CloudRecoService`` querying functionality. """ -from __future__ import annotations - +import io import uuid -from typing import TYPE_CHECKING from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase @@ -13,9 +11,6 @@ from vws import VWS, CloudRecoService from vws.include_target_data import CloudRecoIncludeTargetData -if TYPE_CHECKING: - import io - class TestQuery: """ diff --git a/tests/test_vws.py b/tests/test_vws.py index 7d430d824..15df57494 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -2,13 +2,11 @@ Tests for helper functions for managing a Vuforia database. """ -from __future__ import annotations - import base64 import datetime +import io import secrets import uuid -from typing import TYPE_CHECKING import pytest from freezegun import freeze_time @@ -24,9 +22,6 @@ TargetSummaryReport, ) -if TYPE_CHECKING: - import io - class TestAddTarget: """ From 8b51775c190c512a2b0348e3968f34180c9256b1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 30 Aug 2024 10:15:36 +0000 Subject: [PATCH 0310/1003] Bump ruff from 0.6.2 to 0.6.3 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.6.2 to 0.6.3. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.6.2...0.6.3) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b33fe51d8..8da3849e1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pytest==8.3.2", "pytest-cov==5.0.0", "pyyaml==6.0.2", - "ruff==0.6.2", + "ruff==0.6.3", "sphinx==8.0.2", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", From 4eecd9c5fb8c9ae81965fef6c0a1b4e44be9c3cb Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 30 Aug 2024 16:29:51 +0100 Subject: [PATCH 0311/1003] Do runtime type checking --- pyproject.toml | 2 +- src/vws/exceptions/base_exceptions.py | 10 ++++++++-- src/vws/exceptions/cloud_reco_exceptions.py | 7 +++++++ src/vws/exceptions/custom_exceptions.py | 6 ++++++ src/vws/exceptions/response.py | 3 +++ src/vws/exceptions/vws_exceptions.py | 19 +++++++++++++++++++ src/vws/include_target_data.py | 3 +++ src/vws/query.py | 3 +++ src/vws/reports.py | 9 +++++++++ src/vws/vws.py | 4 ++++ 10 files changed, 63 insertions(+), 3 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 8da3849e1..08620c806 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -33,13 +33,13 @@ dynamic = [ "version", ] dependencies = [ + "beartype>=0.18.5", "requests", "urllib3", "vws-auth-tools", ] optional-dependencies.dev = [ "actionlint-py==1.7.1.15", - "beartype==0.18.5", "check-manifest==0.49", "deptry==0.20.0", "doc8==1.1.1", diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index 907d74731..6747de823 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -3,12 +3,16 @@ Cloud Recognition Web API. """ +from beartype import beartype + from .response import Response +@beartype class CloudRecoError(Exception): """ - Base class for Vuforia Cloud Recognition Web API exceptions. + Base @beartype + class for Vuforia Cloud Recognition Web API exceptions. """ def __init__(self, response: Response) -> None: @@ -27,9 +31,11 @@ def response(self) -> Response: return self._response +@beartype class VWSError(Exception): """ - Base class for Vuforia Web Services errors. + Base @beartype + class for Vuforia Web Services errors. These errors are defined at https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#result-codes. diff --git a/src/vws/exceptions/cloud_reco_exceptions.py b/src/vws/exceptions/cloud_reco_exceptions.py index 26c6fb097..ff5dde209 100644 --- a/src/vws/exceptions/cloud_reco_exceptions.py +++ b/src/vws/exceptions/cloud_reco_exceptions.py @@ -2,9 +2,12 @@ Exceptions which match errors raised by the Vuforia Cloud Recognition Web APIs. """ +from beartype import beartype + from vws.exceptions.base_exceptions import CloudRecoError +@beartype class MaxNumResultsOutOfRangeError(CloudRecoError): """ Exception raised when the ``max_num_results`` given to the Cloud @@ -12,6 +15,7 @@ class MaxNumResultsOutOfRangeError(CloudRecoError): """ +@beartype class InactiveProjectError(CloudRecoError): """ Exception raised when Vuforia returns a response with a result code @@ -19,6 +23,7 @@ class InactiveProjectError(CloudRecoError): """ +@beartype class BadImageError(CloudRecoError): """ Exception raised when Vuforia returns a response with a result code @@ -26,6 +31,7 @@ class BadImageError(CloudRecoError): """ +@beartype class AuthenticationFailureError(CloudRecoError): """ Exception raised when Vuforia returns a response with a result code @@ -33,6 +39,7 @@ class AuthenticationFailureError(CloudRecoError): """ +@beartype class RequestTimeTooSkewedError(CloudRecoError): """ Exception raised when Vuforia returns a response with a result code diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index 33f98187c..d036d8750 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -4,9 +4,12 @@ or simple errors given by the cloud recognition service. """ +from beartype import beartype + from .response import Response +@beartype class OopsAnErrorOccurredPossiblyBadNameError(Exception): """ Exception raised when VWS returns an HTML page which says "Oops, an error @@ -31,6 +34,7 @@ def response(self) -> Response: return self._response +@beartype class RequestEntityTooLargeError(Exception): """ Exception raised when the given image is too large. @@ -52,12 +56,14 @@ def response(self) -> Response: return self._response +@beartype class TargetProcessingTimeoutError(Exception): """ Exception raised when waiting for a target to be processed times out. """ +@beartype class ServerError(Exception): # pragma: no cover """ Exception raised when VWS returns a server error. diff --git a/src/vws/exceptions/response.py b/src/vws/exceptions/response.py index 89a42870b..0b3eced88 100644 --- a/src/vws/exceptions/response.py +++ b/src/vws/exceptions/response.py @@ -2,8 +2,11 @@ from dataclasses import dataclass +from beartype import beartype + @dataclass +@beartype class Response: """ A response from a request. diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index f626aeee6..ae9a4e0e4 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -7,9 +7,12 @@ import json from urllib.parse import urlparse +from beartype import beartype + from vws.exceptions.base_exceptions import VWSError +@beartype class UnknownTargetError(VWSError): """ Exception raised when Vuforia returns a response with a result code @@ -27,6 +30,7 @@ def target_id(self) -> str: return path.split(sep="/", maxsplit=2)[-1] +@beartype class FailError(VWSError): """ Exception raised when Vuforia returns a response with a result code @@ -34,6 +38,7 @@ class FailError(VWSError): """ +@beartype class BadImageError(VWSError): """ Exception raised when Vuforia returns a response with a result code @@ -41,6 +46,7 @@ class BadImageError(VWSError): """ +@beartype class AuthenticationFailureError(VWSError): """ Exception raised when Vuforia returns a response with a result code @@ -49,6 +55,7 @@ class AuthenticationFailureError(VWSError): # See https://github.com/VWS-Python/vws-python/issues/822. +@beartype class RequestQuotaReachedError(VWSError): # pragma: no cover """ Exception raised when Vuforia returns a response with a result code @@ -56,6 +63,7 @@ class RequestQuotaReachedError(VWSError): # pragma: no cover """ +@beartype class TargetStatusProcessingError(VWSError): """ Exception raised when Vuforia returns a response with a result code @@ -74,6 +82,7 @@ def target_id(self) -> str: # This is not simulated by the mock. +@beartype class DateRangeError(VWSError): # pragma: no cover """ Exception raised when Vuforia returns a response with a result code @@ -82,6 +91,7 @@ class DateRangeError(VWSError): # pragma: no cover # This is not simulated by the mock. +@beartype class TargetQuotaReachedError(VWSError): # pragma: no cover """ Exception raised when Vuforia returns a response with a result code @@ -90,6 +100,7 @@ class TargetQuotaReachedError(VWSError): # pragma: no cover # This is not simulated by the mock. +@beartype class ProjectSuspendedError(VWSError): # pragma: no cover """ Exception raised when Vuforia returns a response with a result code @@ -98,6 +109,7 @@ class ProjectSuspendedError(VWSError): # pragma: no cover # This is not simulated by the mock. +@beartype class ProjectHasNoAPIAccessError(VWSError): # pragma: no cover """ Exception raised when Vuforia returns a response with a result code @@ -105,6 +117,7 @@ class ProjectHasNoAPIAccessError(VWSError): # pragma: no cover """ +@beartype class ProjectInactiveError(VWSError): """ Exception raised when Vuforia returns a response with a result code @@ -112,6 +125,7 @@ class ProjectInactiveError(VWSError): """ +@beartype class MetadataTooLargeError(VWSError): """ Exception raised when Vuforia returns a response with a result code @@ -119,6 +133,7 @@ class MetadataTooLargeError(VWSError): """ +@beartype class RequestTimeTooSkewedError(VWSError): """ Exception raised when Vuforia returns a response with a result code @@ -126,6 +141,7 @@ class RequestTimeTooSkewedError(VWSError): """ +@beartype class TargetNameExistError(VWSError): """ Exception raised when Vuforia returns a response with a result code @@ -142,6 +158,7 @@ def target_name(self) -> str: return str(request_json["name"]) +@beartype class ImageTooLargeError(VWSError): """ Exception raised when Vuforia returns a response with a result code @@ -149,6 +166,7 @@ class ImageTooLargeError(VWSError): """ +@beartype class TargetStatusNotSuccessError(VWSError): """ Exception raised when Vuforia returns a response with a result code @@ -166,6 +184,7 @@ def target_id(self) -> str: return path.split(sep="/", maxsplit=2)[-1] +@beartype class TooManyRequestsError(VWSError): # pragma: no cover """ Exception raised when Vuforia returns a response with a result code diff --git a/src/vws/include_target_data.py b/src/vws/include_target_data.py index 0083ceeed..e259f654a 100644 --- a/src/vws/include_target_data.py +++ b/src/vws/include_target_data.py @@ -4,7 +4,10 @@ from enum import StrEnum, auto +from beartype import beartype + +@beartype class CloudRecoIncludeTargetData(StrEnum): """ Options for the ``include_target_data`` parameter of diff --git a/src/vws/query.py b/src/vws/query.py index c0e6b89bd..ce64f9455 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -10,6 +10,7 @@ from urllib.parse import urljoin import requests +from beartype import beartype from urllib3.filepost import encode_multipart_formdata from vws_auth_tools import authorization_header, rfc_1123_date @@ -29,6 +30,7 @@ from vws.reports import QueryResult, TargetData +@beartype def _get_image_data(image: BytesIO | BufferedRandom) -> bytes: """Get the data of an image file.""" original_tell = image.tell() @@ -38,6 +40,7 @@ def _get_image_data(image: BytesIO | BufferedRandom) -> bytes: return image_data +@beartype class CloudRecoService: """ An interface to the Vuforia Cloud Recognition Web APIs. diff --git a/src/vws/reports.py b/src/vws/reports.py index 2784ff078..3d157a783 100644 --- a/src/vws/reports.py +++ b/src/vws/reports.py @@ -6,7 +6,10 @@ from dataclasses import dataclass from enum import Enum +from beartype import BeartypeConf, beartype + +@beartype @dataclass class DatabaseSummaryReport: """ @@ -30,6 +33,7 @@ class DatabaseSummaryReport: total_recos: int +@beartype class TargetStatuses(Enum): """Constants representing VWS target statuses. @@ -42,6 +46,7 @@ class TargetStatuses(Enum): FAILED = "failed" +@beartype @dataclass class TargetSummaryReport: """ @@ -62,6 +67,7 @@ class TargetSummaryReport: previous_month_recos: int +@beartype(conf=BeartypeConf(is_pep484_tower=True)) @dataclass class TargetRecord: """ @@ -79,6 +85,7 @@ class TargetRecord: reco_rating: str +@beartype @dataclass class TargetData: """ @@ -90,6 +97,7 @@ class TargetData: target_timestamp: datetime.datetime +@beartype @dataclass class QueryResult: """ @@ -103,6 +111,7 @@ class QueryResult: target_data: TargetData | None +@beartype @dataclass class TargetStatusAndRecord: """ diff --git a/src/vws/vws.py b/src/vws/vws.py index 1ec660253..8d15fc2fb 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -12,6 +12,7 @@ from urllib.parse import urljoin import requests +from beartype import BeartypeConf, beartype from vws_auth_tools import authorization_header, rfc_1123_date from vws.exceptions.custom_exceptions import ( @@ -49,6 +50,7 @@ from .exceptions.response import Response +@beartype def _get_image_data(image: BytesIO | BufferedRandom) -> bytes: """Get the data of an image file.""" original_tell = image.tell() @@ -58,6 +60,7 @@ def _get_image_data(image: BytesIO | BufferedRandom) -> bytes: return image_data +@beartype def _target_api_request( server_access_key: str, server_secret_key: str, @@ -123,6 +126,7 @@ def _target_api_request( ) +@beartype(conf=BeartypeConf(is_pep484_tower=True)) class VWS: """ An interface to Vuforia Web Services APIs. From 885c7eb08b83540a239ff0d0b862539d96585bea Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 30 Aug 2024 16:38:16 +0100 Subject: [PATCH 0312/1003] Make tests run faster by configuring mock --- tests/conftest.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/conftest.py b/tests/conftest.py index e359e4a82..417879ae2 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -18,7 +18,8 @@ def mock_database() -> Generator[VuforiaDatabase, None, None]: """ Yield a mock ``VuforiaDatabase``. """ - with MockVWS() as mock: + # We use a low processing time so that tests run quickly. + with MockVWS(processing_time_seconds=0.2) as mock: database = VuforiaDatabase() mock.add_database(database=database) yield database From 664f1504849ff0be04c650757cdb9ce39294a886 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 30 Aug 2024 16:41:45 +0100 Subject: [PATCH 0313/1003] Use consistent way of setting image type --- src/vws/query.py | 6 +++--- src/vws/vws.py | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/vws/query.py b/src/vws/query.py index c0e6b89bd..01cfae14f 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -3,9 +3,9 @@ """ import datetime +import io import json from http import HTTPMethod, HTTPStatus -from io import BufferedRandom, BytesIO from typing import Any from urllib.parse import urljoin @@ -29,7 +29,7 @@ from vws.reports import QueryResult, TargetData -def _get_image_data(image: BytesIO | BufferedRandom) -> bytes: +def _get_image_data(image: io.BytesIO | io.BufferedRandom) -> bytes: """Get the data of an image file.""" original_tell = image.tell() image.seek(0) @@ -61,7 +61,7 @@ def __init__( def query( self, - image: BytesIO | BufferedRandom, + image: io.BytesIO | io.BufferedRandom, max_num_results: int = 1, include_target_data: CloudRecoIncludeTargetData = ( CloudRecoIncludeTargetData.TOP diff --git a/src/vws/vws.py b/src/vws/vws.py index 1ec660253..31375613a 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -8,7 +8,7 @@ import time from datetime import date from http import HTTPMethod, HTTPStatus -from io import BufferedRandom, BytesIO +from io import BufferedRandom from urllib.parse import urljoin import requests @@ -49,7 +49,7 @@ from .exceptions.response import Response -def _get_image_data(image: BytesIO | BufferedRandom) -> bytes: +def _get_image_data(image: io.BytesIO | BufferedRandom) -> bytes: """Get the data of an image file.""" original_tell = image.tell() image.seek(0) @@ -234,7 +234,7 @@ def add_target( self, name: str, width: float, - image: BytesIO | BufferedRandom, + image: io.BytesIO | io.BufferedRandom, application_metadata: str | None, *, active_flag: bool, From ecc66af629b48cc7310becc4fdd326e53a66e62f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 30 Aug 2024 17:19:57 +0100 Subject: [PATCH 0314/1003] Make README test run faster --- README.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/README.rst b/README.rst index b1fee9e29..455b1ea5d 100644 --- a/README.rst +++ b/README.rst @@ -30,7 +30,8 @@ Getting Started from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase - mock = MockVWS(real_http=False) + # We use a low processing time so that tests run quickly. + mock = MockVWS(processing_time_seconds=0.2) database = VuforiaDatabase( server_access_key='[server-access-key]', server_secret_key='[server-secret-key]', From c7b4302e980b8ac91111d19df593838bc9b446d3 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 30 Aug 2024 20:42:15 +0100 Subject: [PATCH 0315/1003] Neaten image_file fixture - dedent the main work --- tests/conftest.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/tests/conftest.py b/tests/conftest.py index 417879ae2..9fbb57d23 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -54,11 +54,10 @@ def image_file( ) -> Generator[io.BufferedRandom, None, None]: """An image file object.""" file = tmp_path / "image.jpg" - file.touch() - with file.open("r+b") as fileobj: - buffer = high_quality_image.getvalue() - fileobj.write(buffer) - yield fileobj + buffer = high_quality_image.getvalue() + file.write_bytes(data=buffer) + with file.open("r+b") as file_obj: + yield file_obj @pytest.fixture(params=["high_quality_image", "image_file"]) From 8dac60378e1c335fa3a30d0797b74d90ae65182b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 30 Aug 2024 20:42:55 +0100 Subject: [PATCH 0316/1003] Use kwarg on mode --- tests/conftest.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/conftest.py b/tests/conftest.py index 9fbb57d23..ac733ecaf 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -56,7 +56,7 @@ def image_file( file = tmp_path / "image.jpg" buffer = high_quality_image.getvalue() file.write_bytes(data=buffer) - with file.open("r+b") as file_obj: + with file.open(mode="r+b") as file_obj: yield file_obj From 20ab18f2c0610cd871f2ed0b43d123e6da17d879 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 30 Aug 2024 20:54:17 +0100 Subject: [PATCH 0317/1003] Use a variable for image type in src/ --- src/vws/query.py | 6 ++++-- src/vws/vws.py | 9 +++++---- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/src/vws/query.py b/src/vws/query.py index 01cfae14f..9c0f35120 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -28,8 +28,10 @@ from vws.include_target_data import CloudRecoIncludeTargetData from vws.reports import QueryResult, TargetData +_ImageType = io.BytesIO | io.BufferedRandom -def _get_image_data(image: io.BytesIO | io.BufferedRandom) -> bytes: + +def _get_image_data(image: _ImageType) -> bytes: """Get the data of an image file.""" original_tell = image.tell() image.seek(0) @@ -61,7 +63,7 @@ def __init__( def query( self, - image: io.BytesIO | io.BufferedRandom, + image: _ImageType, max_num_results: int = 1, include_target_data: CloudRecoIncludeTargetData = ( CloudRecoIncludeTargetData.TOP diff --git a/src/vws/vws.py b/src/vws/vws.py index 31375613a..412cf8a3a 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -8,7 +8,6 @@ import time from datetime import date from http import HTTPMethod, HTTPStatus -from io import BufferedRandom from urllib.parse import urljoin import requests @@ -48,8 +47,10 @@ from .exceptions.response import Response +_ImageType = io.BytesIO | io.BufferedRandom -def _get_image_data(image: io.BytesIO | BufferedRandom) -> bytes: + +def _get_image_data(image: _ImageType) -> bytes: """Get the data of an image file.""" original_tell = image.tell() image.seek(0) @@ -234,7 +235,7 @@ def add_target( self, name: str, width: float, - image: io.BytesIO | io.BufferedRandom, + image: _ImageType, application_metadata: str | None, *, active_flag: bool, @@ -617,7 +618,7 @@ def update_target( target_id: str, name: str | None = None, width: float | None = None, - image: io.BytesIO | io.BufferedRandom | None = None, + image: _ImageType | None = None, active_flag: bool | None = None, application_metadata: str | None = None, ) -> None: From 601295394be7bf30b20eae0e9e5d5428ee45d5e0 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 30 Aug 2024 21:05:13 +0100 Subject: [PATCH 0318/1003] Simplify high_quality_image type --- tests/test_cloud_reco_exceptions.py | 6 +++--- tests/test_vws.py | 2 +- tests/test_vws_exceptions.py | 22 ++++++++++------------ 3 files changed, 14 insertions(+), 16 deletions(-) diff --git a/tests/test_cloud_reco_exceptions.py b/tests/test_cloud_reco_exceptions.py index 1de69180e..5c0a89cd2 100644 --- a/tests/test_cloud_reco_exceptions.py +++ b/tests/test_cloud_reco_exceptions.py @@ -27,7 +27,7 @@ def test_too_many_max_results( cloud_reco_client: CloudRecoService, - high_quality_image: io.BytesIO | io.BufferedRandom, + high_quality_image: io.BytesIO, ) -> None: """ A ``MaxNumResultsOutOfRange`` error is raised if the given @@ -78,7 +78,7 @@ def test_cloudrecoexception_inheritance() -> None: def test_authentication_failure( - high_quality_image: io.BytesIO | io.BufferedRandom, + high_quality_image: io.BytesIO, ) -> None: """ An ``AuthenticationFailure`` exception is raised when the client access key @@ -99,7 +99,7 @@ def test_authentication_failure( def test_inactive_project( - high_quality_image: io.BytesIO | io.BufferedRandom, + high_quality_image: io.BytesIO, ) -> None: """ An ``InactiveProject`` exception is raised when querying an inactive diff --git a/tests/test_vws.py b/tests/test_vws.py index 15df57494..6636c4f9a 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -495,7 +495,7 @@ class TestUpdateTarget: def test_update_target( vws_client: VWS, image: io.BytesIO | io.BufferedRandom, - different_high_quality_image: io.BytesIO | io.BufferedRandom, + different_high_quality_image: io.BytesIO, cloud_reco_client: CloudRecoService, ) -> None: """ diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 4f5e15ef2..ef105f7da 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -69,9 +69,7 @@ def test_invalid_given_id(vws_client: VWS) -> None: assert exc.value.target_id == target_id -def test_add_bad_name( - vws_client: VWS, high_quality_image: io.BytesIO | io.BufferedRandom -) -> None: +def test_add_bad_name(vws_client: VWS, high_quality_image: io.BytesIO) -> None: """ When a name with a bad character is given, an ``OopsAnErrorOccurredPossiblyBadName`` exception is raised. @@ -97,7 +95,7 @@ def test_request_quota_reached() -> None: """ -def test_fail(high_quality_image: io.BytesIO | io.BufferedRandom) -> None: +def test_fail(high_quality_image: io.BytesIO) -> None: """ A ``Fail`` exception is raised when the server access key does not exist. """ @@ -138,7 +136,7 @@ def test_bad_image(vws_client: VWS) -> None: def test_target_name_exist( vws_client: VWS, - high_quality_image: io.BytesIO | io.BufferedRandom, + high_quality_image: io.BytesIO, ) -> None: """ A ``TargetNameExist`` exception is raised after adding two targets with @@ -165,7 +163,7 @@ def test_target_name_exist( def test_project_inactive( - high_quality_image: io.BytesIO | io.BufferedRandom, + high_quality_image: io.BytesIO, ) -> None: """ A ``ProjectInactive`` exception is raised if adding a target to an @@ -193,7 +191,7 @@ def test_project_inactive( def test_target_status_processing( vws_client: VWS, - high_quality_image: io.BytesIO | io.BufferedRandom, + high_quality_image: io.BytesIO, ) -> None: """ A ``TargetStatusProcessing`` exception is raised if trying to delete a @@ -216,7 +214,7 @@ def test_target_status_processing( def test_metadata_too_large( vws_client: VWS, - high_quality_image: io.BytesIO | io.BufferedRandom, + high_quality_image: io.BytesIO, ) -> None: """ A ``MetadataTooLarge`` exception is raised if the metadata given is too @@ -236,7 +234,7 @@ def test_metadata_too_large( def test_request_time_too_skewed( vws_client: VWS, - high_quality_image: io.BytesIO | io.BufferedRandom, + high_quality_image: io.BytesIO, ) -> None: """ A ``RequestTimeTooSkewed`` exception is raised when the request time is @@ -270,7 +268,7 @@ def test_request_time_too_skewed( def test_authentication_failure( - high_quality_image: io.BytesIO | io.BufferedRandom, + high_quality_image: io.BytesIO, ) -> None: """ An ``AuthenticationFailure`` exception is raised when the server access key @@ -301,7 +299,7 @@ def test_authentication_failure( def test_target_status_not_success( vws_client: VWS, - high_quality_image: io.BytesIO | io.BufferedRandom, + high_quality_image: io.BytesIO, ) -> None: """ A ``TargetStatusNotSuccess`` exception is raised when updating a target @@ -350,7 +348,7 @@ def test_vwsexception_inheritance() -> None: def test_base_exception( vws_client: VWS, - high_quality_image: io.BytesIO | io.BufferedRandom, + high_quality_image: io.BytesIO, ) -> None: """ ``VWSException``s has a response property. From b36b236fbcfa82d52004954f112f94a5347db9d4 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 30 Aug 2024 21:09:58 +0100 Subject: [PATCH 0319/1003] Remove an isinstance check --- tests/conftest.py | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/tests/conftest.py b/tests/conftest.py index ac733ecaf..0180455a4 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -47,8 +47,8 @@ def cloud_reco_client(_mock_database: VuforiaDatabase) -> CloudRecoService: ) -@pytest.fixture -def image_file( +@pytest.fixture(name="image_file") +def image_file_fixture( high_quality_image: io.BytesIO, tmp_path: Path, ) -> Generator[io.BufferedRandom, None, None]: @@ -63,8 +63,10 @@ def image_file( @pytest.fixture(params=["high_quality_image", "image_file"]) def image( request: pytest.FixtureRequest, + high_quality_image: io.BytesIO, + image_file: io.BufferedRandom, ) -> io.BytesIO | io.BufferedRandom: """An image in any of the types that the API accepts.""" - result = request.getfixturevalue(request.param) - assert isinstance(result, io.BytesIO | io.BufferedRandom) - return result + if request.param == "high_quality_image": + return high_quality_image + return image_file From 4480f9760f8ef9fae424c4156774ed46eb420da7 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 30 Aug 2024 21:17:21 +0100 Subject: [PATCH 0320/1003] Support more ways of passing in an image --- src/vws/query.py | 4 ++-- src/vws/vws.py | 3 ++- tests/conftest.py | 13 ++++++++----- tests/test_query.py | 19 ++++++++++--------- tests/test_vws.py | 29 +++++++++++++++-------------- 5 files changed, 37 insertions(+), 31 deletions(-) diff --git a/src/vws/query.py b/src/vws/query.py index 9c0f35120..8bddbb16b 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -6,7 +6,7 @@ import io import json from http import HTTPMethod, HTTPStatus -from typing import Any +from typing import Any, BinaryIO from urllib.parse import urljoin import requests @@ -28,7 +28,7 @@ from vws.include_target_data import CloudRecoIncludeTargetData from vws.reports import QueryResult, TargetData -_ImageType = io.BytesIO | io.BufferedRandom +_ImageType = io.BytesIO | BinaryIO def _get_image_data(image: _ImageType) -> bytes: diff --git a/src/vws/vws.py b/src/vws/vws.py index 412cf8a3a..89462cdd2 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -8,6 +8,7 @@ import time from datetime import date from http import HTTPMethod, HTTPStatus +from typing import BinaryIO from urllib.parse import urljoin import requests @@ -47,7 +48,7 @@ from .exceptions.response import Response -_ImageType = io.BytesIO | io.BufferedRandom +_ImageType = io.BytesIO | BinaryIO def _get_image_data(image: _ImageType) -> bytes: diff --git a/tests/conftest.py b/tests/conftest.py index 0180455a4..0ec595e31 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -5,6 +5,7 @@ import io from collections.abc import Generator from pathlib import Path +from typing import BinaryIO, Literal import pytest from mock_vws import MockVWS @@ -47,16 +48,18 @@ def cloud_reco_client(_mock_database: VuforiaDatabase) -> CloudRecoService: ) -@pytest.fixture(name="image_file") +@pytest.fixture(name="image_file", params=["r+b", "rb"]) def image_file_fixture( high_quality_image: io.BytesIO, tmp_path: Path, -) -> Generator[io.BufferedRandom, None, None]: + request: pytest.FixtureRequest, +) -> Generator[BinaryIO, None, None]: """An image file object.""" file = tmp_path / "image.jpg" buffer = high_quality_image.getvalue() file.write_bytes(data=buffer) - with file.open(mode="r+b") as file_obj: + mode: Literal["r+b", "rb"] = request.param + with file.open(mode=mode) as file_obj: yield file_obj @@ -64,8 +67,8 @@ def image_file_fixture( def image( request: pytest.FixtureRequest, high_quality_image: io.BytesIO, - image_file: io.BufferedRandom, -) -> io.BytesIO | io.BufferedRandom: + image_file: BinaryIO, +) -> io.BytesIO | BinaryIO: """An image in any of the types that the API accepts.""" if request.param == "high_quality_image": return high_quality_image diff --git a/tests/test_query.py b/tests/test_query.py index 4a3df25cb..e229cf95d 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -4,6 +4,7 @@ import io import uuid +from typing import BinaryIO from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase @@ -20,7 +21,7 @@ class TestQuery: @staticmethod def test_no_matches( cloud_reco_client: CloudRecoService, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ An empty list is returned if there are no matches. @@ -32,7 +33,7 @@ def test_no_matches( def test_match( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ Details of matching targets are returned. @@ -55,7 +56,7 @@ class TestCustomBaseVWQURL: """ @staticmethod - def test_custom_base_url(image: io.BytesIO | io.BufferedRandom) -> None: + def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: """ It is possible to use query a target to a database under a custom VWQ URL. @@ -100,7 +101,7 @@ class TestMaxNumResults: def test_default( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ By default the maximum number of results is 1. @@ -128,7 +129,7 @@ def test_default( def test_custom( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ It is possible to set a custom ``max_num_results``. @@ -174,7 +175,7 @@ class TestIncludeTargetData: def test_default( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ By default, target data is only returned in the top match. @@ -206,7 +207,7 @@ def test_default( def test_top( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ When ``CloudRecoIncludeTargetData.TOP`` is given, target data is only @@ -240,7 +241,7 @@ def test_top( def test_none( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ When ``CloudRecoIncludeTargetData.NONE`` is given, target data is not @@ -274,7 +275,7 @@ def test_none( def test_all( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ When ``CloudRecoIncludeTargetData.ALL`` is given, target data is diff --git a/tests/test_vws.py b/tests/test_vws.py index 6636c4f9a..ab8cd079e 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -7,6 +7,7 @@ import io import secrets import uuid +from typing import BinaryIO import pytest from freezegun import freeze_time @@ -33,7 +34,7 @@ class TestAddTarget: @pytest.mark.parametrize("active_flag", [True, False]) def test_add_target( vws_client: VWS, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, application_metadata: bytes | None, cloud_reco_client: CloudRecoService, *, @@ -77,7 +78,7 @@ def test_add_target( @staticmethod def test_add_two_targets( vws_client: VWS, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ No exception is raised when adding two targets with different names. @@ -100,7 +101,7 @@ class TestCustomBaseVWSURL: """ @staticmethod - def test_custom_base_url(image: io.BytesIO | io.BufferedRandom) -> None: + def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: """ It is possible to use add a target to a database under a custom VWS URL. @@ -132,7 +133,7 @@ class TestListTargets: @staticmethod def test_list_targets( vws_client: VWS, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ It is possible to get a list of target IDs. @@ -162,7 +163,7 @@ class TestDelete: @staticmethod def test_delete_target( vws_client: VWS, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ It is possible to delete a target. @@ -189,7 +190,7 @@ class TestGetTargetSummaryReport: @staticmethod def test_get_target_summary_report( vws_client: VWS, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ Details of a target are returned by ``get_target_summary_report``. @@ -258,7 +259,7 @@ class TestGetTargetRecord: @staticmethod def test_get_target_record( vws_client: VWS, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ Details of a target are returned by ``get_target_record``. @@ -293,7 +294,7 @@ class TestWaitForTargetProcessed: @staticmethod def test_wait_for_target_processed( vws_client: VWS, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ It is possible to wait until a target is processed. @@ -313,7 +314,7 @@ def test_wait_for_target_processed( @staticmethod def test_default_seconds_between_requests( - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ By default, 0.2 seconds are waited between polling requests. @@ -365,7 +366,7 @@ def test_default_seconds_between_requests( @staticmethod def test_custom_seconds_between_requests( - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ It is possible to customize the time waited between polling requests. @@ -416,7 +417,7 @@ def test_custom_seconds_between_requests( assert report.request_usage == expected_requests @staticmethod - def test_custom_timeout(image: io.BytesIO | io.BufferedRandom) -> None: + def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: """ It is possible to set a maximum timeout. """ @@ -460,7 +461,7 @@ class TestGetDuplicateTargets: @staticmethod def test_get_duplicate_targets( vws_client: VWS, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ It is possible to get the IDs of similar targets. @@ -494,7 +495,7 @@ class TestUpdateTarget: @staticmethod def test_update_target( vws_client: VWS, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, different_high_quality_image: io.BytesIO, cloud_reco_client: CloudRecoService, ) -> None: @@ -553,7 +554,7 @@ def test_update_target( @staticmethod def test_no_fields_given( vws_client: VWS, - image: io.BytesIO | io.BufferedRandom, + image: io.BytesIO | BinaryIO, ) -> None: """ It is possible to give no update fields. From ef312200495addbd32039582239e4935a9cba30e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 31 Aug 2024 07:18:31 +0100 Subject: [PATCH 0321/1003] Use newline for better highlighting --- README.rst | 1 + 1 file changed, 1 insertion(+) diff --git a/README.rst b/README.rst index 455b1ea5d..4feb4c62d 100644 --- a/README.rst +++ b/README.rst @@ -85,6 +85,7 @@ Getting Started assert matching_targets[0].target_id == target_id .. invisible-code-block: python + new_image = pathlib.Path('high_quality_image.jpg') new_image.unlink() stack.close() From 2b4071f6bf363ef24570005aa6f9915cdb412a05 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 31 Aug 2024 07:59:33 +0100 Subject: [PATCH 0322/1003] Make it possible to run all tests in parallel --- README.rst | 35 --------------------------- conftest.py | 40 +++++++++++++++++++++++++++++++ docs/source/index.rst | 55 ++----------------------------------------- pyproject.toml | 7 +++++- 4 files changed, 48 insertions(+), 89 deletions(-) diff --git a/README.rst b/README.rst index 4feb4c62d..cb5f4b116 100644 --- a/README.rst +++ b/README.rst @@ -20,35 +20,6 @@ language. Getting Started --------------- -.. invisible-code-block: python - - import contextlib - import pathlib - import shutil - - import vws_test_fixtures - from mock_vws import MockVWS - from mock_vws.database import VuforiaDatabase - - # We use a low processing time so that tests run quickly. - mock = MockVWS(processing_time_seconds=0.2) - database = VuforiaDatabase( - server_access_key='[server-access-key]', - server_secret_key='[server-secret-key]', - client_access_key='[client-access-key]', - client_secret_key='[client-secret-key]', - ) - mock.add_database(database=database) - stack = contextlib.ExitStack() - stack.enter_context(mock) - - # We rely on implementation details of the fixtures package. - image = pathlib.Path(vws_test_fixtures.__path__[0]) / 'high_quality_image.jpg' - assert image.exists(), image.resolve() - new_image = pathlib.Path('high_quality_image.jpg') - shutil.copy(image, new_image) - - .. code-block:: python import pathlib @@ -84,12 +55,6 @@ Getting Started assert matching_targets[0].target_id == target_id -.. invisible-code-block: python - - new_image = pathlib.Path('high_quality_image.jpg') - new_image.unlink() - stack.close() - Full Documentation ------------------ diff --git a/conftest.py b/conftest.py index 1bbad0e64..059fd0968 100644 --- a/conftest.py +++ b/conftest.py @@ -1,9 +1,14 @@ """Setup for Sybil.""" +import io +from collections.abc import Generator from doctest import ELLIPSIS +from pathlib import Path import pytest from beartype import beartype +from mock_vws import MockVWS +from mock_vws.database import VuforiaDatabase from sybil import Sybil from sybil.parsers.rest import ( ClearNamespaceParser, @@ -21,6 +26,40 @@ def pytest_collection_modifyitems(items: list[pytest.Item]) -> None: item.obj = beartype(obj=item.obj) +@pytest.fixture +def make_image_file( + high_quality_image: io.BytesIO, +) -> Generator[None, None, None]: + """ + Make an image file available in the test directory. + The path of this file matches the path in the documentation. + """ + new_image = Path("high_quality_image.jpg") + buffer = high_quality_image.getvalue() + new_image.write_bytes(data=buffer) + yield + new_image.unlink() + + +@pytest.fixture +def mock_vws() -> Generator[None, None, None]: + """ + Yield a mock VWS. + + The keys used here match the keys in the documentation. + """ + database = VuforiaDatabase( + server_access_key="[server-access-key]", + server_secret_key="[server-secret-key]", + client_access_key="[client-access-key]", + client_secret_key="[client-secret-key]", + ) + # We use a low processing time so that tests run quickly. + with MockVWS(processing_time_seconds=0.2) as mock: + mock.add_database(database=database) + yield + + pytest_collect_file = Sybil( parsers=[ ClearNamespaceParser(), @@ -28,4 +67,5 @@ def pytest_collection_modifyitems(items: list[pytest.Item]) -> None: PythonCodeBlockParser(), ], patterns=["*.rst", "*.py"], + fixtures=["make_image_file", "mock_vws"], ).pytest() diff --git a/docs/source/index.rst b/docs/source/index.rst index 287ce7df1..907096d1d 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -16,33 +16,6 @@ Usage See the :doc:`api-reference` for full usage details. -.. invisible-code-block: python - - import contextlib - import pathlib - import shutil - - import vws_test_fixtures - from mock_vws import MockVWS - from mock_vws.database import VuforiaDatabase - - mock = MockVWS(real_http=False) - database = VuforiaDatabase( - server_access_key='[server-access-key]', - server_secret_key='[server-secret-key]', - client_access_key='[client-access-key]', - client_secret_key='[client-secret-key]', - ) - mock.add_database(database=database) - stack = contextlib.ExitStack() - stack.enter_context(mock) - - # We rely on implementation details of the fixtures package. - image = pathlib.Path(vws_test_fixtures.__path__[0]) / 'high_quality_image.jpg' - assert image.exists(), image.resolve() - new_image = pathlib.Path('high_quality_image.jpg') - shutil.copy(image, new_image) - .. code-block:: python import pathlib @@ -62,7 +35,8 @@ See the :doc:`api-reference` for full usage details. client_access_key=client_access_key, client_secret_key=client_secret_key, ) - name = 'my_image_name' + import uuid + name = 'my_image_name' + uuid.uuid4().hex image = pathlib.Path('high_quality_image.jpg') with image.open(mode='rb') as my_image_file: @@ -79,12 +53,6 @@ See the :doc:`api-reference` for full usage details. assert matching_targets[0].target_id == target_id a = 1 -.. invisible-code-block: python - - new_image = pathlib.Path('high_quality_image.jpg') - new_image.unlink() - stack.close() - Testing ------- @@ -96,19 +64,6 @@ To write unit tests for code which uses this library, without using your Vuforia .. clear-namespace -.. invisible-code-block: python - - import pathlib - import shutil - - import vws_test_fixtures - - # We rely on implementation details of the fixtures package. - image = pathlib.Path(vws_test_fixtures.__path__[0]) / 'high_quality_image.jpg' - assert image.exists(), image.resolve() - new_image = pathlib.Path('high_quality_image.jpg') - shutil.copy(image, new_image) - .. code-block:: python import pathlib @@ -129,7 +84,6 @@ To write unit tests for code which uses this library, without using your Vuforia client_secret_key=database.client_secret_key, ) - image = pathlib.Path('high_quality_image.jpg') with image.open(mode='rb') as my_image_file: target_id = vws_client.add_target( @@ -140,11 +94,6 @@ To write unit tests for code which uses this library, without using your Vuforia active_flag=True, ) -.. invisible-code-block: python - - new_image = pathlib.Path('high_quality_image.jpg') - new_image.unlink() - There are some differences between the mock and the real Vuforia. See https://vws-python-mock.readthedocs.io/en/latest/differences-to-vws.html for details. diff --git a/pyproject.toml b/pyproject.toml index 08620c806..d62d8bf02 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -117,7 +117,12 @@ lint.ignore = [ "S101", ] -lint.per-file-ignores."tests/test_*.py" = [ +lint.per-file-ignores."conftest.py" = [ + # Allow hardcoded secrets in tests. + "S106", +] + +lint.per-file-ignores."tests/*.py" = [ # Do not require tests to have a one-line summary. "D205", ] From d2e753516023fee9f5a2eb760f7953de7bf3a06b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 2 Sep 2024 10:15:07 +0000 Subject: [PATCH 0323/1003] Bump pylint from 3.2.6 to 3.2.7 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.2.6 to 3.2.7. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.2.6...v3.2.7) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d62d8bf02..9d5ce3b2d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pyenchant==3.2.2", "pygments==2.18.0", - "pylint==3.2.6", + "pylint==3.2.7", "pyproject-fmt==2.2.1", "pyright==1.1.378", "pyroma==4.2", From b5ddce194e65f6419ea97b89d8abb389710c3342 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 2 Sep 2024 10:19:51 +0000 Subject: [PATCH 0324/1003] Bump vws-python-mock from 2024.7.15 to 2024.8.30 Bumps [vws-python-mock](https://github.com/VWS-Python/vws-python-mock) from 2024.7.15 to 2024.8.30. - [Release notes](https://github.com/VWS-Python/vws-python-mock/releases) - [Changelog](https://github.com/VWS-Python/vws-python-mock/blob/main/CHANGELOG.rst) - [Commits](https://github.com/VWS-Python/vws-python-mock/compare/2024.07.15...2024.08.30) --- updated-dependencies: - dependency-name: vws-python-mock dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9d5ce3b2d..081784af9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -66,7 +66,7 @@ optional-dependencies.dev = [ "sybil==6.1.1", "types-requests==2.32.0.20240712", "vulture==2.11", - "vws-python-mock==2024.7.15", + "vws-python-mock==2024.8.30", "vws-test-fixtures==2023.3.5", ] urls.Documentation = "https://vws-python.readthedocs.io/en/latest/" From 8f2c74aeb65fe7c7c67e335307672e89d32509b7 Mon Sep 17 00:00:00 2001 From: adamtheturtle Date: Mon, 2 Sep 2024 10:47:08 +0000 Subject: [PATCH 0325/1003] Bump CHANGELOG --- CHANGELOG.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 883b5f4e3..ad76c9902 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,9 @@ Changelog Next ---- +2024.09.02 +------------ + * Breaking change: Exception names now end with ``Error``. * Use a timeout (30 seconds) when making requests to the VWS API. * Type hint changes: images are now ``io.BytesIO`` instances or ``io.BufferedRandom``. From 565b1d920f2f40bd38b9475270170f806fd5b73d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 3 Sep 2024 10:27:49 +0000 Subject: [PATCH 0326/1003] Bump doc8 from 1.1.1 to 1.1.2 Bumps [doc8](https://github.com/pycqa/doc8) from 1.1.1 to 1.1.2. - [Release notes](https://github.com/pycqa/doc8/releases) - [Commits](https://github.com/pycqa/doc8/compare/v1.1.1...v1.1.2) --- updated-dependencies: - dependency-name: doc8 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 081784af9..ebabd99e3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -42,7 +42,7 @@ optional-dependencies.dev = [ "actionlint-py==1.7.1.15", "check-manifest==0.49", "deptry==0.20.0", - "doc8==1.1.1", + "doc8==1.1.2", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", From bbae55213f29c32dc91eb496c14828f3310f5aa2 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 3 Sep 2024 15:04:42 +0100 Subject: [PATCH 0327/1003] Use more keyword arguments - better errors from type checkers --- src/vws/exceptions/vws_exceptions.py | 6 +++--- src/vws/query.py | 2 +- src/vws/vws.py | 16 +++++++++------- tests/test_vws.py | 10 ++++++---- tests/test_vws_exceptions.py | 2 +- 5 files changed, 20 insertions(+), 16 deletions(-) diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index ae9a4e0e4..bf6d5fc4d 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -24,7 +24,7 @@ def target_id(self) -> str: """ The unknown target ID. """ - path = urlparse(self.response.url).path + path = urlparse(url=self.response.url).path # Every HTTP path which can raise this error is in the format # `/something/{target_id}`. return path.split(sep="/", maxsplit=2)[-1] @@ -75,7 +75,7 @@ def target_id(self) -> str: """ The processing target ID. """ - path = urlparse(self.response.url).path + path = urlparse(url=self.response.url).path # Every HTTP path which can raise this error is in the format # `/something/{target_id}`. return path.split(sep="/", maxsplit=2)[-1] @@ -178,7 +178,7 @@ def target_id(self) -> str: """ The unknown target ID. """ - path = urlparse(self.response.url).path + path = urlparse(url=self.response.url).path # Every HTTP path which can raise this error is in the format # `/something/{target_id}`. return path.split(sep="/", maxsplit=2)[-1] diff --git a/src/vws/query.py b/src/vws/query.py index 9bc372f2b..fc42a3ff5 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -186,7 +186,7 @@ def query( metadata = target_data_dict["application_metadata"] timestamp_string = target_data_dict["target_timestamp"] target_timestamp = datetime.datetime.fromtimestamp( - timestamp_string, + timestamp=timestamp_string, tz=datetime.UTC, ) target_data = TargetData( diff --git a/src/vws/vws.py b/src/vws/vws.py index b55b3d23d..5982981f6 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -316,7 +316,7 @@ def add_target( expected_result_code="TargetCreated", ) - return str(json.loads(response.text)["target_id"]) + return str(json.loads(s=response.text)["target_id"]) def get_target_record(self, target_id: str) -> TargetStatusAndRecord: """ @@ -354,7 +354,7 @@ def get_target_record(self, target_id: str) -> TargetStatusAndRecord: ) result_data = json.loads(s=response.text) - status = TargetStatuses(result_data["status"]) + status = TargetStatuses(value=result_data["status"]) target_record_dict = dict(result_data["target_record"]) target_record = TargetRecord( target_id=target_record_dict["target_id"], @@ -449,7 +449,7 @@ def list_targets(self) -> list[str]: expected_result_code="Success", ) - return list(json.loads(response.text)["results"]) + return list(json.loads(s=response.text)["results"]) def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: """ @@ -486,9 +486,9 @@ def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: expected_result_code="Success", ) - result_data = dict(json.loads(response.text)) + result_data = dict(json.loads(s=response.text)) return TargetSummaryReport( - status=TargetStatuses(result_data["status"]), + status=TargetStatuses(value=result_data["status"]), database_name=result_data["database_name"], target_name=result_data["target_name"], upload_date=date.fromisoformat(result_data["upload_date"]), @@ -529,7 +529,7 @@ def get_database_summary_report(self) -> DatabaseSummaryReport: expected_result_code="Success", ) - response_data = dict(json.loads(response.text)) + response_data = dict(json.loads(s=response.text)) return DatabaseSummaryReport( active_images=response_data["active_images"], current_month_recos=response_data["current_month_recos"], @@ -682,7 +682,9 @@ def update_target( if image is not None: image_data = _get_image_data(image=image) - image_data_encoded = base64.b64encode(image_data).decode("ascii") + image_data_encoded = base64.b64encode(s=image_data).decode( + encoding="ascii", + ) data["image"] = image_data_encoded if active_flag is not None: diff --git a/tests/test_vws.py b/tests/test_vws.py index ab8cd079e..c5761b78a 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -48,8 +48,8 @@ def test_add_target( if application_metadata is None: encoded_metadata = None else: - encoded_metadata_bytes = base64.b64encode(application_metadata) - encoded_metadata = encoded_metadata_bytes.decode("utf-8") + encoded_metadata_bytes = base64.b64encode(s=application_metadata) + encoded_metadata = encoded_metadata_bytes.decode(encoding="utf-8") target_id = vws_client.add_target( name=name, @@ -197,7 +197,7 @@ def test_get_target_summary_report( """ date = "2018-04-25" target_name = uuid.uuid4().hex - with freeze_time(date): + with freeze_time(time_to_freeze=date): target_id = vws_client.add_target( name=target_name, width=1, @@ -521,7 +521,9 @@ def test_update_target( new_name = uuid.uuid4().hex new_width = secrets.choice(seq=range(1, 5000)) / 100 - new_application_metadata = base64.b64encode(b"a").decode("ascii") + new_application_metadata = base64.b64encode(s=b"a").decode( + encoding="ascii", + ) vws_client.update_target( target_id=target_id, name=new_name, diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index ef105f7da..0c9de2d29 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -121,7 +121,7 @@ def test_bad_image(vws_client: VWS) -> None: """ A ``BadImage`` exception is raised when a non-image is given. """ - not_an_image = io.BytesIO(b"Not an image") + not_an_image = io.BytesIO(initial_bytes=b"Not an image") with pytest.raises(BadImageError) as exc: vws_client.add_target( name="x", From 4a785e5d6caf43f2ba88422e0e803b20f61a2de1 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 3 Sep 2024 15:30:38 +0100 Subject: [PATCH 0328/1003] Make 'VWS.make_request' a public method --- CHANGELOG.rst | 2 ++ src/vws/vws.py | 18 +++++++++--------- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index ad76c9902..64a9f70a9 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,8 @@ Changelog Next ---- +* Make ``VWS.make_request`` a public method. + 2024.09.02 ------------ diff --git a/src/vws/vws.py b/src/vws/vws.py index 5982981f6..c14b76087 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -150,7 +150,7 @@ def __init__( self._server_secret_key = server_secret_key self._base_vws_url = base_vws_url - def _make_request( + def make_request( self, method: str, data: bytes, @@ -309,7 +309,7 @@ def add_target( content = json.dumps(obj=data).encode(encoding="utf-8") - response = self._make_request( + response = self.make_request( method=HTTPMethod.POST, data=content, request_path="/targets", @@ -346,7 +346,7 @@ def get_target_record(self, target_id: str) -> TargetStatusAndRecord: ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is rate limiting access. """ - response = self._make_request( + response = self.make_request( method=HTTPMethod.GET, data=b"", request_path=f"/targets/{target_id}", @@ -442,7 +442,7 @@ def list_targets(self) -> list[str]: ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is rate limiting access. """ - response = self._make_request( + response = self.make_request( method=HTTPMethod.GET, data=b"", request_path="/targets", @@ -479,7 +479,7 @@ def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is rate limiting access. """ - response = self._make_request( + response = self.make_request( method=HTTPMethod.GET, data=b"", request_path=f"/summary/{target_id}", @@ -522,7 +522,7 @@ def get_database_summary_report(self) -> DatabaseSummaryReport: ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is rate limiting access. """ - response = self._make_request( + response = self.make_request( method=HTTPMethod.GET, data=b"", request_path="/summary", @@ -572,7 +572,7 @@ def delete_target(self, target_id: str) -> None: ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is rate limiting access. """ - self._make_request( + self.make_request( method=HTTPMethod.DELETE, data=b"", request_path=f"/targets/{target_id}", @@ -609,7 +609,7 @@ def get_duplicate_targets(self, target_id: str) -> list[str]: ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is rate limiting access. """ - response = self._make_request( + response = self.make_request( method=HTTPMethod.GET, data=b"", request_path=f"/duplicates/{target_id}", @@ -695,7 +695,7 @@ def update_target( content = json.dumps(obj=data).encode(encoding="utf-8") - self._make_request( + self.make_request( method=HTTPMethod.PUT, data=content, request_path=f"/targets/{target_id}", From 1ab0e7c0546dd4f45773a72a57a8a37fca190d73 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 3 Sep 2024 15:37:11 +0100 Subject: [PATCH 0329/1003] Fix API doc references --- src/vws/vws.py | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/vws/vws.py b/src/vws/vws.py index c14b76087..6cbab706e 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -175,17 +175,19 @@ def make_request( The response to the request made by `requests`. Raises: - ~vws.exceptions.OopsAnErrorOccurredPossiblyBadNameError: Vuforia - returns an HTML page with the text "Oops, an error occurred". + ~vws.exceptions.custom_exceptions.OopsAnErrorOccurredPossiblyBadNameError: + Vuforia returns an HTML page with the text "Oops, an error + occurred". + This has been seen to happen when the given name includes a bad character. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is rate limiting access. - json.decoder.JSONDecodeError: The server did not respond with valid - JSON. This may happen if the server address is not a valid - Vuforia server. + json.JSONDecodeError: The server did not respond with valid JSON. + This may happen if the server address is not a valid Vuforia + server. """ response = _target_api_request( server_access_key=self._server_access_key, From 252435c3a081a2837afdf35cb821d902ac5d75d8 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 3 Sep 2024 15:44:37 +0100 Subject: [PATCH 0330/1003] Fix linkcheck builder --- src/vws/vws.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vws/vws.py b/src/vws/vws.py index 6cbab706e..9879102cf 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -160,7 +160,7 @@ def make_request( """ Make a request to the Vuforia Target API. - This uses `requests` to make a request against https://vws.vuforia.com. + This uses `requests` to make a request against Vuforia. The content type of the request will be `application/json`. Args: @@ -168,8 +168,8 @@ def make_request( data: The request body which will be used in the request. request_path: The path to the endpoint which will be used in the request. - expected_result_code: See - https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#result-codes + expected_result_code: See "VWS API Result Codes" on + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api. Returns: The response to the request made by `requests`. From e7d37e91d2c633a5ae2687c8892f2eb58efad94c Mon Sep 17 00:00:00 2001 From: adamtheturtle Date: Tue, 3 Sep 2024 14:50:17 +0000 Subject: [PATCH 0331/1003] Bump CHANGELOG --- CHANGELOG.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 64a9f70a9..82663c55a 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,9 @@ Changelog Next ---- +2024.09.03 +------------ + * Make ``VWS.make_request`` a public method. 2024.09.02 From 26603a60cab9add1d65faa19e10a8ba6a2654970 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 3 Sep 2024 15:59:13 +0100 Subject: [PATCH 0332/1003] Expose content type parameter on VWS.make_request --- src/vws/vws.py | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/src/vws/vws.py b/src/vws/vws.py index 9879102cf..6f622773f 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -64,6 +64,8 @@ def _get_image_data(image: _ImageType) -> bytes: @beartype def _target_api_request( + *, + content_type: str, server_access_key: str, server_secret_key: str, method: str, @@ -75,9 +77,9 @@ def _target_api_request( Make a request to the Vuforia Target API. This uses `requests` to make a request against https://vws.vuforia.com. - The content type of the request will be `application/json`. Args: + content_type: The content type of the request. server_access_key: A VWS server access key. server_secret_key: A VWS server secret key. method: The HTTP method which will be used in the request. @@ -90,7 +92,6 @@ def _target_api_request( The response to the request made by `requests`. """ date_string = rfc_1123_date() - content_type = "application/json" signature_string = authorization_header( access_key=server_access_key, @@ -152,16 +153,17 @@ def __init__( def make_request( self, + *, method: str, data: bytes, request_path: str, expected_result_code: str, + content_type: str, ) -> Response: """ Make a request to the Vuforia Target API. This uses `requests` to make a request against Vuforia. - The content type of the request will be `application/json`. Args: method: The HTTP method which will be used in the request. @@ -170,6 +172,7 @@ def make_request( request. expected_result_code: See "VWS API Result Codes" on https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api. + content_type: The content type of the request. Returns: The response to the request made by `requests`. @@ -190,6 +193,7 @@ def make_request( server. """ response = _target_api_request( + content_type=content_type, server_access_key=self._server_access_key, server_secret_key=self._server_secret_key, method=method, @@ -316,6 +320,7 @@ def add_target( data=content, request_path="/targets", expected_result_code="TargetCreated", + content_type="application/json", ) return str(json.loads(s=response.text)["target_id"]) @@ -353,6 +358,7 @@ def get_target_record(self, target_id: str) -> TargetStatusAndRecord: data=b"", request_path=f"/targets/{target_id}", expected_result_code="Success", + content_type="application/json", ) result_data = json.loads(s=response.text) @@ -449,6 +455,7 @@ def list_targets(self) -> list[str]: data=b"", request_path="/targets", expected_result_code="Success", + content_type="application/json", ) return list(json.loads(s=response.text)["results"]) @@ -486,6 +493,7 @@ def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: data=b"", request_path=f"/summary/{target_id}", expected_result_code="Success", + content_type="application/json", ) result_data = dict(json.loads(s=response.text)) @@ -529,6 +537,7 @@ def get_database_summary_report(self) -> DatabaseSummaryReport: data=b"", request_path="/summary", expected_result_code="Success", + content_type="application/json", ) response_data = dict(json.loads(s=response.text)) @@ -579,6 +588,7 @@ def delete_target(self, target_id: str) -> None: data=b"", request_path=f"/targets/{target_id}", expected_result_code="Success", + content_type="application/json", ) def get_duplicate_targets(self, target_id: str) -> list[str]: @@ -616,6 +626,7 @@ def get_duplicate_targets(self, target_id: str) -> list[str]: data=b"", request_path=f"/duplicates/{target_id}", expected_result_code="Success", + content_type="application/json", ) return list(json.loads(s=response.text)["similar_targets"]) @@ -702,4 +713,5 @@ def update_target( data=content, request_path=f"/targets/{target_id}", expected_result_code="Success", + content_type="application/json", ) From 2cdfc2fefc456b747e94234a14b93c74cc589a45 Mon Sep 17 00:00:00 2001 From: adamtheturtle Date: Tue, 3 Sep 2024 15:06:22 +0000 Subject: [PATCH 0333/1003] Bump CHANGELOG --- CHANGELOG.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 82663c55a..00008ff61 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,9 @@ Changelog Next ---- +2024.09.03.1 +------------ + 2024.09.03 ------------ From f063db055e722616d30cbcfe43bb5ae434fa4783 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 4 Sep 2024 04:15:07 +0100 Subject: [PATCH 0334/1003] Move ``Response`` from ``vws.exceptions.response`` to ``vws.types``. --- CHANGELOG.rst | 3 +-- src/vws/exceptions/base_exceptions.py | 2 +- src/vws/exceptions/custom_exceptions.py | 2 +- src/vws/query.py | 2 +- src/vws/{exceptions/response.py => types.py} | 2 +- src/vws/vws.py | 3 +-- 6 files changed, 6 insertions(+), 8 deletions(-) rename src/vws/{exceptions/response.py => types.py} (85%) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 00008ff61..913584a1f 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,8 +4,7 @@ Changelog Next ---- -2024.09.03.1 ------------- +* Move ``Response`` from ``vws.exceptions.response`` to ``vws.types``. 2024.09.03 ------------ diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index 9dde05ee2..ad1116708 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -5,7 +5,7 @@ from beartype import beartype -from .response import Response +from vws.types import Response @beartype diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index d036d8750..cb237abd8 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -6,7 +6,7 @@ from beartype import beartype -from .response import Response +from vws.types import Response @beartype diff --git a/src/vws/query.py b/src/vws/query.py index fc42a3ff5..dfa0504f2 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -25,9 +25,9 @@ RequestEntityTooLargeError, ServerError, ) -from vws.exceptions.response import Response from vws.include_target_data import CloudRecoIncludeTargetData from vws.reports import QueryResult, TargetData +from vws.types import Response _ImageType = io.BytesIO | BinaryIO diff --git a/src/vws/exceptions/response.py b/src/vws/types.py similarity index 85% rename from src/vws/exceptions/response.py rename to src/vws/types.py index 0b3eced88..b3b941e24 100644 --- a/src/vws/exceptions/response.py +++ b/src/vws/types.py @@ -1,4 +1,4 @@ -"""Responses for exceptions.""" +"""Responses for requests to VWS and VWQ.""" from dataclasses import dataclass diff --git a/src/vws/vws.py b/src/vws/vws.py index 6f622773f..987d94fcc 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -46,8 +46,7 @@ TargetStatuses, TargetSummaryReport, ) - -from .exceptions.response import Response +from vws.types import Response _ImageType = io.BytesIO | BinaryIO From 4800e8c56bdfee5537b414f0d5b9312e8995b6ce Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 4 Sep 2024 04:16:45 +0100 Subject: [PATCH 0335/1003] Add `raw` to Response --- CHANGELOG.rst | 1 + docs/source/api-reference.rst | 4 ++++ docs/source/exceptions.rst | 7 ------- src/vws/query.py | 1 + src/vws/types.py | 1 + src/vws/vws.py | 1 + 6 files changed, 8 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 913584a1f..b30b9a4d0 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -5,6 +5,7 @@ Next ---- * Move ``Response`` from ``vws.exceptions.response`` to ``vws.types``. +* Add ``raw`` field to ``Response``. 2024.09.03 ------------ diff --git a/docs/source/api-reference.rst b/docs/source/api-reference.rst index 3ffbc13da..5b7027550 100644 --- a/docs/source/api-reference.rst +++ b/docs/source/api-reference.rst @@ -12,3 +12,7 @@ API Reference .. automodule:: vws.include_target_data :undoc-members: :members: + +.. automodule:: vws.types + :undoc-members: + :members: diff --git a/docs/source/exceptions.rst b/docs/source/exceptions.rst index f23ab02b8..f48730bfd 100644 --- a/docs/source/exceptions.rst +++ b/docs/source/exceptions.rst @@ -36,10 +36,3 @@ Custom exceptions :show-inheritance: :inherited-members: Exception :exclude-members: errno, filename, filename2, strerror - -Response --------- - -.. automodule:: vws.exceptions.response - :undoc-members: - :members: diff --git a/src/vws/query.py b/src/vws/query.py index dfa0504f2..17382d600 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -154,6 +154,7 @@ def query( status_code=requests_response.status_code, headers=dict(requests_response.headers), request_body=requests_response.request.body, + raw=requests_response.raw, ) if response.status_code == HTTPStatus.REQUEST_ENTITY_TOO_LARGE: diff --git a/src/vws/types.py b/src/vws/types.py index b3b941e24..3e5e49aaa 100644 --- a/src/vws/types.py +++ b/src/vws/types.py @@ -17,3 +17,4 @@ class Response: status_code: int headers: dict[str, str] request_body: bytes | str | None + raw: bytes diff --git a/src/vws/vws.py b/src/vws/vws.py index 987d94fcc..2acc2ca07 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -125,6 +125,7 @@ def _target_api_request( status_code=requests_response.status_code, headers=dict(requests_response.headers), request_body=requests_response.request.body, + raw=requests_response.raw, ) From ad7991d099064519a76e6f1b7b8a787ff2078602 Mon Sep 17 00:00:00 2001 From: adamtheturtle Date: Wed, 4 Sep 2024 03:29:24 +0000 Subject: [PATCH 0336/1003] Bump CHANGELOG --- CHANGELOG.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index b30b9a4d0..288081e00 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,9 @@ Changelog Next ---- +2024.09.04 +------------ + * Move ``Response`` from ``vws.exceptions.response`` to ``vws.types``. * Add ``raw`` field to ``Response``. From 878eff203e5beea150136e15e9c940dda1b1874b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 4 Sep 2024 05:18:42 +0100 Subject: [PATCH 0337/1003] Improve `raw` type --- src/vws/types.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/vws/types.py b/src/vws/types.py index 3e5e49aaa..711da851e 100644 --- a/src/vws/types.py +++ b/src/vws/types.py @@ -1,6 +1,7 @@ """Responses for requests to VWS and VWQ.""" from dataclasses import dataclass +from io import IOBase from beartype import beartype @@ -17,4 +18,4 @@ class Response: status_code: int headers: dict[str, str] request_body: bytes | str | None - raw: bytes + raw: IOBase From abbbb708b5a71f25ae8bb04fbc0e9db51bd759f3 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 4 Sep 2024 05:33:10 +0100 Subject: [PATCH 0338/1003] Save tell-position in Response --- src/vws/types.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/vws/types.py b/src/vws/types.py index 711da851e..e6f59145a 100644 --- a/src/vws/types.py +++ b/src/vws/types.py @@ -1,7 +1,6 @@ """Responses for requests to VWS and VWQ.""" from dataclasses import dataclass -from io import IOBase from beartype import beartype @@ -18,4 +17,4 @@ class Response: status_code: int headers: dict[str, str] request_body: bytes | str | None - raw: IOBase + tell_position: int From 943b215882fa0fff3e11da091dc449d7ca3d36ab Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 4 Sep 2024 05:34:18 +0100 Subject: [PATCH 0339/1003] Update Response callers --- src/vws/query.py | 2 +- src/vws/vws.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vws/query.py b/src/vws/query.py index 17382d600..2380ba962 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -154,7 +154,7 @@ def query( status_code=requests_response.status_code, headers=dict(requests_response.headers), request_body=requests_response.request.body, - raw=requests_response.raw, + tell_position=requests_response.raw.tell(), ) if response.status_code == HTTPStatus.REQUEST_ENTITY_TOO_LARGE: diff --git a/src/vws/vws.py b/src/vws/vws.py index 2acc2ca07..185af1178 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -125,7 +125,7 @@ def _target_api_request( status_code=requests_response.status_code, headers=dict(requests_response.headers), request_body=requests_response.request.body, - raw=requests_response.raw, + tell_position=requests_response.raw.tell(), ) From 43635b24f4ec169cf220e369d0dd8a4b40cc09a5 Mon Sep 17 00:00:00 2001 From: adamtheturtle Date: Wed, 4 Sep 2024 04:42:23 +0000 Subject: [PATCH 0340/1003] Bump CHANGELOG --- CHANGELOG.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 288081e00..2eb9d9a05 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,9 @@ Changelog Next ---- +2024.09.04.1 +------------ + 2024.09.04 ------------ From 10d94680e0999ede070b87d62644c280831ca025 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 4 Sep 2024 11:04:06 +0000 Subject: [PATCH 0341/1003] Bump pyright from 1.1.378 to 1.1.379 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.378 to 1.1.379. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.378...v1.1.379) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ebabd99e3..9d9b9118e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.7", "pyproject-fmt==2.2.1", - "pyright==1.1.378", + "pyright==1.1.379", "pyroma==4.2", "pytest==8.3.2", "pytest-cov==5.0.0", From d9e88a68be9393590e5738f8b2daf74ca6efeb05 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 5 Sep 2024 10:11:26 +0000 Subject: [PATCH 0342/1003] Bump types-requests from 2.32.0.20240712 to 2.32.0.20240905 Bumps [types-requests](https://github.com/python/typeshed) from 2.32.0.20240712 to 2.32.0.20240905. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9d9b9118e..19ea0d5c6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -64,7 +64,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2024.8.6", "sphinxcontrib-spelling==8", "sybil==6.1.1", - "types-requests==2.32.0.20240712", + "types-requests==2.32.0.20240905", "vulture==2.11", "vws-python-mock==2024.8.30", "vws-test-fixtures==2023.3.5", From 9444c4ad23be801d27f955d20ee8a1796da239dc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 6 Sep 2024 10:24:36 +0000 Subject: [PATCH 0343/1003] Bump ruff from 0.6.3 to 0.6.4 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.6.3 to 0.6.4. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.6.3...0.6.4) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 19ea0d5c6..29927ba42 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pytest==8.3.2", "pytest-cov==5.0.0", "pyyaml==6.0.2", - "ruff==0.6.3", + "ruff==0.6.4", "sphinx==8.0.2", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", From 72ba608650e49ed85852bc19808bcf5d19aafecf Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 6 Sep 2024 18:51:28 +0100 Subject: [PATCH 0344/1003] Show diff on ruff format errors --- .pre-commit-config.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 81166ec44..9a88cd81a 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -14,7 +14,7 @@ ci: - deptry - pylint - ruff-check - - ruff-format-check + - ruff-format-diff - ruff-check-fix - ruff-format-fix - doc8 @@ -108,9 +108,9 @@ repos: language: system types_or: [python] - - id: ruff-format-check - name: Ruff format check - entry: ruff format --check + - id: ruff-format-diff + name: Ruff format diff + entry: ruff format --diff language: system types_or: [python] From 834e96259fc5e992aca30289511c2f9dbe468b4d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 8 Sep 2024 02:00:03 +0100 Subject: [PATCH 0345/1003] Add shellcheck pre-commit hook --- .pre-commit-config.yaml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 9a88cd81a..21aefd9c6 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -44,6 +44,11 @@ repos: - id: file-contents-sorter files: spelling_private_dict\.txt$ - id: trailing-whitespace +- repo: https://github.com/shellcheck-py/shellcheck-py + rev: v0.10.0.1 + hooks: + - id: shellcheck + args: ["--shell", "bash"] - repo: local hooks: - id: actionlint From 9b8932963a59fa8b1a94d8ef872dddfcd2c3b36b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 9 Sep 2024 00:15:23 +0100 Subject: [PATCH 0346/1003] Fix the GitHub workflow badge to refer to the right branch --- README.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.rst b/README.rst index cb5f4b116..68af180c6 100644 --- a/README.rst +++ b/README.rst @@ -61,7 +61,7 @@ Full Documentation See the `full documentation `__. -.. |Build Status| image:: https://github.com/VWS-Python/vws-python/workflows/CI/badge.svg +.. |Build Status| image:: https://github.com/VWS-Python/vws-python/actions/workflows/ci.yml/badge.svg?branch=main :target: https://github.com/VWS-Python/vws-python/actions .. |codecov| image:: https://codecov.io/gh/VWS-Python/vws-python/branch/main/graph/badge.svg :target: https://codecov.io/gh/VWS-Python/vws-python From c5ad34df5781a29203a9af2c3a1901c335fbfc83 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 9 Sep 2024 00:34:08 +0100 Subject: [PATCH 0347/1003] Specify Python module use in pre-commit hooks --- .pre-commit-config.yaml | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 21aefd9c6..dcb18efd9 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -53,7 +53,7 @@ repos: hooks: - id: actionlint name: actionlint - entry: actionlint + entry: python -m actionlint language: system pass_filenames: false types_or: [yaml] @@ -61,7 +61,7 @@ repos: - id: mypy name: mypy stages: [push] - entry: mypy . + entry: python -m mypy . language: system types_or: [python, toml] pass_filenames: false @@ -69,90 +69,90 @@ repos: - id: check-manifest name: check-manifest stages: [push] - entry: check-manifest . + entry: python -m check-manifest . language: system pass_filenames: false - id: pyright name: pyright stages: [push] - entry: pyright . + entry: python -m pyright . language: system types_or: [python, toml] pass_filenames: false - id: vulture name: vulture - entry: vulture --min-confidence 100 --exclude .eggs + entry: python -m vulture --min-confidence 100 --exclude .eggs language: system types_or: [python] - id: pyroma name: pyroma - entry: pyroma --min 10 . + entry: python -m pyroma --min 10 . language: system pass_filenames: false types_or: [toml] - id: deptry name: deptry - entry: deptry src/ + entry: python -m deptry src/ language: system pass_filenames: false - id: pylint name: pylint - entry: pylint *.py src/ tests/ docs/ + entry: python -m pylint *.py src/ tests/ docs/ language: system stages: [manual] pass_filenames: false - id: ruff-check name: Ruff check - entry: ruff check + entry: python -m ruff check language: system types_or: [python] - id: ruff-format-diff name: Ruff format diff - entry: ruff format --diff + entry: python -m ruff format --diff language: system types_or: [python] - id: ruff-check-fix name: Ruff check fix - entry: ruff check --fix + entry: python -m ruff check --fix language: system types_or: [python] - id: ruff-format-fix name: Ruff format - entry: ruff format + entry: python -m ruff format language: system types_or: [python] - id: doc8 name: doc8 - entry: doc8 + entry: python -m doc8 language: system types_or: [rst] - id: interrogate name: interrogate - entry: interrogate + entry: python -m interrogate language: system types_or: [python] - id: pyproject-fmt-check name: pyproject-fmt check - entry: pyproject-fmt --check + entry: python -m pyproject-fmt --check language: system types_or: [toml] files: pyproject.toml - id: pyproject-fmt-fix name: pyproject-fmt - entry: pyproject-fmt + entry: python -m pyproject-fmt language: system types_or: [toml] files: pyproject.toml @@ -183,7 +183,7 @@ repos: - id: pyright-verifytypes name: pyright-verifytypes stages: [push] - entry: pyright --verifytypes vws + entry: python -m pyright --verifytypes vws language: system pass_filenames: false types_or: [python] From f480c467967a0135610e5a231795b2e1d1f4de7d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 9 Sep 2024 00:36:32 +0100 Subject: [PATCH 0348/1003] Specify Python module use in pre-commit hooks --- .pre-commit-config.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index dcb18efd9..eeddd9cfd 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -53,7 +53,7 @@ repos: hooks: - id: actionlint name: actionlint - entry: python -m actionlint + entry: actionlint language: system pass_filenames: false types_or: [yaml] @@ -145,14 +145,14 @@ repos: - id: pyproject-fmt-check name: pyproject-fmt check - entry: python -m pyproject-fmt --check + entry: pyproject-fmt --check language: system types_or: [toml] files: pyproject.toml - id: pyproject-fmt-fix name: pyproject-fmt - entry: python -m pyproject-fmt + entry: pyproject-fmt language: system types_or: [toml] files: pyproject.toml From dd4345095a1d4e3d1776cf8fffaeac7154da41fe Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 9 Sep 2024 00:40:23 +0100 Subject: [PATCH 0349/1003] Specify Python module use in pre-commit hooks --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index eeddd9cfd..55d22db37 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -69,7 +69,7 @@ repos: - id: check-manifest name: check-manifest stages: [push] - entry: python -m check-manifest . + entry: python -m check_manifest . language: system pass_filenames: false From 0afbed237dff456adc863bc36f63c922f66cc498 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 9 Sep 2024 10:26:39 +0000 Subject: [PATCH 0350/1003] Bump types-requests from 2.32.0.20240905 to 2.32.0.20240907 Bumps [types-requests](https://github.com/python/typeshed) from 2.32.0.20240905 to 2.32.0.20240907. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 29927ba42..3aa6e4fe1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -64,7 +64,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2024.8.6", "sphinxcontrib-spelling==8", "sybil==6.1.1", - "types-requests==2.32.0.20240905", + "types-requests==2.32.0.20240907", "vulture==2.11", "vws-python-mock==2024.8.30", "vws-test-fixtures==2023.3.5", From cd35906d0c3e89ee9e3bd568ebe1c983e5bf22c4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 9 Sep 2024 10:33:08 +0000 Subject: [PATCH 0351/1003] Bump pyproject-fmt from 2.2.1 to 2.2.3 Bumps [pyproject-fmt](https://github.com/tox-dev/pyproject-fmt) from 2.2.1 to 2.2.3. - [Release notes](https://github.com/tox-dev/pyproject-fmt/releases) - [Commits](https://github.com/tox-dev/pyproject-fmt/compare/2.2.1...2.2.3) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3aa6e4fe1..6b2a0861e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pyenchant==3.2.2", "pygments==2.18.0", "pylint==3.2.7", - "pyproject-fmt==2.2.1", + "pyproject-fmt==2.2.3", "pyright==1.1.379", "pyroma==4.2", "pytest==8.3.2", From be9353fdb07788d6785099875e8438b33228550a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 11 Sep 2024 02:42:45 +0100 Subject: [PATCH 0352/1003] Switch from code to code-block, for consistency --- README.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.rst b/README.rst index 68af180c6..336acd97e 100644 --- a/README.rst +++ b/README.rst @@ -9,7 +9,7 @@ Web Query API. Installation ------------ -.. code:: sh +.. code-block:: sh pip install vws-python From 293a15875c3778b6e9f63841e56c4047494e8c43 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 11 Sep 2024 10:37:03 +0100 Subject: [PATCH 0353/1003] Switch from code-block: sh to code-block: shell - get syntax highlighting --- README.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.rst b/README.rst index 336acd97e..0f54838e3 100644 --- a/README.rst +++ b/README.rst @@ -9,7 +9,7 @@ Web Query API. Installation ------------ -.. code-block:: sh +.. code-block:: shell pip install vws-python From 9f8791567e6b6fda2798cb81a775f5a446a53f8c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 11 Sep 2024 10:42:45 +0000 Subject: [PATCH 0354/1003] Bump pytest from 8.3.2 to 8.3.3 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.3.2 to 8.3.3. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.3.2...8.3.3) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6b2a0861e..e13748891 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pyproject-fmt==2.2.3", "pyright==1.1.379", "pyroma==4.2", - "pytest==8.3.2", + "pytest==8.3.3", "pytest-cov==5.0.0", "pyyaml==6.0.2", "ruff==0.6.4", From d563dec5f035b10450dd5af02b93aab10c71aa6f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 11 Sep 2024 10:51:22 +0000 Subject: [PATCH 0355/1003] Bump pyright from 1.1.379 to 1.1.380 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.379 to 1.1.380. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.379...v1.1.380) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e13748891..5a1d96913 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.7", "pyproject-fmt==2.2.3", - "pyright==1.1.379", + "pyright==1.1.380", "pyroma==4.2", "pytest==8.3.3", "pytest-cov==5.0.0", From 58b9d87dfc228b95280b02187f2847086fb50775 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 12 Sep 2024 10:28:36 +0000 Subject: [PATCH 0356/1003] Bump pre-commit-ci/lite-action from 1.0.2 to 1.0.3 Bumps [pre-commit-ci/lite-action](https://github.com/pre-commit-ci/lite-action) from 1.0.2 to 1.0.3. - [Release notes](https://github.com/pre-commit-ci/lite-action/releases) - [Commits](https://github.com/pre-commit-ci/lite-action/compare/v1.0.2...v1.0.3) --- updated-dependencies: - dependency-name: pre-commit-ci/lite-action dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ad86deb1b..6f424e7a3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -53,5 +53,5 @@ jobs: fail_ci_if_error: true token: ${{ secrets.CODECOV_TOKEN }} - - uses: pre-commit-ci/lite-action@v1.0.2 + - uses: pre-commit-ci/lite-action@v1.0.3 if: always() From 52d970969303fa83d29a8dfa8766942fb7068c3c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 12 Sep 2024 10:49:00 +0000 Subject: [PATCH 0357/1003] Bump sybil from 6.1.1 to 7.0.0 Bumps [sybil](https://github.com/simplistix/sybil) from 6.1.1 to 7.0.0. - [Changelog](https://github.com/simplistix/sybil/blob/master/CHANGELOG.rst) - [Commits](https://github.com/simplistix/sybil/compare/6.1.1...7.0.0) --- updated-dependencies: - dependency-name: sybil dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5a1d96913..0b6da1652 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -63,7 +63,7 @@ optional-dependencies.dev = [ "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", "sphinxcontrib-spelling==8", - "sybil==6.1.1", + "sybil==7.0.0", "types-requests==2.32.0.20240907", "vulture==2.11", "vws-python-mock==2024.8.30", From 1fcec8ca6fbe3b3f5d301773e6fd974f85840387 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 14 Sep 2024 09:07:10 +0100 Subject: [PATCH 0358/1003] Be careful when releasing to not accidentally commit to a file --- .github/workflows/release.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 237858d8b..64761eefa 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -59,6 +59,7 @@ jobs: id: commit with: commit_message: Bump CHANGELOG + file_pattern: CHANGELOG.rst - name: Bump version and push tag id: tag_version From b277d65abd5f3f2df85240e8f6ed1413f4308e0f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Sep 2024 10:03:34 +0100 Subject: [PATCH 0359/1003] Add docrun dependency --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index 0b6da1652..26c57fb17 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,6 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.49", "deptry==0.20.0", "doc8==1.1.2", + "doccmd==2024.9.14.5", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", From ab10547df4ee01e8d84f774009d418dcd00aa844 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Sep 2024 10:22:41 +0100 Subject: [PATCH 0360/1003] Add docrun pre-commit hooks --- .pre-commit-config.yaml | 51 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 55d22db37..f82140622 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -66,6 +66,13 @@ repos: types_or: [python, toml] pass_filenames: false + - id: mypy-docs + name: mypy-docs + stages: [push] + entry: doccmd --language=python --command="mypy" + language: system + types_or: [markdown, rst, python, toml] + - id: check-manifest name: check-manifest stages: [push] @@ -81,6 +88,13 @@ repos: types_or: [python, toml] pass_filenames: false + - id: pyright-docs + name: pyright-docs + stages: [push] + entry: doccmd --language=python --command="pyright" + language: system + types_or: [markdown, rst, python, toml] + - id: vulture name: vulture entry: python -m vulture --min-confidence 100 --exclude .eggs @@ -107,30 +121,61 @@ repos: stages: [manual] pass_filenames: false + - id: pylint-docs + name: pylint-docs + entry: doccmd --language=python --command="pylint" --lowercase-file-name + language: system + stages: [manual] + types_or: [markdown, rst, python, toml] + - id: ruff-check name: Ruff check entry: python -m ruff check language: system types_or: [python] + - id: ruff-check-docs + name: Ruff check docs + entry: doccmd --language=python --command="ruff check" + language: system + types_or: [markdown, rst] + - id: ruff-format-diff name: Ruff format diff entry: python -m ruff format --diff language: system types_or: [python] + - id: ruff-format-diff-docs + name: Ruff format diff docs + entry: doccmd --language=python --no-pad-file --command="ruff format --diff" + language: system + types_or: [markdown, rst] + - id: ruff-check-fix name: Ruff check fix entry: python -m ruff check --fix language: system types_or: [python] + - id: ruff-check-fix-docs + name: Ruff check fix docs + entry: doccmd --language=python --command="ruff check --fix" + language: system + types_or: [markdown, rst] + - id: ruff-format-fix name: Ruff format entry: python -m ruff format language: system types_or: [python] + - id: ruff-format-fix-docs + name: Ruff format docs + entry: doccmd --language=python --no-pad-file --command="ruff format" + language: system + types_or: [markdown, rst] + - id: doc8 name: doc8 entry: python -m doc8 @@ -143,6 +188,12 @@ repos: language: system types_or: [python] + - id: interrogate-docs + name: interrogate docs + entry: doccmd --language=python --command="interrogate" + language: system + types_or: [markdown, rst] + - id: pyproject-fmt-check name: pyproject-fmt check entry: pyproject-fmt --check From 1ed7e80562a03183dc9aad9d8c6a115486fe757e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Sep 2024 10:24:10 +0100 Subject: [PATCH 0361/1003] Ignore docs items in pre-commit config --- .pre-commit-config.yaml | 31 +++++++++++++++++++------------ 1 file changed, 19 insertions(+), 12 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index f82140622..9dbe7b746 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -6,25 +6,32 @@ ci: # We therefore cannot use those dependencies in pre-commit CI. skip: - actionlint - - mypy - check-manifest - - pyright - - vulture - - pyroma - deptry - - pylint - - ruff-check - - ruff-format-diff - - ruff-check-fix - - ruff-format-fix - doc8 + - docs - interrogate + - interrogate-docs + - linkcheck + - mypy + - mypy-docs + - pylint - pyproject-fmt-check - pyproject-fmt-fix - - linkcheck - - spelling - - docs + - pyright + - pyright-docs - pyright-verifytypes + - pyroma + - ruff-check + - ruff-check-docs + - ruff-check-fix + - ruff-check-fix-docs + - ruff-format-diff + - ruff-format-diff-docs + - ruff-format-fix + - ruff-format-fix-docs + - spelling + - vulture default_install_hook_types: [pre-commit, pre-push, commit-msg] repos: From 5113f9d641926c5a249bf2a8c0695e0476b71bad Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Sun, 15 Sep 2024 09:24:38 +0000 Subject: [PATCH 0362/1003] [pre-commit.ci lite] apply automatic fixes --- README.rst | 14 ++++++------ docs/source/index.rst | 53 ++++++++++++++++++++++--------------------- 2 files changed, 34 insertions(+), 33 deletions(-) diff --git a/README.rst b/README.rst index 0f54838e3..aca061a06 100644 --- a/README.rst +++ b/README.rst @@ -26,10 +26,10 @@ Getting Started from vws import VWS, CloudRecoService - server_access_key = '[server-access-key]' - server_secret_key = '[server-secret-key]' - client_access_key = '[client-access-key]' - client_secret_key = '[client-secret-key]' + server_access_key = "[server-access-key]" + server_secret_key = "[server-secret-key]" + client_access_key = "[client-access-key]" + client_secret_key = "[client-secret-key]" vws_client = VWS( server_access_key=server_access_key, @@ -39,10 +39,10 @@ Getting Started client_access_key=client_access_key, client_secret_key=client_secret_key, ) - name = 'my_image_name' + name = "my_image_name" - image = pathlib.Path('high_quality_image.jpg') - with image.open(mode='rb') as my_image_file: + image = pathlib.Path("high_quality_image.jpg") + with image.open(mode="rb") as my_image_file: target_id = vws_client.add_target( name=name, width=1, diff --git a/docs/source/index.rst b/docs/source/index.rst index 907096d1d..b81c4c9bb 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -22,10 +22,10 @@ See the :doc:`api-reference` for full usage details. from vws import VWS, CloudRecoService - server_access_key = '[server-access-key]' - server_secret_key = '[server-secret-key]' - client_access_key = '[client-access-key]' - client_secret_key = '[client-secret-key]' + server_access_key = "[server-access-key]" + server_secret_key = "[server-secret-key]" + client_access_key = "[client-access-key]" + client_secret_key = "[client-secret-key]" vws_client = VWS( server_access_key=server_access_key, @@ -36,19 +36,20 @@ See the :doc:`api-reference` for full usage details. client_secret_key=client_secret_key, ) import uuid - name = 'my_image_name' + uuid.uuid4().hex - - image = pathlib.Path('high_quality_image.jpg') - with image.open(mode='rb') as my_image_file: - target_id = vws_client.add_target( - name=name, - width=1, - image=my_image_file, - active_flag=True, - application_metadata=None, - ) - vws_client.wait_for_target_processed(target_id=target_id) - matching_targets = cloud_reco_client.query(image=my_image_file) + + name = "my_image_name" + uuid.uuid4().hex + + image = pathlib.Path("high_quality_image.jpg") + with image.open(mode="rb") as my_image_file: + target_id = vws_client.add_target( + name=name, + width=1, + image=my_image_file, + active_flag=True, + application_metadata=None, + ) + vws_client.wait_for_target_processed(target_id=target_id) + matching_targets = cloud_reco_client.query(image=my_image_file) assert matching_targets[0].target_id == target_id a = 1 @@ -84,15 +85,15 @@ To write unit tests for code which uses this library, without using your Vuforia client_secret_key=database.client_secret_key, ) - image = pathlib.Path('high_quality_image.jpg') - with image.open(mode='rb') as my_image_file: - target_id = vws_client.add_target( - name="example_image_name", - width=1, - image=my_image_file, - application_metadata=None, - active_flag=True, - ) + image = pathlib.Path("high_quality_image.jpg") + with image.open(mode="rb") as my_image_file: + target_id = vws_client.add_target( + name="example_image_name", + width=1, + image=my_image_file, + application_metadata=None, + active_flag=True, + ) There are some differences between the mock and the real Vuforia. See https://vws-python-mock.readthedocs.io/en/latest/differences-to-vws.html for details. From a97247ce488dad4376435cc421c375bb4a66bd4c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Sep 2024 10:37:44 +0100 Subject: [PATCH 0363/1003] Fix many lint issues --- .pre-commit-config.yaml | 2 ++ README.rst | 7 ++++++- docs/source/index.rst | 13 +++++++++---- pyproject.toml | 5 +++++ 4 files changed, 22 insertions(+), 5 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 9dbe7b746..77321e831 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,3 +1,5 @@ +fail_fast: true + # See https://pre-commit.com for more information # See https://pre-commit.com/hooks.html for more hooks diff --git a/README.rst b/README.rst index aca061a06..b82abf663 100644 --- a/README.rst +++ b/README.rst @@ -22,7 +22,10 @@ Getting Started .. code-block:: python + """Add a target to VWS and then query it.""" + import pathlib + import uuid from vws import VWS, CloudRecoService @@ -39,7 +42,8 @@ Getting Started client_access_key=client_access_key, client_secret_key=client_secret_key, ) - name = "my_image_name" + + name = "my_image_name_" + uuid.uuid4().hex image = pathlib.Path("high_quality_image.jpg") with image.open(mode="rb") as my_image_file: @@ -54,6 +58,7 @@ Getting Started matching_targets = cloud_reco_client.query(image=my_image_file) assert matching_targets[0].target_id == target_id + a = 1 Full Documentation ------------------ diff --git a/docs/source/index.rst b/docs/source/index.rst index b81c4c9bb..d085bcc84 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -18,7 +18,10 @@ See the :doc:`api-reference` for full usage details. .. code-block:: python + """Add a target to VWS and then query it.""" + import pathlib + import uuid from vws import VWS, CloudRecoService @@ -35,9 +38,8 @@ See the :doc:`api-reference` for full usage details. client_access_key=client_access_key, client_secret_key=client_secret_key, ) - import uuid - name = "my_image_name" + uuid.uuid4().hex + name = "my_image_name_" + uuid.uuid4().hex image = pathlib.Path("high_quality_image.jpg") with image.open(mode="rb") as my_image_file: @@ -67,11 +69,14 @@ To write unit tests for code which uses this library, without using your Vuforia .. code-block:: python + """Test adding a target to VWS.""" + import pathlib - from mock_vws.database import VuforiaDatabase from mock_vws import MockVWS - from vws import CloudRecoService, VWS + from mock_vws.database import VuforiaDatabase + + from vws import VWS, CloudRecoService with MockVWS() as mock: database = VuforiaDatabase() diff --git a/pyproject.toml b/pyproject.toml index 26c57fb17..4e152e40b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -123,6 +123,11 @@ lint.per-file-ignores."conftest.py" = [ "S106", ] +lint.per-file-ignores."doccmd_*.py" = [ + # Allow hardcoded secrets in documentation. + "S105", +] + lint.per-file-ignores."tests/*.py" = [ # Do not require tests to have a one-line summary. "D205", From 74c05e06da166cc3855956669f2e36af16f0b581 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Sep 2024 11:00:04 +0100 Subject: [PATCH 0364/1003] Progress towards passing lint --- README.rst | 70 +++++++++++++++---------- conftest.py | 33 +++++++++++- docs/source/index.rst | 115 +++++++++++++++++++++++++----------------- 3 files changed, 142 insertions(+), 76 deletions(-) diff --git a/README.rst b/README.rst index b82abf663..9e008dc33 100644 --- a/README.rst +++ b/README.rst @@ -28,37 +28,51 @@ Getting Started import uuid from vws import VWS, CloudRecoService + from vws.reports import QueryResult - server_access_key = "[server-access-key]" - server_secret_key = "[server-secret-key]" - client_access_key = "[client-access-key]" - client_secret_key = "[client-secret-key]" - - vws_client = VWS( - server_access_key=server_access_key, - server_secret_key=server_secret_key, - ) - cloud_reco_client = CloudRecoService( - client_access_key=client_access_key, - client_secret_key=client_secret_key, - ) - - name = "my_image_name_" + uuid.uuid4().hex - - image = pathlib.Path("high_quality_image.jpg") - with image.open(mode="rb") as my_image_file: - target_id = vws_client.add_target( - name=name, - width=1, - image=my_image_file, - active_flag=True, - application_metadata=None, + + def add_target() -> str: + """Add a target to VWS and return its ID.""" + server_access_key = "[server-access-key]" + server_secret_key = "[server-secret-key]" + vws_client = VWS( + server_access_key=server_access_key, + server_secret_key=server_secret_key, + ) + name = "my_image_name_" + uuid.uuid4().hex + + image = pathlib.Path("high_quality_image.jpg") + with image.open(mode="rb") as my_image_file: + target_id = vws_client.add_target( + name=name, + width=1, + image=my_image_file, + active_flag=True, + application_metadata=None, + ) + vws_client.wait_for_target_processed(target_id=target_id) + + return target_id + + + def get_matching_targets() -> list[QueryResult]: + """Query VWS for matching targets.""" + client_access_key = "[client-access-key]" + client_secret_key = "[client-secret-key]" + + cloud_reco_client = CloudRecoService( + client_access_key=client_access_key, + client_secret_key=client_secret_key, ) - vws_client.wait_for_target_processed(target_id=target_id) - matching_targets = cloud_reco_client.query(image=my_image_file) - assert matching_targets[0].target_id == target_id - a = 1 + image = pathlib.Path("high_quality_image.jpg") + with image.open(mode="rb") as my_image_file: + return cloud_reco_client.query(image=my_image_file) + + + TARGET_ID = add_target() + MATCHING_TARGETS = get_matching_targets() + assert MATCHING_TARGETS[0].target_id == TARGET_ID Full Documentation ------------------ diff --git a/conftest.py b/conftest.py index 059fd0968..8b12e9d09 100644 --- a/conftest.py +++ b/conftest.py @@ -1,6 +1,7 @@ """Setup for Sybil.""" import io +import sys from collections.abc import Generator from doctest import ELLIPSIS from pathlib import Path @@ -12,9 +13,11 @@ from sybil import Sybil from sybil.parsers.rest import ( ClearNamespaceParser, + CodeBlockParser, DocTestParser, PythonCodeBlockParser, ) +from sybil_extras.evaluators.shell_evaluator import ShellCommandEvaluator def pytest_collection_modifyitems(items: list[pytest.Item]) -> None: @@ -67,5 +70,33 @@ def mock_vws() -> Generator[None, None, None]: PythonCodeBlockParser(), ], patterns=["*.rst", "*.py"], - fixtures=["make_image_file", "mock_vws"], ).pytest() + +run_code_sybil = Sybil( + parsers=[ + DocTestParser(optionflags=ELLIPSIS), + PythonCodeBlockParser(), + ], + patterns=["*.rst", "*.py"], + fixtures=["make_image_file", "mock_vws"], +) + +pytest_sybil = Sybil( + parsers=[ + CodeBlockParser( + language="python", + evaluator=ShellCommandEvaluator( + args=[sys.executable, "-m", "pytest"], + tempfile_suffixes=[".py"], + pad_file=True, + write_to_file=False, + ), + ), + ], + patterns=["*.rst"], + fixtures=["make_image_file"], +) + +sybils = run_code_sybil + pytest_sybil + +pytest_collect_file = sybils.pytest() diff --git a/docs/source/index.rst b/docs/source/index.rst index d085bcc84..1861a3de0 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -24,37 +24,51 @@ See the :doc:`api-reference` for full usage details. import uuid from vws import VWS, CloudRecoService + from vws.reports import QueryResult - server_access_key = "[server-access-key]" - server_secret_key = "[server-secret-key]" - client_access_key = "[client-access-key]" - client_secret_key = "[client-secret-key]" - - vws_client = VWS( - server_access_key=server_access_key, - server_secret_key=server_secret_key, - ) - cloud_reco_client = CloudRecoService( - client_access_key=client_access_key, - client_secret_key=client_secret_key, - ) - - name = "my_image_name_" + uuid.uuid4().hex - - image = pathlib.Path("high_quality_image.jpg") - with image.open(mode="rb") as my_image_file: - target_id = vws_client.add_target( - name=name, - width=1, - image=my_image_file, - active_flag=True, - application_metadata=None, + + def add_target() -> str: + """Add a target to VWS and return its ID.""" + server_access_key = "[server-access-key]" + server_secret_key = "[server-secret-key]" + vws_client = VWS( + server_access_key=server_access_key, + server_secret_key=server_secret_key, + ) + name = "my_image_name_" + uuid.uuid4().hex + + image = pathlib.Path("high_quality_image.jpg") + with image.open(mode="rb") as my_image_file: + target_id = vws_client.add_target( + name=name, + width=1, + image=my_image_file, + active_flag=True, + application_metadata=None, + ) + vws_client.wait_for_target_processed(target_id=target_id) + + return target_id + + + def get_matching_targets() -> list[QueryResult]: + """Query VWS for matching targets.""" + client_access_key = "[client-access-key]" + client_secret_key = "[client-secret-key]" + + cloud_reco_client = CloudRecoService( + client_access_key=client_access_key, + client_secret_key=client_secret_key, ) - vws_client.wait_for_target_processed(target_id=target_id) - matching_targets = cloud_reco_client.query(image=my_image_file) - assert matching_targets[0].target_id == target_id - a = 1 + image = pathlib.Path("high_quality_image.jpg") + with image.open(mode="rb") as my_image_file: + return cloud_reco_client.query(image=my_image_file) + + + TARGET_ID = add_target() + MATCHING_TARGETS = get_matching_targets() + assert MATCHING_TARGETS[0].target_id == TARGET_ID Testing ------- @@ -78,27 +92,34 @@ To write unit tests for code which uses this library, without using your Vuforia from vws import VWS, CloudRecoService - with MockVWS() as mock: - database = VuforiaDatabase() - mock.add_database(database=database) - vws_client = VWS( - server_access_key=database.server_access_key, - server_secret_key=database.server_secret_key, - ) - cloud_reco_client = CloudRecoService( - client_access_key=database.client_access_key, - client_secret_key=database.client_secret_key, - ) - image = pathlib.Path("high_quality_image.jpg") - with image.open(mode="rb") as my_image_file: - target_id = vws_client.add_target( - name="example_image_name", - width=1, - image=my_image_file, - application_metadata=None, - active_flag=True, + def test_add_target() -> None: + """Test adding a target to VWS.""" + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, ) + cloud_reco_client = CloudRecoService( + client_access_key=database.client_access_key, + client_secret_key=database.client_secret_key, + ) + + image = pathlib.Path("high_quality_image.jpg") + with image.open(mode="rb") as my_image_file: + target_id = vws_client.add_target( + name="example_image_name", + width=1, + image=my_image_file, + application_metadata=None, + active_flag=True, + ) + + vws_client.wait_for_target_processed(target_id=target_id) + matching_targets = cloud_reco_client.query(image=my_image_file) + assert matching_targets[0].target_id == target_id There are some differences between the mock and the real Vuforia. See https://vws-python-mock.readthedocs.io/en/latest/differences-to-vws.html for details. From 0f41e176a32450fabd4e73ce1fa98b677e9be4e5 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Sep 2024 11:38:01 +0100 Subject: [PATCH 0365/1003] Progress towards passing lint --- conftest.py | 33 +--------------------- docs/source/index.rst | 66 +++++++++++++++++++++++-------------------- 2 files changed, 36 insertions(+), 63 deletions(-) diff --git a/conftest.py b/conftest.py index 8b12e9d09..059fd0968 100644 --- a/conftest.py +++ b/conftest.py @@ -1,7 +1,6 @@ """Setup for Sybil.""" import io -import sys from collections.abc import Generator from doctest import ELLIPSIS from pathlib import Path @@ -13,11 +12,9 @@ from sybil import Sybil from sybil.parsers.rest import ( ClearNamespaceParser, - CodeBlockParser, DocTestParser, PythonCodeBlockParser, ) -from sybil_extras.evaluators.shell_evaluator import ShellCommandEvaluator def pytest_collection_modifyitems(items: list[pytest.Item]) -> None: @@ -70,33 +67,5 @@ def mock_vws() -> Generator[None, None, None]: PythonCodeBlockParser(), ], patterns=["*.rst", "*.py"], -).pytest() - -run_code_sybil = Sybil( - parsers=[ - DocTestParser(optionflags=ELLIPSIS), - PythonCodeBlockParser(), - ], - patterns=["*.rst", "*.py"], fixtures=["make_image_file", "mock_vws"], -) - -pytest_sybil = Sybil( - parsers=[ - CodeBlockParser( - language="python", - evaluator=ShellCommandEvaluator( - args=[sys.executable, "-m", "pytest"], - tempfile_suffixes=[".py"], - pad_file=True, - write_to_file=False, - ), - ), - ], - patterns=["*.rst"], - fixtures=["make_image_file"], -) - -sybils = run_code_sybil + pytest_sybil - -pytest_collect_file = sybils.pytest() +).pytest() diff --git a/docs/source/index.rst b/docs/source/index.rst index 1861a3de0..912cddc14 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -83,43 +83,47 @@ To write unit tests for code which uses this library, without using your Vuforia .. code-block:: python - """Test adding a target to VWS.""" + """Add a target to VWS and then query it.""" - import pathlib + import pathlib - from mock_vws import MockVWS - from mock_vws.database import VuforiaDatabase + from mock_vws import MockVWS + from mock_vws.database import VuforiaDatabase - from vws import VWS, CloudRecoService + from vws import VWS, CloudRecoService - def test_add_target() -> None: - """Test adding a target to VWS.""" - with MockVWS() as mock: - database = VuforiaDatabase() - mock.add_database(database=database) - vws_client = VWS( - server_access_key=database.server_access_key, - server_secret_key=database.server_secret_key, - ) - cloud_reco_client = CloudRecoService( - client_access_key=database.client_access_key, - client_secret_key=database.client_secret_key, - ) + def test_add_target() -> None: + """Test adding a target to VWS.""" + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + ) + cloud_reco_client = CloudRecoService( + client_access_key=database.client_access_key, + client_secret_key=database.client_secret_key, + ) + + image = pathlib.Path("high_quality_image.jpg") + with image.open(mode="rb") as my_image_file: + target_id = vws_client.add_target( + name="example_image_name", + width=1, + image=my_image_file, + application_metadata=None, + active_flag=True, + ) + + vws_client.wait_for_target_processed(target_id=target_id) + matching_targets = cloud_reco_client.query(image=my_image_file) + + assert matching_targets[0].target_id == target_id + - image = pathlib.Path("high_quality_image.jpg") - with image.open(mode="rb") as my_image_file: - target_id = vws_client.add_target( - name="example_image_name", - width=1, - image=my_image_file, - application_metadata=None, - active_flag=True, - ) - - vws_client.wait_for_target_processed(target_id=target_id) - matching_targets = cloud_reco_client.query(image=my_image_file) - assert matching_targets[0].target_id == target_id + test_add_target() There are some differences between the mock and the real Vuforia. See https://vws-python-mock.readthedocs.io/en/latest/differences-to-vws.html for details. From 3cc9ddbfebca03e3f4fa5fab2183e2968bc9a27f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Sep 2024 16:04:36 +0100 Subject: [PATCH 0366/1003] Get pylint passing --- README.rst | 69 ++++++++++-------------- docs/source/index.rst | 121 ++++++++++++++++++------------------------ pyproject.toml | 6 +++ 3 files changed, 87 insertions(+), 109 deletions(-) diff --git a/README.rst b/README.rst index 9e008dc33..ffccbc916 100644 --- a/README.rst +++ b/README.rst @@ -28,51 +28,40 @@ Getting Started import uuid from vws import VWS, CloudRecoService - from vws.reports import QueryResult - - def add_target() -> str: - """Add a target to VWS and return its ID.""" - server_access_key = "[server-access-key]" - server_secret_key = "[server-secret-key]" - vws_client = VWS( - server_access_key=server_access_key, - server_secret_key=server_secret_key, - ) - name = "my_image_name_" + uuid.uuid4().hex - - image = pathlib.Path("high_quality_image.jpg") - with image.open(mode="rb") as my_image_file: - target_id = vws_client.add_target( - name=name, - width=1, - image=my_image_file, - active_flag=True, - application_metadata=None, - ) - vws_client.wait_for_target_processed(target_id=target_id) - - return target_id - - - def get_matching_targets() -> list[QueryResult]: - """Query VWS for matching targets.""" - client_access_key = "[client-access-key]" - client_secret_key = "[client-secret-key]" - - cloud_reco_client = CloudRecoService( - client_access_key=client_access_key, - client_secret_key=client_secret_key, + server_access_key = "[server-access-key]" + server_secret_key = "[server-secret-key]" + client_access_key = "[client-access-key]" + client_secret_key = "[client-secret-key]" + + vws_client = VWS( + server_access_key=server_access_key, + server_secret_key=server_secret_key, + ) + + cloud_reco_client = CloudRecoService( + client_access_key=client_access_key, + client_secret_key=client_secret_key, + ) + + name = "my_image_name_" + uuid.uuid4().hex + + image = pathlib.Path("high_quality_image.jpg") + with image.open(mode="rb") as my_image_file: + target_id = vws_client.add_target( + name=name, + width=1, + image=my_image_file, + active_flag=True, + application_metadata=None, ) - image = pathlib.Path("high_quality_image.jpg") - with image.open(mode="rb") as my_image_file: - return cloud_reco_client.query(image=my_image_file) + vws_client.wait_for_target_processed(target_id=target_id) + with image.open(mode="rb") as my_image_file: + matching_targets = cloud_reco_client.query(image=my_image_file) - TARGET_ID = add_target() - MATCHING_TARGETS = get_matching_targets() - assert MATCHING_TARGETS[0].target_id == TARGET_ID + assert matching_targets[0].target_id == target_id Full Documentation ------------------ diff --git a/docs/source/index.rst b/docs/source/index.rst index 912cddc14..fe1ee9a9e 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -24,51 +24,40 @@ See the :doc:`api-reference` for full usage details. import uuid from vws import VWS, CloudRecoService - from vws.reports import QueryResult - - def add_target() -> str: - """Add a target to VWS and return its ID.""" - server_access_key = "[server-access-key]" - server_secret_key = "[server-secret-key]" - vws_client = VWS( - server_access_key=server_access_key, - server_secret_key=server_secret_key, - ) - name = "my_image_name_" + uuid.uuid4().hex - - image = pathlib.Path("high_quality_image.jpg") - with image.open(mode="rb") as my_image_file: - target_id = vws_client.add_target( - name=name, - width=1, - image=my_image_file, - active_flag=True, - application_metadata=None, - ) - vws_client.wait_for_target_processed(target_id=target_id) - - return target_id - - - def get_matching_targets() -> list[QueryResult]: - """Query VWS for matching targets.""" - client_access_key = "[client-access-key]" - client_secret_key = "[client-secret-key]" - - cloud_reco_client = CloudRecoService( - client_access_key=client_access_key, - client_secret_key=client_secret_key, + server_access_key = "[server-access-key]" + server_secret_key = "[server-secret-key]" + client_access_key = "[client-access-key]" + client_secret_key = "[client-secret-key]" + + vws_client = VWS( + server_access_key=server_access_key, + server_secret_key=server_secret_key, + ) + + cloud_reco_client = CloudRecoService( + client_access_key=client_access_key, + client_secret_key=client_secret_key, + ) + + name = "my_image_name_" + uuid.uuid4().hex + + image = pathlib.Path("high_quality_image.jpg") + with image.open(mode="rb") as my_image_file: + target_id = vws_client.add_target( + name=name, + width=1, + image=my_image_file, + active_flag=True, + application_metadata=None, ) - image = pathlib.Path("high_quality_image.jpg") - with image.open(mode="rb") as my_image_file: - return cloud_reco_client.query(image=my_image_file) + vws_client.wait_for_target_processed(target_id=target_id) + with image.open(mode="rb") as my_image_file: + matching_targets = cloud_reco_client.query(image=my_image_file) - TARGET_ID = add_target() - MATCHING_TARGETS = get_matching_targets() - assert MATCHING_TARGETS[0].target_id == TARGET_ID + assert matching_targets[0].target_id == target_id Testing ------- @@ -92,38 +81,32 @@ To write unit tests for code which uses this library, without using your Vuforia from vws import VWS, CloudRecoService - - def test_add_target() -> None: - """Test adding a target to VWS.""" - with MockVWS() as mock: - database = VuforiaDatabase() - mock.add_database(database=database) - vws_client = VWS( - server_access_key=database.server_access_key, - server_secret_key=database.server_secret_key, - ) - cloud_reco_client = CloudRecoService( - client_access_key=database.client_access_key, - client_secret_key=database.client_secret_key, + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + ) + cloud_reco_client = CloudRecoService( + client_access_key=database.client_access_key, + client_secret_key=database.client_secret_key, + ) + + image = pathlib.Path("high_quality_image.jpg") + with image.open(mode="rb") as my_image_file: + target_id = vws_client.add_target( + name="example_image_name", + width=1, + image=my_image_file, + application_metadata=None, + active_flag=True, ) - image = pathlib.Path("high_quality_image.jpg") - with image.open(mode="rb") as my_image_file: - target_id = vws_client.add_target( - name="example_image_name", - width=1, - image=my_image_file, - application_metadata=None, - active_flag=True, - ) - - vws_client.wait_for_target_processed(target_id=target_id) - matching_targets = cloud_reco_client.query(image=my_image_file) - - assert matching_targets[0].target_id == target_id - + vws_client.wait_for_target_processed(target_id=target_id) + matching_targets = cloud_reco_client.query(image=my_image_file) - test_add_target() + assert matching_targets[0].target_id == target_id There are some differences between the mock and the real Vuforia. See https://vws-python-mock.readthedocs.io/en/latest/differences-to-vws.html for details. diff --git a/pyproject.toml b/pyproject.toml index 4e152e40b..1251725a1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,6 +53,7 @@ optional-dependencies.dev = [ "pyenchant==3.2.2", "pygments==2.18.0", "pylint==3.2.7", + "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.2.3", "pyright==1.1.380", "pyroma==4.2", @@ -154,12 +155,14 @@ jobs = 0 # List of plugins (as comma separated values of python modules names) to load, # usually to register additional checkers. # See https://chezsoi.org/lucas/blog/pylint-strict-base-configuration.html. +# and we also add `pylint_per_file_ignores` to allow per-file ignores. # We do not use the plugins: # - pylint.extensions.code_style # - pylint.extensions.magic_value # - pylint.extensions.while_used # as they seemed to get in the way. load-plugins = [ + "pylint_per_file_ignores", 'pylint.extensions.bad_builtin', 'pylint.extensions.comparison_placement', 'pylint.extensions.consider_refactoring_into_while_condition', @@ -231,6 +234,9 @@ disable = [ 'useless-type-doc', ] +# per-file-ignores = "docs/source/doccmd*.py:invalid-name, \ndoccmd_README:invalid-name" +per-file-ignores = "docs/:invalid-name,\ndoccmd_README_rst.*.py:invalid-name" + [tool.pylint.'FORMAT'] # Allow the body of an if to be on the same line as the test if there is no From 91719e3658fc7955145234e81cd5eac1151d6b85 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Sep 2024 16:19:07 +0100 Subject: [PATCH 0367/1003] Neater per-file-ignores --- pyproject.toml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 1251725a1..da36341d3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -234,8 +234,12 @@ disable = [ 'useless-type-doc', ] -# per-file-ignores = "docs/source/doccmd*.py:invalid-name, \ndoccmd_README:invalid-name" -per-file-ignores = "docs/:invalid-name,\ndoccmd_README_rst.*.py:invalid-name" +# This format is described in the following issue: +# https://github.com/christopherpickering/pylint-per-file-ignores/issues/160 +per-file-ignores = """ +docs/:invalid-name +doccmd_README_rst.*.py:invalid-name +""" [tool.pylint.'FORMAT'] From fd3d1ad49bf5aaa0085f5055b19fd21c2224755e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Sep 2024 16:25:16 +0100 Subject: [PATCH 0368/1003] Explain ignores --- pyproject.toml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index da36341d3..e15800730 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -236,6 +236,10 @@ disable = [ # This format is described in the following issue: # https://github.com/christopherpickering/pylint-per-file-ignores/issues/160 +# +# We ignore invalid names because: +# - We want to use generated module names, which may not be valid, but are never seen. +# - We want to use global variables in documentation, which may not be uppercase per-file-ignores = """ docs/:invalid-name doccmd_README_rst.*.py:invalid-name From fdcd4730ec7285f36736c701069312c38da5f281 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Sep 2024 16:32:49 +0100 Subject: [PATCH 0369/1003] Remove lowercase option --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 77321e831..a7bfd2ff4 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -132,7 +132,7 @@ repos: - id: pylint-docs name: pylint-docs - entry: doccmd --language=python --command="pylint" --lowercase-file-name + entry: doccmd --language=python --command="pylint" language: system stages: [manual] types_or: [markdown, rst, python, toml] From 236a276b22ccc4c86b26648b5c61a25f72e765cb Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Sep 2024 17:41:45 +0100 Subject: [PATCH 0370/1003] Reformat some of pre-commit config to be more like others --- .pre-commit-config.yaml | 420 ++++++++++++++++++++-------------------- 1 file changed, 210 insertions(+), 210 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index a7bfd2ff4..36a8ffb12 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,213 +37,213 @@ ci: default_install_hook_types: [pre-commit, pre-push, commit-msg] repos: -- repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.6.0 - hooks: - - id: check-added-large-files - - id: check-case-conflict - - id: check-executables-have-shebangs - - id: check-merge-conflict - - id: check-shebang-scripts-are-executable - - id: check-symlinks - - id: check-toml - - id: check-vcs-permalinks - - id: check-yaml - - id: end-of-file-fixer - - id: file-contents-sorter - files: spelling_private_dict\.txt$ - - id: trailing-whitespace -- repo: https://github.com/shellcheck-py/shellcheck-py - rev: v0.10.0.1 - hooks: - - id: shellcheck - args: ["--shell", "bash"] -- repo: local - hooks: - - id: actionlint - name: actionlint - entry: actionlint - language: system - pass_filenames: false - types_or: [yaml] - - - id: mypy - name: mypy - stages: [push] - entry: python -m mypy . - language: system - types_or: [python, toml] - pass_filenames: false - - - id: mypy-docs - name: mypy-docs - stages: [push] - entry: doccmd --language=python --command="mypy" - language: system - types_or: [markdown, rst, python, toml] - - - id: check-manifest - name: check-manifest - stages: [push] - entry: python -m check_manifest . - language: system - pass_filenames: false - - - id: pyright - name: pyright - stages: [push] - entry: python -m pyright . - language: system - types_or: [python, toml] - pass_filenames: false - - - id: pyright-docs - name: pyright-docs - stages: [push] - entry: doccmd --language=python --command="pyright" - language: system - types_or: [markdown, rst, python, toml] - - - id: vulture - name: vulture - entry: python -m vulture --min-confidence 100 --exclude .eggs - language: system - types_or: [python] - - - id: pyroma - name: pyroma - entry: python -m pyroma --min 10 . - language: system - pass_filenames: false - types_or: [toml] - - - id: deptry - name: deptry - entry: python -m deptry src/ - language: system - pass_filenames: false - - - id: pylint - name: pylint - entry: python -m pylint *.py src/ tests/ docs/ - language: system - stages: [manual] - pass_filenames: false - - - id: pylint-docs - name: pylint-docs - entry: doccmd --language=python --command="pylint" - language: system - stages: [manual] - types_or: [markdown, rst, python, toml] - - - id: ruff-check - name: Ruff check - entry: python -m ruff check - language: system - types_or: [python] - - - id: ruff-check-docs - name: Ruff check docs - entry: doccmd --language=python --command="ruff check" - language: system - types_or: [markdown, rst] - - - id: ruff-format-diff - name: Ruff format diff - entry: python -m ruff format --diff - language: system - types_or: [python] - - - id: ruff-format-diff-docs - name: Ruff format diff docs - entry: doccmd --language=python --no-pad-file --command="ruff format --diff" - language: system - types_or: [markdown, rst] - - - id: ruff-check-fix - name: Ruff check fix - entry: python -m ruff check --fix - language: system - types_or: [python] - - - id: ruff-check-fix-docs - name: Ruff check fix docs - entry: doccmd --language=python --command="ruff check --fix" - language: system - types_or: [markdown, rst] - - - id: ruff-format-fix - name: Ruff format - entry: python -m ruff format - language: system - types_or: [python] - - - id: ruff-format-fix-docs - name: Ruff format docs - entry: doccmd --language=python --no-pad-file --command="ruff format" - language: system - types_or: [markdown, rst] - - - id: doc8 - name: doc8 - entry: python -m doc8 - language: system - types_or: [rst] - - - id: interrogate - name: interrogate - entry: python -m interrogate - language: system - types_or: [python] - - - id: interrogate-docs - name: interrogate docs - entry: doccmd --language=python --command="interrogate" - language: system - types_or: [markdown, rst] - - - id: pyproject-fmt-check - name: pyproject-fmt check - entry: pyproject-fmt --check - language: system - types_or: [toml] - files: pyproject.toml - - - id: pyproject-fmt-fix - name: pyproject-fmt - entry: pyproject-fmt - language: system - types_or: [toml] - files: pyproject.toml - - - id: linkcheck - name: linkcheck - entry: make -C docs/ linkcheck SPHINXOPTS=-W - language: system - types_or: [rst] - stages: [manual] - pass_filenames: false - - - id: spelling - name: spelling - entry: make -C docs/ spelling SPHINXOPTS=-W - language: system - types_or: [rst] - stages: [manual] - pass_filenames: false - - - id: docs - name: Build Documentation - entry: make docs - language: system - stages: [manual] - pass_filenames: false - - - id: pyright-verifytypes - name: pyright-verifytypes - stages: [push] - entry: python -m pyright --verifytypes vws - language: system - pass_filenames: false - types_or: [python] +- repo: https://github.com/pre-commit/pre-commit-hooks + rev: v4.6.0 + hooks: + - id: check-added-large-files + - id: check-case-conflict + - id: check-executables-have-shebangs + - id: check-merge-conflict + - id: check-shebang-scripts-are-executable + - id: check-symlinks + - id: check-toml + - id: check-vcs-permalinks + - id: check-yaml + - id: end-of-file-fixer + - id: file-contents-sorter + files: spelling_private_dict\.txt$ + - id: trailing-whitespace +- repo: https://github.com/shellcheck-py/shellcheck-py + rev: v0.10.0.1 + hooks: + - id: shellcheck + args: ["--shell", "bash"] +- repo: local + hooks: + - id: actionlint + name: actionlint + entry: actionlint + language: system + pass_filenames: false + types_or: [yaml] + + - id: mypy + name: mypy + stages: [push] + entry: python -m mypy . + language: system + types_or: [python, toml] + pass_filenames: false + + - id: mypy-docs + name: mypy-docs + stages: [push] + entry: doccmd --language=python --command="mypy" + language: system + types_or: [markdown, rst, python, toml] + + - id: check-manifest + name: check-manifest + stages: [push] + entry: python -m check_manifest . + language: system + pass_filenames: false + + - id: pyright + name: pyright + stages: [push] + entry: python -m pyright . + language: system + types_or: [python, toml] + pass_filenames: false + + - id: pyright-docs + name: pyright-docs + stages: [push] + entry: doccmd --language=python --command="pyright" + language: system + types_or: [markdown, rst, python, toml] + + - id: vulture + name: vulture + entry: python -m vulture --min-confidence 100 --exclude .eggs + language: system + types_or: [python] + + - id: pyroma + name: pyroma + entry: python -m pyroma --min 10 . + language: system + pass_filenames: false + types_or: [toml] + + - id: deptry + name: deptry + entry: python -m deptry src/ + language: system + pass_filenames: false + + - id: pylint + name: pylint + entry: python -m pylint *.py src/ tests/ docs/ + language: system + stages: [manual] + pass_filenames: false + + - id: pylint-docs + name: pylint-docs + entry: doccmd --language=python --command="pylint" + language: system + stages: [manual] + types_or: [markdown, rst, python, toml] + + - id: ruff-check + name: Ruff check + entry: python -m ruff check + language: system + types_or: [python] + + - id: ruff-check-docs + name: Ruff check docs + entry: doccmd --language=python --command="ruff check" + language: system + types_or: [markdown, rst] + + - id: ruff-format-diff + name: Ruff format diff + entry: python -m ruff format --diff + language: system + types_or: [python] + + - id: ruff-format-diff-docs + name: Ruff format diff docs + entry: doccmd --language=python --no-pad-file --command="ruff format --diff" + language: system + types_or: [markdown, rst] + + - id: ruff-check-fix + name: Ruff check fix + entry: python -m ruff check --fix + language: system + types_or: [python] + + - id: ruff-check-fix-docs + name: Ruff check fix docs + entry: doccmd --language=python --command="ruff check --fix" + language: system + types_or: [markdown, rst] + + - id: ruff-format-fix + name: Ruff format + entry: python -m ruff format + language: system + types_or: [python] + + - id: ruff-format-fix-docs + name: Ruff format docs + entry: doccmd --language=python --no-pad-file --command="ruff format" + language: system + types_or: [markdown, rst] + + - id: doc8 + name: doc8 + entry: python -m doc8 + language: system + types_or: [rst] + + - id: interrogate + name: interrogate + entry: python -m interrogate + language: system + types_or: [python] + + - id: interrogate-docs + name: interrogate docs + entry: doccmd --language=python --command="interrogate" + language: system + types_or: [markdown, rst] + + - id: pyproject-fmt-check + name: pyproject-fmt check + entry: pyproject-fmt --check + language: system + types_or: [toml] + files: pyproject.toml + + - id: pyproject-fmt-fix + name: pyproject-fmt + entry: pyproject-fmt + language: system + types_or: [toml] + files: pyproject.toml + + - id: linkcheck + name: linkcheck + entry: make -C docs/ linkcheck SPHINXOPTS=-W + language: system + types_or: [rst] + stages: [manual] + pass_filenames: false + + - id: spelling + name: spelling + entry: make -C docs/ spelling SPHINXOPTS=-W + language: system + types_or: [rst] + stages: [manual] + pass_filenames: false + + - id: docs + name: Build Documentation + entry: make docs + language: system + stages: [manual] + pass_filenames: false + + - id: pyright-verifytypes + name: pyright-verifytypes + stages: [push] + entry: python -m pyright --verifytypes vws + language: system + pass_filenames: false + types_or: [python] From 0160f2952192d3cc6fd9d9080fc3d0b482c66b46 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Sep 2024 10:20:04 +0000 Subject: [PATCH 0371/1003] Bump sybil from 7.0.0 to 7.1.0 Bumps [sybil](https://github.com/simplistix/sybil) from 7.0.0 to 7.1.0. - [Changelog](https://github.com/simplistix/sybil/blob/master/CHANGELOG.rst) - [Commits](https://github.com/simplistix/sybil/compare/7.0.0...7.1.0) --- updated-dependencies: - dependency-name: sybil dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e15800730..5a967212c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -65,7 +65,7 @@ optional-dependencies.dev = [ "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", "sphinxcontrib-spelling==8", - "sybil==7.0.0", + "sybil==7.1.0", "types-requests==2.32.0.20240907", "vulture==2.11", "vws-python-mock==2024.8.30", From b4203687eb9b50f014f1594863a66bef3a5b3796 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Sep 2024 10:24:58 +0000 Subject: [PATCH 0372/1003] Bump types-requests from 2.32.0.20240907 to 2.32.0.20240914 Bumps [types-requests](https://github.com/python/typeshed) from 2.32.0.20240907 to 2.32.0.20240914. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5a967212c..e2c71fd57 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -66,7 +66,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2024.8.6", "sphinxcontrib-spelling==8", "sybil==7.1.0", - "types-requests==2.32.0.20240907", + "types-requests==2.32.0.20240914", "vulture==2.11", "vws-python-mock==2024.8.30", "vws-test-fixtures==2023.3.5", From 60f5560d362dbccee065a09d0b6b70010de8d9eb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Sep 2024 10:29:59 +0000 Subject: [PATCH 0373/1003] Bump ruff from 0.6.4 to 0.6.5 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.6.4 to 0.6.5. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.6.4...0.6.5) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e2c71fd57..e11295038 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ optional-dependencies.dev = [ "pytest==8.3.3", "pytest-cov==5.0.0", "pyyaml==6.0.2", - "ruff==0.6.4", + "ruff==0.6.5", "sphinx==8.0.2", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", From b8c7a1bcc7a673fb1c5f0efce23608fbd096340f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Sep 2024 10:41:55 +0000 Subject: [PATCH 0374/1003] Bump doccmd from 2024.9.14.5 to 2024.9.16 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.9.14.5 to 2024.9.16. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.09.14.5...2024.09.16) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e11295038..e148e17b2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.49", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.9.14.5", + "doccmd==2024.9.16", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", From 2bb033d5e3a271eb1e1bfacc14d55bcdd3ec74d2 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 16 Sep 2024 22:39:04 +0100 Subject: [PATCH 0375/1003] Remove pre-commit hooks for which we have a duplicate with an auto-fix --- .pre-commit-config.yaml | 36 ------------------------------------ 1 file changed, 36 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 36a8ffb12..ddda103be 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -18,18 +18,13 @@ ci: - mypy - mypy-docs - pylint - - pyproject-fmt-check - pyproject-fmt-fix - pyright - pyright-docs - pyright-verifytypes - pyroma - - ruff-check - - ruff-check-docs - ruff-check-fix - ruff-check-fix-docs - - ruff-format-diff - - ruff-format-diff-docs - ruff-format-fix - ruff-format-fix-docs - spelling @@ -137,30 +132,6 @@ repos: stages: [manual] types_or: [markdown, rst, python, toml] - - id: ruff-check - name: Ruff check - entry: python -m ruff check - language: system - types_or: [python] - - - id: ruff-check-docs - name: Ruff check docs - entry: doccmd --language=python --command="ruff check" - language: system - types_or: [markdown, rst] - - - id: ruff-format-diff - name: Ruff format diff - entry: python -m ruff format --diff - language: system - types_or: [python] - - - id: ruff-format-diff-docs - name: Ruff format diff docs - entry: doccmd --language=python --no-pad-file --command="ruff format --diff" - language: system - types_or: [markdown, rst] - - id: ruff-check-fix name: Ruff check fix entry: python -m ruff check --fix @@ -203,13 +174,6 @@ repos: language: system types_or: [markdown, rst] - - id: pyproject-fmt-check - name: pyproject-fmt check - entry: pyproject-fmt --check - language: system - types_or: [toml] - files: pyproject.toml - - id: pyproject-fmt-fix name: pyproject-fmt entry: pyproject-fmt From ccd56a3b38cfc9cc08e05856252b619d5d3738bf Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 16 Sep 2024 23:59:37 +0100 Subject: [PATCH 0376/1003] Add shellcheck-py so that GitHub workflow files get linted for shell issues --- .gitignore | 2 ++ pyproject.toml | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/.gitignore b/.gitignore index ec1645423..0a4d3ec0c 100644 --- a/.gitignore +++ b/.gitignore @@ -109,3 +109,5 @@ secrets.tar # setuptools_scm src/*/_setuptools_scm_version.txt + +uv.lock diff --git a/pyproject.toml b/pyproject.toml index e148e17b2..2546fbd92 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,6 +61,10 @@ optional-dependencies.dev = [ "pytest-cov==5.0.0", "pyyaml==6.0.2", "ruff==0.6.5", + # We add shellcheck-py not only for shell scripts and shell code blocks, + # but also because having it installed means that ``actionlint-py`` will + # use it to lint shell commands in GitHub workflow files. + "shellcheck-py==0.10.0.1", "sphinx==8.0.2", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", From f026fbc245c1e9ea592cdd786fc95ffc47ab87b3 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 17 Sep 2024 10:44:07 +0100 Subject: [PATCH 0377/1003] Remove no-longer-needed handling of .eggs directory in Vulture --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ddda103be..b158d66eb 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -101,7 +101,7 @@ repos: - id: vulture name: vulture - entry: python -m vulture --min-confidence 100 --exclude .eggs + entry: python -m vulture --min-confidence 100 language: system types_or: [python] From f5d9ed6423bfe7ab7317733feb6aadb2b21ad52a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 17 Sep 2024 10:58:07 +0100 Subject: [PATCH 0378/1003] Remove requirement to have 100% confidence that code is dead to report it --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index b158d66eb..a8fa23a33 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -101,7 +101,7 @@ repos: - id: vulture name: vulture - entry: python -m vulture --min-confidence 100 + entry: python -m vulture language: system types_or: [python] From 81aee0888a923cc34f8c3abd03a1dd84cb984e5d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 17 Sep 2024 11:48:27 +0100 Subject: [PATCH 0379/1003] Progress towards satisfying vulture --- .pre-commit-config.yaml | 3 ++- conftest.py | 8 ++++---- docs/source/conf.py | 7 +------ pyproject.toml | 42 +++++++++++++++++++++++++++++++++++++++++ tests/conftest.py | 2 +- 5 files changed, 50 insertions(+), 12 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index a8fa23a33..d5ebb2c33 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -101,9 +101,10 @@ repos: - id: vulture name: vulture - entry: python -m vulture + entry: python -m vulture . language: system types_or: [python] + pass_filenames: false - id: pyroma name: pyroma diff --git a/conftest.py b/conftest.py index 059fd0968..02f059890 100644 --- a/conftest.py +++ b/conftest.py @@ -26,8 +26,8 @@ def pytest_collection_modifyitems(items: list[pytest.Item]) -> None: item.obj = beartype(obj=item.obj) -@pytest.fixture -def make_image_file( +@pytest.fixture(name="make_image_file") +def fixture_make_image_file( high_quality_image: io.BytesIO, ) -> Generator[None, None, None]: """ @@ -41,8 +41,8 @@ def make_image_file( new_image.unlink() -@pytest.fixture -def mock_vws() -> Generator[None, None, None]: +@pytest.fixture(name="mock_vws") +def fixture_mock_vws() -> Generator[None, None, None]: """ Yield a mock VWS. diff --git a/docs/source/conf.py b/docs/source/conf.py index c18eb170d..5e3a67830 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -62,12 +62,7 @@ "python": ("https://docs.python.org/3.12", None), } nitpicky = True -nitpick_ignore = ( - ("py:class", "BytesIO"), - ("py:class", "BufferedRandom"), - ("py:class", "_io.BytesIO"), - ("py:class", "_io.BufferedRandom"), -) +nitpick_ignore = (("py:class", "_io.BytesIO"),) warning_is_error = True autoclass_content = "both" diff --git a/pyproject.toml b/pyproject.toml index 2546fbd92..4fc745002 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -342,3 +342,45 @@ ignore_path = [ "./src/*.egg-info/", "./src/*/_setuptools_scm_version.txt", ] + +[tool.vulture] +# Ideally we would limit the paths to the source code where we want to ignore names, +# but Vulture does not enable this. +ignore_names = [ + # pytest configuration + "pytest_collect_file", + "pytest_collection_modifyitems", + "pytest_plugins", + # pytest fixtures - we name fixtures like this for this purpose + "fixture_*", + # Sphinx + "autoclass_content", + "autoclass_content", + "autodoc_member_order", + "copybutton_exclude", + "extensions", + "html_show_copyright", + "html_show_sourcelink", + "html_show_sphinx", + "html_theme", + "html_theme_options", + "html_title", + "htmlhelp_basename", + "intersphinx_mapping", + "language", + "linkcheck_ignore", + "linkcheck_retries", + "master_doc", + "nitpicky", + "nitpick_ignore", + "project_copyright", + "pygments_style", + "rst_prolog", + "source_suffix", + "spelling_word_list_filename", + "templates_path", + "warning_is_error", +] + +# Duplicate some of .gitignore +exclude = [".venv"] diff --git a/tests/conftest.py b/tests/conftest.py index 0ec595e31..6c927cbed 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -15,7 +15,7 @@ @pytest.fixture(name="_mock_database") -def mock_database() -> Generator[VuforiaDatabase, None, None]: +def fixture_mock_database() -> Generator[VuforiaDatabase, None, None]: """ Yield a mock ``VuforiaDatabase``. """ From ddbb36edb0fb34a3d16b2bc99f2470c826384e5c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 17 Sep 2024 11:48:55 +0100 Subject: [PATCH 0380/1003] Progress towards satisfying vulture --- tests/conftest.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/conftest.py b/tests/conftest.py index 6c927cbed..d1b122f15 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -49,7 +49,7 @@ def cloud_reco_client(_mock_database: VuforiaDatabase) -> CloudRecoService: @pytest.fixture(name="image_file", params=["r+b", "rb"]) -def image_file_fixture( +def fixture_image_file( high_quality_image: io.BytesIO, tmp_path: Path, request: pytest.FixtureRequest, From b1d36ab5ff3c75fce4519f2fd18cec59fbcf8a71 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 17 Sep 2024 11:53:04 +0100 Subject: [PATCH 0381/1003] Progress towards satisfying vulture --- tests/test_vws.py | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/tests/test_vws.py b/tests/test_vws.py index c5761b78a..88bcc17c5 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -248,6 +248,24 @@ def test_get_target(vws_client: VWS) -> None: target_quota=1000, total_recos=0, ) + + assert report.active_images == expected_report.active_images + assert ( + report.current_month_recos == expected_report.current_month_recos + ) + assert report.failed_images == expected_report.failed_images + assert report.inactive_images == expected_report.inactive_images + assert report.name == expected_report.name + assert ( + report.previous_month_recos == expected_report.previous_month_recos + ) + assert report.processing_images == expected_report.processing_images + assert report.reco_threshold == expected_report.reco_threshold + assert report.request_quota == expected_report.request_quota + assert report.request_usage == expected_report.request_usage + assert report.target_quota == expected_report.target_quota + assert report.total_recos == expected_report.total_recos + assert report == expected_report From 4fdf2687eec6a9b830bc6175e2a1940afaa98481 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 17 Sep 2024 11:58:25 +0100 Subject: [PATCH 0382/1003] Progress towards satisfying vulture --- tests/test_vws.py | 42 ++++++++++++++++++++++++++++++++++++++---- 1 file changed, 38 insertions(+), 4 deletions(-) diff --git a/tests/test_vws.py b/tests/test_vws.py index 88bcc17c5..158ad9064 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -206,20 +206,35 @@ def test_get_target_summary_report( application_metadata=None, ) - result = vws_client.get_target_summary_report(target_id=target_id) + report = vws_client.get_target_summary_report(target_id=target_id) expected_report = TargetSummaryReport( status=TargetStatuses.SUCCESS, - database_name=result.database_name, + database_name=report.database_name, target_name=target_name, upload_date=datetime.date(2018, 4, 25), active_flag=True, - tracking_rating=result.tracking_rating, + tracking_rating=report.tracking_rating, total_recos=0, current_month_recos=0, previous_month_recos=0, ) - assert result == expected_report + + assert report.status == expected_report.status + assert report.database_name == expected_report.database_name + assert report.target_name == expected_report.target_name + assert report.upload_date == expected_report.upload_date + assert report.active_flag == expected_report.active_flag + assert report.tracking_rating == expected_report.tracking_rating + assert report.total_recos == expected_report.total_recos + assert ( + report.current_month_recos == expected_report.current_month_recos + ) + assert ( + report.previous_month_recos == expected_report.previous_month_recos + ) + + assert report == expected_report class TestGetDatabaseSummaryReport: @@ -301,6 +316,25 @@ def test_get_target_record( ) assert result.target_record == expected_target_record + + assert ( + result.target_record.target_id == expected_target_record.target_id + ) + assert ( + result.target_record.active_flag + == expected_target_record.active_flag + ) + assert result.target_record.name == expected_target_record.name + assert result.target_record.width == expected_target_record.width + assert ( + result.target_record.tracking_rating + == expected_target_record.tracking_rating + ) + assert ( + result.target_record.reco_rating + == expected_target_record.reco_rating + ) + assert result.status == TargetStatuses.PROCESSING From 4f79d4785a842ede11e5246285dedf0ae809c4ca Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 17 Sep 2024 12:06:12 +0100 Subject: [PATCH 0383/1003] Test TargetStatuses FAILED --- tests/test_cloud_reco_exceptions.py | 6 +++++- tests/test_vws.py | 21 +++++++++++++++++++++ 2 files changed, 26 insertions(+), 1 deletion(-) diff --git a/tests/test_cloud_reco_exceptions.py b/tests/test_cloud_reco_exceptions.py index 5c0a89cd2..d33da8e72 100644 --- a/tests/test_cloud_reco_exceptions.py +++ b/tests/test_cloud_reco_exceptions.py @@ -116,4 +116,8 @@ def test_inactive_project( with pytest.raises(InactiveProjectError) as exc: cloud_reco_client.query(image=high_quality_image) - assert exc.value.response.status_code == HTTPStatus.FORBIDDEN + response = exc.value.response + assert response.status_code == HTTPStatus.FORBIDDEN + # We need one test which checks tell position + # and so we choose this one almost at random. + assert response.tell_position != 0 diff --git a/tests/test_vws.py b/tests/test_vws.py index 158ad9064..42fdee45a 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -337,6 +337,27 @@ def test_get_target_record( assert result.status == TargetStatuses.PROCESSING + @staticmethod + def test_get_failed( + vws_client: VWS, + image_file_failed_state: io.BytesIO, + ) -> None: + """ + Check that the report works with a failed target. + """ + target_id = vws_client.add_target( + name="x", + width=1, + image=image_file_failed_state, + active_flag=True, + application_metadata=None, + ) + + vws_client.wait_for_target_processed(target_id=target_id) + result = vws_client.get_target_record(target_id=target_id) + + assert result.status == TargetStatuses.FAILED + class TestWaitForTargetProcessed: """ From 080ee97a4be2f26eb9afff8a847f29ae75ebd023 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Tue, 17 Sep 2024 11:07:47 +0000 Subject: [PATCH 0384/1003] [pre-commit.ci lite] apply automatic fixes --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4fc745002..ae5fea28c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -383,4 +383,4 @@ ignore_names = [ ] # Duplicate some of .gitignore -exclude = [".venv"] +exclude = [ ".venv" ] From 53fbdd4c990ea45beba65674f768226ebaa90f92 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 17 Sep 2024 11:12:41 +0000 Subject: [PATCH 0385/1003] Bump sybil from 7.1.0 to 7.1.1 Bumps [sybil](https://github.com/simplistix/sybil) from 7.1.0 to 7.1.1. - [Changelog](https://github.com/simplistix/sybil/blob/master/CHANGELOG.rst) - [Commits](https://github.com/simplistix/sybil/compare/7.1.0...7.1.1) --- updated-dependencies: - dependency-name: sybil dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ae5fea28c..e5468bfed 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -69,7 +69,7 @@ optional-dependencies.dev = [ "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", "sphinxcontrib-spelling==8", - "sybil==7.1.0", + "sybil==7.1.1", "types-requests==2.32.0.20240914", "vulture==2.11", "vws-python-mock==2024.8.30", From e36d374f3ba05951c08cddc6526d9975cf3fe83e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 18 Sep 2024 04:04:01 +0100 Subject: [PATCH 0386/1003] Use vulture on docs --- .pre-commit-config.yaml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index d5ebb2c33..c7f3f0074 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -29,6 +29,7 @@ ci: - ruff-format-fix-docs - spelling - vulture + - vulture-docs default_install_hook_types: [pre-commit, pre-push, commit-msg] repos: @@ -106,6 +107,12 @@ repos: types_or: [python] pass_filenames: false + - id: vulture-docs + name: vulture docs + entry: doccmd --language=python --command="vulture" + language: system + types_or: [markdown, rst] + - id: pyroma name: pyroma entry: python -m pyroma --min 10 . From 2d855358b9ed83913a4ab56d379a122e6d917343 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 18 Sep 2024 10:56:47 +0000 Subject: [PATCH 0387/1003] Bump vulture from 2.11 to 2.12 Bumps [vulture](https://github.com/jendrikseipp/vulture) from 2.11 to 2.12. - [Release notes](https://github.com/jendrikseipp/vulture/releases) - [Changelog](https://github.com/jendrikseipp/vulture/blob/main/CHANGELOG.md) - [Commits](https://github.com/jendrikseipp/vulture/compare/v2.11...v2.12) --- updated-dependencies: - dependency-name: vulture dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e5468bfed..8c412194a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -71,7 +71,7 @@ optional-dependencies.dev = [ "sphinxcontrib-spelling==8", "sybil==7.1.1", "types-requests==2.32.0.20240914", - "vulture==2.11", + "vulture==2.12", "vws-python-mock==2024.8.30", "vws-test-fixtures==2023.3.5", ] From af827ff3fc3f198603e21d67d1a61f44467b3564 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 18 Sep 2024 10:57:03 +0000 Subject: [PATCH 0388/1003] Bump pyproject-fmt from 2.2.3 to 2.2.4 Bumps [pyproject-fmt](https://github.com/tox-dev/pyproject-fmt) from 2.2.3 to 2.2.4. - [Release notes](https://github.com/tox-dev/pyproject-fmt/releases) - [Commits](https://github.com/tox-dev/pyproject-fmt/compare/2.2.3...2.2.4) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e5468bfed..00e73cb38 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.2.7", "pylint-per-file-ignores==1.3.2", - "pyproject-fmt==2.2.3", + "pyproject-fmt==2.2.4", "pyright==1.1.380", "pyroma==4.2", "pytest==8.3.3", From 0baad7ed36baa543d4feaffe7395c5bf6aff378f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 18 Sep 2024 12:25:02 +0000 Subject: [PATCH 0389/1003] Bump pyright from 1.1.380 to 1.1.381 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.380 to 1.1.381. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.380...v1.1.381) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 654058d64..14f498296 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint==3.2.7", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.2.4", - "pyright==1.1.380", + "pyright==1.1.381", "pyroma==4.2", "pytest==8.3.3", "pytest-cov==5.0.0", From 033daadb512e6b59312852ef592e2e09fcc92d91 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 18 Sep 2024 12:33:21 +0000 Subject: [PATCH 0390/1003] Bump doccmd from 2024.9.16 to 2024.9.18 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.9.16 to 2024.9.18. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.09.16...2024.09.18) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 14f498296..a75a7f9e7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.49", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.9.16", + "doccmd==2024.9.18", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", From 8111a3880cb4b911c89b58cf425c3c0dea3cdeaa Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Sep 2024 08:29:07 +0100 Subject: [PATCH 0391/1003] Simplify release script by removing unnecessary intermediary variables --- .github/workflows/release.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 64761eefa..faf2c7d2e 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -47,11 +47,9 @@ jobs: - name: "Update changelog" uses: jacobtomlinson/gha-find-replace@v3 - env: - NEXT_VERSION: ${{ steps.calver.outputs.release }} with: find: "Next\n----" - replace: "Next\n----\n\n${{ env.NEXT_VERSION }}\n------------" + replace: "Next\n----\n\n${{ steps.calver.outputs.release }}\n------------" include: "CHANGELOG.rst" regex: false From a1c87b57b0df55f8576e0cbf8f6e3b155675a6b7 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Sep 2024 08:48:25 +0100 Subject: [PATCH 0392/1003] Simplify release script by removing unnecessary git fetch tags command --- .github/workflows/release.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index faf2c7d2e..5c0cd1771 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -78,8 +78,7 @@ jobs: - name: Build a binary wheel and a source tarball run: | # Checkout the latest tag - the one we just created. - git fetch --tags - git checkout "$(git describe --tags "$(git rev-list --tags --max-count=1)")" + git checkout ${{ steps.tag_version.outputs.new_tag }} python -m pip install build check-wheel-contents python -m build --sdist --wheel --outdir dist/ . check-wheel-contents dist/*.whl From af6cfb79557e78d154fab0c68913561086ef4783 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Sep 2024 09:01:40 +0100 Subject: [PATCH 0393/1003] Add back required part of the command --- .github/workflows/release.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 5c0cd1771..a24d5daff 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -78,6 +78,7 @@ jobs: - name: Build a binary wheel and a source tarball run: | # Checkout the latest tag - the one we just created. + git fetch --tags git checkout ${{ steps.tag_version.outputs.new_tag }} python -m pip install build check-wheel-contents python -m build --sdist --wheel --outdir dist/ . From e9d5f41cc01ddb7078893aefaf38e40d0ed38807 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 19 Sep 2024 10:44:58 +0000 Subject: [PATCH 0394/1003] Bump doccmd from 2024.9.18 to 2024.9.19.3 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.9.18 to 2024.9.19.3. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.09.18...2024.09.19.3) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a75a7f9e7..5a2984164 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.49", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.9.18", + "doccmd==2024.9.19.3", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", From d5d07fd13aedf30f2c918f2fd09deb8ef01dc778 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 20 Sep 2024 10:49:10 +0000 Subject: [PATCH 0395/1003] Bump ruff from 0.6.5 to 0.6.6 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.6.5 to 0.6.6. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.6.5...0.6.6) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5a2984164..5082934bc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ optional-dependencies.dev = [ "pytest==8.3.3", "pytest-cov==5.0.0", "pyyaml==6.0.2", - "ruff==0.6.5", + "ruff==0.6.6", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 121a925697d930011297444edb392dbe6c3c741b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 20 Sep 2024 10:53:48 +0000 Subject: [PATCH 0396/1003] Bump sybil from 7.1.1 to 8.0.0 Bumps [sybil](https://github.com/simplistix/sybil) from 7.1.1 to 8.0.0. - [Changelog](https://github.com/simplistix/sybil/blob/master/CHANGELOG.rst) - [Commits](https://github.com/simplistix/sybil/compare/7.1.1...8.0.0) --- updated-dependencies: - dependency-name: sybil dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5082934bc..27e70ed6c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -69,7 +69,7 @@ optional-dependencies.dev = [ "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", "sphinxcontrib-spelling==8", - "sybil==7.1.1", + "sybil==8.0.0", "types-requests==2.32.0.20240914", "vulture==2.12", "vws-python-mock==2024.8.30", From 156f46f7c678b469607524d80dbd8dcd4614c455 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 20 Sep 2024 21:13:33 +0100 Subject: [PATCH 0397/1003] Remove lint ignores - do not allow hardcoded secrets in documentation --- README.rst | 9 +++++---- conftest.py | 23 ++++++++++++++++++----- docs/source/index.rst | 9 +++++---- pyproject.toml | 10 ---------- 4 files changed, 28 insertions(+), 23 deletions(-) diff --git a/README.rst b/README.rst index ffccbc916..ce352e4e5 100644 --- a/README.rst +++ b/README.rst @@ -24,15 +24,16 @@ Getting Started """Add a target to VWS and then query it.""" + import os import pathlib import uuid from vws import VWS, CloudRecoService - server_access_key = "[server-access-key]" - server_secret_key = "[server-secret-key]" - client_access_key = "[client-access-key]" - client_secret_key = "[client-secret-key]" + server_access_key = os.environ["VWS_SERVER_ACCESS_KEY"] + server_secret_key = os.environ["VWS_SERVER_SECRET_KEY"] + client_access_key = os.environ["VWS_CLIENT_ACCESS_KEY"] + client_secret_key = os.environ["VWS_CLIENT_SECRET_KEY"] vws_client = VWS( server_access_key=server_access_key, diff --git a/conftest.py b/conftest.py index 02f059890..691dcbe0e 100644 --- a/conftest.py +++ b/conftest.py @@ -1,6 +1,7 @@ """Setup for Sybil.""" import io +import uuid from collections.abc import Generator from doctest import ELLIPSIS from pathlib import Path @@ -42,18 +43,30 @@ def fixture_make_image_file( @pytest.fixture(name="mock_vws") -def fixture_mock_vws() -> Generator[None, None, None]: +def fixture_mock_vws( + monkeypatch: pytest.MonkeyPatch, +) -> Generator[None, None, None]: """ Yield a mock VWS. The keys used here match the keys in the documentation. """ + server_access_key = uuid.uuid4().hex + server_secret_key = uuid.uuid4().hex + client_access_key = uuid.uuid4().hex + client_secret_key = uuid.uuid4().hex + database = VuforiaDatabase( - server_access_key="[server-access-key]", - server_secret_key="[server-secret-key]", - client_access_key="[client-access-key]", - client_secret_key="[client-secret-key]", + server_access_key=server_access_key, + server_secret_key=server_secret_key, + client_access_key=client_access_key, + client_secret_key=client_secret_key, ) + + monkeypatch.setenv(name="VWS_SERVER_ACCESS_KEY", value=server_access_key) + monkeypatch.setenv(name="VWS_SERVER_SECRET_KEY", value=server_secret_key) + monkeypatch.setenv(name="VWS_CLIENT_ACCESS_KEY", value=client_access_key) + monkeypatch.setenv(name="VWS_CLIENT_SECRET_KEY", value=client_secret_key) # We use a low processing time so that tests run quickly. with MockVWS(processing_time_seconds=0.2) as mock: mock.add_database(database=database) diff --git a/docs/source/index.rst b/docs/source/index.rst index fe1ee9a9e..fe0f8584a 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -20,15 +20,16 @@ See the :doc:`api-reference` for full usage details. """Add a target to VWS and then query it.""" + import os import pathlib import uuid from vws import VWS, CloudRecoService - server_access_key = "[server-access-key]" - server_secret_key = "[server-secret-key]" - client_access_key = "[client-access-key]" - client_secret_key = "[client-secret-key]" + server_access_key = os.environ["VWS_SERVER_ACCESS_KEY"] + server_secret_key = os.environ["VWS_SERVER_SECRET_KEY"] + client_access_key = os.environ["VWS_CLIENT_ACCESS_KEY"] + client_secret_key = os.environ["VWS_CLIENT_SECRET_KEY"] vws_client = VWS( server_access_key=server_access_key, diff --git a/pyproject.toml b/pyproject.toml index 27e70ed6c..71ab39eee 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -123,16 +123,6 @@ lint.ignore = [ "S101", ] -lint.per-file-ignores."conftest.py" = [ - # Allow hardcoded secrets in tests. - "S106", -] - -lint.per-file-ignores."doccmd_*.py" = [ - # Allow hardcoded secrets in documentation. - "S105", -] - lint.per-file-ignores."tests/*.py" = [ # Do not require tests to have a one-line summary. "D205", From ce03744bd22e28dbf74c59e98317847de67f8881 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 21 Sep 2024 00:23:42 +0100 Subject: [PATCH 0398/1003] Bump version of Python mentioned in docs --- docs/source/index.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/source/index.rst b/docs/source/index.rst index fe0f8584a..661814708 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -8,7 +8,7 @@ Installation $ pip install vws-python -This is tested on Python 3.8+. +This is tested on Python 3.12+. Get in touch with ``adamdangoor@gmail.com`` if you would like to use this with another language. Usage From bdf672a8260d4c87480c1c5a3386aabbd072b1e6 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 21 Sep 2024 09:52:44 +0100 Subject: [PATCH 0399/1003] Test shell snippets in documentation code blocks --- .pre-commit-config.yaml | 18 +++++++++++++----- docs/source/release-process.rst | 2 +- 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c7f3f0074..1b9f9b56b 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -49,11 +49,6 @@ repos: - id: file-contents-sorter files: spelling_private_dict\.txt$ - id: trailing-whitespace -- repo: https://github.com/shellcheck-py/shellcheck-py - rev: v0.10.0.1 - hooks: - - id: shellcheck - args: ["--shell", "bash"] - repo: local hooks: - id: actionlint @@ -63,6 +58,19 @@ repos: pass_filenames: false types_or: [yaml] + - id: shellcheck + name: shellcheck + entry: shellcheck --shell bash + language: system + pass_filenames: false + types_or: [shell] + + - id: shellcheck-docs + name: shellcheck-docs + entry: doccmd --language=shell --language=console --command="shellcheck --shell=bash" + language: system + types_or: [markdown, rst] + - id: mypy name: mypy stages: [push] diff --git a/docs/source/release-process.rst b/docs/source/release-process.rst index 0c662f553..db1744feb 100644 --- a/docs/source/release-process.rst +++ b/docs/source/release-process.rst @@ -17,6 +17,6 @@ Perform a Release .. code-block:: console :substitutions: - $ gh workflow run release.yml --repo |github-owner|/|github-repository| + $ gh workflow run release.yml --repo "|github-owner|/|github-repository|" .. _Install GitHub CLI: https://cli.github.com/ From a78c28a5afc14a76e2a3e09cee1ac8296ac7f519 Mon Sep 17 00:00:00 2001 From: adamtheturtle Date: Sat, 21 Sep 2024 08:53:13 +0000 Subject: [PATCH 0400/1003] Bump CHANGELOG --- CHANGELOG.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 2eb9d9a05..b18bc5e4f 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,9 @@ Changelog Next ---- +2024.09.21 +------------ + 2024.09.04.1 ------------ From 7101f9eeb6d3da63383e98fc7b1ee46394e8f705 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 21 Sep 2024 09:53:40 +0100 Subject: [PATCH 0401/1003] Do not run new hooks on pre-commit CI --- .pre-commit-config.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 1b9f9b56b..f71de6b92 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -30,6 +30,8 @@ ci: - spelling - vulture - vulture-docs + - shellcheck + - shellcheck-docs default_install_hook_types: [pre-commit, pre-push, commit-msg] repos: From b7a2e47860753f6f05ca5a73d8ac6a9284e06b4d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 23 Sep 2024 10:12:41 +0000 Subject: [PATCH 0402/1003] Bump ruff from 0.6.6 to 0.6.7 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.6.6 to 0.6.7. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.6.6...0.6.7) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 71ab39eee..4e70acc0d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ optional-dependencies.dev = [ "pytest==8.3.3", "pytest-cov==5.0.0", "pyyaml==6.0.2", - "ruff==0.6.6", + "ruff==0.6.7", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From c05549a18d3c0710420dd17bbda917890878e95e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 23 Sep 2024 10:17:33 +0000 Subject: [PATCH 0403/1003] Bump pylint from 3.2.7 to 3.3.0 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.2.7 to 3.3.0. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.2.7...v3.3.0) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4e70acc0d..8f50326bf 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pyenchant==3.2.2", "pygments==2.18.0", - "pylint==3.2.7", + "pylint==3.3.0", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.2.4", "pyright==1.1.381", From cd819da5a467a4f8272f51d16aec2cfa9e81d354 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 23 Sep 2024 10:17:33 +0000 Subject: [PATCH 0404/1003] Bump doccmd from 2024.9.19.3 to 2024.9.21 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.9.19.3 to 2024.9.21. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.09.19.3...2024.09.21) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4e70acc0d..29c20d514 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.49", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.9.19.3", + "doccmd==2024.9.21", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", From 4616984c0b063cc6a7fc3273be3bee0ee1a9605d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 23 Sep 2024 11:26:05 +0100 Subject: [PATCH 0405/1003] Satisfy pylint --- conftest.py | 4 ++-- docs/source/conf.py | 2 -- src/vws/vws.py | 1 + tests/conftest.py | 4 ++-- 4 files changed, 5 insertions(+), 6 deletions(-) diff --git a/conftest.py b/conftest.py index 691dcbe0e..05d6727f2 100644 --- a/conftest.py +++ b/conftest.py @@ -30,7 +30,7 @@ def pytest_collection_modifyitems(items: list[pytest.Item]) -> None: @pytest.fixture(name="make_image_file") def fixture_make_image_file( high_quality_image: io.BytesIO, -) -> Generator[None, None, None]: +) -> Generator[None]: """ Make an image file available in the test directory. The path of this file matches the path in the documentation. @@ -45,7 +45,7 @@ def fixture_make_image_file( @pytest.fixture(name="mock_vws") def fixture_mock_vws( monkeypatch: pytest.MonkeyPatch, -) -> Generator[None, None, None]: +) -> Generator[None]: """ Yield a mock VWS. diff --git a/docs/source/conf.py b/docs/source/conf.py index 5e3a67830..9c88cea7d 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -3,8 +3,6 @@ Configuration for Sphinx. """ -# pylint: disable=invalid-name - import datetime import importlib.metadata diff --git a/src/vws/vws.py b/src/vws/vws.py index 185af1178..9e40655d2 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -633,6 +633,7 @@ def get_duplicate_targets(self, target_id: str) -> list[str]: def update_target( self, + *, target_id: str, name: str | None = None, width: float | None = None, diff --git a/tests/conftest.py b/tests/conftest.py index d1b122f15..ed50f2e7b 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -15,7 +15,7 @@ @pytest.fixture(name="_mock_database") -def fixture_mock_database() -> Generator[VuforiaDatabase, None, None]: +def fixture_mock_database() -> Generator[VuforiaDatabase]: """ Yield a mock ``VuforiaDatabase``. """ @@ -53,7 +53,7 @@ def fixture_image_file( high_quality_image: io.BytesIO, tmp_path: Path, request: pytest.FixtureRequest, -) -> Generator[BinaryIO, None, None]: +) -> Generator[BinaryIO]: """An image file object.""" file = tmp_path / "image.jpg" buffer = high_quality_image.getvalue() From 2ce2199b0fd0895456ff5b48ab4ec0dbacea15b6 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 23 Sep 2024 21:40:31 +0100 Subject: [PATCH 0406/1003] Add check-json and meta pre-commit hooks --- .pre-commit-config.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index f71de6b92..621e643b9 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -35,6 +35,9 @@ ci: default_install_hook_types: [pre-commit, pre-push, commit-msg] repos: +- repo: meta + hooks: + - id: check-useless-excludes - repo: https://github.com/pre-commit/pre-commit-hooks rev: v4.6.0 hooks: @@ -44,6 +47,7 @@ repos: - id: check-merge-conflict - id: check-shebang-scripts-are-executable - id: check-symlinks + - id: check-json - id: check-toml - id: check-vcs-permalinks - id: check-yaml From c4f2e11613cf08fa7b358689d533b8172b7fd7a9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 24 Sep 2024 10:19:18 +0000 Subject: [PATCH 0407/1003] Bump doccmd from 2024.9.21 to 2024.9.23 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.9.21 to 2024.9.23. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.09.21...2024.09.23) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d0533d97b..82bb8c825 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.49", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.9.21", + "doccmd==2024.9.23", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", From 7a1fbd9fd4af7170c6c170656591b72cf0c58bfe Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 24 Sep 2024 10:24:41 +0000 Subject: [PATCH 0408/1003] Bump actionlint-py from 1.7.1.15 to 1.7.2.16 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.7.1.15 to 1.7.2.16. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.7.1.15...v1.7.2.16) --- updated-dependencies: - dependency-name: actionlint-py dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 82bb8c825..c65ef4771 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -39,7 +39,7 @@ dependencies = [ "vws-auth-tools", ] optional-dependencies.dev = [ - "actionlint-py==1.7.1.15", + "actionlint-py==1.7.2.16", "check-manifest==0.49", "deptry==0.20.0", "doc8==1.1.2", From 64ded7f8648a0e3237c6b73621b1cd36636760ec Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 25 Sep 2024 10:18:41 +0000 Subject: [PATCH 0409/1003] Bump pylint from 3.3.0 to 3.3.1 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.3.0 to 3.3.1. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.3.0...v3.3.1) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c65ef4771..757113f9b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pyenchant==3.2.2", "pygments==2.18.0", - "pylint==3.3.0", + "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.2.4", "pyright==1.1.381", From 3e13270c37feab6a6177a7981b192c05f6fa8651 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 25 Sep 2024 10:24:23 +0000 Subject: [PATCH 0410/1003] Bump pyright from 1.1.381 to 1.1.382 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.381 to 1.1.382. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.381...v1.1.382) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 757113f9b..71dcd0270 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.2.4", - "pyright==1.1.381", + "pyright==1.1.382", "pyroma==4.2", "pytest==8.3.3", "pytest-cov==5.0.0", From 9e7a7e3c988e9cf9cbd450875bd1894cef8801af Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 25 Sep 2024 10:30:31 +0000 Subject: [PATCH 0411/1003] Bump doccmd from 2024.9.23 to 2024.9.24 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.9.23 to 2024.9.24. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.09.23...2024.09.24) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 71dcd0270..e13d7b1ad 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.49", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.9.23", + "doccmd==2024.9.24", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", From 25cee00767dd5023f6fbdbffd2970d28f491b49a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 25 Sep 2024 12:46:10 +0100 Subject: [PATCH 0412/1003] Update RTD build OS --- readthedocs.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/readthedocs.yaml b/readthedocs.yaml index 88e40e66a..d3bd4fd21 100644 --- a/readthedocs.yaml +++ b/readthedocs.yaml @@ -1,7 +1,7 @@ version: 2 build: - os: ubuntu-20.04 + os: ubuntu-24.04 tools: python: "3.12" From dfd4798d915586cf4d60270981f2d1a8835b236c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 26 Sep 2024 08:50:23 +0100 Subject: [PATCH 0413/1003] Remove ignores of deprecated ruff rules --- pyproject.toml | 2 -- 1 file changed, 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index e13d7b1ad..c881eaf5a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -103,8 +103,6 @@ lint.select = [ "ALL", ] lint.ignore = [ - # We do not annotate the type of 'self'. - "ANN101", # We are happy to manage our own "complexity". "C901", # Ruff warns that this conflicts with the formatter. From 8e8562436fb3e808c05a2cf633ce201b9e3320c1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 26 Sep 2024 10:14:35 +0000 Subject: [PATCH 0414/1003] Bump doccmd from 2024.9.24 to 2024.9.26 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.9.24 to 2024.9.26. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.09.24...2024.09.26) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c881eaf5a..b1d52d097 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.49", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.9.24", + "doccmd==2024.9.26", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", From 3a94c400228a2d6c64ce9f69ff7f68ffd3e5a09b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 26 Sep 2024 10:21:46 +0000 Subject: [PATCH 0415/1003] Bump pyright from 1.1.382 to 1.1.382.post0 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.382 to 1.1.382.post0. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.382...v1.1.382.post0) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b1d52d097..e79e38925 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.2.4", - "pyright==1.1.382", + "pyright==1.1.382.post0", "pyroma==4.2", "pytest==8.3.3", "pytest-cov==5.0.0", From c3a52d1c883ba04815ca96e04ae210781986b496 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 27 Sep 2024 10:42:03 +0000 Subject: [PATCH 0416/1003] Bump ruff from 0.6.7 to 0.6.8 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.6.7 to 0.6.8. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.6.7...0.6.8) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e79e38925..0680b1e1b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ optional-dependencies.dev = [ "pytest==8.3.3", "pytest-cov==5.0.0", "pyyaml==6.0.2", - "ruff==0.6.7", + "ruff==0.6.8", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 5607425d89fb79469fd2a582d937f097c29aa945 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 28 Sep 2024 12:27:26 +0100 Subject: [PATCH 0417/1003] Make it possible create sets of our custom types --- src/vws/reports.py | 12 ++++++------ src/vws/types.py | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/vws/reports.py b/src/vws/reports.py index 3d157a783..431cfcaa6 100644 --- a/src/vws/reports.py +++ b/src/vws/reports.py @@ -10,7 +10,7 @@ @beartype -@dataclass +@dataclass(frozen=True) class DatabaseSummaryReport: """ A database summary report. @@ -47,7 +47,7 @@ class TargetStatuses(Enum): @beartype -@dataclass +@dataclass(frozen=True) class TargetSummaryReport: """ A target summary report. @@ -68,7 +68,7 @@ class TargetSummaryReport: @beartype(conf=BeartypeConf(is_pep484_tower=True)) -@dataclass +@dataclass(frozen=True) class TargetRecord: """ A target record. @@ -86,7 +86,7 @@ class TargetRecord: @beartype -@dataclass +@dataclass(frozen=True) class TargetData: """ The target data optionally included with a query match. @@ -98,7 +98,7 @@ class TargetData: @beartype -@dataclass +@dataclass(frozen=True) class QueryResult: """ One query match result. @@ -112,7 +112,7 @@ class QueryResult: @beartype -@dataclass +@dataclass(frozen=True) class TargetStatusAndRecord: """ The target status and a target record. diff --git a/src/vws/types.py b/src/vws/types.py index e6f59145a..22e912607 100644 --- a/src/vws/types.py +++ b/src/vws/types.py @@ -5,7 +5,7 @@ from beartype import beartype -@dataclass +@dataclass(frozen=True) @beartype class Response: """ From 05323e4c6d0ca6b1e34ed90dc46de3fb30014c3e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 30 Sep 2024 10:19:44 +0000 Subject: [PATCH 0418/1003] Bump doccmd from 2024.9.26 to 2024.9.27 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.9.26 to 2024.9.27. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.09.26...2024.09.27) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0680b1e1b..19b7ac353 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.49", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.9.26", + "doccmd==2024.9.27", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", From fc7327548f72d495c3b72c3e32cafee14e83798d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 30 Sep 2024 10:25:39 +0000 Subject: [PATCH 0419/1003] Bump pyright from 1.1.382.post0 to 1.1.382.post1 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.382.post0 to 1.1.382.post1. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.382.post0...v1.1.382.post1) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 19b7ac353..35b86716b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.2.4", - "pyright==1.1.382.post0", + "pyright==1.1.382.post1", "pyroma==4.2", "pytest==8.3.3", "pytest-cov==5.0.0", From 262376afbdf65344e92ffd4932b69775492318dd Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 2 Oct 2024 10:51:34 +0100 Subject: [PATCH 0420/1003] Work out minimum Python version so that fewer replacements are needed when we bump the version --- README.rst | 3 ++- docs/source/conf.py | 13 ++++++++++++- docs/source/index.rst | 2 +- 3 files changed, 15 insertions(+), 3 deletions(-) diff --git a/README.rst b/README.rst index ce352e4e5..730535169 100644 --- a/README.rst +++ b/README.rst @@ -13,7 +13,7 @@ Installation pip install vws-python -This is tested on Python 3.12+. Get in touch with +This is tested on Python |minimum-python-version|\+. Get in touch with ``adamdangoor@gmail.com`` if you would like to use this with another language. @@ -78,3 +78,4 @@ documentation `__. :target: https://badge.fury.io/py/VWS-Python .. |Documentation Status| image:: https://readthedocs.org/projects/vws-python/badge/?version=latest :target: https://vws-python.readthedocs.io/en/latest/?badge=latest +.. |minimum-python-version| replace:: 3.12 diff --git a/docs/source/conf.py b/docs/source/conf.py index 9c88cea7d..6f96be9c4 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -6,6 +6,8 @@ import datetime import importlib.metadata +from packaging.specifiers import SpecifierSet + project = "VWS-Python" author = "Adam Dangoor" @@ -39,6 +41,14 @@ _month, _day, _year, *_ = version.split(".") release = f"{_month}.{_day}.{_year}" + +project_metadata = importlib.metadata.metadata(distribution_name=project) +requires_python = project_metadata["Requires-Python"] +specifiers = SpecifierSet(specifiers=requires_python) +(specifier,) = specifiers +assert specifier.operator == ">=" +minimum_python_version = specifier.version + language = "en" # The name of the syntax highlighting style to use. @@ -57,7 +67,7 @@ htmlhelp_basename = "VWSPYTHONdoc" autoclass_content = "init" intersphinx_mapping = { - "python": ("https://docs.python.org/3.12", None), + "python": (f"https://docs.python.org/{minimum_python_version}", None), } nitpicky = True nitpick_ignore = (("py:class", "_io.BytesIO"),) @@ -75,6 +85,7 @@ rst_prolog = f""" .. |project| replace:: {project} .. |release| replace:: {release} +.. |minimum-python-version| replace:: {minimum_python_version} .. |github-owner| replace:: VWS-Python .. |github-repository| replace:: vws-python """ diff --git a/docs/source/index.rst b/docs/source/index.rst index 661814708..3c89de779 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -8,7 +8,7 @@ Installation $ pip install vws-python -This is tested on Python 3.12+. +This is tested on Python |minimum-python-version|\+. Get in touch with ``adamdangoor@gmail.com`` if you would like to use this with another language. Usage From fff2e20c8ab7151e735f9ef01be7438fe32c7fb2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 2 Oct 2024 10:46:33 +0000 Subject: [PATCH 0421/1003] Bump pyright from 1.1.382.post1 to 1.1.383 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.382.post1 to 1.1.383. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.382.post1...v1.1.383) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 35b86716b..76c134517 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.2.4", - "pyright==1.1.382.post1", + "pyright==1.1.383", "pyroma==4.2", "pytest==8.3.3", "pytest-cov==5.0.0", From 44806d048401875a07fe5b014d9e34d3c9b908e0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 3 Oct 2024 10:25:23 +0000 Subject: [PATCH 0422/1003] Bump actionlint-py from 1.7.2.16 to 1.7.3.17 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.7.2.16 to 1.7.3.17. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.7.2.16...v1.7.3.17) --- updated-dependencies: - dependency-name: actionlint-py dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 76c134517..5eb8f84a9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -39,7 +39,7 @@ dependencies = [ "vws-auth-tools", ] optional-dependencies.dev = [ - "actionlint-py==1.7.2.16", + "actionlint-py==1.7.3.17", "check-manifest==0.49", "deptry==0.20.0", "doc8==1.1.2", From f25a4b4f2b5661b676ed5cad6b3cb5950e7c2238 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 3 Oct 2024 10:29:39 +0000 Subject: [PATCH 0423/1003] Bump vulture from 2.12 to 2.13 Bumps [vulture](https://github.com/jendrikseipp/vulture) from 2.12 to 2.13. - [Release notes](https://github.com/jendrikseipp/vulture/releases) - [Changelog](https://github.com/jendrikseipp/vulture/blob/main/CHANGELOG.md) - [Commits](https://github.com/jendrikseipp/vulture/compare/v2.12...v2.13) --- updated-dependencies: - dependency-name: vulture dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5eb8f84a9..f5aa17b71 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -71,7 +71,7 @@ optional-dependencies.dev = [ "sphinxcontrib-spelling==8", "sybil==8.0.0", "types-requests==2.32.0.20240914", - "vulture==2.12", + "vulture==2.13", "vws-python-mock==2024.8.30", "vws-test-fixtures==2023.3.5", ] From e8462d53374bec0483c759802df3a4fc43768631 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 4 Oct 2024 23:40:08 +0100 Subject: [PATCH 0424/1003] Add shfmt to pre-commit --- .pre-commit-config.yaml | 15 +++++++++++++++ pyproject.toml | 1 + 2 files changed, 16 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 621e643b9..424fb2551 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -32,6 +32,8 @@ ci: - vulture-docs - shellcheck - shellcheck-docs + - shfmt + - shfmt-docs default_install_hook_types: [pre-commit, pre-push, commit-msg] repos: @@ -77,6 +79,19 @@ repos: language: system types_or: [markdown, rst] + - id: shfmt + name: shfmt + entry: shfmt --write + language: system + pass_filenames: false + types_or: [shell] + + - id: shfmt-docs + name: shfmt-docs + entry: doccmd --language=shell --language=console --no-pad-file --command="shfmt --write" + language: system + types_or: [markdown, rst] + - id: mypy name: mypy stages: [push] diff --git a/pyproject.toml b/pyproject.toml index f5aa17b71..72d010d30 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -65,6 +65,7 @@ optional-dependencies.dev = [ # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. "shellcheck-py==0.10.0.1", + "shfmt-py==3.7.0.1", "sphinx==8.0.2", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", From cb1a73994bcac505f7f570a42793649e84948410 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 5 Oct 2024 00:25:06 +0100 Subject: [PATCH 0425/1003] Update shfmt command to work on more inputs --- .pre-commit-config.yaml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 424fb2551..df7c059cb 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -81,14 +81,13 @@ repos: - id: shfmt name: shfmt - entry: shfmt --write + entry: shfmt --write --space-redirects --indent=4 language: system - pass_filenames: false types_or: [shell] - id: shfmt-docs name: shfmt-docs - entry: doccmd --language=shell --language=console --no-pad-file --command="shfmt --write" + entry: doccmd --language=shell --language=console --skip-marker=shfmt --no-pad-file --command="shfmt --write --space-redirects --indent=4" language: system types_or: [markdown, rst] From 63e5cbd755ec88ac0880d9ef06076b65ff00ca64 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 13:05:58 +0100 Subject: [PATCH 0426/1003] Start using uv for Python in CI --- .github/workflows/ci.yml | 19 +++++++++++-------- .github/workflows/release.yml | 1 + .github/workflows/windows-ci.yml | 1 + 3 files changed, 13 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6f424e7a3..855fc0b6a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -24,28 +24,31 @@ jobs: steps: - uses: actions/checkout@v4 - - name: "Set up Python" - uses: actions/setup-python@v5 + + - name: Install the latest version of uv + uses: astral-sh/setup-uv@v3 with: - python-version: ${{ matrix.python-version }} + enable-cache: true + + - name: Install Python 3.12 + run: uv python install ${{ matrix.python-version }} # We do not use the cache action as uv is faster than the cache action. - name: "Install dependencies" run: | - curl -LsSf https://astral.sh/uv/install.sh | sh uv pip install --system --upgrade --editable .[dev] - name: "Lint" run: | - pre-commit run --all-files --hook-stage commit --verbose - pre-commit run --all-files --hook-stage push --verbose - pre-commit run --all-files --hook-stage manual --verbose + uv run --all-extras pre-commit run --all-files --hook-stage commit --verbose + uv run --all-extras pre-commit run --all-files --hook-stage push --verbose + uv run --all-extras pre-commit run --all-files --hook-stage manual --verbose - name: "Run tests" run: | # We run tests against "." and not the tests directory as we test the README # and documentation. - pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml + uv run --all-extras pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests/ . --cov-report=xml - name: "Upload coverage to Codecov" uses: "codecov/codecov-action@v4" diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a24d5daff..a0f9e80f5 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -31,6 +31,7 @@ jobs: # https://github.com/stefanzweifel/git-auto-commit-action?tab=readme-ov-file#push-to-protected-branches token: ${{ secrets.RELEASE_PAT }} + # TODO use UV here - name: "Set up Python" uses: actions/setup-python@v5 with: diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index 16bf4706a..bb4fdb566 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -29,6 +29,7 @@ jobs: with: python-version: ${{ matrix.python-version }} + # TODO Here (or maybe get rid of this and use the ci yml?) # We do not use the cache action as uv is faster than the cache action. - name: "Install dependencies" run: | From 82795ca377a55defbfaf7d18082970800c7ce40f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 13:09:04 +0100 Subject: [PATCH 0427/1003] Disable cache for now --- .github/workflows/ci.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 855fc0b6a..83aec1393 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -27,8 +27,6 @@ jobs: - name: Install the latest version of uv uses: astral-sh/setup-uv@v3 - with: - enable-cache: true - name: Install Python 3.12 run: uv python install ${{ matrix.python-version }} From 9b540e7c7712bf3b133dfd05deb8b5b626de9d9b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 13:09:25 +0100 Subject: [PATCH 0428/1003] Remove unnecessary setup --- .github/workflows/ci.yml | 5 ----- 1 file changed, 5 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 83aec1393..e515c9de4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -31,11 +31,6 @@ jobs: - name: Install Python 3.12 run: uv python install ${{ matrix.python-version }} - # We do not use the cache action as uv is faster than the cache action. - - name: "Install dependencies" - run: | - uv pip install --system --upgrade --editable .[dev] - - name: "Lint" run: | uv run --all-extras pre-commit run --all-files --hook-stage commit --verbose From 36f8282322abd23d159e682238f246ae41c5db9f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 13:14:50 +0100 Subject: [PATCH 0429/1003] Remove duplicate Python version spec --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e515c9de4..19856ca36 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -28,7 +28,7 @@ jobs: - name: Install the latest version of uv uses: astral-sh/setup-uv@v3 - - name: Install Python 3.12 + - name: Install Python run: uv python install ${{ matrix.python-version }} - name: "Lint" From e63a99a6e05d226a13ea4f988183ee5a5168f6de Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 13:59:47 +0100 Subject: [PATCH 0430/1003] Use uv in move CI places --- .github/workflows/ci.yml | 4 ++-- .github/workflows/release.yml | 17 ++++++++--------- .github/workflows/windows-ci.yml | 19 +++++++------------ 3 files changed, 17 insertions(+), 23 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 19856ca36..ff6b3002b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -18,14 +18,14 @@ jobs: strategy: matrix: python-version: ["3.12"] - platform: [ubuntu-latest] + platform: ["ubuntu-latest", "windows-latest"] runs-on: ${{ matrix.platform }} steps: - uses: actions/checkout@v4 - - name: Install the latest version of uv + - name: Install uv uses: astral-sh/setup-uv@v3 - name: Install Python diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a0f9e80f5..b7eae4b80 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -31,11 +31,11 @@ jobs: # https://github.com/stefanzweifel/git-auto-commit-action?tab=readme-ov-file#push-to-protected-branches token: ${{ secrets.RELEASE_PAT }} - # TODO use UV here - - name: "Set up Python" - uses: actions/setup-python@v5 - with: - python-version: ${{ matrix.python-version }} + - name: Install uv + uses: astral-sh/setup-uv@v3 + + - name: Install Python + run: uv python install ${{ matrix.python-version }} - name: "Calver calculate version" uses: StephaneBour/actions-calver@master @@ -78,12 +78,11 @@ jobs: - name: Build a binary wheel and a source tarball run: | - # Checkout the latest tag - the one we just created. git fetch --tags git checkout ${{ steps.tag_version.outputs.new_tag }} - python -m pip install build check-wheel-contents - python -m build --sdist --wheel --outdir dist/ . - check-wheel-contents dist/*.whl + uv run pip install build check-wheel-contents + uv run python -m build --sdist --wheel --outdir dist/ . + uv run check-wheel-contents dist/*.whl # We use PyPI trusted publishing rather than a PyPI API token. # See https://github.com/pypa/gh-action-pypi-publish/tree/release/v1/?tab=readme-ov-file#trusted-publishing. diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index bb4fdb566..bbd432c32 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -24,20 +24,15 @@ jobs: steps: - uses: actions/checkout@v4 - - name: "Set up Python" - uses: actions/setup-python@v5 - with: - python-version: ${{ matrix.python-version }} - - # TODO Here (or maybe get rid of this and use the ci yml?) - # We do not use the cache action as uv is faster than the cache action. - - name: "Install dependencies" - run: | - irm https://astral.sh/uv/install.ps1 | iex - uv pip install --system --upgrade --editable .[dev] + + - name: Install uv + uses: astral-sh/setup-uv@v3 + + - name: Install Python + run: uv python install ${{ matrix.python-version }} - name: "Run tests" run: | # We run tests against "." and not the tests directory as we test the README # and documentation. - python -m pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml + uv run pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 10c2f9002322401d3bcf899cf58f8423752a63e1 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 14:06:43 +0100 Subject: [PATCH 0431/1003] Update calling method for shellcheck shell option to be consistent amoung projects --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index df7c059cb..07471f79c 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -41,7 +41,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-case-conflict @@ -68,7 +68,7 @@ repos: - id: shellcheck name: shellcheck - entry: shellcheck --shell bash + entry: shellcheck --shell=bash language: system pass_filenames: false types_or: [shell] From 0d9b3f7e4577662f1fa3b539009666da2792287f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 14:12:35 +0100 Subject: [PATCH 0432/1003] Exclude shellcheck error which prevents it from working on Windows --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 07471f79c..2dcd8d24f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -68,14 +68,14 @@ repos: - id: shellcheck name: shellcheck - entry: shellcheck --shell=bash + entry: shellcheck --shell=bash --exclude=SC1017 language: system pass_filenames: false types_or: [shell] - id: shellcheck-docs name: shellcheck-docs - entry: doccmd --language=shell --language=console --command="shellcheck --shell=bash" + entry: doccmd --language=shell --language=console --command="shellcheck --shell=bash --exclude=SC1017" language: system types_or: [markdown, rst] From db39ad0c9815b1cd64fe00f2aff2e0218db21f12 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 14:20:19 +0100 Subject: [PATCH 0433/1003] Use --all-extras in Windows CI setup --- .github/workflows/windows-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml index bbd432c32..a8d11ed69 100644 --- a/.github/workflows/windows-ci.yml +++ b/.github/workflows/windows-ci.yml @@ -35,4 +35,4 @@ jobs: run: | # We run tests against "." and not the tests directory as we test the README # and documentation. - uv run pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml + uv run --all-extras pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From fe7c11ee7b622adae553b802d20c374bc9c77bbe Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 14:29:11 +0100 Subject: [PATCH 0434/1003] Ignore D004 errors in doc8 so it works on Windows --- pyproject.toml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index 72d010d30..69483b9fa 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -332,6 +332,9 @@ ignore_path = [ "./src/*/_setuptools_scm_version.txt", ] +# See https://github.com/PyCQA/doc8/issues/78 +ignore = [ "D004" ] + [tool.vulture] # Ideally we would limit the paths to the source code where we want to ignore names, # but Vulture does not enable this. From 0c5de9d6b57cba66d47c5f2393c0ac1c7d47bc83 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 14:42:59 +0100 Subject: [PATCH 0435/1003] Try to work around Windows line endings issue --- .gitattributes | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitattributes b/.gitattributes index 00a7b00c9..b5c2d0d58 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1 +1,2 @@ .git_archival.txt export-subst +*.txt text eol=lf From 5bc6c372b2a9529f434f35e4486b312282853099 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 14:44:20 +0100 Subject: [PATCH 0436/1003] Remove duplicate Windows CI setup --- .github/workflows/windows-ci.yml | 38 -------------------------------- 1 file changed, 38 deletions(-) delete mode 100644 .github/workflows/windows-ci.yml diff --git a/.github/workflows/windows-ci.yml b/.github/workflows/windows-ci.yml deleted file mode 100644 index a8d11ed69..000000000 --- a/.github/workflows/windows-ci.yml +++ /dev/null @@ -1,38 +0,0 @@ ---- - -name: Windows CI - -on: - push: - branches: [main] - pull_request: - branches: [main] - schedule: - # * is a special character in YAML so you have to quote this string - # Run at 1:00 every day - - cron: '0 1 * * *' - -jobs: - build: - - strategy: - matrix: - python-version: ["3.12"] - platform: [windows-latest] - - runs-on: ${{ matrix.platform }} - - steps: - - uses: actions/checkout@v4 - - - name: Install uv - uses: astral-sh/setup-uv@v3 - - - name: Install Python - run: uv python install ${{ matrix.python-version }} - - - name: "Run tests" - run: | - # We run tests against "." and not the tests directory as we test the README - # and documentation. - uv run --all-extras pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests . --cov-report=xml From 1cc5ea02c9994487ad92b22378e0a124c36269e9 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 17:09:21 +0100 Subject: [PATCH 0437/1003] Use setup-uv GitHub Action --- .github/workflows/ci.yml | 11 ++++------- .github/workflows/release.yml | 3 --- 2 files changed, 4 insertions(+), 10 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ff6b3002b..497045078 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -28,20 +28,17 @@ jobs: - name: Install uv uses: astral-sh/setup-uv@v3 - - name: Install Python - run: uv python install ${{ matrix.python-version }} - - name: "Lint" run: | - uv run --all-extras pre-commit run --all-files --hook-stage commit --verbose - uv run --all-extras pre-commit run --all-files --hook-stage push --verbose - uv run --all-extras pre-commit run --all-files --hook-stage manual --verbose + uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage commit --verbose + uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage push --verbose + uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage manual --verbose - name: "Run tests" run: | # We run tests against "." and not the tests directory as we test the README # and documentation. - uv run --all-extras pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests/ . --cov-report=xml + uv run --all-extras --python=${{ matrix.python-version }} pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests/ . --cov-report=xml - name: "Upload coverage to Codecov" uses: "codecov/codecov-action@v4" diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index b7eae4b80..c38a38adc 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -34,9 +34,6 @@ jobs: - name: Install uv uses: astral-sh/setup-uv@v3 - - name: Install Python - run: uv python install ${{ matrix.python-version }} - - name: "Calver calculate version" uses: StephaneBour/actions-calver@master id: calver From 105496609fb81ef3960ca3934aba564ede94bff0 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 17:20:45 +0100 Subject: [PATCH 0438/1003] Move release dependencies to pyproject.toml --- .github/workflows/release.yml | 3 +-- pyproject.toml | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c38a38adc..bdca6c419 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -77,8 +77,7 @@ jobs: run: | git fetch --tags git checkout ${{ steps.tag_version.outputs.new_tag }} - uv run pip install build check-wheel-contents - uv run python -m build --sdist --wheel --outdir dist/ . + uv run --extra=release python -m build --sdist --wheel --outdir dist/ . uv run check-wheel-contents dist/*.whl # We use PyPI trusted publishing rather than a PyPI API token. diff --git a/pyproject.toml b/pyproject.toml index 69483b9fa..ca54e17c1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -77,6 +77,7 @@ optional-dependencies.dev = [ "vws-test-fixtures==2023.3.5", ] urls.Documentation = "https://vws-python.readthedocs.io/en/latest/" +optional-dependencies.release = ["build", "check-wheel-contents"] urls.Source = "https://github.com/VWS-Python/vws-python" [tool.setuptools] From 5f5ab26714453475b7d0b546f3796237ee1d3b2b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 17:26:03 +0100 Subject: [PATCH 0439/1003] Ignore release dependency group in deptry --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index ca54e17c1..014a99631 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -287,6 +287,7 @@ ignore = [ [tool.deptry] pep621_dev_dependency_groups = [ "dev", + "release", ] [tool.pyproject-fmt] From b11da61d835d1395e8644cd6d2cfc0ed310d818c Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Sun, 6 Oct 2024 16:28:10 +0000 Subject: [PATCH 0440/1003] [pre-commit.ci lite] apply automatic fixes --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 014a99631..9160b5793 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -76,8 +76,8 @@ optional-dependencies.dev = [ "vws-python-mock==2024.8.30", "vws-test-fixtures==2023.3.5", ] +optional-dependencies.release = [ "build", "check-wheel-contents" ] urls.Documentation = "https://vws-python.readthedocs.io/en/latest/" -optional-dependencies.release = ["build", "check-wheel-contents"] urls.Source = "https://github.com/VWS-Python/vws-python" [tool.setuptools] From 71c7d3b9f10d4bcf77358d7fed864f67f911e969 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 23:07:06 +0100 Subject: [PATCH 0441/1003] Use uv to run actionlint --- .pre-commit-config.yaml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 2dcd8d24f..98066432a 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -7,7 +7,6 @@ ci: # We use system Python, with required dependencies specified in pyproject.toml. # We therefore cannot use those dependencies in pre-commit CI. skip: - - actionlint - check-manifest - deptry - doc8 @@ -61,8 +60,8 @@ repos: hooks: - id: actionlint name: actionlint - entry: actionlint - language: system + entry: uv run --all-extras actionlint + language: python pass_filenames: false types_or: [yaml] From efc20c088c77d65d47411358cc0aafcb41e55618 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 23:08:23 +0100 Subject: [PATCH 0442/1003] Add the uv dependency --- .pre-commit-config.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 98066432a..8ab4682c0 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -64,6 +64,7 @@ repos: language: python pass_filenames: false types_or: [yaml] + additional_dependencies: ["uv"] - id: shellcheck name: shellcheck From 099f7ae93242a791048246cc6d577bae7d6526a0 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 6 Oct 2024 23:37:05 +0100 Subject: [PATCH 0443/1003] Make pre-commit work without activating a virtualenv --- .pre-commit-config.yaml | 138 ++++++++++++++++++++++++---------------- pyproject.toml | 2 +- 2 files changed, 84 insertions(+), 56 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 8ab4682c0..c91592406 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -7,6 +7,7 @@ ci: # We use system Python, with required dependencies specified in pyproject.toml. # We therefore cannot use those dependencies in pre-commit CI. skip: + - actionlint - check-manifest - deptry - doc8 @@ -60,7 +61,7 @@ repos: hooks: - id: actionlint name: actionlint - entry: uv run --all-extras actionlint + entry: uv run --extra=dev actionlint language: python pass_filenames: false types_or: [yaml] @@ -68,182 +69,209 @@ repos: - id: shellcheck name: shellcheck - entry: shellcheck --shell=bash --exclude=SC1017 - language: system + entry: uv run --extra=dev shellcheck --shell=bash --exclude=SC1017 + language: python pass_filenames: false types_or: [shell] + additional_dependencies: ["uv"] - id: shellcheck-docs name: shellcheck-docs - entry: doccmd --language=shell --language=console --command="shellcheck --shell=bash --exclude=SC1017" - language: system + entry: uv run --extra=dev doccmd --language=shell --language=console --command="shellcheck --shell=bash --exclude=SC1017" + language: python types_or: [markdown, rst] + additional_dependencies: ["uv"] - id: shfmt name: shfmt - entry: shfmt --write --space-redirects --indent=4 - language: system + entry: uv run --extra=dev shfmt --write --space-redirects --indent=4 + language: python types_or: [shell] + additional_dependencies: ["uv"] - id: shfmt-docs name: shfmt-docs - entry: doccmd --language=shell --language=console --skip-marker=shfmt --no-pad-file --command="shfmt --write --space-redirects --indent=4" - language: system + entry: uv run --extra=dev doccmd --language=shell --language=console --skip-marker=shfmt --no-pad-file --command="shfmt --write --space-redirects --indent=4" + language: python types_or: [markdown, rst] + additional_dependencies: ["uv"] - id: mypy name: mypy stages: [push] - entry: python -m mypy . - language: system + entry: uv run --extra=dev -m mypy . + language: python types_or: [python, toml] pass_filenames: false + additional_dependencies: ["uv"] - id: mypy-docs name: mypy-docs stages: [push] - entry: doccmd --language=python --command="mypy" - language: system + entry: uv run --extra=dev doccmd --language=python --command="mypy" + language: python types_or: [markdown, rst, python, toml] + additional_dependencies: ["uv"] - id: check-manifest name: check-manifest stages: [push] - entry: python -m check_manifest . - language: system + entry: uv run --extra=dev -m check_manifest . + language: python pass_filenames: false + additional_dependencies: ["uv"] - id: pyright name: pyright stages: [push] - entry: python -m pyright . - language: system + entry: uv run --extra=dev -m pyright . + language: python types_or: [python, toml] pass_filenames: false + additional_dependencies: ["uv"] - id: pyright-docs name: pyright-docs stages: [push] - entry: doccmd --language=python --command="pyright" - language: system + entry: uv run --extra=dev doccmd --language=python --command="pyright" + language: python types_or: [markdown, rst, python, toml] + additional_dependencies: ["uv"] - id: vulture name: vulture - entry: python -m vulture . - language: system + entry: uv run --extra=dev -m vulture . + language: python types_or: [python] pass_filenames: false + additional_dependencies: ["uv"] - id: vulture-docs name: vulture docs - entry: doccmd --language=python --command="vulture" - language: system + entry: uv run --extra=dev doccmd --language=python --command="vulture" + language: python types_or: [markdown, rst] + additional_dependencies: ["uv"] - id: pyroma name: pyroma - entry: python -m pyroma --min 10 . - language: system + entry: uv run --extra=dev -m pyroma --min 10 . + language: python pass_filenames: false types_or: [toml] + additional_dependencies: ["uv"] - id: deptry name: deptry - entry: python -m deptry src/ - language: system + entry: uv run --extra=dev -m deptry src/ + language: python pass_filenames: false + additional_dependencies: ["uv"] - id: pylint name: pylint - entry: python -m pylint *.py src/ tests/ docs/ - language: system + entry: uv run --extra=dev -m pylint *.py src/ tests/ docs/ + language: python stages: [manual] pass_filenames: false + additional_dependencies: ["uv"] - id: pylint-docs name: pylint-docs - entry: doccmd --language=python --command="pylint" - language: system + entry: uv run --extra=dev doccmd --language=python --command="pylint" + language: python stages: [manual] types_or: [markdown, rst, python, toml] + additional_dependencies: ["uv"] - id: ruff-check-fix name: Ruff check fix - entry: python -m ruff check --fix - language: system + entry: uv run --extra=dev -m ruff check --fix + language: python types_or: [python] + additional_dependencies: ["uv"] - id: ruff-check-fix-docs name: Ruff check fix docs - entry: doccmd --language=python --command="ruff check --fix" - language: system + entry: uv run --extra=dev doccmd --language=python --command="ruff check --fix" + language: python types_or: [markdown, rst] + additional_dependencies: ["uv"] - id: ruff-format-fix name: Ruff format - entry: python -m ruff format - language: system + entry: uv run --extra=dev -m ruff format + language: python types_or: [python] + additional_dependencies: ["uv"] - id: ruff-format-fix-docs name: Ruff format docs - entry: doccmd --language=python --no-pad-file --command="ruff format" - language: system + entry: uv run --extra=dev doccmd --language=python --no-pad-file --command="ruff format" + language: python types_or: [markdown, rst] + additional_dependencies: ["uv"] - id: doc8 name: doc8 - entry: python -m doc8 - language: system + entry: uv run --extra=dev -m doc8 + language: python types_or: [rst] + additional_dependencies: ["uv"] - id: interrogate name: interrogate - entry: python -m interrogate - language: system + entry: uv run --extra=dev -m interrogate + language: python types_or: [python] + additional_dependencies: ["uv"] - id: interrogate-docs name: interrogate docs - entry: doccmd --language=python --command="interrogate" - language: system + entry: uv run --extra=dev doccmd --language=python --command="interrogate" + language: python types_or: [markdown, rst] + additional_dependencies: ["uv"] - id: pyproject-fmt-fix name: pyproject-fmt - entry: pyproject-fmt - language: system + entry: uv run --extra=dev pyproject-fmt + language: python types_or: [toml] files: pyproject.toml + additional_dependencies: ["uv"] - id: linkcheck name: linkcheck - entry: make -C docs/ linkcheck SPHINXOPTS=-W - language: system + entry: uv run --extra=dev sphinx-build -M clean docs/source/ docs/build/ -W && uv run --extra=dev sphinx-build -M linkcheck docs/source/ docs/build/ -W + language: python types_or: [rst] stages: [manual] pass_filenames: false + additional_dependencies: ["uv"] - id: spelling name: spelling - entry: make -C docs/ spelling SPHINXOPTS=-W - language: system + entry: uv run --extra=dev sphinx-build -M clean docs/source/ docs/build/ -W && uv run --extra=dev sphinx-build -M spelling docs/source/ docs/build/ -W + language: python types_or: [rst] stages: [manual] pass_filenames: false + additional_dependencies: ["uv"] - id: docs name: Build Documentation - entry: make docs - language: system + entry: uv run --extra=dev sphinx-build -M clean docs/source/ docs/build/ -W && uv run --extra=dev sphinx-build -M html docs/source/ docs/build/ -W + language: python stages: [manual] pass_filenames: false + additional_dependencies: ["uv"] - id: pyright-verifytypes name: pyright-verifytypes stages: [push] - entry: python -m pyright --verifytypes vws - language: system + entry: uv run --extra=dev -m pyright --verifytypes vws + language: python pass_filenames: false types_or: [python] + additional_dependencies: ["uv"] diff --git a/pyproject.toml b/pyproject.toml index 9160b5793..d1619c959 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -50,7 +50,7 @@ optional-dependencies.dev = [ "mypy==1.11.2", "pre-commit==3.8.0", "pydocstyle==6.3", - "pyenchant==3.2.2", + "pyenchant==3.3.0rc1", "pygments==2.18.0", "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", From 7775e637ed1edcc8bbacab115de05940effab608 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 7 Oct 2024 10:01:51 +0100 Subject: [PATCH 0444/1003] Bump pyenchant to a macOS ARM compatible RC --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9160b5793..d1619c959 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -50,7 +50,7 @@ optional-dependencies.dev = [ "mypy==1.11.2", "pre-commit==3.8.0", "pydocstyle==6.3", - "pyenchant==3.2.2", + "pyenchant==3.3.0rc1", "pygments==2.18.0", "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", From 6407bd18c983716d4ce4de5a67bc57c464d9320f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 7 Oct 2024 10:38:05 +0100 Subject: [PATCH 0445/1003] Update pre-commit config --- .pre-commit-config.yaml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c91592406..298105352 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -98,7 +98,7 @@ repos: - id: mypy name: mypy - stages: [push] + stages: [pre-push] entry: uv run --extra=dev -m mypy . language: python types_or: [python, toml] @@ -107,7 +107,7 @@ repos: - id: mypy-docs name: mypy-docs - stages: [push] + stages: [pre-push] entry: uv run --extra=dev doccmd --language=python --command="mypy" language: python types_or: [markdown, rst, python, toml] @@ -115,7 +115,7 @@ repos: - id: check-manifest name: check-manifest - stages: [push] + stages: [pre-push] entry: uv run --extra=dev -m check_manifest . language: python pass_filenames: false @@ -123,7 +123,7 @@ repos: - id: pyright name: pyright - stages: [push] + stages: [pre-push] entry: uv run --extra=dev -m pyright . language: python types_or: [python, toml] @@ -132,7 +132,7 @@ repos: - id: pyright-docs name: pyright-docs - stages: [push] + stages: [pre-push] entry: uv run --extra=dev doccmd --language=python --command="pyright" language: python types_or: [markdown, rst, python, toml] @@ -269,7 +269,7 @@ repos: - id: pyright-verifytypes name: pyright-verifytypes - stages: [push] + stages: [pre-push] entry: uv run --extra=dev -m pyright --verifytypes vws language: python pass_filenames: false From 195f9b3520c851845c725af0063ba0dbdba3ecc3 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 7 Oct 2024 10:40:44 +0100 Subject: [PATCH 0446/1003] Use new hook stage names --- .github/workflows/ci.yml | 4 ++-- docs/source/contributing.rst | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 497045078..a0823870e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -30,8 +30,8 @@ jobs: - name: "Lint" run: | - uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage commit --verbose - uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage push --verbose + uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage pre-commit --verbose + uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage pre-push --verbose uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage manual --verbose - name: "Run tests" diff --git a/docs/source/contributing.rst b/docs/source/contributing.rst index 2a61da727..21e5dbe82 100644 --- a/docs/source/contributing.rst +++ b/docs/source/contributing.rst @@ -40,8 +40,8 @@ Run lint tools either by committing, or with: .. code-block:: console - $ pre-commit run --all-files --hook-stage commit --verbose - $ pre-commit run --all-files --hook-stage push --verbose + $ pre-commit run --all-files --hook-stage pre-commit --verbose + $ pre-commit run --all-files --hook-stage pre-push --verbose $ pre-commit run --all-files --hook-stage manual --verbose .. _Homebrew: https://brew.sh From 83b8110112ebaeed1da3496b5c1475706d0a2bc9 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 7 Oct 2024 11:18:12 +0100 Subject: [PATCH 0447/1003] Simplify docs setup --- .pre-commit-config.yaml | 6 +++--- docs/Makefile | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 298105352..ef2edf370 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -243,7 +243,7 @@ repos: - id: linkcheck name: linkcheck - entry: uv run --extra=dev sphinx-build -M clean docs/source/ docs/build/ -W && uv run --extra=dev sphinx-build -M linkcheck docs/source/ docs/build/ -W + entry: make -C docs/ linkcheck SPHINXOPTS=-W language: python types_or: [rst] stages: [manual] @@ -252,7 +252,7 @@ repos: - id: spelling name: spelling - entry: uv run --extra=dev sphinx-build -M clean docs/source/ docs/build/ -W && uv run --extra=dev sphinx-build -M spelling docs/source/ docs/build/ -W + entry: make -C docs/ spelling SPHINXOPTS=-W language: python types_or: [rst] stages: [manual] @@ -261,7 +261,7 @@ repos: - id: docs name: Build Documentation - entry: uv run --extra=dev sphinx-build -M clean docs/source/ docs/build/ -W && uv run --extra=dev sphinx-build -M html docs/source/ docs/build/ -W + entry: make docs language: python stages: [manual] pass_filenames: false diff --git a/docs/Makefile b/docs/Makefile index 6225d81e0..e8f3118ce 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -17,4 +17,4 @@ help: # Catch-all target: route all unknown targets to Sphinx using the new # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). %: Makefile - @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) + @uv run --extra=dev $(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) From 54cdd7f9b86bd10ef8484f4f9256e22513a99a2a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 7 Oct 2024 11:19:54 +0100 Subject: [PATCH 0448/1003] Make it possible to run docs help without virtualenv --- docs/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/Makefile b/docs/Makefile index e8f3118ce..15e9c44b1 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -10,7 +10,7 @@ BUILDDIR = build # Put it first so that "make" without argument is like "make help". help: - @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) + @uv run --extra=dev $(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) .PHONY: help Makefile From f8d59b51c22c4110cbb9ab0ff2a004159127d313 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 7 Oct 2024 10:40:00 +0000 Subject: [PATCH 0449/1003] Bump pre-commit from 3.8.0 to 4.0.0 Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 3.8.0 to 4.0.0. - [Release notes](https://github.com/pre-commit/pre-commit/releases) - [Changelog](https://github.com/pre-commit/pre-commit/blob/main/CHANGELOG.md) - [Commits](https://github.com/pre-commit/pre-commit/compare/v3.8.0...v4.0.0) --- updated-dependencies: - dependency-name: pre-commit dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d1619c959..82c5d548c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "furo==2024.8.6", "interrogate==1.7.0", "mypy==1.11.2", - "pre-commit==3.8.0", + "pre-commit==4.0.0", "pydocstyle==6.3", "pyenchant==3.3.0rc1", "pygments==2.18.0", From 87b670f930bd9fb1f1d3d268fcc4d1e9e08df08d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 7 Oct 2024 10:46:42 +0000 Subject: [PATCH 0450/1003] Bump ruff from 0.6.8 to 0.6.9 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.6.8 to 0.6.9. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.6.8...0.6.9) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 82c5d548c..99059f736 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ optional-dependencies.dev = [ "pytest==8.3.3", "pytest-cov==5.0.0", "pyyaml==6.0.2", - "ruff==0.6.8", + "ruff==0.6.9", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From adf881808c0d5dcce241c8ead6a15dc0c2e97c61 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 7 Oct 2024 10:57:10 +0000 Subject: [PATCH 0451/1003] Bump doccmd from 2024.9.27 to 2024.10.6 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.9.27 to 2024.10.6. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.09.27...2024.10.06) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 99059f736..1a9fcd24e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.49", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.9.27", + "doccmd==2024.10.6", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", From 08f911851937987f6bd30e77a922b391ee998766 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 7 Oct 2024 13:18:52 +0100 Subject: [PATCH 0452/1003] Use Sphinx feature to simplify setting copyright --- docs/source/conf.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 6f96be9c4..0fa6f6f69 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -3,7 +3,6 @@ Configuration for Sphinx. """ -import datetime import importlib.metadata from packaging.specifiers import SpecifierSet @@ -24,8 +23,7 @@ source_suffix = ".rst" master_doc = "index" -year = datetime.datetime.now(tz=datetime.UTC).year -project_copyright = f"{year}, {author}" +project_copyright = f"%Y, {author}" # Exclude the prompt from copied code with sphinx_copybutton. # https://sphinx-copybutton.readthedocs.io/en/latest/use.html#automatic-exclusion-of-prompts-from-the-copies. From e7e5f48254aa657cb0425d6912209dc101932da6 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 7 Oct 2024 22:53:05 +0100 Subject: [PATCH 0453/1003] Separate test and lint CI build --- .github/workflows/ci.yml | 9 --------- .github/workflows/lint.yml | 38 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 38 insertions(+), 9 deletions(-) create mode 100644 .github/workflows/lint.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a0823870e..f7f4e9bf1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -28,12 +28,6 @@ jobs: - name: Install uv uses: astral-sh/setup-uv@v3 - - name: "Lint" - run: | - uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage pre-commit --verbose - uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage pre-push --verbose - uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage manual --verbose - - name: "Run tests" run: | # We run tests against "." and not the tests directory as we test the README @@ -45,6 +39,3 @@ jobs: with: fail_ci_if_error: true token: ${{ secrets.CODECOV_TOKEN }} - - - uses: pre-commit-ci/lite-action@v1.0.3 - if: always() diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml new file mode 100644 index 000000000..a3caafacf --- /dev/null +++ b/.github/workflows/lint.yml @@ -0,0 +1,38 @@ +--- + +name: CI + +on: + push: + branches: [main] + pull_request: + branches: [main] + schedule: + # * is a special character in YAML so you have to quote this string + # Run at 1:00 every day + - cron: '0 1 * * *' + +jobs: + build: + + strategy: + matrix: + python-version: ["3.12"] + platform: ["ubuntu-latest", "windows-latest"] + + runs-on: ${{ matrix.platform }} + + steps: + - uses: actions/checkout@v4 + + - name: Install uv + uses: astral-sh/setup-uv@v3 + + - name: "Lint" + run: | + uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage pre-commit --verbose + uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage pre-push --verbose + uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage manual --verbose + + - uses: pre-commit-ci/lite-action@v1.0.3 + if: always() From 263e2bcf9db8271446c896020f99cf70ce40b368 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 7 Oct 2024 22:55:17 +0100 Subject: [PATCH 0454/1003] Change build names --- .github/workflows/ci.yml | 2 +- .github/workflows/lint.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index f7f4e9bf1..ad53968be 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,6 +1,6 @@ --- -name: CI +name: Test on: push: diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index a3caafacf..41109f7d5 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -1,6 +1,6 @@ --- -name: CI +name: Lint on: push: From 526817e71375263fbe3f079faf168cd3e4cee666 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 8 Oct 2024 02:02:02 +0100 Subject: [PATCH 0455/1003] Pin build and check-wheel-contents --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1a9fcd24e..f3fd720a3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -76,7 +76,7 @@ optional-dependencies.dev = [ "vws-python-mock==2024.8.30", "vws-test-fixtures==2023.3.5", ] -optional-dependencies.release = [ "build", "check-wheel-contents" ] +optional-dependencies.release = [ "build==1.2.2.post1", "check-wheel-contents==0.6.0" ] urls.Documentation = "https://vws-python.readthedocs.io/en/latest/" urls.Source = "https://github.com/VWS-Python/vws-python" From 287c006f09ef0653622c0cac374010f1bcd2a673 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 8 Oct 2024 02:55:10 +0100 Subject: [PATCH 0456/1003] Use uv instead of 'build' for building --- .github/workflows/release.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index bdca6c419..25de8e0ee 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -77,8 +77,8 @@ jobs: run: | git fetch --tags git checkout ${{ steps.tag_version.outputs.new_tag }} - uv run --extra=release python -m build --sdist --wheel --outdir dist/ . - uv run check-wheel-contents dist/*.whl + uv build --sdist --wheel --out-dir dist/ + uv run --extra=release check-wheel-contents dist/*.whl # We use PyPI trusted publishing rather than a PyPI API token. # See https://github.com/pypa/gh-action-pypi-publish/tree/release/v1/?tab=readme-ov-file#trusted-publishing. From 8ae14320b9804244d24c387dd473b04384c0d732 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 8 Oct 2024 02:56:38 +0100 Subject: [PATCH 0457/1003] Use uv instead of 'build' for building --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f3fd720a3..b458a89db 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -76,7 +76,7 @@ optional-dependencies.dev = [ "vws-python-mock==2024.8.30", "vws-test-fixtures==2023.3.5", ] -optional-dependencies.release = [ "build==1.2.2.post1", "check-wheel-contents==0.6.0" ] +optional-dependencies.release = [ "check-wheel-contents==0.6.0" ] urls.Documentation = "https://vws-python.readthedocs.io/en/latest/" urls.Source = "https://github.com/VWS-Python/vws-python" From 2cf3c493d22eac70f5227883df28fb4ff958c2ed Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 8 Oct 2024 04:12:36 +0100 Subject: [PATCH 0458/1003] Use environment variables to remove duplication in uv commands --- .github/workflows/ci.yml | 2 +- .github/workflows/lint.yml | 8 +++++--- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ad53968be..9c36d9c0d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -32,7 +32,7 @@ jobs: run: | # We run tests against "." and not the tests directory as we test the README # and documentation. - uv run --all-extras --python=${{ matrix.python-version }} pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests/ . --cov-report=xml + uv run --extra=dev --python=${{ matrix.python-version }} pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests/ . --cov-report=xml - name: "Upload coverage to Codecov" uses: "codecov/codecov-action@v4" diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 41109f7d5..9c52e9b2e 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -30,9 +30,11 @@ jobs: - name: "Lint" run: | - uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage pre-commit --verbose - uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage pre-push --verbose - uv run --all-extras --python=${{ matrix.python-version }} pre-commit run --all-files --hook-stage manual --verbose + uv run --extra=dev pre-commit run --all-files --hook-stage pre-commit --verbose + uv run --extra=dev pre-commit run --all-files --hook-stage pre-push --verbose + uv run --extra=dev pre-commit run --all-files --hook-stage manual --verbose + env: + UV_PYTHON: ${{ matrix.python-version }} - uses: pre-commit-ci/lite-action@v1.0.3 if: always() From 462db7033ad09f67c393f8bddc203ff4280646eb Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 8 Oct 2024 04:23:41 +0100 Subject: [PATCH 0459/1003] Update release process to support >= 10 releases in a day --- .github/workflows/release.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 25de8e0ee..2074d8655 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -43,11 +43,17 @@ jobs: env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + - name: Get the changelog underline + id: changelog_underline + run: | + underline="$(echo "${{ steps.calver.outputs.release }}" | tr -c '\n' '-')" + echo "underline=${underline}" >> "$GITHUB_OUTPUT" + - name: "Update changelog" uses: jacobtomlinson/gha-find-replace@v3 with: find: "Next\n----" - replace: "Next\n----\n\n${{ steps.calver.outputs.release }}\n------------" + replace: "Next\n----\n\n${{ steps.calver.outputs.release }}\n${{ steps.changelog_underline.outputs.underline }}" include: "CHANGELOG.rst" regex: false From 2e78c52033aeff5f652e3857580992985bac9763 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 8 Oct 2024 05:00:25 +0100 Subject: [PATCH 0460/1003] Format some yaml files --- .github/dependabot.yml | 21 +- .pre-commit-config.yaml | 483 ++++++++++++++++++++-------------------- 2 files changed, 253 insertions(+), 251 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index a04c486d6..76027ef36 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -1,12 +1,13 @@ +--- version: 2 updates: -- package-ecosystem: pip - directory: "/" - schedule: - interval: daily - open-pull-requests-limit: 10 -- package-ecosystem: "github-actions" - directory: "/" - schedule: - interval: daily - open-pull-requests-limit: 10 + - package-ecosystem: pip + directory: "/" + schedule: + interval: daily + open-pull-requests-limit: 10 + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: daily + open-pull-requests-limit: 10 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ef2edf370..b0538c0b1 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,277 +1,278 @@ +--- fail_fast: true # See https://pre-commit.com for more information # See https://pre-commit.com/hooks.html for more hooks ci: - # We use system Python, with required dependencies specified in pyproject.toml. - # We therefore cannot use those dependencies in pre-commit CI. - skip: - - actionlint - - check-manifest - - deptry - - doc8 - - docs - - interrogate - - interrogate-docs - - linkcheck - - mypy - - mypy-docs - - pylint - - pyproject-fmt-fix - - pyright - - pyright-docs - - pyright-verifytypes - - pyroma - - ruff-check-fix - - ruff-check-fix-docs - - ruff-format-fix - - ruff-format-fix-docs - - spelling - - vulture - - vulture-docs - - shellcheck - - shellcheck-docs - - shfmt - - shfmt-docs + # We use system Python, with required dependencies specified in pyproject.toml. + # We therefore cannot use those dependencies in pre-commit CI. + skip: + - actionlint + - check-manifest + - deptry + - doc8 + - docs + - interrogate + - interrogate-docs + - linkcheck + - mypy + - mypy-docs + - pylint + - pyproject-fmt-fix + - pyright + - pyright-docs + - pyright-verifytypes + - pyroma + - ruff-check-fix + - ruff-check-fix-docs + - ruff-format-fix + - ruff-format-fix-docs + - spelling + - vulture + - vulture-docs + - shellcheck + - shellcheck-docs + - shfmt + - shfmt-docs default_install_hook_types: [pre-commit, pre-push, commit-msg] repos: -- repo: meta - hooks: - - id: check-useless-excludes -- repo: https://github.com/pre-commit/pre-commit-hooks - rev: v5.0.0 - hooks: - - id: check-added-large-files - - id: check-case-conflict - - id: check-executables-have-shebangs - - id: check-merge-conflict - - id: check-shebang-scripts-are-executable - - id: check-symlinks - - id: check-json - - id: check-toml - - id: check-vcs-permalinks - - id: check-yaml - - id: end-of-file-fixer - - id: file-contents-sorter - files: spelling_private_dict\.txt$ - - id: trailing-whitespace -- repo: local - hooks: - - id: actionlint - name: actionlint - entry: uv run --extra=dev actionlint - language: python - pass_filenames: false - types_or: [yaml] - additional_dependencies: ["uv"] + - repo: meta + hooks: + - id: check-useless-excludes + - repo: https://github.com/pre-commit/pre-commit-hooks + rev: v5.0.0 + hooks: + - id: check-added-large-files + - id: check-case-conflict + - id: check-executables-have-shebangs + - id: check-merge-conflict + - id: check-shebang-scripts-are-executable + - id: check-symlinks + - id: check-json + - id: check-toml + - id: check-vcs-permalinks + - id: check-yaml + - id: end-of-file-fixer + - id: file-contents-sorter + files: spelling_private_dict\.txt$ + - id: trailing-whitespace + - repo: local + hooks: + - id: actionlint + name: actionlint + entry: uv run --extra=dev actionlint + language: python + pass_filenames: false + types_or: [yaml] + additional_dependencies: ["uv"] - - id: shellcheck - name: shellcheck - entry: uv run --extra=dev shellcheck --shell=bash --exclude=SC1017 - language: python - pass_filenames: false - types_or: [shell] - additional_dependencies: ["uv"] + - id: shellcheck + name: shellcheck + entry: uv run --extra=dev shellcheck --shell=bash --exclude=SC1017 + language: python + pass_filenames: false + types_or: [shell] + additional_dependencies: ["uv"] - - id: shellcheck-docs - name: shellcheck-docs - entry: uv run --extra=dev doccmd --language=shell --language=console --command="shellcheck --shell=bash --exclude=SC1017" - language: python - types_or: [markdown, rst] - additional_dependencies: ["uv"] + - id: shellcheck-docs + name: shellcheck-docs + entry: uv run --extra=dev doccmd --language=shell --language=console --command="shellcheck --shell=bash --exclude=SC1017" + language: python + types_or: [markdown, rst] + additional_dependencies: ["uv"] - - id: shfmt - name: shfmt - entry: uv run --extra=dev shfmt --write --space-redirects --indent=4 - language: python - types_or: [shell] - additional_dependencies: ["uv"] + - id: shfmt + name: shfmt + entry: uv run --extra=dev shfmt --write --space-redirects --indent=4 + language: python + types_or: [shell] + additional_dependencies: ["uv"] - - id: shfmt-docs - name: shfmt-docs - entry: uv run --extra=dev doccmd --language=shell --language=console --skip-marker=shfmt --no-pad-file --command="shfmt --write --space-redirects --indent=4" - language: python - types_or: [markdown, rst] - additional_dependencies: ["uv"] + - id: shfmt-docs + name: shfmt-docs + entry: uv run --extra=dev doccmd --language=shell --language=console --skip-marker=shfmt --no-pad-file --command="shfmt --write --space-redirects --indent=4" + language: python + types_or: [markdown, rst] + additional_dependencies: ["uv"] - - id: mypy - name: mypy - stages: [pre-push] - entry: uv run --extra=dev -m mypy . - language: python - types_or: [python, toml] - pass_filenames: false - additional_dependencies: ["uv"] + - id: mypy + name: mypy + stages: [pre-push] + entry: uv run --extra=dev -m mypy . + language: python + types_or: [python, toml] + pass_filenames: false + additional_dependencies: ["uv"] - - id: mypy-docs - name: mypy-docs - stages: [pre-push] - entry: uv run --extra=dev doccmd --language=python --command="mypy" - language: python - types_or: [markdown, rst, python, toml] - additional_dependencies: ["uv"] + - id: mypy-docs + name: mypy-docs + stages: [pre-push] + entry: uv run --extra=dev doccmd --language=python --command="mypy" + language: python + types_or: [markdown, rst, python, toml] + additional_dependencies: ["uv"] - - id: check-manifest - name: check-manifest - stages: [pre-push] - entry: uv run --extra=dev -m check_manifest . - language: python - pass_filenames: false - additional_dependencies: ["uv"] + - id: check-manifest + name: check-manifest + stages: [pre-push] + entry: uv run --extra=dev -m check_manifest . + language: python + pass_filenames: false + additional_dependencies: ["uv"] - - id: pyright - name: pyright - stages: [pre-push] - entry: uv run --extra=dev -m pyright . - language: python - types_or: [python, toml] - pass_filenames: false - additional_dependencies: ["uv"] + - id: pyright + name: pyright + stages: [pre-push] + entry: uv run --extra=dev -m pyright . + language: python + types_or: [python, toml] + pass_filenames: false + additional_dependencies: ["uv"] - - id: pyright-docs - name: pyright-docs - stages: [pre-push] - entry: uv run --extra=dev doccmd --language=python --command="pyright" - language: python - types_or: [markdown, rst, python, toml] - additional_dependencies: ["uv"] + - id: pyright-docs + name: pyright-docs + stages: [pre-push] + entry: uv run --extra=dev doccmd --language=python --command="pyright" + language: python + types_or: [markdown, rst, python, toml] + additional_dependencies: ["uv"] - - id: vulture - name: vulture - entry: uv run --extra=dev -m vulture . - language: python - types_or: [python] - pass_filenames: false - additional_dependencies: ["uv"] + - id: vulture + name: vulture + entry: uv run --extra=dev -m vulture . + language: python + types_or: [python] + pass_filenames: false + additional_dependencies: ["uv"] - - id: vulture-docs - name: vulture docs - entry: uv run --extra=dev doccmd --language=python --command="vulture" - language: python - types_or: [markdown, rst] - additional_dependencies: ["uv"] + - id: vulture-docs + name: vulture docs + entry: uv run --extra=dev doccmd --language=python --command="vulture" + language: python + types_or: [markdown, rst] + additional_dependencies: ["uv"] - - id: pyroma - name: pyroma - entry: uv run --extra=dev -m pyroma --min 10 . - language: python - pass_filenames: false - types_or: [toml] - additional_dependencies: ["uv"] + - id: pyroma + name: pyroma + entry: uv run --extra=dev -m pyroma --min 10 . + language: python + pass_filenames: false + types_or: [toml] + additional_dependencies: ["uv"] - - id: deptry - name: deptry - entry: uv run --extra=dev -m deptry src/ - language: python - pass_filenames: false - additional_dependencies: ["uv"] + - id: deptry + name: deptry + entry: uv run --extra=dev -m deptry src/ + language: python + pass_filenames: false + additional_dependencies: ["uv"] - - id: pylint - name: pylint - entry: uv run --extra=dev -m pylint *.py src/ tests/ docs/ - language: python - stages: [manual] - pass_filenames: false - additional_dependencies: ["uv"] + - id: pylint + name: pylint + entry: uv run --extra=dev -m pylint *.py src/ tests/ docs/ + language: python + stages: [manual] + pass_filenames: false + additional_dependencies: ["uv"] - - id: pylint-docs - name: pylint-docs - entry: uv run --extra=dev doccmd --language=python --command="pylint" - language: python - stages: [manual] - types_or: [markdown, rst, python, toml] - additional_dependencies: ["uv"] + - id: pylint-docs + name: pylint-docs + entry: uv run --extra=dev doccmd --language=python --command="pylint" + language: python + stages: [manual] + types_or: [markdown, rst, python, toml] + additional_dependencies: ["uv"] - - id: ruff-check-fix - name: Ruff check fix - entry: uv run --extra=dev -m ruff check --fix - language: python - types_or: [python] - additional_dependencies: ["uv"] + - id: ruff-check-fix + name: Ruff check fix + entry: uv run --extra=dev -m ruff check --fix + language: python + types_or: [python] + additional_dependencies: ["uv"] - - id: ruff-check-fix-docs - name: Ruff check fix docs - entry: uv run --extra=dev doccmd --language=python --command="ruff check --fix" - language: python - types_or: [markdown, rst] - additional_dependencies: ["uv"] + - id: ruff-check-fix-docs + name: Ruff check fix docs + entry: uv run --extra=dev doccmd --language=python --command="ruff check --fix" + language: python + types_or: [markdown, rst] + additional_dependencies: ["uv"] - - id: ruff-format-fix - name: Ruff format - entry: uv run --extra=dev -m ruff format - language: python - types_or: [python] - additional_dependencies: ["uv"] + - id: ruff-format-fix + name: Ruff format + entry: uv run --extra=dev -m ruff format + language: python + types_or: [python] + additional_dependencies: ["uv"] - - id: ruff-format-fix-docs - name: Ruff format docs - entry: uv run --extra=dev doccmd --language=python --no-pad-file --command="ruff format" - language: python - types_or: [markdown, rst] - additional_dependencies: ["uv"] + - id: ruff-format-fix-docs + name: Ruff format docs + entry: uv run --extra=dev doccmd --language=python --no-pad-file --command="ruff format" + language: python + types_or: [markdown, rst] + additional_dependencies: ["uv"] - - id: doc8 - name: doc8 - entry: uv run --extra=dev -m doc8 - language: python - types_or: [rst] - additional_dependencies: ["uv"] + - id: doc8 + name: doc8 + entry: uv run --extra=dev -m doc8 + language: python + types_or: [rst] + additional_dependencies: ["uv"] - - id: interrogate - name: interrogate - entry: uv run --extra=dev -m interrogate - language: python - types_or: [python] - additional_dependencies: ["uv"] + - id: interrogate + name: interrogate + entry: uv run --extra=dev -m interrogate + language: python + types_or: [python] + additional_dependencies: ["uv"] - - id: interrogate-docs - name: interrogate docs - entry: uv run --extra=dev doccmd --language=python --command="interrogate" - language: python - types_or: [markdown, rst] - additional_dependencies: ["uv"] + - id: interrogate-docs + name: interrogate docs + entry: uv run --extra=dev doccmd --language=python --command="interrogate" + language: python + types_or: [markdown, rst] + additional_dependencies: ["uv"] - - id: pyproject-fmt-fix - name: pyproject-fmt - entry: uv run --extra=dev pyproject-fmt - language: python - types_or: [toml] - files: pyproject.toml - additional_dependencies: ["uv"] + - id: pyproject-fmt-fix + name: pyproject-fmt + entry: uv run --extra=dev pyproject-fmt + language: python + types_or: [toml] + files: pyproject.toml + additional_dependencies: ["uv"] - - id: linkcheck - name: linkcheck - entry: make -C docs/ linkcheck SPHINXOPTS=-W - language: python - types_or: [rst] - stages: [manual] - pass_filenames: false - additional_dependencies: ["uv"] + - id: linkcheck + name: linkcheck + entry: make -C docs/ linkcheck SPHINXOPTS=-W + language: python + types_or: [rst] + stages: [manual] + pass_filenames: false + additional_dependencies: ["uv"] - - id: spelling - name: spelling - entry: make -C docs/ spelling SPHINXOPTS=-W - language: python - types_or: [rst] - stages: [manual] - pass_filenames: false - additional_dependencies: ["uv"] + - id: spelling + name: spelling + entry: make -C docs/ spelling SPHINXOPTS=-W + language: python + types_or: [rst] + stages: [manual] + pass_filenames: false + additional_dependencies: ["uv"] - - id: docs - name: Build Documentation - entry: make docs - language: python - stages: [manual] - pass_filenames: false - additional_dependencies: ["uv"] + - id: docs + name: Build Documentation + entry: make docs + language: python + stages: [manual] + pass_filenames: false + additional_dependencies: ["uv"] - - id: pyright-verifytypes - name: pyright-verifytypes - stages: [pre-push] - entry: uv run --extra=dev -m pyright --verifytypes vws - language: python - pass_filenames: false - types_or: [python] - additional_dependencies: ["uv"] + - id: pyright-verifytypes + name: pyright-verifytypes + stages: [pre-push] + entry: uv run --extra=dev -m pyright --verifytypes vws + language: python + pass_filenames: false + types_or: [python] + additional_dependencies: ["uv"] From 21ab5e8513a4da1386910bf607a9df8808e2e3b0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 8 Oct 2024 10:15:25 +0000 Subject: [PATCH 0461/1003] Bump doccmd from 2024.10.6 to 2024.10.8.12 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.10.6 to 2024.10.8.12. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.10.06...2024.10.08.12) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b458a89db..3bef30376 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.49", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.10.6", + "doccmd==2024.10.8.12", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", From fd8c70cd4eacdf2f60542c876187ece0f4f2e3d7 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 8 Oct 2024 12:50:01 +0100 Subject: [PATCH 0462/1003] Add YAML formatting --- .pre-commit-config.yaml | 4 ++++ .yamlfmt | 5 +++++ codecov.yaml | 1 + readthedocs.yaml | 9 +++++---- 4 files changed, 15 insertions(+), 4 deletions(-) create mode 100644 .yamlfmt diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index b0538c0b1..27090c9f6 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -58,6 +58,10 @@ repos: - id: file-contents-sorter files: spelling_private_dict\.txt$ - id: trailing-whitespace + - repo: https://github.com/google/yamlfmt + rev: v0.13.0 + hooks: + - id: yamlfmt - repo: local hooks: - id: actionlint diff --git a/.yamlfmt b/.yamlfmt new file mode 100644 index 000000000..fbb6dd434 --- /dev/null +++ b/.yamlfmt @@ -0,0 +1,5 @@ +formatter: + include_document_start: true + retain_line_breaks_single: true + trim_trailing_whitespace: true + end_of_file_newline: true diff --git a/codecov.yaml b/codecov.yaml index e49034f39..5c35baac9 100644 --- a/codecov.yaml +++ b/codecov.yaml @@ -1,3 +1,4 @@ +--- coverage: status: patch: diff --git a/readthedocs.yaml b/readthedocs.yaml index d3bd4fd21..4b8a4eb2b 100644 --- a/readthedocs.yaml +++ b/readthedocs.yaml @@ -1,3 +1,4 @@ +--- version: 2 build: @@ -7,10 +8,10 @@ build: python: install: - - method: pip - path: . - extra_requirements: - - dev + - method: pip + path: . + extra_requirements: + - dev sphinx: builder: html From 04d8fcd9d83557e4761ca7aee2d40183b8e598f8 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 8 Oct 2024 12:54:11 +0100 Subject: [PATCH 0463/1003] Add checkmake --- .checkmake-config.ini | 2 ++ .pre-commit-config.yaml | 5 +++++ 2 files changed, 7 insertions(+) create mode 100644 .checkmake-config.ini diff --git a/.checkmake-config.ini b/.checkmake-config.ini new file mode 100644 index 000000000..f2ac3c91b --- /dev/null +++ b/.checkmake-config.ini @@ -0,0 +1,2 @@ +[minphony] +disabled = true diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 27090c9f6..655b9afb3 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -58,6 +58,11 @@ repos: - id: file-contents-sorter files: spelling_private_dict\.txt$ - id: trailing-whitespace + - repo: https://github.com/mrtazz/checkmake.git + rev: 0.2.2 + hooks: + - id: checkmake + args: ["--config", ".checkmake-config.ini"] - repo: https://github.com/google/yamlfmt rev: v0.13.0 hooks: From 7ba119cf11ee3a48fef77ffd8005aa7c214e4446 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 8 Oct 2024 12:56:16 +0100 Subject: [PATCH 0464/1003] Add pygrep hooks --- .pre-commit-config.yaml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 655b9afb3..706c7aede 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -58,6 +58,13 @@ repos: - id: file-contents-sorter files: spelling_private_dict\.txt$ - id: trailing-whitespace + - repo: https://github.com/pre-commit/pygrep-hooks + rev: v1.10.0 # Use the ref you want to point at + hooks: + - id: rst-directive-colons + - id: rst-inline-touching-normal + - id: text-unicode-replacement-char + - id: rst-backticks - repo: https://github.com/mrtazz/checkmake.git rev: 0.2.2 hooks: From 464b398a12906a7f0bbd4fad795e9f6b66f7de99 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 8 Oct 2024 13:03:05 +0100 Subject: [PATCH 0465/1003] Add docformatter pre-commit --- .pre-commit-config.yaml | 9 +++++- conftest.py | 11 +++---- docs/source/__init__.py | 4 ++- pyproject.toml | 4 +++ src/vws/exceptions/base_exceptions.py | 3 +- src/vws/exceptions/custom_exceptions.py | 8 +++--- src/vws/exceptions/vws_exceptions.py | 3 +- src/vws/query.py | 7 +++-- src/vws/reports.py | 15 ++++------ src/vws/types.py | 4 ++- src/vws/vws.py | 38 ++++++++++--------------- tests/__init__.py | 4 ++- tests/conftest.py | 8 ++++-- tests/test_vws.py | 3 +- tests/test_vws_exceptions.py | 8 +++--- 15 files changed, 68 insertions(+), 61 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 706c7aede..ddcbc74cc 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -59,7 +59,7 @@ repos: files: spelling_private_dict\.txt$ - id: trailing-whitespace - repo: https://github.com/pre-commit/pygrep-hooks - rev: v1.10.0 # Use the ref you want to point at + rev: v1.10.0 hooks: - id: rst-directive-colons - id: rst-inline-touching-normal @@ -84,6 +84,13 @@ repos: types_or: [yaml] additional_dependencies: ["uv"] + - id: docformatter + name: docformatter + entry: uv run --extra=dev -m docformatter + language: python + types_or: [python] + additional_dependencies: ["uv"] + - id: shellcheck name: shellcheck entry: uv run --extra=dev shellcheck --shell=bash --exclude=SC1017 diff --git a/conftest.py b/conftest.py index 05d6727f2..1d776f8db 100644 --- a/conftest.py +++ b/conftest.py @@ -1,4 +1,6 @@ -"""Setup for Sybil.""" +""" +Setup for Sybil. +""" import io import uuid @@ -31,8 +33,8 @@ def pytest_collection_modifyitems(items: list[pytest.Item]) -> None: def fixture_make_image_file( high_quality_image: io.BytesIO, ) -> Generator[None]: - """ - Make an image file available in the test directory. + """Make an image file available in the test directory. + The path of this file matches the path in the documentation. """ new_image = Path("high_quality_image.jpg") @@ -46,8 +48,7 @@ def fixture_make_image_file( def fixture_mock_vws( monkeypatch: pytest.MonkeyPatch, ) -> Generator[None]: - """ - Yield a mock VWS. + """Yield a mock VWS. The keys used here match the keys in the documentation. """ diff --git a/docs/source/__init__.py b/docs/source/__init__.py index 535ceb2ec..b63eed5fb 100644 --- a/docs/source/__init__.py +++ b/docs/source/__init__.py @@ -1 +1,3 @@ -"""Documentation.""" +""" +Documentation. +""" diff --git a/pyproject.toml b/pyproject.toml index 3bef30376..06e8c93b0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -44,6 +44,7 @@ optional-dependencies.dev = [ "deptry==0.20.0", "doc8==1.1.2", "doccmd==2024.10.8.12", + "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", @@ -258,6 +259,9 @@ spelling-private-dict-file = 'spelling_private_dict.txt' # --spelling-private-dict-file option instead of raising a message. spelling-store-unknown-words = 'no' +[tool.docformatter] +make-summary-multi-line = true + [tool.check-manifest] ignore = [ diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index ad1116708..b0888f93f 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -32,8 +32,7 @@ def response(self) -> Response: @beartype class VWSError(Exception): - """ - Base class for Vuforia Web Services errors. + """Base class for Vuforia Web Services errors. These errors are defined at https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#result-codes. diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index cb237abd8..f05d59b41 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -11,11 +11,11 @@ @beartype class OopsAnErrorOccurredPossiblyBadNameError(Exception): - """ - Exception raised when VWS returns an HTML page which says "Oops, an error - occurred". + """Exception raised when VWS returns an HTML page which says "Oops, an + error occurred". - This has been seen to happen when the given name includes a bad character. + This has been seen to happen when the given name includes a bad + character. """ def __init__(self, response: Response) -> None: diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index bf6d5fc4d..b0e3dcbda 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -33,8 +33,7 @@ def target_id(self) -> str: @beartype class FailError(VWSError): """ - Exception raised when Vuforia returns a response with a result code - 'Fail'. + Exception raised when Vuforia returns a response with a result code 'Fail'. """ diff --git a/src/vws/query.py b/src/vws/query.py index 2380ba962..84144691c 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -34,7 +34,9 @@ @beartype def _get_image_data(image: _ImageType) -> bytes: - """Get the data of an image file.""" + """ + Get the data of an image file. + """ original_tell = image.tell() image.seek(0) image_data = image.read() @@ -72,8 +74,7 @@ def query( CloudRecoIncludeTargetData.TOP ), ) -> list[QueryResult]: - """ - Use the Vuforia Web Query API to make an Image Recognition Query. + """Use the Vuforia Web Query API to make an Image Recognition Query. See https://developer.vuforia.com/library/web-api/vuforia-query-web-api diff --git a/src/vws/reports.py b/src/vws/reports.py index 431cfcaa6..85b5d9133 100644 --- a/src/vws/reports.py +++ b/src/vws/reports.py @@ -12,8 +12,7 @@ @beartype @dataclass(frozen=True) class DatabaseSummaryReport: - """ - A database summary report. + """A database summary report. See https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#summary-report. @@ -49,8 +48,7 @@ class TargetStatuses(Enum): @beartype @dataclass(frozen=True) class TargetSummaryReport: - """ - A target summary report. + """A target summary report. See https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#summary-report. @@ -70,8 +68,7 @@ class TargetSummaryReport: @beartype(conf=BeartypeConf(is_pep484_tower=True)) @dataclass(frozen=True) class TargetRecord: - """ - A target record. + """A target record. See https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#target-record. @@ -100,8 +97,7 @@ class TargetData: @beartype @dataclass(frozen=True) class QueryResult: - """ - One query match result. + """One query match result. See https://developer.vuforia.com/library/web-api/vuforia-query-web-api. @@ -114,8 +110,7 @@ class QueryResult: @beartype @dataclass(frozen=True) class TargetStatusAndRecord: - """ - The target status and a target record. + """The target status and a target record. See https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#target-record. diff --git a/src/vws/types.py b/src/vws/types.py index 22e912607..269f2e23f 100644 --- a/src/vws/types.py +++ b/src/vws/types.py @@ -1,4 +1,6 @@ -"""Responses for requests to VWS and VWQ.""" +""" +Responses for requests to VWS and VWQ. +""" from dataclasses import dataclass diff --git a/src/vws/vws.py b/src/vws/vws.py index 9e40655d2..492bef5cf 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -53,7 +53,9 @@ @beartype def _get_image_data(image: _ImageType) -> bytes: - """Get the data of an image file.""" + """ + Get the data of an image file. + """ original_tell = image.tell() image.seek(0) image_data = image.read() @@ -72,8 +74,7 @@ def _target_api_request( request_path: str, base_vws_url: str, ) -> Response: - """ - Make a request to the Vuforia Target API. + """Make a request to the Vuforia Target API. This uses `requests` to make a request against https://vws.vuforia.com. @@ -160,8 +161,7 @@ def make_request( expected_result_code: str, content_type: str, ) -> Response: - """ - Make a request to the Vuforia Target API. + """Make a request to the Vuforia Target API. This uses `requests` to make a request against Vuforia. @@ -251,8 +251,7 @@ def add_target( *, active_flag: bool, ) -> str: - """ - Add a target to a Vuforia Web Services database. + """Add a target to a Vuforia Web Services database. See https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#add @@ -326,8 +325,8 @@ def add_target( return str(json.loads(s=response.text)["target_id"]) def get_target_record(self, target_id: str) -> TargetStatusAndRecord: - """ - Get a given target's target record from the Target Management System. + """Get a given target's target record from the Target Management + System. See https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#target-record. @@ -383,8 +382,7 @@ def wait_for_target_processed( seconds_between_requests: float = 0.2, timeout_seconds: float = 60 * 5, ) -> None: - """ - Wait up to five minutes (arbitrary) for a target to get past the + """Wait up to five minutes (arbitrary) for a target to get past the processing stage. Args: @@ -428,8 +426,7 @@ def wait_for_target_processed( time.sleep(seconds_between_requests) def list_targets(self) -> list[str]: - """ - List target IDs. + """List target IDs. See https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#details-list. @@ -461,8 +458,7 @@ def list_targets(self) -> list[str]: return list(json.loads(s=response.text)["results"]) def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: - """ - Get a summary report for a target. + """Get a summary report for a target. See https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#summary-report. @@ -510,8 +506,7 @@ def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: ) def get_database_summary_report(self) -> DatabaseSummaryReport: - """ - Get a summary report for the database. + """Get a summary report for the database. See https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#summary-report. @@ -557,8 +552,7 @@ def get_database_summary_report(self) -> DatabaseSummaryReport: ) def delete_target(self, target_id: str) -> None: - """ - Delete a given target. + """Delete a given target. See https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#delete. @@ -592,8 +586,7 @@ def delete_target(self, target_id: str) -> None: ) def get_duplicate_targets(self, target_id: str) -> list[str]: - """ - Get targets which may be considered duplicates of a given target. + """Get targets which may be considered duplicates of a given target. See https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#check. @@ -641,8 +634,7 @@ def update_target( active_flag: bool | None = None, application_metadata: str | None = None, ) -> None: - """ - Update a target in a Vuforia Web Services database. + """Update a target in a Vuforia Web Services database. See https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#update diff --git a/tests/__init__.py b/tests/__init__.py index 3502d86d5..c7e38a862 100644 --- a/tests/__init__.py +++ b/tests/__init__.py @@ -1 +1,3 @@ -"""Tests for ``vws``.""" +""" +Tests for ``vws``. +""" diff --git a/tests/conftest.py b/tests/conftest.py index ed50f2e7b..74c6fc56d 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -54,7 +54,9 @@ def fixture_image_file( tmp_path: Path, request: pytest.FixtureRequest, ) -> Generator[BinaryIO]: - """An image file object.""" + """ + An image file object. + """ file = tmp_path / "image.jpg" buffer = high_quality_image.getvalue() file.write_bytes(data=buffer) @@ -69,7 +71,9 @@ def image( high_quality_image: io.BytesIO, image_file: BinaryIO, ) -> io.BytesIO | BinaryIO: - """An image in any of the types that the API accepts.""" + """ + An image in any of the types that the API accepts. + """ if request.param == "high_quality_image": return high_quality_image return image_file diff --git a/tests/test_vws.py b/tests/test_vws.py index 42fdee45a..500320c0a 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -80,8 +80,7 @@ def test_add_two_targets( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - No exception is raised when adding two targets with different names. + """No exception is raised when adding two targets with different names. This demonstrates that the image seek position is not changed. """ diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 0c9de2d29..8f422615d 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -139,8 +139,8 @@ def test_target_name_exist( high_quality_image: io.BytesIO, ) -> None: """ - A ``TargetNameExist`` exception is raised after adding two targets with - the same name. + A ``TargetNameExist`` exception is raised after adding two targets with the + same name. """ vws_client.add_target( name="x", @@ -166,8 +166,8 @@ def test_project_inactive( high_quality_image: io.BytesIO, ) -> None: """ - A ``ProjectInactive`` exception is raised if adding a target to an - inactive database. + A ``ProjectInactive`` exception is raised if adding a target to an inactive + database. """ database = VuforiaDatabase(state=States.PROJECT_INACTIVE) with MockVWS() as mock: From 590a61bb8c1b4f0c44dbf84c9bdd56ad7f1a0002 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 8 Oct 2024 13:06:44 +0100 Subject: [PATCH 0466/1003] Do not run docformatter on pre-commit.ci --- .pre-commit-config.yaml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ddcbc74cc..7c9012062 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -12,6 +12,7 @@ ci: - check-manifest - deptry - doc8 + - docformatter - docs - interrogate - interrogate-docs @@ -28,13 +29,13 @@ ci: - ruff-check-fix-docs - ruff-format-fix - ruff-format-fix-docs - - spelling - - vulture - - vulture-docs - shellcheck - shellcheck-docs - shfmt - shfmt-docs + - spelling + - vulture + - vulture-docs default_install_hook_types: [pre-commit, pre-push, commit-msg] repos: From 4cb28c0a6540df059dd9ed2d289f59264ad9f090 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Tue, 8 Oct 2024 12:10:06 +0000 Subject: [PATCH 0467/1003] [pre-commit.ci lite] apply automatic fixes --- .github/workflows/release.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 2074d8655..2ea1e6aa7 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -86,9 +86,9 @@ jobs: uv build --sdist --wheel --out-dir dist/ uv run --extra=release check-wheel-contents dist/*.whl - # We use PyPI trusted publishing rather than a PyPI API token. - # See https://github.com/pypa/gh-action-pypi-publish/tree/release/v1/?tab=readme-ov-file#trusted-publishing. - name: Publish distribution 📦 to PyPI + # We use PyPI trusted publishing rather than a PyPI API token. + # See https://github.com/pypa/gh-action-pypi-publish/tree/release/v1/?tab=readme-ov-file#trusted-publishing. uses: pypa/gh-action-pypi-publish@release/v1 with: verbose: true From 6a9c7f0bde39421d2cd36eec52dab2049caa67f6 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 9 Oct 2024 09:11:51 +0100 Subject: [PATCH 0468/1003] Run docformatter in place --- .pre-commit-config.yaml | 2 +- pyproject.toml | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 7c9012062..d774662ab 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -87,7 +87,7 @@ repos: - id: docformatter name: docformatter - entry: uv run --extra=dev -m docformatter + entry: uv run --extra=dev -m docformatter --in-place language: python types_or: [python] additional_dependencies: ["uv"] diff --git a/pyproject.toml b/pyproject.toml index 06e8c93b0..801d197b0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -265,6 +265,8 @@ make-summary-multi-line = true [tool.check-manifest] ignore = [ + ".checkmake-config.ini", + ".yamlfmt", "*.enc", ".pre-commit-config.yaml", "readthedocs.yaml", From 522efd9611e6eaf38941d140f2828e5234c8cfa5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 9 Oct 2024 10:24:12 +0000 Subject: [PATCH 0469/1003] Bump pre-commit from 4.0.0 to 4.0.1 Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 4.0.0 to 4.0.1. - [Release notes](https://github.com/pre-commit/pre-commit/releases) - [Changelog](https://github.com/pre-commit/pre-commit/blob/main/CHANGELOG.md) - [Commits](https://github.com/pre-commit/pre-commit/compare/v4.0.0...v4.0.1) --- updated-dependencies: - dependency-name: pre-commit dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 801d197b0..1eae0bf50 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -49,7 +49,7 @@ optional-dependencies.dev = [ "furo==2024.8.6", "interrogate==1.7.0", "mypy==1.11.2", - "pre-commit==4.0.0", + "pre-commit==4.0.1", "pydocstyle==6.3", "pyenchant==3.3.0rc1", "pygments==2.18.0", From da5af35f35c27ac1e2c9e194e033cc86b3225e1c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 9 Oct 2024 10:29:30 +0000 Subject: [PATCH 0470/1003] Bump check-manifest from 0.49 to 0.50 Bumps [check-manifest](https://github.com/mgedmin/check-manifest) from 0.49 to 0.50. - [Changelog](https://github.com/mgedmin/check-manifest/blob/master/CHANGES.rst) - [Commits](https://github.com/mgedmin/check-manifest/compare/0.49...0.50) --- updated-dependencies: - dependency-name: check-manifest dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1eae0bf50..187a88381 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -40,7 +40,7 @@ dependencies = [ ] optional-dependencies.dev = [ "actionlint-py==1.7.3.17", - "check-manifest==0.49", + "check-manifest==0.50", "deptry==0.20.0", "doc8==1.1.2", "doccmd==2024.10.8.12", From bf034b3f9c45dd44dc0a4cbc6f9b5563bca150e6 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 9 Oct 2024 14:31:36 +0100 Subject: [PATCH 0471/1003] Specify Windows support in classifiers --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index 187a88381..074d754b3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -25,6 +25,7 @@ classifiers = [ "Development Status :: 5 - Production/Stable", "Environment :: Web Environment", "License :: OSI Approved :: MIT License", + "Operating System :: Microsoft :: Windows", "Operating System :: POSIX", "Programming Language :: Python :: 3 :: Only", "Programming Language :: Python :: 3.12", From b5f707d8c3ed9a95610ed50da3ecadccdc40b093 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 9 Oct 2024 15:37:09 +0100 Subject: [PATCH 0472/1003] Switch from yamlfmt to yamlfix --- .github/dependabot.yml | 7 ++- .github/workflows/ci.yml | 12 ++-- .github/workflows/dependabot-merge.yml | 2 +- .github/workflows/lint.yml | 8 +-- .github/workflows/release.yml | 15 ++--- .pre-commit-config.yaml | 83 ++++++++++++++------------ pyproject.toml | 5 ++ readthedocs.yaml | 5 +- 8 files changed, 76 insertions(+), 61 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 76027ef36..610da79f8 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -1,13 +1,14 @@ --- version: 2 + updates: - package-ecosystem: pip - directory: "/" + directory: / schedule: interval: daily open-pull-requests-limit: 10 - - package-ecosystem: "github-actions" - directory: "/" + - package-ecosystem: github-actions + directory: / schedule: interval: daily open-pull-requests-limit: 10 diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9c36d9c0d..71a07849e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -10,15 +10,15 @@ on: schedule: # * is a special character in YAML so you have to quote this string # Run at 1:00 every day - - cron: '0 1 * * *' + - cron: 0 1 * * * jobs: build: strategy: matrix: - python-version: ["3.12"] - platform: ["ubuntu-latest", "windows-latest"] + python-version: ['3.12'] + platform: [ubuntu-latest, windows-latest] runs-on: ${{ matrix.platform }} @@ -28,14 +28,14 @@ jobs: - name: Install uv uses: astral-sh/setup-uv@v3 - - name: "Run tests" + - name: Run tests run: | # We run tests against "." and not the tests directory as we test the README # and documentation. uv run --extra=dev --python=${{ matrix.python-version }} pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests/ . --cov-report=xml - - name: "Upload coverage to Codecov" - uses: "codecov/codecov-action@v4" + - name: Upload coverage to Codecov + uses: codecov/codecov-action@v4 with: fail_ci_if_error: true token: ${{ secrets.CODECOV_TOKEN }} diff --git a/.github/workflows/dependabot-merge.yml b/.github/workflows/dependabot-merge.yml index 1c75ca282..5238c9f68 100644 --- a/.github/workflows/dependabot-merge.yml +++ b/.github/workflows/dependabot-merge.yml @@ -16,7 +16,7 @@ jobs: id: metadata uses: dependabot/fetch-metadata@v2 with: - github-token: "${{ secrets.GITHUB_TOKEN }}" + github-token: ${{ secrets.GITHUB_TOKEN }} - name: Enable auto-merge for Dependabot PRs run: gh pr merge --auto --merge "$PR_URL" env: diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 9c52e9b2e..630311fc3 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -10,15 +10,15 @@ on: schedule: # * is a special character in YAML so you have to quote this string # Run at 1:00 every day - - cron: '0 1 * * *' + - cron: 0 1 * * * jobs: build: strategy: matrix: - python-version: ["3.12"] - platform: ["ubuntu-latest", "windows-latest"] + python-version: ['3.12'] + platform: [ubuntu-latest, windows-latest] runs-on: ${{ matrix.platform }} @@ -28,7 +28,7 @@ jobs: - name: Install uv uses: astral-sh/setup-uv@v3 - - name: "Lint" + - name: Lint run: | uv run --extra=dev pre-commit run --all-files --hook-stage pre-commit --verbose uv run --extra=dev pre-commit run --all-files --hook-stage pre-push --verbose diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 2ea1e6aa7..8fd8c1ce9 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -22,7 +22,7 @@ jobs: strategy: matrix: - python-version: ["3.12"] + python-version: ['3.12'] steps: - uses: actions/checkout@v4 @@ -34,11 +34,11 @@ jobs: - name: Install uv uses: astral-sh/setup-uv@v3 - - name: "Calver calculate version" + - name: Calver calculate version uses: StephaneBour/actions-calver@master id: calver with: - date_format: "%Y.%m.%d" + date_format: '%Y.%m.%d' release: false env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -49,12 +49,13 @@ jobs: underline="$(echo "${{ steps.calver.outputs.release }}" | tr -c '\n' '-')" echo "underline=${underline}" >> "$GITHUB_OUTPUT" - - name: "Update changelog" + - name: Update changelog uses: jacobtomlinson/gha-find-replace@v3 with: find: "Next\n----" - replace: "Next\n----\n\n${{ steps.calver.outputs.release }}\n${{ steps.changelog_underline.outputs.underline }}" - include: "CHANGELOG.rst" + replace: "Next\n----\n\n${{ steps.calver.outputs.release }}\n${{ steps.changelog_underline.outputs.underline\ + \ }}" + include: CHANGELOG.rst regex: false - uses: stefanzweifel/git-auto-commit-action@v5 @@ -69,7 +70,7 @@ jobs: with: github_token: ${{ secrets.GITHUB_TOKEN }} custom_tag: ${{ steps.calver.outputs.release }} - tag_prefix: "" + tag_prefix: '' commit_sha: ${{ steps.commit.outputs.commit_hash }} - name: Create a GitHub release diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index d774662ab..8ff06fc0c 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -36,8 +36,10 @@ ci: - spelling - vulture - vulture-docs + - yamlfix default_install_hook_types: [pre-commit, pre-push, commit-msg] + repos: - repo: meta hooks: @@ -70,11 +72,8 @@ repos: rev: 0.2.2 hooks: - id: checkmake - args: ["--config", ".checkmake-config.ini"] - - repo: https://github.com/google/yamlfmt - rev: v0.13.0 - hooks: - - id: yamlfmt + args: [--config, .checkmake-config.ini] + - repo: local hooks: - id: actionlint @@ -83,14 +82,14 @@ repos: language: python pass_filenames: false types_or: [yaml] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: docformatter name: docformatter entry: uv run --extra=dev -m docformatter --in-place language: python types_or: [python] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: shellcheck name: shellcheck @@ -98,28 +97,30 @@ repos: language: python pass_filenames: false types_or: [shell] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: shellcheck-docs name: shellcheck-docs - entry: uv run --extra=dev doccmd --language=shell --language=console --command="shellcheck --shell=bash --exclude=SC1017" + entry: uv run --extra=dev doccmd --language=shell --language=console --command="shellcheck + --shell=bash --exclude=SC1017" language: python types_or: [markdown, rst] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: shfmt name: shfmt entry: uv run --extra=dev shfmt --write --space-redirects --indent=4 language: python types_or: [shell] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: shfmt-docs name: shfmt-docs - entry: uv run --extra=dev doccmd --language=shell --language=console --skip-marker=shfmt --no-pad-file --command="shfmt --write --space-redirects --indent=4" + entry: uv run --extra=dev doccmd --language=shell --language=console --skip-marker=shfmt + --no-pad-file --command="shfmt --write --space-redirects --indent=4" language: python types_or: [markdown, rst] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: mypy name: mypy @@ -128,7 +129,7 @@ repos: language: python types_or: [python, toml] pass_filenames: false - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: mypy-docs name: mypy-docs @@ -136,7 +137,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="mypy" language: python types_or: [markdown, rst, python, toml] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: check-manifest name: check-manifest @@ -144,7 +145,7 @@ repos: entry: uv run --extra=dev -m check_manifest . language: python pass_filenames: false - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: pyright name: pyright @@ -153,7 +154,7 @@ repos: language: python types_or: [python, toml] pass_filenames: false - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: pyright-docs name: pyright-docs @@ -161,7 +162,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="pyright" language: python types_or: [markdown, rst, python, toml] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: vulture name: vulture @@ -169,14 +170,14 @@ repos: language: python types_or: [python] pass_filenames: false - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: vulture-docs name: vulture docs entry: uv run --extra=dev doccmd --language=python --command="vulture" language: python types_or: [markdown, rst] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: pyroma name: pyroma @@ -184,14 +185,14 @@ repos: language: python pass_filenames: false types_or: [toml] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: deptry name: deptry entry: uv run --extra=dev -m deptry src/ language: python pass_filenames: false - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: pylint name: pylint @@ -199,7 +200,7 @@ repos: language: python stages: [manual] pass_filenames: false - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: pylint-docs name: pylint-docs @@ -207,56 +208,57 @@ repos: language: python stages: [manual] types_or: [markdown, rst, python, toml] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: ruff-check-fix name: Ruff check fix entry: uv run --extra=dev -m ruff check --fix language: python types_or: [python] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: ruff-check-fix-docs name: Ruff check fix docs entry: uv run --extra=dev doccmd --language=python --command="ruff check --fix" language: python types_or: [markdown, rst] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: ruff-format-fix name: Ruff format entry: uv run --extra=dev -m ruff format language: python types_or: [python] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: ruff-format-fix-docs name: Ruff format docs - entry: uv run --extra=dev doccmd --language=python --no-pad-file --command="ruff format" + entry: uv run --extra=dev doccmd --language=python --no-pad-file --command="ruff + format" language: python types_or: [markdown, rst] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: doc8 name: doc8 entry: uv run --extra=dev -m doc8 language: python types_or: [rst] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: interrogate name: interrogate entry: uv run --extra=dev -m interrogate language: python types_or: [python] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: interrogate-docs name: interrogate docs entry: uv run --extra=dev doccmd --language=python --command="interrogate" language: python types_or: [markdown, rst] - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: pyproject-fmt-fix name: pyproject-fmt @@ -264,7 +266,7 @@ repos: language: python types_or: [toml] files: pyproject.toml - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: linkcheck name: linkcheck @@ -273,7 +275,7 @@ repos: types_or: [rst] stages: [manual] pass_filenames: false - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: spelling name: spelling @@ -282,7 +284,7 @@ repos: types_or: [rst] stages: [manual] pass_filenames: false - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: docs name: Build Documentation @@ -290,7 +292,7 @@ repos: language: python stages: [manual] pass_filenames: false - additional_dependencies: ["uv"] + additional_dependencies: [uv] - id: pyright-verifytypes name: pyright-verifytypes @@ -299,4 +301,11 @@ repos: language: python pass_filenames: false types_or: [python] - additional_dependencies: ["uv"] + additional_dependencies: [uv] + + - id: yamlfix + name: pyproject-fmt + entry: uv run --extra=dev yamlfix + language: python + types_or: [yaml] + additional_dependencies: [uv] diff --git a/pyproject.toml b/pyproject.toml index 187a88381..aefcc61cb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -76,6 +76,7 @@ optional-dependencies.dev = [ "vulture==2.13", "vws-python-mock==2024.8.30", "vws-test-fixtures==2023.3.5", + "yamlfix==1.17.0", ] optional-dependencies.release = [ "check-wheel-contents==0.6.0" ] urls.Documentation = "https://vws-python.readthedocs.io/en/latest/" @@ -384,3 +385,7 @@ ignore_names = [ # Duplicate some of .gitignore exclude = [ ".venv" ] + +[tool.yamlfix] +section_whitelines = 1 +whitelines = 1 diff --git a/readthedocs.yaml b/readthedocs.yaml index 4b8a4eb2b..bdd2bf053 100644 --- a/readthedocs.yaml +++ b/readthedocs.yaml @@ -4,14 +4,13 @@ version: 2 build: os: ubuntu-24.04 tools: - python: "3.12" + python: '3.12' python: install: - method: pip path: . - extra_requirements: - - dev + extra_requirements: [dev] sphinx: builder: html From c1da067b33c0197311848b1530458bafd210b680 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 9 Oct 2024 15:47:52 +0100 Subject: [PATCH 0473/1003] Remove checkmake - it is flaky on Windows --- .checkmake-config.ini | 2 -- .pre-commit-config.yaml | 6 +----- 2 files changed, 1 insertion(+), 7 deletions(-) delete mode 100644 .checkmake-config.ini diff --git a/.checkmake-config.ini b/.checkmake-config.ini deleted file mode 100644 index f2ac3c91b..000000000 --- a/.checkmake-config.ini +++ /dev/null @@ -1,2 +0,0 @@ -[minphony] -disabled = true diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 8ff06fc0c..94dbbfd07 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -68,11 +68,7 @@ repos: - id: rst-inline-touching-normal - id: text-unicode-replacement-char - id: rst-backticks - - repo: https://github.com/mrtazz/checkmake.git - rev: 0.2.2 - hooks: - - id: checkmake - args: [--config, .checkmake-config.ini] + - repo: local hooks: From a04341e24d8538f408937965eff577d677249173 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Wed, 9 Oct 2024 14:50:12 +0000 Subject: [PATCH 0474/1003] [pre-commit.ci lite] apply automatic fixes --- .pre-commit-config.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 94dbbfd07..7e7426899 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -69,7 +69,6 @@ repos: - id: text-unicode-replacement-char - id: rst-backticks - - repo: local hooks: - id: actionlint From bf6fe462c8e17d6f7571c30dda4ffdd93de273a9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 9 Oct 2024 14:55:12 +0000 Subject: [PATCH 0475/1003] Bump pyright from 1.1.383 to 1.1.384 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.383 to 1.1.384. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.383...v1.1.384) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index aefcc61cb..5c505ece7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.2.4", - "pyright==1.1.383", + "pyright==1.1.384", "pyroma==4.2", "pytest==8.3.3", "pytest-cov==5.0.0", From 645d2a3682d3736407b61d03ca73bed430ff8ab8 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 9 Oct 2024 15:56:11 +0100 Subject: [PATCH 0476/1003] Remove yamlfmt config --- .yamlfmt | 5 ----- 1 file changed, 5 deletions(-) delete mode 100644 .yamlfmt diff --git a/.yamlfmt b/.yamlfmt deleted file mode 100644 index fbb6dd434..000000000 --- a/.yamlfmt +++ /dev/null @@ -1,5 +0,0 @@ -formatter: - include_document_start: true - retain_line_breaks_single: true - trim_trailing_whitespace: true - end_of_file_newline: true From dad0faf59ac761179a00e382af24182a9eebdc21 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 9 Oct 2024 22:53:31 +0100 Subject: [PATCH 0477/1003] Add Windows classifier --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index 5c505ece7..11acd2531 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -25,6 +25,7 @@ classifiers = [ "Development Status :: 5 - Production/Stable", "Environment :: Web Environment", "License :: OSI Approved :: MIT License", + "Operating System :: Microsoft :: Windows", "Operating System :: POSIX", "Programming Language :: Python :: 3 :: Only", "Programming Language :: Python :: 3.12", From 91a46c92f822a823799e23334bddea14b7f7919a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 11 Oct 2024 10:09:44 +0100 Subject: [PATCH 0478/1003] Use max supported Python version for explicit pyproject-fmt configuration --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index 11acd2531..6311092d3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -301,6 +301,7 @@ pep621_dev_dependency_groups = [ [tool.pyproject-fmt] indent = 4 keep_full_version = true +max_supported_python = "3.12" [tool.pytest.ini_options] From 1c5572c1fd3e1c2b482f25599dcfdfde56032742 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 11 Oct 2024 10:15:38 +0000 Subject: [PATCH 0479/1003] Bump sphinx from 8.0.2 to 8.1.0 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 8.0.2 to 8.1.0. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v8.0.2...v8.1.0) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6311092d3..7f23c7ffd 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -68,7 +68,7 @@ optional-dependencies.dev = [ # use it to lint shell commands in GitHub workflow files. "shellcheck-py==0.10.0.1", "shfmt-py==3.7.0.1", - "sphinx==8.0.2", + "sphinx==8.1.0", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", "sphinxcontrib-spelling==8", From 807a87855910dffda050130af43a150753d7aace Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 11 Oct 2024 10:20:22 +0000 Subject: [PATCH 0480/1003] Bump pyproject-fmt from 2.2.4 to 2.3.0 Bumps [pyproject-fmt](https://github.com/tox-dev/pyproject-fmt) from 2.2.4 to 2.3.0. - [Release notes](https://github.com/tox-dev/pyproject-fmt/releases) - [Commits](https://github.com/tox-dev/pyproject-fmt/compare/2.2.4...2.3.0) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7f23c7ffd..097ffe582 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", - "pyproject-fmt==2.2.4", + "pyproject-fmt==2.3.0", "pyright==1.1.384", "pyroma==4.2", "pytest==8.3.3", From cc684da5da89565721ae44aaf5f9c75ee9649af9 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 11 Oct 2024 13:24:39 +0100 Subject: [PATCH 0481/1003] Remove workaround for CRLF line endings now we tell git to check out with lf --- pyproject.toml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 097ffe582..35f7cb6fd 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -343,8 +343,7 @@ ignore_path = [ "./src/*/_setuptools_scm_version.txt", ] -# See https://github.com/PyCQA/doc8/issues/78 -ignore = [ "D004" ] + [tool.vulture] # Ideally we would limit the paths to the source code where we want to ignore names, From 2815ef71af7a4c26c2640c722e45e054e57d42cf Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Fri, 11 Oct 2024 12:27:05 +0000 Subject: [PATCH 0482/1003] [pre-commit.ci lite] apply automatic fixes --- pyproject.toml | 2 -- 1 file changed, 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 35f7cb6fd..859c191d2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -343,8 +343,6 @@ ignore_path = [ "./src/*/_setuptools_scm_version.txt", ] - - [tool.vulture] # Ideally we would limit the paths to the source code where we want to ignore names, # but Vulture does not enable this. From 2bc9f573673e00695536249008f7de3750424536 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 11 Oct 2024 13:39:25 +0100 Subject: [PATCH 0483/1003] Update git attributes --- .gitattributes | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitattributes b/.gitattributes index b5c2d0d58..ee0f759ba 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,2 +1,2 @@ .git_archival.txt export-subst -*.txt text eol=lf +* text=auto eol=lf From b935b983b4da493d38b1bbb3745766e92f163ad0 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 11 Oct 2024 13:59:19 +0100 Subject: [PATCH 0484/1003] Move shellcheck settings to rc file --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 7e7426899..685d83135 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -88,7 +88,7 @@ repos: - id: shellcheck name: shellcheck - entry: uv run --extra=dev shellcheck --shell=bash --exclude=SC1017 + entry: uv run --extra=dev shellcheck --shell=bash language: python pass_filenames: false types_or: [shell] @@ -97,7 +97,7 @@ repos: - id: shellcheck-docs name: shellcheck-docs entry: uv run --extra=dev doccmd --language=shell --language=console --command="shellcheck - --shell=bash --exclude=SC1017" + --shell=bash" language: python types_or: [markdown, rst] additional_dependencies: [uv] From 68cd32fa1ee89aac6b5e6d2c569e7041e71c2d9e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 11 Oct 2024 21:15:39 +0100 Subject: [PATCH 0485/1003] Bump doccmd --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 859c191d2..4f4413514 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -44,7 +44,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.10.8.12", + "doccmd==2024.10.11", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From 14c89176ba5a3fac78f3718e60a9922049446830 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sat, 12 Oct 2024 11:23:59 +0000 Subject: [PATCH 0486/1003] Bump sphinx from 8.1.0 to 8.1.1 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 8.1.0 to 8.1.1. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v8.1.0...v8.1.1) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4f4413514..0c4bd0c16 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -68,7 +68,7 @@ optional-dependencies.dev = [ # use it to lint shell commands in GitHub workflow files. "shellcheck-py==0.10.0.1", "shfmt-py==3.7.0.1", - "sphinx==8.1.0", + "sphinx==8.1.1", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", "sphinxcontrib-spelling==8", From 14cb8b8a1f519778e8a6d8c9ed32d519bfc95317 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sat, 12 Oct 2024 11:37:42 +0000 Subject: [PATCH 0487/1003] Bump doccmd from 2024.10.11 to 2024.10.12 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.10.11 to 2024.10.12. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.10.11...2024.10.12) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0c4bd0c16..83fade1c0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -44,7 +44,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.10.11", + "doccmd==2024.10.12", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From 2b2065c751ebcfc66214a4abbd75ae461174218a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 12 Oct 2024 15:58:06 +0100 Subject: [PATCH 0488/1003] Configure VSCode to run tests in its UI --- .vscode/settings.json | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index 9f41e3120..69abf060e 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -6,5 +6,10 @@ "editor.defaultFormatter": "charliermarsh.ruff", "editor.formatOnSave": true }, - "esbonio.sphinx.confDir": "" + "esbonio.sphinx.confDir": "", + "python.testing.pytestArgs": [ + "." + ], + "python.testing.unittestEnabled": false, + "python.testing.pytestEnabled": true } From 2cdb39022ea3baa1f91f657e31ab5c66a71348de Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 12 Oct 2024 16:34:49 +0100 Subject: [PATCH 0489/1003] Add lower bounds to all requirements --- pyproject.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 83fade1c0..cff439de0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -35,9 +35,9 @@ dynamic = [ ] dependencies = [ "beartype>=0.18.5", - "requests", - "urllib3", - "vws-auth-tools", + "requests>=2.32.3", + "urllib3>=2.2.3", + "vws-auth-tools>=2024.7.12", ] optional-dependencies.dev = [ "actionlint-py==1.7.3.17", From bb103d18d7eaaf258c78f19424bdc681fc27424b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 12 Oct 2024 17:07:41 +0100 Subject: [PATCH 0490/1003] Move mypy file definitions to pyproject.toml --- .pre-commit-config.yaml | 2 +- pyproject.toml | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 685d83135..2d174ed65 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -120,7 +120,7 @@ repos: - id: mypy name: mypy stages: [pre-push] - entry: uv run --extra=dev -m mypy . + entry: uv run --extra=dev -m mypy language: python types_or: [python, toml] pass_filenames: false diff --git a/pyproject.toml b/pyproject.toml index cff439de0..89061bec7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -320,6 +320,8 @@ exclude_also = [ [tool.mypy] strict = true +files = [ "." ] +exclude = [ "build" ] [tool.pyright] From 7b9bf892452eb78d632252cd7e93d36f6682b446 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 12 Oct 2024 17:48:16 +0100 Subject: [PATCH 0491/1003] No need to give directory to check-manifest --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 2d174ed65..beedacfcc 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -137,7 +137,7 @@ repos: - id: check-manifest name: check-manifest stages: [pre-push] - entry: uv run --extra=dev -m check_manifest . + entry: uv run --extra=dev -m check_manifest language: python pass_filenames: false additional_dependencies: [uv] From dc8263655eefbf83ada9406f24f99dddc4469103 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 14 Oct 2024 10:43:20 +0000 Subject: [PATCH 0492/1003] Bump pre-commit-ci/lite-action from 1.0.3 to 1.1.0 Bumps [pre-commit-ci/lite-action](https://github.com/pre-commit-ci/lite-action) from 1.0.3 to 1.1.0. - [Release notes](https://github.com/pre-commit-ci/lite-action/releases) - [Commits](https://github.com/pre-commit-ci/lite-action/compare/v1.0.3...v1.1.0) --- updated-dependencies: - dependency-name: pre-commit-ci/lite-action dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- .github/workflows/lint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 630311fc3..9e70657b7 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -36,5 +36,5 @@ jobs: env: UV_PYTHON: ${{ matrix.python-version }} - - uses: pre-commit-ci/lite-action@v1.0.3 + - uses: pre-commit-ci/lite-action@v1.1.0 if: always() From 4fd84ff4badd1a4c96693a09acdc87eea5b76621 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 14 Oct 2024 10:58:13 +0000 Subject: [PATCH 0493/1003] Bump doccmd from 2024.10.12 to 2024.10.13.1 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.10.12 to 2024.10.13.1. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.10.12...2024.10.13.1) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 89061bec7..d1f29501a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -44,7 +44,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.10.12", + "doccmd==2024.10.13.1", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From 13198d45ddabd6e52a9d17aea65fb10d188d8b80 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 14 Oct 2024 10:58:21 +0000 Subject: [PATCH 0494/1003] Bump sphinx from 8.1.1 to 8.1.3 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 8.1.1 to 8.1.3. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v8.1.1...v8.1.3) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 89061bec7..1dc192d0a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -68,7 +68,7 @@ optional-dependencies.dev = [ # use it to lint shell commands in GitHub workflow files. "shellcheck-py==0.10.0.1", "shfmt-py==3.7.0.1", - "sphinx==8.1.1", + "sphinx==8.1.3", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.8.6", "sphinxcontrib-spelling==8", From ff4deced2935ddff9d6a119c77d4c1e500e0f886 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 15 Oct 2024 10:56:24 +0100 Subject: [PATCH 0495/1003] Fix the version in Sphinx to be the last released version --- docs/source/conf.py | 6 ++++-- pyproject.toml | 7 +++++++ 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 0fa6f6f69..da1b8193b 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -36,8 +36,10 @@ # Use ``importlib.metadata.version`` as per # https://setuptools-scm.readthedocs.io/en/latest/usage/#usage-from-sphinx version = importlib.metadata.version(distribution_name=project) -_month, _day, _year, *_ = version.split(".") -release = f"{_month}.{_day}.{_year}" +# This method of getting the release from the version goes hand in hand with +# the ``post-release`` versioning scheme chosen in the ``setuptools-scm`` +# configuration. +release = version.split(".post")[0] project_metadata = importlib.metadata.metadata(distribution_name=project) diff --git a/pyproject.toml b/pyproject.toml index 133dc39af..7bfac91d8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -101,6 +101,13 @@ universal = true [tool.setuptools_scm] +# This keeps the start of the version the same as the last release. +# This is useful for our documentation to include e.g. binary links +# to the latest released binary. +# +# Code to match this is in ``conf.py``. +version_scheme = "post-release" + [tool.ruff] line-length = 79 From 5d33d0fc9ecfa38090d2fec259f25f167bdf6dce Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 15 Oct 2024 10:26:23 +0000 Subject: [PATCH 0496/1003] Bump mypy from 1.11.2 to 1.12.0 Bumps [mypy](https://github.com/python/mypy) from 1.11.2 to 1.12.0. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.11.2...v1.12.0) --- updated-dependencies: - dependency-name: mypy dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7bfac91d8..62bc754b9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -49,7 +49,7 @@ optional-dependencies.dev = [ "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", - "mypy==1.11.2", + "mypy==1.12.0", "pre-commit==4.0.1", "pydocstyle==6.3", "pyenchant==3.3.0rc1", From dd59c3d91f33810452b92c8bbff00b29ea752a6c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 15 Oct 2024 10:26:30 +0000 Subject: [PATCH 0497/1003] Bump pyproject-fmt from 2.3.0 to 2.3.1 Bumps [pyproject-fmt](https://github.com/tox-dev/pyproject-fmt) from 2.3.0 to 2.3.1. - [Release notes](https://github.com/tox-dev/pyproject-fmt/releases) - [Commits](https://github.com/tox-dev/pyproject-fmt/compare/2.3.0...2.3.1) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7bfac91d8..8806a6e66 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", - "pyproject-fmt==2.3.0", + "pyproject-fmt==2.3.1", "pyright==1.1.384", "pyroma==4.2", "pytest==8.3.3", From f07f73ac88655e902e5641751852f411d318707f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 15 Oct 2024 10:26:41 +0000 Subject: [PATCH 0498/1003] Bump doccmd from 2024.10.13.1 to 2024.10.14.2 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.10.13.1 to 2024.10.14.2. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.10.13.1...2024.10.14.2) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7bfac91d8..dfe4c79dc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -44,7 +44,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.10.13.1", + "doccmd==2024.10.14.2", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From 2cd5a89085f1ab1b0972f66fb04e095a9bf2871c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 16 Oct 2024 10:23:16 +0000 Subject: [PATCH 0499/1003] Bump types-requests from 2.32.0.20240914 to 2.32.0.20241016 Bumps [types-requests](https://github.com/python/typeshed) from 2.32.0.20240914 to 2.32.0.20241016. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5da09aeb5..e5bc87b45 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,7 +73,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2024.8.6", "sphinxcontrib-spelling==8", "sybil==8.0.0", - "types-requests==2.32.0.20240914", + "types-requests==2.32.0.20241016", "vulture==2.13", "vws-python-mock==2024.8.30", "vws-test-fixtures==2023.3.5", From dc74630c01e7dc7ec6fc57905e569951105df3ab Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 16 Oct 2024 10:23:24 +0000 Subject: [PATCH 0500/1003] Bump pyright from 1.1.384 to 1.1.385 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.384 to 1.1.385. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.384...v1.1.385) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5da09aeb5..52d907df4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.3.1", - "pyright==1.1.384", + "pyright==1.1.385", "pyroma==4.2", "pytest==8.3.3", "pytest-cov==5.0.0", From ce8962edd5c77071d07cadda6e54f4ddd61f3448 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 17 Oct 2024 10:36:17 +0000 Subject: [PATCH 0501/1003] Bump pyproject-fmt from 2.3.1 to 2.4.2 Bumps [pyproject-fmt](https://github.com/tox-dev/toml-fmt) from 2.3.1 to 2.4.2. - [Release notes](https://github.com/tox-dev/toml-fmt/releases) - [Commits](https://github.com/tox-dev/toml-fmt/commits/pyproject-fmt/2.4.2) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 519eaefc0..ef9fd64dd 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", - "pyproject-fmt==2.3.1", + "pyproject-fmt==2.4.2", "pyright==1.1.385", "pyroma==4.2", "pytest==8.3.3", From 2509610c91acdc8670d240430adcbe41c9fb60cc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 18 Oct 2024 10:46:33 +0000 Subject: [PATCH 0502/1003] Bump sphinx-substitution-extensions from 2024.8.6 to 2024.10.17 Bumps [sphinx-substitution-extensions](https://github.com/adamtheturtle/sphinx-substitution-extensions) from 2024.8.6 to 2024.10.17. - [Release notes](https://github.com/adamtheturtle/sphinx-substitution-extensions/releases) - [Changelog](https://github.com/adamtheturtle/sphinx-substitution-extensions/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/sphinx-substitution-extensions/compare/2024.08.06...2024.10.17) --- updated-dependencies: - dependency-name: sphinx-substitution-extensions dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ef9fd64dd..5cbd0e67c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -70,7 +70,7 @@ optional-dependencies.dev = [ "shfmt-py==3.7.0.1", "sphinx==8.1.3", "sphinx-copybutton==0.5.2", - "sphinx-substitution-extensions==2024.8.6", + "sphinx-substitution-extensions==2024.10.17", "sphinxcontrib-spelling==8", "sybil==8.0.0", "types-requests==2.32.0.20241016", From 9c43fd596543e6a10c944839f7d9655c504c9fdf Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 18 Oct 2024 10:46:53 +0000 Subject: [PATCH 0503/1003] Bump ruff from 0.6.9 to 0.7.0 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.6.9 to 0.7.0. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.6.9...0.7.0) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ef9fd64dd..8a572334a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.3", "pytest-cov==5.0.0", "pyyaml==6.0.2", - "ruff==0.6.9", + "ruff==0.7.0", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 8a4cc589e17ed655267a314d781fb7c08cc58709 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 18 Oct 2024 10:46:58 +0000 Subject: [PATCH 0504/1003] Bump pyproject-fmt from 2.4.2 to 2.4.3 Bumps [pyproject-fmt](https://github.com/tox-dev/toml-fmt) from 2.4.2 to 2.4.3. - [Release notes](https://github.com/tox-dev/toml-fmt/releases) - [Commits](https://github.com/tox-dev/toml-fmt/compare/pyproject-fmt/2.4.2...pyproject-fmt/2.4.3) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ef9fd64dd..751bf3d06 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", - "pyproject-fmt==2.4.2", + "pyproject-fmt==2.4.3", "pyright==1.1.385", "pyroma==4.2", "pytest==8.3.3", From f1abe8355a2b0dcede791e32ba3719ca5ab2d01b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 20 Oct 2024 11:00:38 +0200 Subject: [PATCH 0505/1003] Fix the name of the yamlfix pre-commit hook --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index beedacfcc..77643a13e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -299,7 +299,7 @@ repos: additional_dependencies: [uv] - id: yamlfix - name: pyproject-fmt + name: yamlfix entry: uv run --extra=dev yamlfix language: python types_or: [yaml] From 075cc5a7b0b82957c58f1ae5a10924c327d4975d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 21 Oct 2024 10:59:45 +0000 Subject: [PATCH 0506/1003] Bump doccmd from 2024.10.14.2 to 2024.10.18 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.10.14.2 to 2024.10.18. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.10.14.2...2024.10.18) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e9fdc41f0..7af4baf7a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -44,7 +44,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.10.14.2", + "doccmd==2024.10.18", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From f0af2c3e981bcda770435fee34ac3d1e246e1f0e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 21 Oct 2024 10:59:56 +0000 Subject: [PATCH 0507/1003] Bump mypy from 1.12.0 to 1.12.1 Bumps [mypy](https://github.com/python/mypy) from 1.12.0 to 1.12.1. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.12.0...v1.12.1) --- updated-dependencies: - dependency-name: mypy dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e9fdc41f0..454abbc44 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -49,7 +49,7 @@ optional-dependencies.dev = [ "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", - "mypy==1.12.0", + "mypy==1.12.1", "pre-commit==4.0.1", "pydocstyle==6.3", "pyenchant==3.3.0rc1", From e8083dd412058de0c87a66e5d6ab5c272b8f0d90 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 21 Oct 2024 23:09:22 +0100 Subject: [PATCH 0508/1003] Pin uv for pre-commit hook --- .pre-commit-config.yaml | 60 ++++++++++++++++++++--------------------- 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 77643a13e..0812bf573 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -77,14 +77,14 @@ repos: language: python pass_filenames: false types_or: [yaml] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: docformatter name: docformatter entry: uv run --extra=dev -m docformatter --in-place language: python types_or: [python] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: shellcheck name: shellcheck @@ -92,7 +92,7 @@ repos: language: python pass_filenames: false types_or: [shell] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: shellcheck-docs name: shellcheck-docs @@ -100,14 +100,14 @@ repos: --shell=bash" language: python types_or: [markdown, rst] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: shfmt name: shfmt entry: uv run --extra=dev shfmt --write --space-redirects --indent=4 language: python types_or: [shell] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: shfmt-docs name: shfmt-docs @@ -115,7 +115,7 @@ repos: --no-pad-file --command="shfmt --write --space-redirects --indent=4" language: python types_or: [markdown, rst] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: mypy name: mypy @@ -124,7 +124,7 @@ repos: language: python types_or: [python, toml] pass_filenames: false - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: mypy-docs name: mypy-docs @@ -132,7 +132,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="mypy" language: python types_or: [markdown, rst, python, toml] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: check-manifest name: check-manifest @@ -140,7 +140,7 @@ repos: entry: uv run --extra=dev -m check_manifest language: python pass_filenames: false - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: pyright name: pyright @@ -149,7 +149,7 @@ repos: language: python types_or: [python, toml] pass_filenames: false - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: pyright-docs name: pyright-docs @@ -157,7 +157,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="pyright" language: python types_or: [markdown, rst, python, toml] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: vulture name: vulture @@ -165,14 +165,14 @@ repos: language: python types_or: [python] pass_filenames: false - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: vulture-docs name: vulture docs entry: uv run --extra=dev doccmd --language=python --command="vulture" language: python types_or: [markdown, rst] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: pyroma name: pyroma @@ -180,14 +180,14 @@ repos: language: python pass_filenames: false types_or: [toml] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: deptry name: deptry entry: uv run --extra=dev -m deptry src/ language: python pass_filenames: false - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: pylint name: pylint @@ -195,7 +195,7 @@ repos: language: python stages: [manual] pass_filenames: false - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: pylint-docs name: pylint-docs @@ -203,28 +203,28 @@ repos: language: python stages: [manual] types_or: [markdown, rst, python, toml] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: ruff-check-fix name: Ruff check fix entry: uv run --extra=dev -m ruff check --fix language: python types_or: [python] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: ruff-check-fix-docs name: Ruff check fix docs entry: uv run --extra=dev doccmd --language=python --command="ruff check --fix" language: python types_or: [markdown, rst] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: ruff-format-fix name: Ruff format entry: uv run --extra=dev -m ruff format language: python types_or: [python] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: ruff-format-fix-docs name: Ruff format docs @@ -232,28 +232,28 @@ repos: format" language: python types_or: [markdown, rst] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: doc8 name: doc8 entry: uv run --extra=dev -m doc8 language: python types_or: [rst] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: interrogate name: interrogate entry: uv run --extra=dev -m interrogate language: python types_or: [python] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: interrogate-docs name: interrogate docs entry: uv run --extra=dev doccmd --language=python --command="interrogate" language: python types_or: [markdown, rst] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: pyproject-fmt-fix name: pyproject-fmt @@ -261,7 +261,7 @@ repos: language: python types_or: [toml] files: pyproject.toml - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: linkcheck name: linkcheck @@ -270,7 +270,7 @@ repos: types_or: [rst] stages: [manual] pass_filenames: false - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: spelling name: spelling @@ -279,7 +279,7 @@ repos: types_or: [rst] stages: [manual] pass_filenames: false - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: docs name: Build Documentation @@ -287,7 +287,7 @@ repos: language: python stages: [manual] pass_filenames: false - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: pyright-verifytypes name: pyright-verifytypes @@ -296,11 +296,11 @@ repos: language: python pass_filenames: false types_or: [python] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] - id: yamlfix name: yamlfix entry: uv run --extra=dev yamlfix language: python types_or: [yaml] - additional_dependencies: [uv] + additional_dependencies: [uv==0.4.25] From 407d9ecc1f0b70b5bf4c529ebe9df957bd3962d9 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 23 Oct 2024 07:57:24 +0100 Subject: [PATCH 0509/1003] Remove unnecessary build dependency - pip --- pyproject.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 553586bff..ec7ab4e74 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,6 @@ [build-system] build-backend = "setuptools.build_meta" requires = [ - "pip", "setuptools", "setuptools-scm[toml]>=7.1", "wheel", From e593d7ae219cfdf85179b3ae5d18b47dbe3f1ccb Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 23 Oct 2024 08:36:21 +0100 Subject: [PATCH 0510/1003] Use faster mypy cache --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ec7ab4e74..615d3f72a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", - "mypy==1.12.1", + "mypy[faster-cache]==1.13.0", "pre-commit==4.0.1", "pydocstyle==6.3", "pyenchant==3.3.0rc1", From afeaa00ad4f55be98e2c418188e5e6337f67be9f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 23 Oct 2024 10:54:47 +0000 Subject: [PATCH 0511/1003] Bump pyright from 1.1.385 to 1.1.386 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.385 to 1.1.386. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.385...v1.1.386) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 615d3f72a..a9a05c103 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.4.3", - "pyright==1.1.385", + "pyright==1.1.386", "pyroma==4.2", "pytest==8.3.3", "pytest-cov==5.0.0", From 2ec44c07ce746abf172314d9afca7c837e0b198a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 25 Oct 2024 10:17:06 +0000 Subject: [PATCH 0512/1003] Bump ruff from 0.7.0 to 0.7.1 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.7.0 to 0.7.1. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.7.0...0.7.1) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a9a05c103..80d64af0f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.3", "pytest-cov==5.0.0", "pyyaml==6.0.2", - "ruff==0.7.0", + "ruff==0.7.1", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 2aa33f520fb7e3de6144a773a932d1731f430cdf Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 30 Oct 2024 10:25:18 +0000 Subject: [PATCH 0513/1003] Bump pytest-cov from 5.0.0 to 6.0.0 Bumps [pytest-cov](https://github.com/pytest-dev/pytest-cov) from 5.0.0 to 6.0.0. - [Changelog](https://github.com/pytest-dev/pytest-cov/blob/master/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest-cov/compare/v5.0.0...v6.0.0) --- updated-dependencies: - dependency-name: pytest-cov dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 80d64af0f..0ca2be15e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pyright==1.1.386", "pyroma==4.2", "pytest==8.3.3", - "pytest-cov==5.0.0", + "pytest-cov==6.0.0", "pyyaml==6.0.2", "ruff==0.7.1", # We add shellcheck-py not only for shell scripts and shell code blocks, From 96e8221a17383cbebaad402b70b4bbb898e71245 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 30 Oct 2024 10:25:36 +0000 Subject: [PATCH 0514/1003] Bump pyright from 1.1.386 to 1.1.387 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.386 to 1.1.387. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.386...v1.1.387) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 80d64af0f..69b992507 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.4.3", - "pyright==1.1.386", + "pyright==1.1.387", "pyroma==4.2", "pytest==8.3.3", "pytest-cov==5.0.0", From 980ff1d2402218532a644b6a5a00cdeab4e57d86 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 31 Oct 2024 10:44:27 +0000 Subject: [PATCH 0515/1003] Bump pyproject-fmt from 2.4.3 to 2.5.0 Bumps [pyproject-fmt](https://github.com/tox-dev/toml-fmt) from 2.4.3 to 2.5.0. - [Release notes](https://github.com/tox-dev/toml-fmt/releases) - [Commits](https://github.com/tox-dev/toml-fmt/compare/pyproject-fmt/2.4.3...pyproject-fmt/2.5.0) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2424d52f4..4275ca7b5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pygments==2.18.0", "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", - "pyproject-fmt==2.4.3", + "pyproject-fmt==2.5.0", "pyright==1.1.387", "pyroma==4.2", "pytest==8.3.3", From de9ab9c39e10ae51a9e280e10d00e64b96a467db Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 31 Oct 2024 10:44:45 +0000 Subject: [PATCH 0516/1003] Bump sybil from 8.0.0 to 8.0.1 Bumps [sybil](https://github.com/simplistix/sybil) from 8.0.0 to 8.0.1. - [Changelog](https://github.com/simplistix/sybil/blob/master/CHANGELOG.rst) - [Commits](https://github.com/simplistix/sybil/compare/8.0.0...8.0.1) --- updated-dependencies: - dependency-name: sybil dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2424d52f4..6ad7ab7d3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -71,7 +71,7 @@ optional-dependencies.dev = [ "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.10.17", "sphinxcontrib-spelling==8", - "sybil==8.0.0", + "sybil==8.0.1", "types-requests==2.32.0.20241016", "vulture==2.13", "vws-python-mock==2024.8.30", From b12077eae7ae2e50ce7346601f5efcd46af58cf6 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Nov 2024 10:12:38 +0000 Subject: [PATCH 0517/1003] Bump ruff from 0.7.1 to 0.7.2 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.7.1 to 0.7.2. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.7.1...0.7.2) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ad5efe8d8..298a0df4f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.3", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.7.1", + "ruff==0.7.2", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 1daef9ab15f2e4a64138073def7097902e8dace0 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 4 Nov 2024 16:16:29 +0000 Subject: [PATCH 0518/1003] Use @unique to ensure and communicate enum uniqueness --- src/vws/include_target_data.py | 3 ++- src/vws/reports.py | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/vws/include_target_data.py b/src/vws/include_target_data.py index e259f654a..37682e08a 100644 --- a/src/vws/include_target_data.py +++ b/src/vws/include_target_data.py @@ -2,12 +2,13 @@ Tools for managing ``CloudRecoService.query``'s ``include_target_data``. """ -from enum import StrEnum, auto +from enum import StrEnum, auto, unique from beartype import beartype @beartype +@unique class CloudRecoIncludeTargetData(StrEnum): """ Options for the ``include_target_data`` parameter of diff --git a/src/vws/reports.py b/src/vws/reports.py index 85b5d9133..f6a77133c 100644 --- a/src/vws/reports.py +++ b/src/vws/reports.py @@ -4,7 +4,7 @@ import datetime from dataclasses import dataclass -from enum import Enum +from enum import Enum, unique from beartype import BeartypeConf, beartype @@ -33,6 +33,7 @@ class DatabaseSummaryReport: @beartype +@unique class TargetStatuses(Enum): """Constants representing VWS target statuses. From 9739a24ee72fad19fedba0818f93545226e2595f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 5 Nov 2024 10:18:06 +0000 Subject: [PATCH 0519/1003] Bump actionlint-py from 1.7.3.17 to 1.7.4.18 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.7.3.17 to 1.7.4.18. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.7.3.17...v1.7.4.18) --- updated-dependencies: - dependency-name: actionlint-py dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 298a0df4f..690657ec4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -39,7 +39,7 @@ dependencies = [ "vws-auth-tools>=2024.7.12", ] optional-dependencies.dev = [ - "actionlint-py==1.7.3.17", + "actionlint-py==1.7.4.18", "check-manifest==0.50", "deptry==0.20.0", "doc8==1.1.2", From 2f618b920c1748a34d6d30137d0b99a67103d334 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 5 Nov 2024 20:13:08 +0000 Subject: [PATCH 0520/1003] Do not run doccmd against Python or toml files --- .pre-commit-config.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 0812bf573..1f294554b 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -131,7 +131,7 @@ repos: stages: [pre-push] entry: uv run --extra=dev doccmd --language=python --command="mypy" language: python - types_or: [markdown, rst, python, toml] + types_or: [markdown, rst] additional_dependencies: [uv==0.4.25] - id: check-manifest @@ -156,7 +156,7 @@ repos: stages: [pre-push] entry: uv run --extra=dev doccmd --language=python --command="pyright" language: python - types_or: [markdown, rst, python, toml] + types_or: [markdown, rst] additional_dependencies: [uv==0.4.25] - id: vulture @@ -202,7 +202,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="pylint" language: python stages: [manual] - types_or: [markdown, rst, python, toml] + types_or: [markdown, rst] additional_dependencies: [uv==0.4.25] - id: ruff-check-fix From 5af1a602dd67a6ebf65debd4369513cf3ddc7943 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 5 Nov 2024 22:36:52 +0000 Subject: [PATCH 0521/1003] Bump doccmd from 2024.10.18 to 2024.11.5 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.10.18 to 2024.11.5. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.10.18...2024.11.05) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 690657ec4..6c39d3d01 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.10.18", + "doccmd==2024.11.5", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From 5e78ef0673387e37b610a12f1b4026676d347d91 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 6 Nov 2024 11:02:21 +0000 Subject: [PATCH 0522/1003] Bump pyright from 1.1.387 to 1.1.388 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.387 to 1.1.388. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.387...v1.1.388) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6c39d3d01..bd1705d9a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.5.0", - "pyright==1.1.387", + "pyright==1.1.388", "pyroma==4.2", "pytest==8.3.3", "pytest-cov==6.0.0", From 2a8852858c4f9b218ce7d1df67b8cc7543f5c02a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 7 Nov 2024 10:06:42 +0000 Subject: [PATCH 0523/1003] Bump doccmd from 2024.11.5 to 2024.11.6.1 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.11.5 to 2024.11.6.1. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.11.05...2024.11.06.1) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index bd1705d9a..eec897621 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.11.5", + "doccmd==2024.11.6.1", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From 9e88c0dd62aa91d30e328cd988b9bf95673e3a96 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 8 Nov 2024 10:16:45 +0000 Subject: [PATCH 0524/1003] Bump doccmd from 2024.11.6.1 to 2024.11.7 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.11.6.1 to 2024.11.7. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.11.06.1...2024.11.07) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index eec897621..c399ae48b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.20.0", "doc8==1.1.2", - "doccmd==2024.11.6.1", + "doccmd==2024.11.7", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From a6d114b11d3a11f95a4fe94eb2f06264da8c233a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Nov 2024 10:17:09 +0000 Subject: [PATCH 0525/1003] Bump ruff from 0.7.2 to 0.7.3 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.7.2 to 0.7.3. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.7.2...0.7.3) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c399ae48b..3aff29e7f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.3", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.7.2", + "ruff==0.7.3", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 74bb998ca19f486b24e556b86ab662193363853d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Nov 2024 10:17:19 +0000 Subject: [PATCH 0526/1003] Bump deptry from 0.20.0 to 0.21.0 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.20.0 to 0.21.0. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.20.0...0.21.0) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c399ae48b..e9db15c79 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ dependencies = [ optional-dependencies.dev = [ "actionlint-py==1.7.4.18", "check-manifest==0.50", - "deptry==0.20.0", + "deptry==0.21.0", "doc8==1.1.2", "doccmd==2024.11.7", "docformatter==1.7.5", From 9f406c2deea7538e323d3cf039988e326ac00c69 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 13 Nov 2024 10:58:19 +0000 Subject: [PATCH 0527/1003] Bump sybil from 8.0.1 to 9.0.0 Bumps [sybil](https://github.com/simplistix/sybil) from 8.0.1 to 9.0.0. - [Changelog](https://github.com/simplistix/sybil/blob/master/CHANGELOG.rst) - [Commits](https://github.com/simplistix/sybil/compare/8.0.1...9.0.0) --- updated-dependencies: - dependency-name: sybil dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9e8090be7..7004063b0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -71,7 +71,7 @@ optional-dependencies.dev = [ "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.10.17", "sphinxcontrib-spelling==8", - "sybil==8.0.1", + "sybil==9.0.0", "types-requests==2.32.0.20241016", "vulture==2.13", "vws-python-mock==2024.8.30", From b55458e1edb758d2fd3fcfea657455d55beafe17 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 14 Nov 2024 11:04:35 +0000 Subject: [PATCH 0528/1003] Bump doccmd from 2024.11.7 to 2024.11.14 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.11.7 to 2024.11.14. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.11.07...2024.11.14) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7004063b0..ad76b0516 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.21.0", "doc8==1.1.2", - "doccmd==2024.11.7", + "doccmd==2024.11.14", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From 445526966b2ced8c55671dfd0c8ff6056a6922bc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 14 Nov 2024 11:04:47 +0000 Subject: [PATCH 0529/1003] Bump pyright from 1.1.388 to 1.1.389 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.388 to 1.1.389. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.388...v1.1.389) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7004063b0..60f545b93 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pylint==3.3.1", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.5.0", - "pyright==1.1.388", + "pyright==1.1.389", "pyroma==4.2", "pytest==8.3.3", "pytest-cov==6.0.0", From 86f74a13c7c7317b58d6e8d8d6d4c505d96d2708 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Nov 2024 10:57:05 +0000 Subject: [PATCH 0530/1003] Bump ruff from 0.7.3 to 0.7.4 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.7.3 to 0.7.4. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.7.3...0.7.4) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d385dc6e0..7f533a20d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.3", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.7.3", + "ruff==0.7.4", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From abc954d08269297e30f7daf9a719e8e5375b3ee1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Nov 2024 10:57:22 +0000 Subject: [PATCH 0531/1003] Bump deptry from 0.21.0 to 0.21.1 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.21.0 to 0.21.1. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.21.0...0.21.1) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d385dc6e0..e83bb2c7d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ dependencies = [ optional-dependencies.dev = [ "actionlint-py==1.7.4.18", "check-manifest==0.50", - "deptry==0.21.0", + "deptry==0.21.1", "doc8==1.1.2", "doccmd==2024.11.14", "docformatter==1.7.5", From 3c55fb81a5eee8e9ae0372e34c801c0eef99ae64 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 18 Nov 2024 11:26:54 +0000 Subject: [PATCH 0532/1003] Bump codecov/codecov-action from 4 to 5 Bumps [codecov/codecov-action](https://github.com/codecov/codecov-action) from 4 to 5. - [Release notes](https://github.com/codecov/codecov-action/releases) - [Changelog](https://github.com/codecov/codecov-action/blob/main/CHANGELOG.md) - [Commits](https://github.com/codecov/codecov-action/compare/v4...v5) --- updated-dependencies: - dependency-name: codecov/codecov-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 71a07849e..bb73eadda 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -35,7 +35,7 @@ jobs: uv run --extra=dev --python=${{ matrix.python-version }} pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests/ . --cov-report=xml - name: Upload coverage to Codecov - uses: codecov/codecov-action@v4 + uses: codecov/codecov-action@v5 with: fail_ci_if_error: true token: ${{ secrets.CODECOV_TOKEN }} From 0576a32161e431dbf7073a44015ecf191a660542 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 22 Nov 2024 10:34:18 +0000 Subject: [PATCH 0533/1003] Bump ruff from 0.7.4 to 0.8.0 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.7.4 to 0.8.0. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.7.4...0.8.0) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 36cd9d384..3d7623855 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.3", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.7.4", + "ruff==0.8.0", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From fa0addc8db76ca85b4639eca91189b84c2243c70 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 22 Nov 2024 12:46:30 +0000 Subject: [PATCH 0534/1003] Autofix ruff issue --- src/vws/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vws/__init__.py b/src/vws/__init__.py index 9e4633af8..42788b92d 100644 --- a/src/vws/__init__.py +++ b/src/vws/__init__.py @@ -6,6 +6,6 @@ from .vws import VWS __all__ = [ - "CloudRecoService", "VWS", + "CloudRecoService", ] From fdf5a16f77b5a3bb33285173b0729fa4314434da Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 25 Nov 2024 11:00:28 +0000 Subject: [PATCH 0535/1003] Bump astral-sh/setup-uv from 3 to 4 Bumps [astral-sh/setup-uv](https://github.com/astral-sh/setup-uv) from 3 to 4. - [Release notes](https://github.com/astral-sh/setup-uv/releases) - [Commits](https://github.com/astral-sh/setup-uv/compare/v3...v4) --- updated-dependencies: - dependency-name: astral-sh/setup-uv dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- .github/workflows/lint.yml | 2 +- .github/workflows/release.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index bb73eadda..35cc026b6 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -26,7 +26,7 @@ jobs: - uses: actions/checkout@v4 - name: Install uv - uses: astral-sh/setup-uv@v3 + uses: astral-sh/setup-uv@v4 - name: Run tests run: | diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 9e70657b7..0a55727a1 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -26,7 +26,7 @@ jobs: - uses: actions/checkout@v4 - name: Install uv - uses: astral-sh/setup-uv@v3 + uses: astral-sh/setup-uv@v4 - name: Lint run: | diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 8fd8c1ce9..5e6f15e6a 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -32,7 +32,7 @@ jobs: token: ${{ secrets.RELEASE_PAT }} - name: Install uv - uses: astral-sh/setup-uv@v3 + uses: astral-sh/setup-uv@v4 - name: Calver calculate version uses: StephaneBour/actions-calver@master From 34b4b9aab0de114073858f0359f521e8ae9c9064 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 26 Nov 2024 10:30:19 +0000 Subject: [PATCH 0536/1003] Bump actionlint-py from 1.7.4.18 to 1.7.4.20 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.7.4.18 to 1.7.4.20. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.7.4.18...v1.7.4.20) --- updated-dependencies: - dependency-name: actionlint-py dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3d7623855..2c8142542 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -39,7 +39,7 @@ dependencies = [ "vws-auth-tools>=2024.7.12", ] optional-dependencies.dev = [ - "actionlint-py==1.7.4.18", + "actionlint-py==1.7.4.20", "check-manifest==0.50", "deptry==0.21.1", "doc8==1.1.2", From 20e0b07a7394b3ff4b69f6360874167a30680ca2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 29 Nov 2024 11:04:08 +0000 Subject: [PATCH 0537/1003] Bump ruff from 0.8.0 to 0.8.1 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.8.0 to 0.8.1. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.8.0...0.8.1) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2c8142542..d0ee6f44f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.3", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.8.0", + "ruff==0.8.1", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 370c8a5a66a6753c7ecd299de78839d56bdda1ad Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 2 Dec 2024 11:53:21 +0000 Subject: [PATCH 0538/1003] Bump pytest from 8.3.3 to 8.3.4 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.3.3 to 8.3.4. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.3.3...8.3.4) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d0ee6f44f..b74b6a66e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pyproject-fmt==2.5.0", "pyright==1.1.389", "pyroma==4.2", - "pytest==8.3.3", + "pytest==8.3.4", "pytest-cov==6.0.0", "pyyaml==6.0.2", "ruff==0.8.1", From 1cce0971b880daf4bdf879fadb2244dfc97f3549 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 2 Dec 2024 11:53:35 +0000 Subject: [PATCH 0539/1003] Bump pylint from 3.3.1 to 3.3.2 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.3.1 to 3.3.2. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.3.1...v3.3.2) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d0ee6f44f..bf0c961b9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pyenchant==3.3.0rc1", "pygments==2.18.0", - "pylint==3.3.1", + "pylint==3.3.2", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.5.0", "pyright==1.1.389", From b3ff7cc12c2c94fa9e230e4244d7c644da4f4d27 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 2 Dec 2024 11:53:48 +0000 Subject: [PATCH 0540/1003] Bump check-wheel-contents from 0.6.0 to 0.6.1 Bumps [check-wheel-contents](https://github.com/jwodder/check-wheel-contents) from 0.6.0 to 0.6.1. - [Release notes](https://github.com/jwodder/check-wheel-contents/releases) - [Changelog](https://github.com/jwodder/check-wheel-contents/blob/master/CHANGELOG.md) - [Commits](https://github.com/jwodder/check-wheel-contents/compare/v0.6.0...v0.6.1) --- updated-dependencies: - dependency-name: check-wheel-contents dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d0ee6f44f..56ca35d84 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -78,7 +78,7 @@ optional-dependencies.dev = [ "vws-test-fixtures==2023.3.5", "yamlfix==1.17.0", ] -optional-dependencies.release = [ "check-wheel-contents==0.6.0" ] +optional-dependencies.release = [ "check-wheel-contents==0.6.1" ] urls.Documentation = "https://vws-python.readthedocs.io/en/latest/" urls.Source = "https://github.com/VWS-Python/vws-python" From e74039ad71083e9a470cdb3fe0e52347e83d785f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 5 Dec 2024 10:28:43 +0000 Subject: [PATCH 0541/1003] Bump pyright from 1.1.389 to 1.1.390 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.389 to 1.1.390. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.389...v1.1.390) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e0a07199d..ecca88562 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pylint==3.3.2", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.5.0", - "pyright==1.1.389", + "pyright==1.1.390", "pyroma==4.2", "pytest==8.3.4", "pytest-cov==6.0.0", From bb992fd87907d12b0deae55e53f7a54c9823e51b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 6 Dec 2024 10:26:59 +0000 Subject: [PATCH 0542/1003] Bump ruff from 0.8.1 to 0.8.2 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.8.1 to 0.8.2. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.8.1...0.8.2) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ecca88562..edd1c2c55 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.4", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.8.1", + "ruff==0.8.2", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From aeb05ee1cfc608ee9da9ccd954b86064af84badb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 9 Dec 2024 11:01:10 +0000 Subject: [PATCH 0543/1003] Bump vulture from 2.13 to 2.14 Bumps [vulture](https://github.com/jendrikseipp/vulture) from 2.13 to 2.14. - [Release notes](https://github.com/jendrikseipp/vulture/releases) - [Changelog](https://github.com/jendrikseipp/vulture/blob/main/CHANGELOG.md) - [Commits](https://github.com/jendrikseipp/vulture/compare/v2.13...v2.14) --- updated-dependencies: - dependency-name: vulture dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index edd1c2c55..3e2a979d2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,7 +73,7 @@ optional-dependencies.dev = [ "sphinxcontrib-spelling==8", "sybil==9.0.0", "types-requests==2.32.0.20241016", - "vulture==2.13", + "vulture==2.14", "vws-python-mock==2024.8.30", "vws-test-fixtures==2023.3.5", "yamlfix==1.17.0", From ed3817c454fc26bbcf0a7b7498cbb604dc82ea32 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 13 Dec 2024 10:59:27 +0000 Subject: [PATCH 0544/1003] Bump ruff from 0.8.2 to 0.8.3 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.8.2 to 0.8.3. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.8.2...0.8.3) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3e2a979d2..6b81fed6c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.4", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.8.2", + "ruff==0.8.3", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From ff43aad37a966384ac97cf9f6f890c94a17b4b93 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 18 Dec 2024 10:49:38 +0000 Subject: [PATCH 0545/1003] Bump pyright from 1.1.390 to 1.1.391 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.390 to 1.1.391. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.390...v1.1.391) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6b81fed6c..52d8d147a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pylint==3.3.2", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.5.0", - "pyright==1.1.390", + "pyright==1.1.391", "pyroma==4.2", "pytest==8.3.4", "pytest-cov==6.0.0", From f52e3e4701c2fd4d702250d84bf99581e9404199 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 18 Dec 2024 16:17:28 +0000 Subject: [PATCH 0546/1003] Update RTD config with new requirements --- readthedocs.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/readthedocs.yaml b/readthedocs.yaml index bdd2bf053..8f093abcc 100644 --- a/readthedocs.yaml +++ b/readthedocs.yaml @@ -14,4 +14,5 @@ python: sphinx: builder: html + configuration: docs/source/conf.py fail_on_warning: true From f6c4ec183632c1df4730e8c8c00ec969d0902f64 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 20 Dec 2024 10:32:42 +0000 Subject: [PATCH 0547/1003] Bump deptry from 0.21.1 to 0.21.2 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.21.1 to 0.21.2. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.21.1...0.21.2) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 52d8d147a..3b7b2568a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ dependencies = [ optional-dependencies.dev = [ "actionlint-py==1.7.4.20", "check-manifest==0.50", - "deptry==0.21.1", + "deptry==0.21.2", "doc8==1.1.2", "doccmd==2024.11.14", "docformatter==1.7.5", From c1532193ffbfdcc6c0e2c4091ebec0b6c8cf7bd9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 20 Dec 2024 10:33:01 +0000 Subject: [PATCH 0548/1003] Bump ruff from 0.8.3 to 0.8.4 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.8.3 to 0.8.4. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.8.3...0.8.4) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 52d8d147a..7e830040f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.4", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.8.3", + "ruff==0.8.4", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 0937e2a0f7ec5abe592ac7000fc7d41ef7af5408 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 20 Dec 2024 10:33:06 +0000 Subject: [PATCH 0549/1003] Bump sphinxcontrib-spelling from 8 to 8.0.1 Bumps [sphinxcontrib-spelling](https://github.com/sphinx-contrib/spelling) from 8 to 8.0.1. - [Release notes](https://github.com/sphinx-contrib/spelling/releases) - [Commits](https://github.com/sphinx-contrib/spelling/compare/8.0.0...8.0.1) --- updated-dependencies: - dependency-name: sphinxcontrib-spelling dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 52d8d147a..f25340ce1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -70,7 +70,7 @@ optional-dependencies.dev = [ "sphinx==8.1.3", "sphinx-copybutton==0.5.2", "sphinx-substitution-extensions==2024.10.17", - "sphinxcontrib-spelling==8", + "sphinxcontrib-spelling==8.0.1", "sybil==9.0.0", "types-requests==2.32.0.20241016", "vulture==2.14", From d8ebbab8d077f76a6ecc4179e7ef787223096a49 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 21 Dec 2024 11:48:06 +0000 Subject: [PATCH 0550/1003] Do not use now-useless toml specifier for setuptools-scm --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 32e9f8f46..4016997ec 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -2,7 +2,7 @@ build-backend = "setuptools.build_meta" requires = [ "setuptools", - "setuptools-scm[toml]>=7.1", + "setuptools-scm>=8.1.0", "wheel", ] From 6cd662ccaa746c47197b59dff99f7bf4de88669a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sat, 21 Dec 2024 22:50:23 +0000 Subject: [PATCH 0551/1003] Bump astral-sh/setup-uv from 4 to 5 Bumps [astral-sh/setup-uv](https://github.com/astral-sh/setup-uv) from 4 to 5. - [Release notes](https://github.com/astral-sh/setup-uv/releases) - [Commits](https://github.com/astral-sh/setup-uv/compare/v4...v5) --- updated-dependencies: - dependency-name: astral-sh/setup-uv dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- .github/workflows/lint.yml | 2 +- .github/workflows/release.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 35cc026b6..a97d1ec58 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -26,7 +26,7 @@ jobs: - uses: actions/checkout@v4 - name: Install uv - uses: astral-sh/setup-uv@v4 + uses: astral-sh/setup-uv@v5 - name: Run tests run: | diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 0a55727a1..2a3910dd7 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -26,7 +26,7 @@ jobs: - uses: actions/checkout@v4 - name: Install uv - uses: astral-sh/setup-uv@v4 + uses: astral-sh/setup-uv@v5 - name: Lint run: | diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 5e6f15e6a..14bba54cc 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -32,7 +32,7 @@ jobs: token: ${{ secrets.RELEASE_PAT }} - name: Install uv - uses: astral-sh/setup-uv@v4 + uses: astral-sh/setup-uv@v5 - name: Calver calculate version uses: StephaneBour/actions-calver@master From fd30fbd5debf5f819829fcfb67a020a2e318f0a9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 23 Dec 2024 10:14:45 +0000 Subject: [PATCH 0552/1003] Bump mypy[faster-cache] from 1.13.0 to 1.14.0 Bumps [mypy[faster-cache]](https://github.com/python/mypy) from 1.13.0 to 1.14.0. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.13.0...v1.14.0) --- updated-dependencies: - dependency-name: mypy[faster-cache] dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4016997ec..687e6593a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", - "mypy[faster-cache]==1.13.0", + "mypy[faster-cache]==1.14.0", "pre-commit==4.0.1", "pydocstyle==6.3", "pyenchant==3.3.0rc1", From f53424b1e183dc3e938fd91407980115b751753f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 23 Dec 2024 12:00:13 +0000 Subject: [PATCH 0553/1003] Use new follow_untyped_imports mypy setting --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index 687e6593a..aa3600e57 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -328,6 +328,7 @@ exclude_also = [ strict = true files = [ "." ] exclude = [ "build" ] +follow_untyped_imports = true [tool.pyright] From 05d54c857511795806262026f17bb4b5b114a515 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 24 Dec 2024 10:14:18 +0000 Subject: [PATCH 0554/1003] Remove duplicated ruff configuration --- pyproject.toml | 5 ----- 1 file changed, 5 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index aa3600e57..90290dc5f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -132,11 +132,6 @@ lint.ignore = [ "S101", ] -lint.per-file-ignores."tests/*.py" = [ - # Do not require tests to have a one-line summary. - "D205", -] - # Do not automatically remove commented out code. # We comment out code during development, and with VSCode auto-save, this code # is sometimes annoyingly removed. From d6d66a410b074f927df04f90ed8962c788648683 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 24 Dec 2024 10:14:48 +0000 Subject: [PATCH 0555/1003] Remove unnecessary ruff ignore --- pyproject.toml | 2 -- 1 file changed, 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 90290dc5f..99df439da 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -114,8 +114,6 @@ lint.select = [ "ALL", ] lint.ignore = [ - # We are happy to manage our own "complexity". - "C901", # Ruff warns that this conflicts with the formatter. "COM812", # Allow our chosen docstring line-style - no one-line summary. From 539d225043c1750e53413d048bf4df8b3132058a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 24 Dec 2024 10:15:02 +0000 Subject: [PATCH 0556/1003] Remove unnecessary ruff ignore --- pyproject.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 99df439da..9a62370da 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -120,7 +120,6 @@ lint.ignore = [ "D200", "D205", "D212", - "D415", # Ruff warns that this conflicts with the formatter. "ISC001", # Ignore "too-many-*" errors as they seem to get in the way more than From 8b5a6897701bf5ec402e415b27609f5d7199dad9 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 24 Dec 2024 10:15:48 +0000 Subject: [PATCH 0557/1003] Remove unnecessary ruff ignore --- pyproject.toml | 2 -- 1 file changed, 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 9a62370da..5f5c1db89 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -120,8 +120,6 @@ lint.ignore = [ "D200", "D205", "D212", - # Ruff warns that this conflicts with the formatter. - "ISC001", # Ignore "too-many-*" errors as they seem to get in the way more than # helping. "PLR0913", From b4f25c8dacdbe762958d1c67b6c7fe3d58d2d4a1 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 24 Dec 2024 10:18:47 +0000 Subject: [PATCH 0558/1003] Only allow assert in tests --- docs/source/conf.py | 6 +++++- pyproject.toml | 5 ++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index da1b8193b..99ef1ff1c 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -46,7 +46,11 @@ requires_python = project_metadata["Requires-Python"] specifiers = SpecifierSet(specifiers=requires_python) (specifier,) = specifiers -assert specifier.operator == ">=" +if specifier.operator != ">=": + msg = ( + f"We only support '>=' for Requires-Python, got {specifier.operator}." + ) + raise ValueError(msg) minimum_python_version = specifier.version language = "en" diff --git a/pyproject.toml b/pyproject.toml index 5f5c1db89..ae5990b27 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -123,7 +123,10 @@ lint.ignore = [ # Ignore "too-many-*" errors as they seem to get in the way more than # helping. "PLR0913", - # Allow 'assert' as we use it for tests. +] + +lint.per-file-ignores."tests/*.py" = [ + # Do not require tests to have a one-line summary. "S101", ] From 4e1d021c82a6adf8dc8887687a5e7bf5a935f2f1 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 24 Dec 2024 10:20:05 +0000 Subject: [PATCH 0559/1003] Put back conflict ignore --- pyproject.toml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index ae5990b27..75c51e73e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -120,6 +120,8 @@ lint.ignore = [ "D200", "D205", "D212", + # Ruff warns that this conflicts with the formatter. + "ISC001", # Ignore "too-many-*" errors as they seem to get in the way more than # helping. "PLR0913", From 16bc9a915c058a8bb4a2c83ca96e553f11fd7d4d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 24 Dec 2024 10:35:15 +0000 Subject: [PATCH 0560/1003] Allow asserts in docs --- pyproject.toml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 75c51e73e..cb6b2568c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -127,8 +127,13 @@ lint.ignore = [ "PLR0913", ] +lint.per-file-ignores."docs/source/*.py" = [ + # Allow asserts in docs. + "S101", +] + lint.per-file-ignores."tests/*.py" = [ - # Do not require tests to have a one-line summary. + # Allow asserts in tests. "S101", ] From 1df656fc3ee2d8ed0f7de88eae3b44e21b37e8e8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 24 Dec 2024 10:41:22 +0000 Subject: [PATCH 0561/1003] Bump pylint from 3.3.2 to 3.3.3 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.3.2 to 3.3.3. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.3.2...v3.3.3) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index aa3600e57..549871ba9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pyenchant==3.3.0rc1", "pygments==2.18.0", - "pylint==3.3.2", + "pylint==3.3.3", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.5.0", "pyright==1.1.391", From 21318569f938c843a1058a6dfd18ef4ff9bb97bd Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 24 Dec 2024 11:56:53 +0000 Subject: [PATCH 0562/1003] Allow asserts in README --- pyproject.toml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index cb6b2568c..161471daa 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -127,6 +127,11 @@ lint.ignore = [ "PLR0913", ] +lint.per-file-ignores."doccmd_*.py" = [ + # Allow asserts in docs. + "S101", +] + lint.per-file-ignores."docs/source/*.py" = [ # Allow asserts in docs. "S101", From c88618247a7462144d33d3e5b608f584cdf83e35 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 24 Dec 2024 23:13:32 +0000 Subject: [PATCH 0563/1003] Use new mypy plugin for strict kwargs --- pyproject.toml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index eb9b6e3e1..6db511fff 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -49,6 +49,7 @@ optional-dependencies.dev = [ "furo==2024.8.6", "interrogate==1.7.0", "mypy[faster-cache]==1.14.0", + "mypy-strict-kwargs==2024.12.24", "pre-commit==4.0.1", "pydocstyle==6.3", "pyenchant==3.3.0rc1", @@ -334,6 +335,9 @@ strict = true files = [ "." ] exclude = [ "build" ] follow_untyped_imports = true +plugins = [ + "mypy_strict_kwargs", +] [tool.pyright] From b9f8f7cc2204b09d4ae04c085f7c433813424395 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 24 Dec 2024 23:19:11 +0000 Subject: [PATCH 0564/1003] Use one more kwarg --- docs/source/conf.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 99ef1ff1c..3255877d6 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -39,7 +39,7 @@ # This method of getting the release from the version goes hand in hand with # the ``post-release`` versioning scheme chosen in the ``setuptools-scm`` # configuration. -release = version.split(".post")[0] +release = version.split(sep=".post")[0] project_metadata = importlib.metadata.metadata(distribution_name=project) From b1adac283828212f3681713592745a88940dbb6c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 24 Dec 2024 23:25:59 +0000 Subject: [PATCH 0565/1003] Use keyword args all over --- src/vws/exceptions/vws_exceptions.py | 2 +- src/vws/vws.py | 2 +- tests/test_cloud_reco_exceptions.py | 12 ++++++----- tests/test_vws.py | 13 ++++++++---- tests/test_vws_exceptions.py | 30 ++++++++++++++++------------ 5 files changed, 35 insertions(+), 24 deletions(-) diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index b0e3dcbda..482223766 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -154,7 +154,7 @@ def target_name(self) -> str: """ response_body = self.response.request_body or b"" request_json = json.loads(s=response_body) - return str(request_json["name"]) + return str(object=request_json["name"]) @beartype diff --git a/src/vws/vws.py b/src/vws/vws.py index 492bef5cf..f101a7ecc 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -322,7 +322,7 @@ def add_target( content_type="application/json", ) - return str(json.loads(s=response.text)["target_id"]) + return str(object=json.loads(s=response.text)["target_id"]) def get_target_record(self, target_id: str) -> TargetStatusAndRecord: """Get a given target's target record from the Target Management diff --git a/tests/test_cloud_reco_exceptions.py b/tests/test_cloud_reco_exceptions.py index d33da8e72..3515b0d22 100644 --- a/tests/test_cloud_reco_exceptions.py +++ b/tests/test_cloud_reco_exceptions.py @@ -33,7 +33,7 @@ def test_too_many_max_results( A ``MaxNumResultsOutOfRange`` error is raised if the given ``max_num_results`` is out of range. """ - with pytest.raises(MaxNumResultsOutOfRangeError) as exc: + with pytest.raises(expected_exception=MaxNumResultsOutOfRangeError) as exc: cloud_reco_client.query( image=high_quality_image, max_num_results=51, @@ -43,7 +43,7 @@ def test_too_many_max_results( "Integer out of range (51) in form data part 'max_result'. " "Accepted range is from 1 to 50 (inclusive)." ) - assert str(exc.value) == exc.value.response.text == expected_value + assert str(object=exc.value) == exc.value.response.text == expected_value def test_image_too_large( @@ -54,7 +54,7 @@ def test_image_too_large( A ``RequestEntityTooLarge`` exception is raised if an image which is too large is given. """ - with pytest.raises(RequestEntityTooLargeError) as exc: + with pytest.raises(expected_exception=RequestEntityTooLargeError) as exc: cloud_reco_client.query(image=png_too_large) assert ( @@ -92,7 +92,9 @@ def test_authentication_failure( with MockVWS() as mock: mock.add_database(database=database) - with pytest.raises(AuthenticationFailureError) as exc: + with pytest.raises( + expected_exception=AuthenticationFailureError + ) as exc: cloud_reco_client.query(image=high_quality_image) assert exc.value.response.status_code == HTTPStatus.UNAUTHORIZED @@ -113,7 +115,7 @@ def test_inactive_project( client_secret_key=database.client_secret_key, ) - with pytest.raises(InactiveProjectError) as exc: + with pytest.raises(expected_exception=InactiveProjectError) as exc: cloud_reco_client.query(image=high_quality_image) response = exc.value.response diff --git a/tests/test_vws.py b/tests/test_vws.py index 500320c0a..e16eff555 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -30,8 +30,11 @@ class TestAddTarget: """ @staticmethod - @pytest.mark.parametrize("application_metadata", [None, b"a"]) - @pytest.mark.parametrize("active_flag", [True, False]) + @pytest.mark.parametrize( + argnames="application_metadata", + argvalues=[None, b"a"], + ) + @pytest.mark.parametrize(argnames="active_flag", argvalues=[True, False]) def test_add_target( vws_client: VWS, image: io.BytesIO | BinaryIO, @@ -211,7 +214,7 @@ def test_get_target_summary_report( status=TargetStatuses.SUCCESS, database_name=report.database_name, target_name=target_name, - upload_date=datetime.date(2018, 4, 25), + upload_date=datetime.date(year=2018, month=4, day=25), active_flag=True, tracking_rating=report.tracking_rating, total_recos=0, @@ -511,7 +514,9 @@ def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: report = vws_client.get_target_summary_report(target_id=target_id) assert report.status == TargetStatuses.PROCESSING - with pytest.raises(TargetProcessingTimeoutError): + with pytest.raises( + expected_exception=TargetProcessingTimeoutError + ): vws_client.wait_for_target_processed( target_id=target_id, timeout_seconds=0.1, diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 8f422615d..f9a7b8dab 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -45,7 +45,7 @@ def test_image_too_large( When giving an image which is too large, an ``ImageTooLarge`` exception is raised. """ - with pytest.raises(ImageTooLargeError) as exc: + with pytest.raises(expected_exception=ImageTooLargeError) as exc: vws_client.add_target( name="x", width=1, @@ -63,7 +63,7 @@ def test_invalid_given_id(vws_client: VWS) -> None: causes an ``UnknownTarget`` exception to be raised. """ target_id = "12345abc" - with pytest.raises(UnknownTargetError) as exc: + with pytest.raises(expected_exception=UnknownTargetError) as exc: vws_client.delete_target(target_id=target_id) assert exc.value.response.status_code == HTTPStatus.NOT_FOUND assert exc.value.target_id == target_id @@ -76,7 +76,9 @@ def test_add_bad_name(vws_client: VWS, high_quality_image: io.BytesIO) -> None: """ max_char_value = 65535 bad_name = chr(max_char_value + 1) - with pytest.raises(OopsAnErrorOccurredPossiblyBadNameError) as exc: + with pytest.raises( + expected_exception=OopsAnErrorOccurredPossiblyBadNameError + ) as exc: vws_client.add_target( name=bad_name, width=1, @@ -105,7 +107,7 @@ def test_fail(high_quality_image: io.BytesIO) -> None: server_secret_key=uuid.uuid4().hex, ) - with pytest.raises(FailError) as exc: + with pytest.raises(expected_exception=FailError) as exc: vws_client.add_target( name="x", width=1, @@ -122,7 +124,7 @@ def test_bad_image(vws_client: VWS) -> None: A ``BadImage`` exception is raised when a non-image is given. """ not_an_image = io.BytesIO(initial_bytes=b"Not an image") - with pytest.raises(BadImageError) as exc: + with pytest.raises(expected_exception=BadImageError) as exc: vws_client.add_target( name="x", width=1, @@ -149,7 +151,7 @@ def test_target_name_exist( active_flag=True, application_metadata=None, ) - with pytest.raises(TargetNameExistError) as exc: + with pytest.raises(expected_exception=TargetNameExistError) as exc: vws_client.add_target( name="x", width=1, @@ -177,7 +179,7 @@ def test_project_inactive( server_secret_key=database.server_secret_key, ) - with pytest.raises(ProjectInactiveError) as exc: + with pytest.raises(expected_exception=ProjectInactiveError) as exc: vws_client.add_target( name="x", width=1, @@ -205,7 +207,7 @@ def test_target_status_processing( application_metadata=None, ) - with pytest.raises(TargetStatusProcessingError) as exc: + with pytest.raises(expected_exception=TargetStatusProcessingError) as exc: vws_client.delete_target(target_id=target_id) assert exc.value.response.status_code == HTTPStatus.FORBIDDEN @@ -220,7 +222,7 @@ def test_metadata_too_large( A ``MetadataTooLarge`` exception is raised if the metadata given is too large. """ - with pytest.raises(MetadataTooLargeError) as exc: + with pytest.raises(expected_exception=MetadataTooLargeError) as exc: vws_client.add_target( name="x", width=1, @@ -260,7 +262,7 @@ def test_request_time_too_skewed( # >= 1 ticks are acceptable. with ( freeze_time(auto_tick_seconds=time_difference_from_now), - pytest.raises(RequestTimeTooSkewedError) as exc, + pytest.raises(expected_exception=RequestTimeTooSkewedError) as exc, ): vws_client.get_target_record(target_id=target_id) @@ -285,7 +287,9 @@ def test_authentication_failure( with MockVWS() as mock: mock.add_database(database=database) - with pytest.raises(AuthenticationFailureError) as exc: + with pytest.raises( + expected_exception=AuthenticationFailureError + ) as exc: vws_client.add_target( name="x", width=1, @@ -313,7 +317,7 @@ def test_target_status_not_success( application_metadata=None, ) - with pytest.raises(TargetStatusNotSuccessError) as exc: + with pytest.raises(expected_exception=TargetStatusNotSuccessError) as exc: vws_client.update_target(target_id=target_id) assert exc.value.response.status_code == HTTPStatus.FORBIDDEN @@ -353,7 +357,7 @@ def test_base_exception( """ ``VWSException``s has a response property. """ - with pytest.raises(VWSError) as exc: + with pytest.raises(expected_exception=VWSError) as exc: vws_client.get_target_record(target_id="a") assert exc.value.response.status_code == HTTPStatus.NOT_FOUND From ad0795cf48d84f8ee6cf533963bc4510aaf92d1d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 25 Dec 2024 10:20:18 +0000 Subject: [PATCH 0566/1003] Bump mypy-strict-kwargs from 2024.12.24 to 2024.12.25 Bumps [mypy-strict-kwargs](https://github.com/adamtheturtle/mypy-strict-kwargs) from 2024.12.24 to 2024.12.25. - [Release notes](https://github.com/adamtheturtle/mypy-strict-kwargs/releases) - [Changelog](https://github.com/adamtheturtle/mypy-strict-kwargs/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/mypy-strict-kwargs/compare/2024.12.24...2024.12.25) --- updated-dependencies: - dependency-name: mypy-strict-kwargs dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6db511fff..726dbd4ca 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -49,7 +49,7 @@ optional-dependencies.dev = [ "furo==2024.8.6", "interrogate==1.7.0", "mypy[faster-cache]==1.14.0", - "mypy-strict-kwargs==2024.12.24", + "mypy-strict-kwargs==2024.12.25", "pre-commit==4.0.1", "pydocstyle==6.3", "pyenchant==3.3.0rc1", From 64607a2fa7dfdd670e8f4399eb5c5592bd2356ba Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 26 Dec 2024 07:01:41 +0000 Subject: [PATCH 0567/1003] Disable type ignore comments for pyright --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index 726dbd4ca..6ee5eec29 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -341,6 +341,7 @@ plugins = [ [tool.pyright] +enableTypeIgnoreComments = false reportUnnecessaryTypeIgnoreComment = true typeCheckingMode = "strict" From 8f2631e60c3a9c8547898f2cd85a3acd4f2127cc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 27 Dec 2024 10:59:42 +0000 Subject: [PATCH 0568/1003] Bump doccmd from 2024.11.14 to 2024.12.26 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.11.14 to 2024.12.26. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.11.14...2024.12.26) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6ee5eec29..3c82dd032 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.21.2", "doc8==1.1.2", - "doccmd==2024.11.14", + "doccmd==2024.12.26", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From b641d7e40e2ecfd700eebb168a4fd99624a245cc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 30 Dec 2024 10:54:02 +0000 Subject: [PATCH 0569/1003] Bump actionlint-py from 1.7.4.20 to 1.7.5.21 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.7.4.20 to 1.7.5.21. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.7.4.20...v1.7.5.21) --- updated-dependencies: - dependency-name: actionlint-py dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3c82dd032..5bf392282 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -39,7 +39,7 @@ dependencies = [ "vws-auth-tools>=2024.7.12", ] optional-dependencies.dev = [ - "actionlint-py==1.7.4.20", + "actionlint-py==1.7.5.21", "check-manifest==0.50", "deptry==0.21.2", "doc8==1.1.2", From d8c738d775ea332b6d1bd19fc32da9b6cfafe512 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 30 Dec 2024 11:03:32 +0000 Subject: [PATCH 0570/1003] Set release fetch-depth to 0 with a comment why --- .github/workflows/release.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 14bba54cc..e25f5f32e 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -30,6 +30,12 @@ jobs: # See # https://github.com/stefanzweifel/git-auto-commit-action?tab=readme-ov-file#push-to-protected-branches token: ${{ secrets.RELEASE_PAT }} + # Fetch all history including tags. + # Needed to find the latest tag. + # + # Also, avoids + # https://github.com/stefanzweifel/git-auto-commit-action/issues/99. + fetch-depth: 0 - name: Install uv uses: astral-sh/setup-uv@v5 From 3e9e239dab2da489e4af0a473d513f3105ebdaec Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 31 Dec 2024 10:14:09 +0000 Subject: [PATCH 0571/1003] Bump mypy[faster-cache] from 1.14.0 to 1.14.1 Bumps [mypy[faster-cache]](https://github.com/python/mypy) from 1.14.0 to 1.14.1. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.14.0...v1.14.1) --- updated-dependencies: - dependency-name: mypy[faster-cache] dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5bf392282..c0f6a28f7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", - "mypy[faster-cache]==1.14.0", + "mypy[faster-cache]==1.14.1", "mypy-strict-kwargs==2024.12.25", "pre-commit==4.0.1", "pydocstyle==6.3", From abac5901fdad9feed0e2c44130d0ca781e41ee2a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 2 Jan 2025 10:45:59 +0000 Subject: [PATCH 0572/1003] Bump sphinx-substitution-extensions from 2024.10.17 to 2025.1.2 Bumps [sphinx-substitution-extensions](https://github.com/adamtheturtle/sphinx-substitution-extensions) from 2024.10.17 to 2025.1.2. - [Release notes](https://github.com/adamtheturtle/sphinx-substitution-extensions/releases) - [Changelog](https://github.com/adamtheturtle/sphinx-substitution-extensions/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/sphinx-substitution-extensions/compare/2024.10.17...2025.01.02) --- updated-dependencies: - dependency-name: sphinx-substitution-extensions dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c0f6a28f7..8819a5885 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -70,7 +70,7 @@ optional-dependencies.dev = [ "shfmt-py==3.7.0.1", "sphinx==8.1.3", "sphinx-copybutton==0.5.2", - "sphinx-substitution-extensions==2024.10.17", + "sphinx-substitution-extensions==2025.1.2", "sphinxcontrib-spelling==8.0.1", "sybil==9.0.0", "types-requests==2.32.0.20241016", From 2405e89225dc55d38f1f7d70465a275a88e87aa2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 3 Jan 2025 10:31:36 +0000 Subject: [PATCH 0573/1003] Bump ruff from 0.8.4 to 0.8.5 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.8.4 to 0.8.5. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.8.4...0.8.5) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8819a5885..3007e1da3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.4", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.8.4", + "ruff==0.8.5", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 5c309c01e1c4f5e5f0706182acfe3c5a19fe26e0 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 5 Jan 2025 10:25:40 +0000 Subject: [PATCH 0574/1003] Git ignore DS_Store files --- .gitignore | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 0a4d3ec0c..556e31308 100644 --- a/.gitignore +++ b/.gitignore @@ -98,8 +98,9 @@ secrets.tar # mypy .mypy_cache/ -# macOS attributes -*.DS_Store +# Ignore Mac DS_Store files +.DS_Store +**/.DS_Store # pyre .pyre/ From 7da543de3eeee679b6f114223173afea9bfb2a6e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 5 Jan 2025 12:44:48 +0000 Subject: [PATCH 0575/1003] Add sphinx-lint --- .pre-commit-config.yaml | 69 +++++++++++++++++++++++------------------ pyproject.toml | 1 + 2 files changed, 40 insertions(+), 30 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 1f294554b..ea72086b0 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -9,6 +9,7 @@ ci: # We therefore cannot use those dependencies in pre-commit CI. skip: - actionlint + - sphinx-lint - check-manifest - deptry - doc8 @@ -77,14 +78,14 @@ repos: language: python pass_filenames: false types_or: [yaml] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: docformatter name: docformatter entry: uv run --extra=dev -m docformatter --in-place language: python types_or: [python] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: shellcheck name: shellcheck @@ -92,7 +93,7 @@ repos: language: python pass_filenames: false types_or: [shell] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: shellcheck-docs name: shellcheck-docs @@ -100,14 +101,14 @@ repos: --shell=bash" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: shfmt name: shfmt entry: uv run --extra=dev shfmt --write --space-redirects --indent=4 language: python types_or: [shell] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: shfmt-docs name: shfmt-docs @@ -115,7 +116,7 @@ repos: --no-pad-file --command="shfmt --write --space-redirects --indent=4" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: mypy name: mypy @@ -124,7 +125,7 @@ repos: language: python types_or: [python, toml] pass_filenames: false - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: mypy-docs name: mypy-docs @@ -132,7 +133,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="mypy" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: check-manifest name: check-manifest @@ -140,7 +141,7 @@ repos: entry: uv run --extra=dev -m check_manifest language: python pass_filenames: false - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: pyright name: pyright @@ -149,7 +150,7 @@ repos: language: python types_or: [python, toml] pass_filenames: false - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: pyright-docs name: pyright-docs @@ -157,7 +158,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="pyright" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: vulture name: vulture @@ -165,14 +166,14 @@ repos: language: python types_or: [python] pass_filenames: false - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: vulture-docs name: vulture docs entry: uv run --extra=dev doccmd --language=python --command="vulture" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: pyroma name: pyroma @@ -180,14 +181,14 @@ repos: language: python pass_filenames: false types_or: [toml] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: deptry name: deptry entry: uv run --extra=dev -m deptry src/ language: python pass_filenames: false - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: pylint name: pylint @@ -195,7 +196,7 @@ repos: language: python stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: pylint-docs name: pylint-docs @@ -203,28 +204,28 @@ repos: language: python stages: [manual] types_or: [markdown, rst] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: ruff-check-fix name: Ruff check fix entry: uv run --extra=dev -m ruff check --fix language: python types_or: [python] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: ruff-check-fix-docs name: Ruff check fix docs entry: uv run --extra=dev doccmd --language=python --command="ruff check --fix" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: ruff-format-fix name: Ruff format entry: uv run --extra=dev -m ruff format language: python types_or: [python] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: ruff-format-fix-docs name: Ruff format docs @@ -232,28 +233,28 @@ repos: format" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: doc8 name: doc8 entry: uv run --extra=dev -m doc8 language: python types_or: [rst] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: interrogate name: interrogate entry: uv run --extra=dev -m interrogate language: python types_or: [python] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: interrogate-docs name: interrogate docs entry: uv run --extra=dev doccmd --language=python --command="interrogate" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: pyproject-fmt-fix name: pyproject-fmt @@ -261,7 +262,7 @@ repos: language: python types_or: [toml] files: pyproject.toml - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: linkcheck name: linkcheck @@ -270,7 +271,7 @@ repos: types_or: [rst] stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: spelling name: spelling @@ -279,7 +280,7 @@ repos: types_or: [rst] stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: docs name: Build Documentation @@ -287,7 +288,7 @@ repos: language: python stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: pyright-verifytypes name: pyright-verifytypes @@ -296,11 +297,19 @@ repos: language: python pass_filenames: false types_or: [python] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] - id: yamlfix name: yamlfix entry: uv run --extra=dev yamlfix language: python types_or: [yaml] - additional_dependencies: [uv==0.4.25] + additional_dependencies: [uv==0.5.14] + + - id: sphinx-lint + name: sphinx-lint + entry: uv run --extra=dev sphinx-lint --enable=all --disable=line-too-long + *.rst + language: python + types_or: [rst] + additional_dependencies: [uv==0.5.14] diff --git a/pyproject.toml b/pyproject.toml index 3007e1da3..64653715f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -70,6 +70,7 @@ optional-dependencies.dev = [ "shfmt-py==3.7.0.1", "sphinx==8.1.3", "sphinx-copybutton==0.5.2", + "sphinx-lint==1.0.0", "sphinx-substitution-extensions==2025.1.2", "sphinxcontrib-spelling==8.0.1", "sybil==9.0.0", From 4cca633998b09d0e411fe6a0dd6b0ef1382e126b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 5 Jan 2025 12:49:23 +0000 Subject: [PATCH 0576/1003] Add sphinx-lint --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ea72086b0..0373a88bb 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -309,7 +309,7 @@ repos: - id: sphinx-lint name: sphinx-lint entry: uv run --extra=dev sphinx-lint --enable=all --disable=line-too-long - *.rst + README.rst CHANGELOG.rst language: python types_or: [rst] additional_dependencies: [uv==0.5.14] From 83db11de8b240c59aad39de1330307caf28aa399 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 5 Jan 2025 13:01:48 +0000 Subject: [PATCH 0577/1003] Add sphinx-lint --- .pre-commit-config.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 0373a88bb..ea4c5ebc2 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -309,7 +309,6 @@ repos: - id: sphinx-lint name: sphinx-lint entry: uv run --extra=dev sphinx-lint --enable=all --disable=line-too-long - README.rst CHANGELOG.rst language: python types_or: [rst] additional_dependencies: [uv==0.5.14] From c8128785f2b615d12e9fef35970344acd7dff7f8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 6 Jan 2025 10:50:08 +0000 Subject: [PATCH 0578/1003] Bump ruff from 0.8.5 to 0.8.6 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.8.5 to 0.8.6. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.8.5...0.8.6) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 64653715f..6bacaed13 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.4", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.8.5", + "ruff==0.8.6", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 0e0cb9272b36cab04f4307a4b9f7a5b2f5e8646e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 6 Jan 2025 10:50:17 +0000 Subject: [PATCH 0579/1003] Bump actionlint-py from 1.7.5.21 to 1.7.6.22 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.7.5.21 to 1.7.6.22. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.7.5.21...v1.7.6.22) --- updated-dependencies: - dependency-name: actionlint-py dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 64653715f..daa0a562d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -39,7 +39,7 @@ dependencies = [ "vws-auth-tools>=2024.7.12", ] optional-dependencies.dev = [ - "actionlint-py==1.7.5.21", + "actionlint-py==1.7.6.22", "check-manifest==0.50", "deptry==0.21.2", "doc8==1.1.2", From cec8a50c73dd3b18d9e37c65b09222b694bc38f2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 6 Jan 2025 10:50:27 +0000 Subject: [PATCH 0580/1003] Bump pygments from 2.18.0 to 2.19.0 Bumps [pygments](https://github.com/pygments/pygments) from 2.18.0 to 2.19.0. - [Release notes](https://github.com/pygments/pygments/releases) - [Changelog](https://github.com/pygments/pygments/blob/master/CHANGES) - [Commits](https://github.com/pygments/pygments/compare/2.18.0...2.19.0) --- updated-dependencies: - dependency-name: pygments dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 64653715f..a73ffc731 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pre-commit==4.0.1", "pydocstyle==6.3", "pyenchant==3.3.0rc1", - "pygments==2.18.0", + "pygments==2.19.0", "pylint==3.3.3", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.5.0", From c5e71b61a5fbf3096cddd18304e473a729cb1a63 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 7 Jan 2025 10:25:13 +0000 Subject: [PATCH 0581/1003] Bump pygments from 2.19.0 to 2.19.1 Bumps [pygments](https://github.com/pygments/pygments) from 2.19.0 to 2.19.1. - [Release notes](https://github.com/pygments/pygments/releases) - [Changelog](https://github.com/pygments/pygments/blob/master/CHANGES) - [Commits](https://github.com/pygments/pygments/compare/2.19.0...2.19.1) --- updated-dependencies: - dependency-name: pygments dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1037669a8..7808e35f5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pre-commit==4.0.1", "pydocstyle==6.3", "pyenchant==3.3.0rc1", - "pygments==2.19.0", + "pygments==2.19.1", "pylint==3.3.3", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.5.0", From d1cdad93a0b67da8790e6891a0717f43635d5698 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 Jan 2025 10:37:29 +0000 Subject: [PATCH 0582/1003] Bump deptry from 0.21.2 to 0.22.0 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.21.2 to 0.22.0. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.21.2...0.22.0) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7808e35f5..6debe88fc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ dependencies = [ optional-dependencies.dev = [ "actionlint-py==1.7.6.22", "check-manifest==0.50", - "deptry==0.21.2", + "deptry==0.22.0", "doc8==1.1.2", "doccmd==2024.12.26", "docformatter==1.7.5", From d1f2c40bbabee195aaa5042f9188232035f74cc7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 Jan 2025 10:37:36 +0000 Subject: [PATCH 0583/1003] Bump doccmd from 2024.12.26 to 2025.1.11 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2024.12.26 to 2025.1.11. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2024.12.26...2025.01.11) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7808e35f5..86ad9ace3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.21.2", "doc8==1.1.2", - "doccmd==2024.12.26", + "doccmd==2025.1.11", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From 8ca426106fc6de07929bc7773935e3b33cbb49c1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 Jan 2025 10:37:53 +0000 Subject: [PATCH 0584/1003] Bump ruff from 0.8.6 to 0.9.1 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.8.6 to 0.9.1. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.8.6...0.9.1) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7808e35f5..6644e66c8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.4", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.8.6", + "ruff==0.9.1", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From e8b9c02a0f7bfe474475a7c28ac6565d0b26cfb7 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 13 Jan 2025 19:49:07 +0000 Subject: [PATCH 0585/1003] Stop shadowing Python builtin "types" --- CHANGELOG.rst | 8 ++------ docs/source/api-reference.rst | 2 +- src/vws/exceptions/base_exceptions.py | 2 +- src/vws/exceptions/custom_exceptions.py | 2 +- src/vws/query.py | 2 +- src/vws/{vws.py => response.py} | 2 +- 6 files changed, 7 insertions(+), 11 deletions(-) rename src/vws/{vws.py => response.py} (99%) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index b18bc5e4f..346066c86 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,16 +4,12 @@ Changelog Next ---- -2024.09.21 ------------- - -2024.09.04.1 ------------- +* Move ``Response`` from ``vws.response`` to ``vws.response``. 2024.09.04 ------------ -* Move ``Response`` from ``vws.exceptions.response`` to ``vws.types``. +* Move ``Response`` from ``vws.exceptions.response`` to ``vws.response``. * Add ``raw`` field to ``Response``. 2024.09.03 diff --git a/docs/source/api-reference.rst b/docs/source/api-reference.rst index 5b7027550..01bba09b2 100644 --- a/docs/source/api-reference.rst +++ b/docs/source/api-reference.rst @@ -13,6 +13,6 @@ API Reference :undoc-members: :members: -.. automodule:: vws.types +.. automodule:: vws.response :undoc-members: :members: diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index b0888f93f..943323bfd 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -5,7 +5,7 @@ from beartype import beartype -from vws.types import Response +from vws.response import Response @beartype diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index f05d59b41..11d47a67a 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -6,7 +6,7 @@ from beartype import beartype -from vws.types import Response +from vws.response import Response @beartype diff --git a/src/vws/query.py b/src/vws/query.py index 84144691c..96122aa14 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -27,7 +27,7 @@ ) from vws.include_target_data import CloudRecoIncludeTargetData from vws.reports import QueryResult, TargetData -from vws.types import Response +from vws.response import Response _ImageType = io.BytesIO | BinaryIO diff --git a/src/vws/vws.py b/src/vws/response.py similarity index 99% rename from src/vws/vws.py rename to src/vws/response.py index f101a7ecc..f87766571 100644 --- a/src/vws/vws.py +++ b/src/vws/response.py @@ -46,7 +46,7 @@ TargetStatuses, TargetSummaryReport, ) -from vws.types import Response +from vws.response import Response _ImageType = io.BytesIO | BinaryIO From 91d7fffa311e9e0ea6ec18fb6799c2a5e588dd27 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 13 Jan 2025 19:51:53 +0000 Subject: [PATCH 0586/1003] Revert "Stop shadowing Python builtin "types"" This reverts commit e8b9c02a0f7bfe474475a7c28ac6565d0b26cfb7. --- CHANGELOG.rst | 8 ++++++-- docs/source/api-reference.rst | 2 +- src/vws/exceptions/base_exceptions.py | 2 +- src/vws/exceptions/custom_exceptions.py | 2 +- src/vws/query.py | 2 +- src/vws/{response.py => vws.py} | 2 +- 6 files changed, 11 insertions(+), 7 deletions(-) rename src/vws/{response.py => vws.py} (99%) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 346066c86..b18bc5e4f 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,12 +4,16 @@ Changelog Next ---- -* Move ``Response`` from ``vws.response`` to ``vws.response``. +2024.09.21 +------------ + +2024.09.04.1 +------------ 2024.09.04 ------------ -* Move ``Response`` from ``vws.exceptions.response`` to ``vws.response``. +* Move ``Response`` from ``vws.exceptions.response`` to ``vws.types``. * Add ``raw`` field to ``Response``. 2024.09.03 diff --git a/docs/source/api-reference.rst b/docs/source/api-reference.rst index 01bba09b2..5b7027550 100644 --- a/docs/source/api-reference.rst +++ b/docs/source/api-reference.rst @@ -13,6 +13,6 @@ API Reference :undoc-members: :members: -.. automodule:: vws.response +.. automodule:: vws.types :undoc-members: :members: diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index 943323bfd..b0888f93f 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -5,7 +5,7 @@ from beartype import beartype -from vws.response import Response +from vws.types import Response @beartype diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index 11d47a67a..f05d59b41 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -6,7 +6,7 @@ from beartype import beartype -from vws.response import Response +from vws.types import Response @beartype diff --git a/src/vws/query.py b/src/vws/query.py index 96122aa14..84144691c 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -27,7 +27,7 @@ ) from vws.include_target_data import CloudRecoIncludeTargetData from vws.reports import QueryResult, TargetData -from vws.response import Response +from vws.types import Response _ImageType = io.BytesIO | BinaryIO diff --git a/src/vws/response.py b/src/vws/vws.py similarity index 99% rename from src/vws/response.py rename to src/vws/vws.py index f87766571..f101a7ecc 100644 --- a/src/vws/response.py +++ b/src/vws/vws.py @@ -46,7 +46,7 @@ TargetStatuses, TargetSummaryReport, ) -from vws.response import Response +from vws.types import Response _ImageType = io.BytesIO | BinaryIO From cfa9a065ee95cff51de806d33113612b58cf7769 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 13 Jan 2025 19:52:24 +0000 Subject: [PATCH 0587/1003] Stop shadowing Python builtin "types" --- docs/source/api-reference.rst | 2 +- src/vws/exceptions/base_exceptions.py | 2 +- src/vws/exceptions/custom_exceptions.py | 2 +- src/vws/query.py | 2 +- src/vws/{types.py => response.py} | 0 src/vws/vws.py | 2 +- 6 files changed, 5 insertions(+), 5 deletions(-) rename src/vws/{types.py => response.py} (100%) diff --git a/docs/source/api-reference.rst b/docs/source/api-reference.rst index 5b7027550..01bba09b2 100644 --- a/docs/source/api-reference.rst +++ b/docs/source/api-reference.rst @@ -13,6 +13,6 @@ API Reference :undoc-members: :members: -.. automodule:: vws.types +.. automodule:: vws.response :undoc-members: :members: diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index b0888f93f..943323bfd 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -5,7 +5,7 @@ from beartype import beartype -from vws.types import Response +from vws.response import Response @beartype diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index f05d59b41..11d47a67a 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -6,7 +6,7 @@ from beartype import beartype -from vws.types import Response +from vws.response import Response @beartype diff --git a/src/vws/query.py b/src/vws/query.py index 84144691c..96122aa14 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -27,7 +27,7 @@ ) from vws.include_target_data import CloudRecoIncludeTargetData from vws.reports import QueryResult, TargetData -from vws.types import Response +from vws.response import Response _ImageType = io.BytesIO | BinaryIO diff --git a/src/vws/types.py b/src/vws/response.py similarity index 100% rename from src/vws/types.py rename to src/vws/response.py diff --git a/src/vws/vws.py b/src/vws/vws.py index f101a7ecc..f87766571 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -46,7 +46,7 @@ TargetStatuses, TargetSummaryReport, ) -from vws.types import Response +from vws.response import Response _ImageType = io.BytesIO | BinaryIO From fa88b5aba6cb2644051f897791580077599246e9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 15 Jan 2025 10:57:17 +0000 Subject: [PATCH 0588/1003] Bump pyright from 1.1.391 to 1.1.392 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.391 to 1.1.392. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.391...v1.1.392) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 95088de94..1fe83f189 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pylint==3.3.3", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.5.0", - "pyright==1.1.391", + "pyright==1.1.392", "pyroma==4.2", "pytest==8.3.4", "pytest-cov==6.0.0", From ec09302f088a783c88888bf67a001f78480dcef1 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 16 Jan 2025 08:29:31 +0000 Subject: [PATCH 0589/1003] Bump uv in pre-commit hooks to 0.5.20 --- .pre-commit-config.yaml | 62 ++++++++++++++++++++--------------------- 1 file changed, 31 insertions(+), 31 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ea4c5ebc2..8cfad7775 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -78,14 +78,14 @@ repos: language: python pass_filenames: false types_or: [yaml] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: docformatter name: docformatter entry: uv run --extra=dev -m docformatter --in-place language: python types_or: [python] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: shellcheck name: shellcheck @@ -93,7 +93,7 @@ repos: language: python pass_filenames: false types_or: [shell] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: shellcheck-docs name: shellcheck-docs @@ -101,14 +101,14 @@ repos: --shell=bash" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: shfmt name: shfmt entry: uv run --extra=dev shfmt --write --space-redirects --indent=4 language: python types_or: [shell] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: shfmt-docs name: shfmt-docs @@ -116,7 +116,7 @@ repos: --no-pad-file --command="shfmt --write --space-redirects --indent=4" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: mypy name: mypy @@ -125,7 +125,7 @@ repos: language: python types_or: [python, toml] pass_filenames: false - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: mypy-docs name: mypy-docs @@ -133,7 +133,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="mypy" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: check-manifest name: check-manifest @@ -141,7 +141,7 @@ repos: entry: uv run --extra=dev -m check_manifest language: python pass_filenames: false - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: pyright name: pyright @@ -150,7 +150,7 @@ repos: language: python types_or: [python, toml] pass_filenames: false - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: pyright-docs name: pyright-docs @@ -158,7 +158,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="pyright" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: vulture name: vulture @@ -166,14 +166,14 @@ repos: language: python types_or: [python] pass_filenames: false - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: vulture-docs name: vulture docs entry: uv run --extra=dev doccmd --language=python --command="vulture" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: pyroma name: pyroma @@ -181,14 +181,14 @@ repos: language: python pass_filenames: false types_or: [toml] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: deptry name: deptry entry: uv run --extra=dev -m deptry src/ language: python pass_filenames: false - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: pylint name: pylint @@ -196,7 +196,7 @@ repos: language: python stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: pylint-docs name: pylint-docs @@ -204,28 +204,28 @@ repos: language: python stages: [manual] types_or: [markdown, rst] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: ruff-check-fix name: Ruff check fix entry: uv run --extra=dev -m ruff check --fix language: python types_or: [python] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: ruff-check-fix-docs name: Ruff check fix docs entry: uv run --extra=dev doccmd --language=python --command="ruff check --fix" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: ruff-format-fix name: Ruff format entry: uv run --extra=dev -m ruff format language: python types_or: [python] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: ruff-format-fix-docs name: Ruff format docs @@ -233,28 +233,28 @@ repos: format" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: doc8 name: doc8 entry: uv run --extra=dev -m doc8 language: python types_or: [rst] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: interrogate name: interrogate entry: uv run --extra=dev -m interrogate language: python types_or: [python] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: interrogate-docs name: interrogate docs entry: uv run --extra=dev doccmd --language=python --command="interrogate" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: pyproject-fmt-fix name: pyproject-fmt @@ -262,7 +262,7 @@ repos: language: python types_or: [toml] files: pyproject.toml - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: linkcheck name: linkcheck @@ -271,7 +271,7 @@ repos: types_or: [rst] stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: spelling name: spelling @@ -280,7 +280,7 @@ repos: types_or: [rst] stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: docs name: Build Documentation @@ -288,7 +288,7 @@ repos: language: python stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: pyright-verifytypes name: pyright-verifytypes @@ -297,18 +297,18 @@ repos: language: python pass_filenames: false types_or: [python] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: yamlfix name: yamlfix entry: uv run --extra=dev yamlfix language: python types_or: [yaml] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] - id: sphinx-lint name: sphinx-lint entry: uv run --extra=dev sphinx-lint --enable=all --disable=line-too-long language: python types_or: [rst] - additional_dependencies: [uv==0.5.14] + additional_dependencies: [uv==0.5.20] From 84ed631f22d6c48d0a176e967f7bf51d3360d1d3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 16 Jan 2025 10:55:30 +0000 Subject: [PATCH 0590/1003] Bump pyright from 1.1.392 to 1.1.392.post0 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.392 to 1.1.392.post0. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.392...v1.1.392.post0) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1fe83f189..fc80a4b8b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pylint==3.3.3", "pylint-per-file-ignores==1.3.2", "pyproject-fmt==2.5.0", - "pyright==1.1.392", + "pyright==1.1.392.post0", "pyroma==4.2", "pytest==8.3.4", "pytest-cov==6.0.0", From 381e4c14ac8d8101eb416f76450fdaf335c3c65a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 17 Jan 2025 10:12:52 +0000 Subject: [PATCH 0591/1003] Bump ruff from 0.9.1 to 0.9.2 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.9.1 to 0.9.2. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.9.1...0.9.2) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index fc80a4b8b..ffc039e6f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.4", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.9.1", + "ruff==0.9.2", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From e0b9f4304803a9d303b2ecfa8dae97c3297576cc Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 17 Jan 2025 21:42:29 +0000 Subject: [PATCH 0592/1003] Use new format for pylint-per-file-ignores --- pyproject.toml | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index ffc039e6f..7876b245e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pyenchant==3.3.0rc1", "pygments==2.19.1", "pylint==3.3.3", - "pylint-per-file-ignores==1.3.2", + "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.5.0", "pyright==1.1.392.post0", "pyroma==4.2", @@ -244,16 +244,14 @@ disable = [ 'useless-type-doc', ] -# This format is described in the following issue: -# https://github.com/christopherpickering/pylint-per-file-ignores/issues/160 -# # We ignore invalid names because: # - We want to use generated module names, which may not be valid, but are never seen. -# - We want to use global variables in documentation, which may not be uppercase -per-file-ignores = """ -docs/:invalid-name -doccmd_README_rst.*.py:invalid-name -""" +# - We want to use global variables in documentation, which may not be uppercase. +# - conf.py is a Sphinx configuration file which requires lowercase global variable names. +per-file-ignores = [ + "docs/:invalid-name", + "doccmd_README_rst.*.py:invalid-name", +] [tool.pylint.'FORMAT'] From 62b7929c87295b6b84e20f5e10c327fbd3170403 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 20 Jan 2025 10:44:58 +0000 Subject: [PATCH 0593/1003] Bump actionlint-py from 1.7.6.22 to 1.7.7.23 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.7.6.22 to 1.7.7.23. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.7.6.22...v1.7.7.23) --- updated-dependencies: - dependency-name: actionlint-py dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7876b245e..ac82f3dae 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -39,7 +39,7 @@ dependencies = [ "vws-auth-tools>=2024.7.12", ] optional-dependencies.dev = [ - "actionlint-py==1.7.6.22", + "actionlint-py==1.7.7.23", "check-manifest==0.50", "deptry==0.22.0", "doc8==1.1.2", From be7bd0807c3abf3a71eb88ac2b06309aec2e9079 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 21 Jan 2025 10:56:35 +0000 Subject: [PATCH 0594/1003] Bump pre-commit from 4.0.1 to 4.1.0 Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 4.0.1 to 4.1.0. - [Release notes](https://github.com/pre-commit/pre-commit/releases) - [Changelog](https://github.com/pre-commit/pre-commit/blob/main/CHANGELOG.md) - [Commits](https://github.com/pre-commit/pre-commit/compare/v4.0.1...v4.1.0) --- updated-dependencies: - dependency-name: pre-commit dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ac82f3dae..ce014677f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -50,7 +50,7 @@ optional-dependencies.dev = [ "interrogate==1.7.0", "mypy[faster-cache]==1.14.1", "mypy-strict-kwargs==2024.12.25", - "pre-commit==4.0.1", + "pre-commit==4.1.0", "pydocstyle==6.3", "pyenchant==3.3.0rc1", "pygments==2.19.1", From 1db4390098d433c9a18e26b5d2b0013dd755a558 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 24 Jan 2025 10:38:35 +0000 Subject: [PATCH 0595/1003] Bump ruff from 0.9.2 to 0.9.3 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.9.2 to 0.9.3. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.9.2...0.9.3) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ce014677f..8380900e6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.4", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.9.2", + "ruff==0.9.3", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From effe06f77ac552a50acdc8f409eda201914e9123 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 27 Jan 2025 10:30:22 +0000 Subject: [PATCH 0596/1003] Bump deptry from 0.22.0 to 0.23.0 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.22.0 to 0.23.0. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.22.0...0.23.0) --- updated-dependencies: - dependency-name: deptry dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8380900e6..8321983b1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ dependencies = [ optional-dependencies.dev = [ "actionlint-py==1.7.7.23", "check-manifest==0.50", - "deptry==0.22.0", + "deptry==0.23.0", "doc8==1.1.2", "doccmd==2025.1.11", "docformatter==1.7.5", From b9b14c4a488a8a28017f388294a54cb2d1082ad7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 29 Jan 2025 10:31:31 +0000 Subject: [PATCH 0597/1003] Bump pylint from 3.3.3 to 3.3.4 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.3.3 to 3.3.4. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.3.3...v3.3.4) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8321983b1..04b173ec3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pyenchant==3.3.0rc1", "pygments==2.19.1", - "pylint==3.3.3", + "pylint==3.3.4", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.5.0", "pyright==1.1.392.post0", From 1c6c6a146b6eb9ee23faa18eedd82f9e0bff6ff4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 30 Jan 2025 10:33:08 +0000 Subject: [PATCH 0598/1003] Bump pyright from 1.1.392.post0 to 1.1.393 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.392.post0 to 1.1.393. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.392.post0...v1.1.393) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 04b173ec3..eb97626ac 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pylint==3.3.4", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.5.0", - "pyright==1.1.392.post0", + "pyright==1.1.393", "pyroma==4.2", "pytest==8.3.4", "pytest-cov==6.0.0", From d83dc0fc60a019e12c88c0eebb9cb07ed282a210 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 31 Jan 2025 10:12:44 +0000 Subject: [PATCH 0599/1003] Bump ruff from 0.9.3 to 0.9.4 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.9.3 to 0.9.4. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.9.3...0.9.4) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index eb97626ac..528d2a1da 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.4", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.9.3", + "ruff==0.9.4", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 72724e3a35848f2fa5b1941d09631c68a220c445 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 5 Feb 2025 10:40:00 +0000 Subject: [PATCH 0600/1003] Bump mypy[faster-cache] from 1.14.1 to 1.15.0 Bumps [mypy[faster-cache]](https://github.com/python/mypy) from 1.14.1 to 1.15.0. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.14.1...v1.15.0) --- updated-dependencies: - dependency-name: mypy[faster-cache] dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 528d2a1da..9d13cb32a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", - "mypy[faster-cache]==1.14.1", + "mypy[faster-cache]==1.15.0", "mypy-strict-kwargs==2024.12.25", "pre-commit==4.1.0", "pydocstyle==6.3", From 27e4ff50ce7d8f45770bedb2b296e24997a97773 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 7 Feb 2025 10:32:43 +0000 Subject: [PATCH 0601/1003] Bump ruff from 0.9.4 to 0.9.5 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.9.4 to 0.9.5. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.9.4...0.9.5) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9d13cb32a..25cfe33a3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.4", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.9.4", + "ruff==0.9.5", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 6cd98b652dc0b875aea5fbfa1e6756f25c4edbea Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 11 Feb 2025 10:14:24 +0000 Subject: [PATCH 0602/1003] Bump ruff from 0.9.5 to 0.9.6 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.9.5 to 0.9.6. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.9.5...0.9.6) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 25cfe33a3..42bf430f7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.4", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.9.5", + "ruff==0.9.6", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From e1285610787bebc584e3f2135fe4d99c73fd37c0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 12 Feb 2025 11:01:49 +0000 Subject: [PATCH 0603/1003] Bump pyright from 1.1.393 to 1.1.394 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.393 to 1.1.394. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.393...v1.1.394) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 42bf430f7..8c4119585 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pylint==3.3.4", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.5.0", - "pyright==1.1.393", + "pyright==1.1.394", "pyroma==4.2", "pytest==8.3.4", "pytest-cov==6.0.0", From e13c439e4816c10dfbe044910538025f1e65c3e9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 18 Feb 2025 10:50:57 +0000 Subject: [PATCH 0604/1003] Bump doccmd from 2025.1.11 to 2025.2.17 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.1.11 to 2025.2.17. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.01.11...2025.02.17) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8c4119585..f1a471279 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.23.0", "doc8==1.1.2", - "doccmd==2025.1.11", + "doccmd==2025.2.17", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From ce1e6ab169dc7f4cb26f41f4b43a53bec41b3179 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 20 Feb 2025 10:40:30 +0000 Subject: [PATCH 0605/1003] Bump pyproject-fmt from 2.5.0 to 2.5.1 Bumps [pyproject-fmt](https://github.com/tox-dev/toml-fmt) from 2.5.0 to 2.5.1. - [Release notes](https://github.com/tox-dev/toml-fmt/releases) - [Commits](https://github.com/tox-dev/toml-fmt/compare/pyproject-fmt/2.5.0...pyproject-fmt/2.5.1) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f1a471279..297222105 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pygments==2.19.1", "pylint==3.3.4", "pylint-per-file-ignores==1.4.0", - "pyproject-fmt==2.5.0", + "pyproject-fmt==2.5.1", "pyright==1.1.394", "pyroma==4.2", "pytest==8.3.4", From ef308f4e3b3db2e8a5b668fdc3b740c69246bc40 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 20 Feb 2025 10:40:36 +0000 Subject: [PATCH 0606/1003] Bump sphinx-substitution-extensions from 2025.1.2 to 2025.2.19 Bumps [sphinx-substitution-extensions](https://github.com/adamtheturtle/sphinx-substitution-extensions) from 2025.1.2 to 2025.2.19. - [Release notes](https://github.com/adamtheturtle/sphinx-substitution-extensions/releases) - [Changelog](https://github.com/adamtheturtle/sphinx-substitution-extensions/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/sphinx-substitution-extensions/compare/2025.01.02...2025.02.19) --- updated-dependencies: - dependency-name: sphinx-substitution-extensions dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f1a471279..36967d9bc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -71,7 +71,7 @@ optional-dependencies.dev = [ "sphinx==8.1.3", "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.0", - "sphinx-substitution-extensions==2025.1.2", + "sphinx-substitution-extensions==2025.2.19", "sphinxcontrib-spelling==8.0.1", "sybil==9.0.0", "types-requests==2.32.0.20241016", From aeb12cb061f732c534a0bd569c437e51ba650088 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 20 Feb 2025 10:45:54 +0000 Subject: [PATCH 0607/1003] Bump sybil from 9.0.0 to 9.1.0 Bumps [sybil](https://github.com/simplistix/sybil) from 9.0.0 to 9.1.0. - [Changelog](https://github.com/simplistix/sybil/blob/master/CHANGELOG.rst) - [Commits](https://github.com/simplistix/sybil/compare/9.0.0...9.1.0) --- updated-dependencies: - dependency-name: sybil dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4617145cd..16399ce7a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,7 +73,7 @@ optional-dependencies.dev = [ "sphinx-lint==1.0.0", "sphinx-substitution-extensions==2025.2.19", "sphinxcontrib-spelling==8.0.1", - "sybil==9.0.0", + "sybil==9.1.0", "types-requests==2.32.0.20241016", "vulture==2.14", "vws-python-mock==2024.8.30", From 5b5f08bec20e2c161225bb9f779e260a0fbe9052 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 20 Feb 2025 11:00:54 +0000 Subject: [PATCH 0608/1003] Bump sphinx from 8.1.3 to 8.2.0 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 8.1.3 to 8.2.0. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v8.1.3...v8.2.0) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 16399ce7a..6b77bb7a4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -68,7 +68,7 @@ optional-dependencies.dev = [ # use it to lint shell commands in GitHub workflow files. "shellcheck-py==0.10.0.1", "shfmt-py==3.7.0.1", - "sphinx==8.1.3", + "sphinx==8.2.0", "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.0", "sphinx-substitution-extensions==2025.2.19", From 34db2b50cdaa147e699db601317bc2be889ee0dc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 20 Feb 2025 11:00:55 +0000 Subject: [PATCH 0609/1003] Bump vws-python-mock from 2024.8.30 to 2025.2.18 Bumps [vws-python-mock](https://github.com/VWS-Python/vws-python-mock) from 2024.8.30 to 2025.2.18. - [Release notes](https://github.com/VWS-Python/vws-python-mock/releases) - [Changelog](https://github.com/VWS-Python/vws-python-mock/blob/main/CHANGELOG.rst) - [Commits](https://github.com/VWS-Python/vws-python-mock/compare/2024.08.30...2025.02.18) --- updated-dependencies: - dependency-name: vws-python-mock dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 16399ce7a..63bf52922 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -76,7 +76,7 @@ optional-dependencies.dev = [ "sybil==9.1.0", "types-requests==2.32.0.20241016", "vulture==2.14", - "vws-python-mock==2024.8.30", + "vws-python-mock==2025.2.18", "vws-test-fixtures==2023.3.5", "yamlfix==1.17.0", ] From e703605f962b1bf89c320895a46a1b3cc89ed7a5 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 20 Feb 2025 13:38:43 +0000 Subject: [PATCH 0610/1003] Add traceback to word list --- spelling_private_dict.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/spelling_private_dict.txt b/spelling_private_dict.txt index ec77ade47..ce782a4af 100644 --- a/spelling_private_dict.txt +++ b/spelling_private_dict.txt @@ -90,6 +90,7 @@ rgb str timestamp todo +traceback travis txt unmocked From e80f13e4f7eb7fd4d39bdfc3770223f129fa1c4c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 20 Feb 2025 13:47:01 +0000 Subject: [PATCH 0611/1003] Bump doccmd from 2025.2.17 to 2025.2.19 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.2.17 to 2025.2.19. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.02.17...2025.02.19) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6b77bb7a4..c97064e77 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.23.0", "doc8==1.1.2", - "doccmd==2025.2.17", + "doccmd==2025.2.19", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From a37bc0c4e65717bf575c77f3e3a82bd83b74180d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 20 Feb 2025 13:57:17 +0000 Subject: [PATCH 0612/1003] Remove unnecessary strategy from release.yml --- .github/workflows/release.yml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index e25f5f32e..5f18688d2 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -20,10 +20,6 @@ jobs: # This is needed for https://github.com/stefanzweifel/git-auto-commit-action. contents: write - strategy: - matrix: - python-version: ['3.12'] - steps: - uses: actions/checkout@v4 with: From 95d1f7252555bd05e805a733746694eec095881e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 20 Feb 2025 14:51:04 +0000 Subject: [PATCH 0613/1003] Make sure GitHub releases are marked as latest --- .github/workflows/release.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 5f18688d2..e0e8e6c11 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -79,6 +79,7 @@ jobs: uses: ncipollo/release-action@v1 with: tag: ${{ steps.tag_version.outputs.new_tag }} + makeLatest: true name: Release ${{ steps.tag_version.outputs.new_tag }} body: ${{ steps.tag_version.outputs.changelog }} From 91804f94b814b8cdb14b840f1b7983a3f664091c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 20 Feb 2025 19:09:23 +0000 Subject: [PATCH 0614/1003] Fix release parsing in conf.py --- docs/source/conf.py | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 3255877d6..e7a796f4a 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -6,6 +6,7 @@ import importlib.metadata from packaging.specifiers import SpecifierSet +from packaging.version import Version project = "VWS-Python" author = "Adam Dangoor" @@ -30,16 +31,16 @@ copybutton_exclude = ".linenos, .gp" # The version info for the project you're documenting, acts as replacement for -# |version| and |release|, also used in various other places throughout the +# |release|, also used in various other places throughout the # built documents. # # Use ``importlib.metadata.version`` as per -# https://setuptools-scm.readthedocs.io/en/latest/usage/#usage-from-sphinx -version = importlib.metadata.version(distribution_name=project) -# This method of getting the release from the version goes hand in hand with -# the ``post-release`` versioning scheme chosen in the ``setuptools-scm`` -# configuration. -release = version.split(sep=".post")[0] +# https://setuptools-scm.readthedocs.io/en/latest/usage/#usage-from-sphinx. +_version_string = importlib.metadata.version(distribution_name=project) +_version = Version(version=_version_string) +# GitHub release tags have the format YYYY.MM.DD, while Python requirement +# versions may have the format YYYY.M.D for single digit months and days. +release = ".".join(f"{part:02d}" for part in _version.release) project_metadata = importlib.metadata.metadata(distribution_name=project) From 37906612599247027b1eff5c1a5d29f8d6aba90f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 21 Feb 2025 08:40:18 +0000 Subject: [PATCH 0615/1003] Error in release process if trying to commit changes and there are none --- .github/workflows/release.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index e0e8e6c11..89ba2b4e6 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -65,6 +65,8 @@ jobs: with: commit_message: Bump CHANGELOG file_pattern: CHANGELOG.rst + # Error if there are no changes. + skip_dirty_check: true - name: Bump version and push tag id: tag_version From ea17aae6a2d7f09c5f83361511255e2924b17c89 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 21 Feb 2025 09:10:50 +0000 Subject: [PATCH 0616/1003] Enable the uv cache in CI --- .github/workflows/ci.yml | 3 +++ .github/workflows/lint.yml | 3 +++ .github/workflows/release.yml | 3 +++ 3 files changed, 9 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a97d1ec58..a2ce97e41 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -27,6 +27,9 @@ jobs: - name: Install uv uses: astral-sh/setup-uv@v5 + with: + enable-cache: true + cache-dependency-glob: '**/pyproject.toml' - name: Run tests run: | diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 2a3910dd7..ab512c738 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -27,6 +27,9 @@ jobs: - name: Install uv uses: astral-sh/setup-uv@v5 + with: + enable-cache: true + cache-dependency-glob: '**/pyproject.toml' - name: Lint run: | diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 89ba2b4e6..e44c847b8 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -35,6 +35,9 @@ jobs: - name: Install uv uses: astral-sh/setup-uv@v5 + with: + enable-cache: true + cache-dependency-glob: '**/pyproject.toml' - name: Calver calculate version uses: StephaneBour/actions-calver@master From 86126a6e594e9defa3dc229d582885cd0fddda58 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 21 Feb 2025 10:52:59 +0000 Subject: [PATCH 0617/1003] Bump ruff from 0.9.6 to 0.9.7 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.9.6 to 0.9.7. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.9.6...0.9.7) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c97064e77..0dbc1f172 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.4", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.9.6", + "ruff==0.9.7", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 56f93d3d7f356bc0ca01455c187070922a02b88b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 21 Feb 2025 10:53:05 +0000 Subject: [PATCH 0618/1003] Bump doccmd from 2025.2.19 to 2025.2.20.7 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.2.19 to 2025.2.20.7. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.02.19...2025.02.20.7) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c97064e77..67cb564bc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.23.0", "doc8==1.1.2", - "doccmd==2025.2.19", + "doccmd==2025.2.20.7", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From 94f256d5f71d2d639decba4d11bb3b608a16cca8 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 21 Feb 2025 12:16:49 +0000 Subject: [PATCH 0619/1003] Remove unused version setting in conf.py --- docs/source/conf.py | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index e7a796f4a..c6f6230bb 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -6,7 +6,6 @@ import importlib.metadata from packaging.specifiers import SpecifierSet -from packaging.version import Version project = "VWS-Python" author = "Adam Dangoor" @@ -30,19 +29,6 @@ # https://sphinx-copybutton.readthedocs.io/en/latest/use.html#automatic-exclusion-of-prompts-from-the-copies. copybutton_exclude = ".linenos, .gp" -# The version info for the project you're documenting, acts as replacement for -# |release|, also used in various other places throughout the -# built documents. -# -# Use ``importlib.metadata.version`` as per -# https://setuptools-scm.readthedocs.io/en/latest/usage/#usage-from-sphinx. -_version_string = importlib.metadata.version(distribution_name=project) -_version = Version(version=_version_string) -# GitHub release tags have the format YYYY.MM.DD, while Python requirement -# versions may have the format YYYY.M.D for single digit months and days. -release = ".".join(f"{part:02d}" for part in _version.release) - - project_metadata = importlib.metadata.metadata(distribution_name=project) requires_python = project_metadata["Requires-Python"] specifiers = SpecifierSet(specifiers=requires_python) @@ -89,7 +75,6 @@ rst_prolog = f""" .. |project| replace:: {project} -.. |release| replace:: {release} .. |minimum-python-version| replace:: {minimum_python_version} .. |github-owner| replace:: VWS-Python .. |github-repository| replace:: vws-python From a42aa17bce274f17184da429dc3fce1d7956d41b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 21 Feb 2025 12:23:52 +0000 Subject: [PATCH 0620/1003] Remove double setting of autoclass content - just use both --- docs/source/conf.py | 1 - 1 file changed, 1 deletion(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index c6f6230bb..924fc9d41 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -56,7 +56,6 @@ # Output file base name for HTML help builder. htmlhelp_basename = "VWSPYTHONdoc" -autoclass_content = "init" intersphinx_mapping = { "python": (f"https://docs.python.org/{minimum_python_version}", None), } From 81e270b44b52d4af5a25b97b05456f42aa511ba9 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 21 Feb 2025 21:15:59 +0000 Subject: [PATCH 0621/1003] Use SphinxConfig to avoid some duplication --- docs/source/conf.py | 12 ++++++++++-- pyproject.toml | 1 + 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 924fc9d41..8c7e78f05 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -4,11 +4,19 @@ """ import importlib.metadata +from pathlib import Path from packaging.specifiers import SpecifierSet +from sphinx_pyproject import SphinxConfig -project = "VWS-Python" -author = "Adam Dangoor" +_pyproject_file = Path(__file__).parent.parent.parent / "pyproject.toml" +_pyproject_config = SphinxConfig( + pyproject_file=_pyproject_file, + config_overrides={"version": None}, +) + +project = _pyproject_config.name +author = _pyproject_config.author extensions = [ "sphinx_copybutton", diff --git a/pyproject.toml b/pyproject.toml index 67cb564bc..11e82235f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -71,6 +71,7 @@ optional-dependencies.dev = [ "sphinx==8.2.0", "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.0", + "sphinx-pyproject==0.3.0", "sphinx-substitution-extensions==2025.2.19", "sphinxcontrib-spelling==8.0.1", "sybil==9.1.0", From e7aa907bec4f3aa56f5708069bb00f02fb9e2e7d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 22 Feb 2025 21:21:13 +0000 Subject: [PATCH 0622/1003] Switch from ReadTheDocs to GitHub Pages --- .github/workflows/publish-site.yml | 27 +++++++++++++++++++++++++++ README.rst | 7 ++----- docs/source/index.rst | 1 - pyproject.toml | 3 +-- readthedocs.yaml | 18 ------------------ 5 files changed, 30 insertions(+), 26 deletions(-) create mode 100644 .github/workflows/publish-site.yml delete mode 100644 readthedocs.yaml diff --git a/.github/workflows/publish-site.yml b/.github/workflows/publish-site.yml new file mode 100644 index 000000000..4ca927ccb --- /dev/null +++ b/.github/workflows/publish-site.yml @@ -0,0 +1,27 @@ +--- +name: Deploy documentation + +on: + push: + branches: [main] + pull_request: + branches: [main] + +jobs: + pages: + runs-on: ubuntu-latest + environment: + name: ${{ github.ref_name == 'main' && 'github-pages' || 'development' }} + url: ${{ steps.deployment.outputs.page_url }} + permissions: + pages: write + id-token: write + steps: + - id: deployment + uses: sphinx-notes/pages@v3 + with: + documentation_path: docs/source + pyproject_extras: dev + python_version: '3.13' + sphinx_build_options: -W + publish: ${{ github.ref_name == 'main' }} diff --git a/README.rst b/README.rst index 730535169..d7943b35f 100644 --- a/README.rst +++ b/README.rst @@ -1,4 +1,4 @@ -|Build Status| |codecov| |PyPI| |Documentation Status| +|Build Status| |codecov| |PyPI| vws-python ========== @@ -67,8 +67,7 @@ Getting Started Full Documentation ------------------ -See the `full -documentation `__. +See the `full documentation `__. .. |Build Status| image:: https://github.com/VWS-Python/vws-python/actions/workflows/ci.yml/badge.svg?branch=main :target: https://github.com/VWS-Python/vws-python/actions @@ -76,6 +75,4 @@ documentation `__. :target: https://codecov.io/gh/VWS-Python/vws-python .. |PyPI| image:: https://badge.fury.io/py/VWS-Python.svg :target: https://badge.fury.io/py/VWS-Python -.. |Documentation Status| image:: https://readthedocs.org/projects/vws-python/badge/?version=latest - :target: https://vws-python.readthedocs.io/en/latest/?badge=latest .. |minimum-python-version| replace:: 3.12 diff --git a/docs/source/index.rst b/docs/source/index.rst index 3c89de779..505d6569a 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -114,7 +114,6 @@ See https://vws-python-mock.readthedocs.io/en/latest/differences-to-vws.html for .. _VWS Python Mock: https://github.com/VWS-Python/vws-python-mock - Reference --------- diff --git a/pyproject.toml b/pyproject.toml index 11e82235f..f72b912e7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -82,7 +82,7 @@ optional-dependencies.dev = [ "yamlfix==1.17.0", ] optional-dependencies.release = [ "check-wheel-contents==0.6.1" ] -urls.Documentation = "https://vws-python.readthedocs.io/en/latest/" +urls.Documentation = "https://vws-python.github.io/vws-python/" urls.Source = "https://github.com/VWS-Python/vws-python" [tool.setuptools] @@ -283,7 +283,6 @@ ignore = [ ".yamlfmt", "*.enc", ".pre-commit-config.yaml", - "readthedocs.yaml", "CHANGELOG.rst", "CODE_OF_CONDUCT.rst", "CONTRIBUTING.rst", diff --git a/readthedocs.yaml b/readthedocs.yaml deleted file mode 100644 index 8f093abcc..000000000 --- a/readthedocs.yaml +++ /dev/null @@ -1,18 +0,0 @@ ---- -version: 2 - -build: - os: ubuntu-24.04 - tools: - python: '3.12' - -python: - install: - - method: pip - path: . - extra_requirements: [dev] - -sphinx: - builder: html - configuration: docs/source/conf.py - fail_on_warning: true From c0b426f2a234ad835ea0e00fcfdd091d8e61c02f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 23 Feb 2025 02:29:44 +0000 Subject: [PATCH 0623/1003] Update VWS-Python-Mock link to new site --- docs/source/index.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/source/index.rst b/docs/source/index.rst index 505d6569a..818b0698d 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -110,7 +110,7 @@ To write unit tests for code which uses this library, without using your Vuforia assert matching_targets[0].target_id == target_id There are some differences between the mock and the real Vuforia. -See https://vws-python-mock.readthedocs.io/en/latest/differences-to-vws.html for details. +See https://vws-python.github.io/vws-python-mock/differences-to-vws for details. .. _VWS Python Mock: https://github.com/VWS-Python/vws-python-mock From ab4a5ebec7e21706610568be4f9bcd86be0c1c4e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 23 Feb 2025 02:38:25 +0000 Subject: [PATCH 0624/1003] Use cache on publish site --- .github/workflows/publish-site.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/publish-site.yml b/.github/workflows/publish-site.yml index 4ca927ccb..8f5a347a4 100644 --- a/.github/workflows/publish-site.yml +++ b/.github/workflows/publish-site.yml @@ -24,4 +24,5 @@ jobs: pyproject_extras: dev python_version: '3.13' sphinx_build_options: -W + cache: true publish: ${{ github.ref_name == 'main' }} From a0f127ea7a98e4df08681c4defce9d4ea437c78f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Feb 2025 12:10:58 +0000 Subject: [PATCH 0625/1003] Bump vws-python-mock from 2025.2.18 to 2025.2.21 Bumps [vws-python-mock](https://github.com/VWS-Python/vws-python-mock) from 2025.2.18 to 2025.2.21. - [Release notes](https://github.com/VWS-Python/vws-python-mock/releases) - [Changelog](https://github.com/VWS-Python/vws-python-mock/blob/main/CHANGELOG.rst) - [Commits](https://github.com/VWS-Python/vws-python-mock/compare/2025.02.18...2025.02.21) --- updated-dependencies: - dependency-name: vws-python-mock dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f16742d4a..29d2e31c2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -77,7 +77,7 @@ optional-dependencies.dev = [ "sybil==9.1.0", "types-requests==2.32.0.20241016", "vulture==2.14", - "vws-python-mock==2025.2.18", + "vws-python-mock==2025.2.21", "vws-test-fixtures==2023.3.5", "yamlfix==1.17.0", ] From 2e92c1f7a720bada0aef0e0d27d2cbdd2d254e8e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Feb 2025 12:11:14 +0000 Subject: [PATCH 0626/1003] Bump sphinx from 8.2.0 to 8.2.1 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 8.2.0 to 8.2.1. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/v8.2.1/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v8.2.0...v8.2.1) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f16742d4a..a683b4218 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -68,7 +68,7 @@ optional-dependencies.dev = [ # use it to lint shell commands in GitHub workflow files. "shellcheck-py==0.10.0.1", "shfmt-py==3.7.0.1", - "sphinx==8.2.0", + "sphinx==8.2.1", "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.0", "sphinx-pyproject==0.3.0", From e37bdaf1bab87e5631ca05b58b1aaa506b4495dc Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 26 Feb 2025 06:32:15 +0000 Subject: [PATCH 0627/1003] Bump uv in pre-commit --- .pre-commit-config.yaml | 62 ++++++++++++++++++++--------------------- 1 file changed, 31 insertions(+), 31 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 8cfad7775..cf9bf80da 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -78,14 +78,14 @@ repos: language: python pass_filenames: false types_or: [yaml] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: docformatter name: docformatter entry: uv run --extra=dev -m docformatter --in-place language: python types_or: [python] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: shellcheck name: shellcheck @@ -93,7 +93,7 @@ repos: language: python pass_filenames: false types_or: [shell] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: shellcheck-docs name: shellcheck-docs @@ -101,14 +101,14 @@ repos: --shell=bash" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: shfmt name: shfmt entry: uv run --extra=dev shfmt --write --space-redirects --indent=4 language: python types_or: [shell] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: shfmt-docs name: shfmt-docs @@ -116,7 +116,7 @@ repos: --no-pad-file --command="shfmt --write --space-redirects --indent=4" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: mypy name: mypy @@ -125,7 +125,7 @@ repos: language: python types_or: [python, toml] pass_filenames: false - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: mypy-docs name: mypy-docs @@ -133,7 +133,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="mypy" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: check-manifest name: check-manifest @@ -141,7 +141,7 @@ repos: entry: uv run --extra=dev -m check_manifest language: python pass_filenames: false - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: pyright name: pyright @@ -150,7 +150,7 @@ repos: language: python types_or: [python, toml] pass_filenames: false - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: pyright-docs name: pyright-docs @@ -158,7 +158,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="pyright" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: vulture name: vulture @@ -166,14 +166,14 @@ repos: language: python types_or: [python] pass_filenames: false - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: vulture-docs name: vulture docs entry: uv run --extra=dev doccmd --language=python --command="vulture" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: pyroma name: pyroma @@ -181,14 +181,14 @@ repos: language: python pass_filenames: false types_or: [toml] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: deptry name: deptry entry: uv run --extra=dev -m deptry src/ language: python pass_filenames: false - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: pylint name: pylint @@ -196,7 +196,7 @@ repos: language: python stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: pylint-docs name: pylint-docs @@ -204,28 +204,28 @@ repos: language: python stages: [manual] types_or: [markdown, rst] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: ruff-check-fix name: Ruff check fix entry: uv run --extra=dev -m ruff check --fix language: python types_or: [python] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: ruff-check-fix-docs name: Ruff check fix docs entry: uv run --extra=dev doccmd --language=python --command="ruff check --fix" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: ruff-format-fix name: Ruff format entry: uv run --extra=dev -m ruff format language: python types_or: [python] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: ruff-format-fix-docs name: Ruff format docs @@ -233,28 +233,28 @@ repos: format" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: doc8 name: doc8 entry: uv run --extra=dev -m doc8 language: python types_or: [rst] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: interrogate name: interrogate entry: uv run --extra=dev -m interrogate language: python types_or: [python] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: interrogate-docs name: interrogate docs entry: uv run --extra=dev doccmd --language=python --command="interrogate" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: pyproject-fmt-fix name: pyproject-fmt @@ -262,7 +262,7 @@ repos: language: python types_or: [toml] files: pyproject.toml - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: linkcheck name: linkcheck @@ -271,7 +271,7 @@ repos: types_or: [rst] stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: spelling name: spelling @@ -280,7 +280,7 @@ repos: types_or: [rst] stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: docs name: Build Documentation @@ -288,7 +288,7 @@ repos: language: python stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: pyright-verifytypes name: pyright-verifytypes @@ -297,18 +297,18 @@ repos: language: python pass_filenames: false types_or: [python] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: yamlfix name: yamlfix entry: uv run --extra=dev yamlfix language: python types_or: [yaml] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] - id: sphinx-lint name: sphinx-lint entry: uv run --extra=dev sphinx-lint --enable=all --disable=line-too-long language: python types_or: [rst] - additional_dependencies: [uv==0.5.20] + additional_dependencies: [uv==0.6.3] From 3fa7b062bf5276fe492b77d497e3b89cc2ba3796 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 27 Feb 2025 10:17:12 +0000 Subject: [PATCH 0628/1003] Bump pyright from 1.1.394 to 1.1.395 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.394 to 1.1.395. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.394...v1.1.395) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1d79f2b5a..c14a3a4d8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pylint==3.3.4", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.5.1", - "pyright==1.1.394", + "pyright==1.1.395", "pyroma==4.2", "pytest==8.3.4", "pytest-cov==6.0.0", From 7c9be95b6b0f5289c61bcf98576f24238b887af5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 28 Feb 2025 10:39:46 +0000 Subject: [PATCH 0629/1003] Bump ruff from 0.9.7 to 0.9.9 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.9.7 to 0.9.9. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.9.7...0.9.9) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c14a3a4d8..650fabaef 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.4", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.9.7", + "ruff==0.9.9", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 25670bd10c923d608556eaa2a3353df08ccf6ff5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 3 Mar 2025 11:07:10 +0000 Subject: [PATCH 0630/1003] Bump types-requests from 2.32.0.20241016 to 2.32.0.20250301 Bumps [types-requests](https://github.com/python/typeshed) from 2.32.0.20241016 to 2.32.0.20250301. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 650fabaef..5ce93f65c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -75,7 +75,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.2.19", "sphinxcontrib-spelling==8.0.1", "sybil==9.1.0", - "types-requests==2.32.0.20241016", + "types-requests==2.32.0.20250301", "vulture==2.14", "vws-python-mock==2025.2.21", "vws-test-fixtures==2023.3.5", From a3593ca8a42020c824cc683db51cff51de295062 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 3 Mar 2025 11:07:20 +0000 Subject: [PATCH 0631/1003] Bump sphinx from 8.2.1 to 8.2.3 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 8.2.1 to 8.2.3. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v8.2.1...v8.2.3) --- updated-dependencies: - dependency-name: sphinx dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 650fabaef..1ec046ef5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -68,7 +68,7 @@ optional-dependencies.dev = [ # use it to lint shell commands in GitHub workflow files. "shellcheck-py==0.10.0.1", "shfmt-py==3.7.0.1", - "sphinx==8.2.1", + "sphinx==8.2.3", "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.0", "sphinx-pyproject==0.3.0", From ecc014373f7fdd4d519c1b12b2afd1ab753cea6c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 3 Mar 2025 11:07:33 +0000 Subject: [PATCH 0632/1003] Bump pytest from 8.3.4 to 8.3.5 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.3.4 to 8.3.5. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.3.4...8.3.5) --- updated-dependencies: - dependency-name: pytest dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 650fabaef..9d9d5a22b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pyproject-fmt==2.5.1", "pyright==1.1.395", "pyroma==4.2", - "pytest==8.3.4", + "pytest==8.3.5", "pytest-cov==6.0.0", "pyyaml==6.0.2", "ruff==0.9.9", From d8f1e1bc2aec99e4841db51924012d58e180a7e7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 3 Mar 2025 11:12:34 +0000 Subject: [PATCH 0633/1003] Bump pyright from 1.1.395 to 1.1.396 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.395 to 1.1.396. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.395...v1.1.396) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9d9d5a22b..1fc27ee6f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pylint==3.3.4", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.5.1", - "pyright==1.1.395", + "pyright==1.1.396", "pyroma==4.2", "pytest==8.3.5", "pytest-cov==6.0.0", From e0e84ba39cd3698c43ff821301774fbed015690e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 4 Mar 2025 10:07:16 +0000 Subject: [PATCH 0634/1003] Bump sphinx-substitution-extensions from 2025.2.19 to 2025.3.3 Bumps [sphinx-substitution-extensions](https://github.com/adamtheturtle/sphinx-substitution-extensions) from 2025.2.19 to 2025.3.3. - [Release notes](https://github.com/adamtheturtle/sphinx-substitution-extensions/releases) - [Changelog](https://github.com/adamtheturtle/sphinx-substitution-extensions/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/sphinx-substitution-extensions/compare/2025.02.19...2025.03.03) --- updated-dependencies: - dependency-name: sphinx-substitution-extensions dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d623d796a..79bf6ee6c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -72,7 +72,7 @@ optional-dependencies.dev = [ "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.0", "sphinx-pyproject==0.3.0", - "sphinx-substitution-extensions==2025.2.19", + "sphinx-substitution-extensions==2025.3.3", "sphinxcontrib-spelling==8.0.1", "sybil==9.1.0", "types-requests==2.32.0.20250301", From 408308459172071dd3b9f5f6f1d54353cf166574 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 6 Mar 2025 10:30:48 +0000 Subject: [PATCH 0635/1003] Bump types-requests from 2.32.0.20250301 to 2.32.0.20250306 Bumps [types-requests](https://github.com/python/typeshed) from 2.32.0.20250301 to 2.32.0.20250306. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 79bf6ee6c..2b47a90b3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -75,7 +75,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.3.3", "sphinxcontrib-spelling==8.0.1", "sybil==9.1.0", - "types-requests==2.32.0.20250301", + "types-requests==2.32.0.20250306", "vulture==2.14", "vws-python-mock==2025.2.21", "vws-test-fixtures==2023.3.5", From da809ed87553479188e84aa0ca0d40ea8c0f7082 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 7 Mar 2025 11:04:52 +0000 Subject: [PATCH 0636/1003] Bump doccmd from 2025.2.20.7 to 2025.3.6 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.2.20.7 to 2025.3.6. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.02.20.7...2025.03.06) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2b47a90b3..19855a789 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.23.0", "doc8==1.1.2", - "doccmd==2025.2.20.7", + "doccmd==2025.3.6", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From c472d754bac31f89af3e1f3da8da7c25ef05db43 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 10 Mar 2025 10:16:16 +0000 Subject: [PATCH 0637/1003] Bump ruff from 0.9.9 to 0.9.10 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.9.9 to 0.9.10. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.9.9...0.9.10) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 19855a789..3aea85732 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.9.9", + "ruff==0.9.10", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From bcc4f866d1debdd529206672c684038af74f393d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 10 Mar 2025 10:16:30 +0000 Subject: [PATCH 0638/1003] Bump vws-python-mock from 2025.2.21 to 2025.3.10 Bumps [vws-python-mock](https://github.com/VWS-Python/vws-python-mock) from 2025.2.21 to 2025.3.10. - [Release notes](https://github.com/VWS-Python/vws-python-mock/releases) - [Changelog](https://github.com/VWS-Python/vws-python-mock/blob/main/CHANGELOG.rst) - [Commits](https://github.com/VWS-Python/vws-python-mock/compare/2025.02.21...2025.03.10) --- updated-dependencies: - dependency-name: vws-python-mock dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 19855a789..86d9b4964 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -77,7 +77,7 @@ optional-dependencies.dev = [ "sybil==9.1.0", "types-requests==2.32.0.20250306", "vulture==2.14", - "vws-python-mock==2025.2.21", + "vws-python-mock==2025.3.10", "vws-test-fixtures==2023.3.5", "yamlfix==1.17.0", ] From 086563f1ce61f99973bab89d253bc4f30992b498 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 10 Mar 2025 10:30:54 +0000 Subject: [PATCH 0639/1003] Remove OopsAnErrorOccurredPossiblyBadName which matches error no longer found in Vuforia --- CHANGELOG.rst | 2 ++ src/vws/exceptions/custom_exceptions.py | 25 ------------------------- src/vws/vws.py | 17 ++--------------- tests/test_vws_exceptions.py | 8 ++++---- 4 files changed, 8 insertions(+), 44 deletions(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index b18bc5e4f..e2c0eeaa8 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,8 @@ Changelog Next ---- +* Removed ``vws.exceptions.custom_exceptions.OopsAnErrorOccurredPossiblyBadName`` which now does not occur in VWS. + 2024.09.21 ------------ diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index 11d47a67a..694e98c30 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -9,31 +9,6 @@ from vws.response import Response -@beartype -class OopsAnErrorOccurredPossiblyBadNameError(Exception): - """Exception raised when VWS returns an HTML page which says "Oops, an - error occurred". - - This has been seen to happen when the given name includes a bad - character. - """ - - def __init__(self, response: Response) -> None: - """ - Args: - response: The response returned by Vuforia. - """ - super().__init__(response.text) - self._response = response - - @property - def response(self) -> Response: - """ - The response returned by Vuforia which included this error. - """ - return self._response - - @beartype class RequestEntityTooLargeError(Exception): """ diff --git a/src/vws/vws.py b/src/vws/vws.py index f87766571..5dd7503db 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -16,7 +16,6 @@ from vws_auth_tools import authorization_header, rfc_1123_date from vws.exceptions.custom_exceptions import ( - OopsAnErrorOccurredPossiblyBadNameError, ServerError, TargetProcessingTimeoutError, ) @@ -178,12 +177,6 @@ def make_request( The response to the request made by `requests`. Raises: - ~vws.exceptions.custom_exceptions.OopsAnErrorOccurredPossiblyBadNameError: - Vuforia returns an HTML page with the text "Oops, an error - occurred". - - This has been seen to happen when the given name includes a bad - character. ~vws.exceptions.custom_exceptions.ServerError: There is an error with Vuforia's servers. ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is @@ -202,9 +195,6 @@ def make_request( base_vws_url=self._base_vws_url, ) - if "Oops, an error occurred" in response.text: - raise OopsAnErrorOccurredPossiblyBadNameError(response=response) - if ( response.status_code == HTTPStatus.TOO_MANY_REQUESTS ): # pragma: no cover @@ -290,12 +280,9 @@ def add_target( inactive. ~vws.exceptions.vws_exceptions.RequestTimeTooSkewedError: There is an error with the time sent to Vuforia. - ~vws.exceptions.custom_exceptions.OopsAnErrorOccurredPossiblyBadNameError: - Vuforia returns an HTML page with the text "Oops, an error - occurred". This has been seen to happen when the given name - includes a bad character. ~vws.exceptions.custom_exceptions.ServerError: There is an error - with Vuforia's servers. + with Vuforia's servers. This has been seen to happen when the + given name includes a bad character. ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is rate limiting access. """ diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index f9a7b8dab..86da66040 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -15,7 +15,7 @@ from vws import VWS from vws.exceptions.base_exceptions import VWSError from vws.exceptions.custom_exceptions import ( - OopsAnErrorOccurredPossiblyBadNameError, + ServerError, ) from vws.exceptions.vws_exceptions import ( AuthenticationFailureError, @@ -71,13 +71,13 @@ def test_invalid_given_id(vws_client: VWS) -> None: def test_add_bad_name(vws_client: VWS, high_quality_image: io.BytesIO) -> None: """ - When a name with a bad character is given, an - ``OopsAnErrorOccurredPossiblyBadName`` exception is raised. + When a name with a bad character is given, a ``ServerError`` exception is + raised. """ max_char_value = 65535 bad_name = chr(max_char_value + 1) with pytest.raises( - expected_exception=OopsAnErrorOccurredPossiblyBadNameError + expected_exception=ServerError, ) as exc: vws_client.add_target( name=bad_name, From 7f525577813f690b49895cb8bba333e8a4e8ba49 Mon Sep 17 00:00:00 2001 From: adamtheturtle <797801+adamtheturtle@users.noreply.github.com> Date: Mon, 10 Mar 2025 10:42:18 +0000 Subject: [PATCH 0640/1003] Bump CHANGELOG --- CHANGELOG.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index e2c0eeaa8..46318086d 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,9 @@ Changelog Next ---- +2025.03.10 +---------- + * Removed ``vws.exceptions.custom_exceptions.OopsAnErrorOccurredPossiblyBadName`` which now does not occur in VWS. 2024.09.21 From 6e6701d9fd7d7470bf168f34ac7802a07968be2d Mon Sep 17 00:00:00 2001 From: adamtheturtle <797801+adamtheturtle@users.noreply.github.com> Date: Mon, 10 Mar 2025 19:50:15 +0000 Subject: [PATCH 0641/1003] Bump CHANGELOG --- CHANGELOG.rst | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 46318086d..5527f9da1 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,9 @@ Changelog Next ---- +2025.03.10.1 +------------ + 2025.03.10 ---------- From 51e0e83ab2f2de22f8f310f31c2e953db9fd7ecf Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 11 Mar 2025 11:03:06 +0000 Subject: [PATCH 0642/1003] Bump vws-python-mock from 2025.3.10 to 2025.3.10.1 Bumps [vws-python-mock](https://github.com/VWS-Python/vws-python-mock) from 2025.3.10 to 2025.3.10.1. - [Release notes](https://github.com/VWS-Python/vws-python-mock/releases) - [Changelog](https://github.com/VWS-Python/vws-python-mock/blob/main/CHANGELOG.rst) - [Commits](https://github.com/VWS-Python/vws-python-mock/compare/2025.03.10...2025.03.10.1) --- updated-dependencies: - dependency-name: vws-python-mock dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f69231fbe..3aba724f7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -77,7 +77,7 @@ optional-dependencies.dev = [ "sybil==9.1.0", "types-requests==2.32.0.20250306", "vulture==2.14", - "vws-python-mock==2025.3.10", + "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", "yamlfix==1.17.0", ] From 823cfb827003752e479c612cff30109d49f80acf Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 13 Mar 2025 10:35:09 +0000 Subject: [PATCH 0643/1003] Bump shfmt-py from 3.7.0.1 to 3.11.0.2 Bumps [shfmt-py](https://github.com/maxwinterstein/shfmt-py) from 3.7.0.1 to 3.11.0.2. - [Release notes](https://github.com/maxwinterstein/shfmt-py/releases) - [Commits](https://github.com/maxwinterstein/shfmt-py/compare/v3.7.0.1...v3.11.0.2) --- updated-dependencies: - dependency-name: shfmt-py dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3aba724f7..99d313eda 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -67,7 +67,7 @@ optional-dependencies.dev = [ # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. "shellcheck-py==0.10.0.1", - "shfmt-py==3.7.0.1", + "shfmt-py==3.11.0.2", "sphinx==8.2.3", "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.0", From c67858dc430910c9b70d464d3ac051556c51fcd1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 14 Mar 2025 10:41:37 +0000 Subject: [PATCH 0644/1003] Bump ruff from 0.9.10 to 0.10.0 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.9.10 to 0.10.0. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.9.10...0.10.0) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 99d313eda..6152cd7c7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.9.10", + "ruff==0.10.0", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 4726f68c8a8e1a9b49210a134cf305632108ee5f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 17 Mar 2025 11:06:13 +0000 Subject: [PATCH 0645/1003] Bump ruff from 0.10.0 to 0.11.0 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.10.0 to 0.11.0. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.10.0...0.11.0) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6152cd7c7..e49d7a2cf 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.10.0", + "ruff==0.11.0", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From f2e0c7c2e141f8a05f95928c48e5144ef8a41e36 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 19 Mar 2025 10:47:37 +0000 Subject: [PATCH 0646/1003] Bump pre-commit from 4.1.0 to 4.2.0 Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 4.1.0 to 4.2.0. - [Release notes](https://github.com/pre-commit/pre-commit/releases) - [Changelog](https://github.com/pre-commit/pre-commit/blob/main/CHANGELOG.md) - [Commits](https://github.com/pre-commit/pre-commit/compare/v4.1.0...v4.2.0) --- updated-dependencies: - dependency-name: pre-commit dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e49d7a2cf..fca1e2784 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -50,7 +50,7 @@ optional-dependencies.dev = [ "interrogate==1.7.0", "mypy[faster-cache]==1.15.0", "mypy-strict-kwargs==2024.12.25", - "pre-commit==4.1.0", + "pre-commit==4.2.0", "pydocstyle==6.3", "pyenchant==3.3.0rc1", "pygments==2.19.1", From 4adb1a576b1c5daf2d0e3dc60306f2295045727b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 19 Mar 2025 10:47:43 +0000 Subject: [PATCH 0647/1003] Bump doccmd from 2025.3.6 to 2025.3.18 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.3.6 to 2025.3.18. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.03.06...2025.03.18) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e49d7a2cf..5a49a2558 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.23.0", "doc8==1.1.2", - "doccmd==2025.3.6", + "doccmd==2025.3.18", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From b12abb58534eb3ab88855c6e8b2ab1aed0133c57 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 19 Mar 2025 15:10:20 +0000 Subject: [PATCH 0648/1003] Pass filenames to shellcheck --- .pre-commit-config.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index cf9bf80da..c480de3e9 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -91,7 +91,6 @@ repos: name: shellcheck entry: uv run --extra=dev shellcheck --shell=bash language: python - pass_filenames: false types_or: [shell] additional_dependencies: [uv==0.6.3] From 9b6b8e08d285e3055743a8783e8d913bc6e9ca7d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 20 Mar 2025 10:53:46 +0000 Subject: [PATCH 0649/1003] Bump pyright from 1.1.396 to 1.1.397 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.396 to 1.1.397. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.396...v1.1.397) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a14c92787..1e1580858 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pylint==3.3.4", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.5.1", - "pyright==1.1.396", + "pyright==1.1.397", "pyroma==4.2", "pytest==8.3.5", "pytest-cov==6.0.0", From e72c2c9108ef72e9b6e593005188323e30db48ec Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 21 Mar 2025 10:29:12 +0000 Subject: [PATCH 0650/1003] Bump ruff from 0.11.0 to 0.11.1 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.0 to 0.11.1. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.11.0...0.11.1) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1e1580858..047e4cfb7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.11.0", + "ruff==0.11.1", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 54d083cd8954d614c5e4f71c35517bd2b942ae19 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 21 Mar 2025 10:29:20 +0000 Subject: [PATCH 0651/1003] Bump pylint from 3.3.4 to 3.3.6 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.3.4 to 3.3.6. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.3.4...v3.3.6) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1e1580858..ded6b9ed3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pyenchant==3.3.0rc1", "pygments==2.19.1", - "pylint==3.3.4", + "pylint==3.3.6", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.5.1", "pyright==1.1.397", From 8d3c781fd34f93d8ad772954d981ad513b26a99d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 21 Mar 2025 13:00:47 +0000 Subject: [PATCH 0652/1003] Make it easier to change the build matrix while still keeping builds required --- .github/workflows/ci.yml | 12 ++++++++++++ .github/workflows/lint.yml | 12 ++++++++++++ 2 files changed, 24 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8c8d881e8..deab0867e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -42,3 +42,15 @@ jobs: with: fail_ci_if_error: true token: ${{ secrets.CODECOV_TOKEN }} + + completion-ci: + needs: build + runs-on: ubuntu-latest + if: always() # Run even if one matrix job fails + steps: + - name: Check matrix job status + run: |- + if ! ${{ needs.build.result == 'success' }}; then + echo "One or more matrix jobs failed" + exit 1 + fi diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index def06bdb9..7637891d2 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -41,3 +41,15 @@ jobs: - uses: pre-commit-ci/lite-action@v1.1.0 if: always() + + completion-lint: + needs: build + runs-on: ubuntu-latest + if: always() # Run even if one matrix job fails + steps: + - name: Check matrix job status + run: |- + if ! ${{ needs.build.result == 'success' }}; then + echo "One or more matrix jobs failed" + exit 1 + fi From 2cfb3e3c11a27c181dc7d1d4a470ff97f0f9cdab Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Mar 2025 11:20:52 +0000 Subject: [PATCH 0653/1003] Bump ruff from 0.11.1 to 0.11.2 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.1 to 0.11.2. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.11.1...0.11.2) --- updated-dependencies: - dependency-name: ruff dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7a22e6b7e..6bd8f4825 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.0.0", "pyyaml==6.0.2", - "ruff==0.11.1", + "ruff==0.11.2", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From dc420554ddc1757501a0b70904d1b92eb8b6bd9d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 26 Mar 2025 10:37:35 +0000 Subject: [PATCH 0654/1003] Bump pyright from 1.1.397 to 1.1.398 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.397 to 1.1.398. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.397...v1.1.398) --- updated-dependencies: - dependency-name: pyright dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6bd8f4825..b41b4f468 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pylint==3.3.6", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.5.1", - "pyright==1.1.397", + "pyright==1.1.398", "pyroma==4.2", "pytest==8.3.5", "pytest-cov==6.0.0", From e6017b7db627213fbc64516c356580c0896ed4f9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 28 Mar 2025 10:34:51 +0000 Subject: [PATCH 0655/1003] Bump types-requests from 2.32.0.20250306 to 2.32.0.20250328 Bumps [types-requests](https://github.com/python/typeshed) from 2.32.0.20250306 to 2.32.0.20250328. - [Commits](https://github.com/python/typeshed/commits) --- updated-dependencies: - dependency-name: types-requests dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b41b4f468..9290e1518 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -75,7 +75,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.3.3", "sphinxcontrib-spelling==8.0.1", "sybil==9.1.0", - "types-requests==2.32.0.20250306", + "types-requests==2.32.0.20250328", "vulture==2.14", "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", From b3cf41f56fbdc562f9e04b3c342665d3941871be Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 28 Mar 2025 10:35:02 +0000 Subject: [PATCH 0656/1003] Bump doccmd from 2025.3.18 to 2025.3.27 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.3.18 to 2025.3.27. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.03.18...2025.03.27) --- updated-dependencies: - dependency-name: doccmd dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b41b4f468..6543f851b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.23.0", "doc8==1.1.2", - "doccmd==2025.3.18", + "doccmd==2025.3.27", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From 00a7c8676a86820aa6d047d9f03d91cfd3f8de9f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 31 Mar 2025 10:48:55 +0000 Subject: [PATCH 0657/1003] Bump mypy-strict-kwargs from 2024.12.25 to 2025.3.28 Bumps [mypy-strict-kwargs](https://github.com/adamtheturtle/mypy-strict-kwargs) from 2024.12.25 to 2025.3.28. - [Release notes](https://github.com/adamtheturtle/mypy-strict-kwargs/releases) - [Changelog](https://github.com/adamtheturtle/mypy-strict-kwargs/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/mypy-strict-kwargs/compare/2024.12.25...2025.03.28) --- updated-dependencies: - dependency-name: mypy-strict-kwargs dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 986e51bd8..df66297c2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -49,7 +49,7 @@ optional-dependencies.dev = [ "furo==2024.8.6", "interrogate==1.7.0", "mypy[faster-cache]==1.15.0", - "mypy-strict-kwargs==2024.12.25", + "mypy-strict-kwargs==2025.3.28", "pre-commit==4.2.0", "pydocstyle==6.3", "pyenchant==3.3.0rc1", From b50071fcca3104aa06524f84ec73fbec2f56879f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 2 Apr 2025 10:44:58 +0000 Subject: [PATCH 0658/1003] Bump pytest-cov from 6.0.0 to 6.1.0 Bumps [pytest-cov](https://github.com/pytest-dev/pytest-cov) from 6.0.0 to 6.1.0. - [Changelog](https://github.com/pytest-dev/pytest-cov/blob/master/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest-cov/compare/v6.0.0...v6.1.0) --- updated-dependencies: - dependency-name: pytest-cov dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index df66297c2..2a18a426c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ optional-dependencies.dev = [ "pyright==1.1.398", "pyroma==4.2", "pytest==8.3.5", - "pytest-cov==6.0.0", + "pytest-cov==6.1.0", "pyyaml==6.0.2", "ruff==0.11.2", # We add shellcheck-py not only for shell scripts and shell code blocks, From e72346e10bd38700bb2f49b4610f5f078d8fc1b2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 4 Apr 2025 10:12:35 +0000 Subject: [PATCH 0659/1003] Bump ruff from 0.11.2 to 0.11.3 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.2 to 0.11.3. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.11.2...0.11.3) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.11.3 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2a18a426c..662260b43 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.1.0", "pyyaml==6.0.2", - "ruff==0.11.2", + "ruff==0.11.3", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 5ad4fe25aa60b45b703a5b3a9657602873010393 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 4 Apr 2025 10:12:42 +0000 Subject: [PATCH 0660/1003] Bump sphinx-substitution-extensions from 2025.3.3 to 2025.4.3 Bumps [sphinx-substitution-extensions](https://github.com/adamtheturtle/sphinx-substitution-extensions) from 2025.3.3 to 2025.4.3. - [Release notes](https://github.com/adamtheturtle/sphinx-substitution-extensions/releases) - [Changelog](https://github.com/adamtheturtle/sphinx-substitution-extensions/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/sphinx-substitution-extensions/compare/2025.03.03...2025.04.03) --- updated-dependencies: - dependency-name: sphinx-substitution-extensions dependency-version: 2025.4.3 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2a18a426c..beee172d5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -72,7 +72,7 @@ optional-dependencies.dev = [ "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.0", "sphinx-pyproject==0.3.0", - "sphinx-substitution-extensions==2025.3.3", + "sphinx-substitution-extensions==2025.4.3", "sphinxcontrib-spelling==8.0.1", "sybil==9.1.0", "types-requests==2.32.0.20250328", From dabb34e50db11a6912db9c0fc1286a0495286efd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 4 Apr 2025 10:12:57 +0000 Subject: [PATCH 0661/1003] Bump mypy-strict-kwargs from 2025.3.28 to 2025.4.3 Bumps [mypy-strict-kwargs](https://github.com/adamtheturtle/mypy-strict-kwargs) from 2025.3.28 to 2025.4.3. - [Release notes](https://github.com/adamtheturtle/mypy-strict-kwargs/releases) - [Changelog](https://github.com/adamtheturtle/mypy-strict-kwargs/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/mypy-strict-kwargs/compare/2025.03.28...2025.04.03) --- updated-dependencies: - dependency-name: mypy-strict-kwargs dependency-version: 2025.4.3 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2a18a426c..84e54941b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -49,7 +49,7 @@ optional-dependencies.dev = [ "furo==2024.8.6", "interrogate==1.7.0", "mypy[faster-cache]==1.15.0", - "mypy-strict-kwargs==2025.3.28", + "mypy-strict-kwargs==2025.4.3", "pre-commit==4.2.0", "pydocstyle==6.3", "pyenchant==3.3.0rc1", From 040c9eeccac0cd8ef228d627e36411b5906e241b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 4 Apr 2025 10:13:03 +0000 Subject: [PATCH 0662/1003] Bump doccmd from 2025.3.27 to 2025.4.4 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.3.27 to 2025.4.4. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.03.27...2025.04.04) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2025.4.4 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2a18a426c..422ab9f68 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.23.0", "doc8==1.1.2", - "doccmd==2025.3.27", + "doccmd==2025.4.4", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From 2ec8751c80a7ef45b939df84de8c20083c3d34dc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 7 Apr 2025 10:51:32 +0000 Subject: [PATCH 0663/1003] Bump ruff from 0.11.3 to 0.11.4 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.3 to 0.11.4. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.11.3...0.11.4) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.11.4 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 341882fa4..97b4c3e7e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.1.0", "pyyaml==6.0.2", - "ruff==0.11.3", + "ruff==0.11.4", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 8db63d5b94862506847d3efaa6e9f8da8978c1f5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 7 Apr 2025 10:51:41 +0000 Subject: [PATCH 0664/1003] Bump pytest-cov from 6.1.0 to 6.1.1 Bumps [pytest-cov](https://github.com/pytest-dev/pytest-cov) from 6.1.0 to 6.1.1. - [Changelog](https://github.com/pytest-dev/pytest-cov/blob/master/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest-cov/compare/v6.1.0...v6.1.1) --- updated-dependencies: - dependency-name: pytest-cov dependency-version: 6.1.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 341882fa4..6c9f0d12c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ optional-dependencies.dev = [ "pyright==1.1.398", "pyroma==4.2", "pytest==8.3.5", - "pytest-cov==6.1.0", + "pytest-cov==6.1.1", "pyyaml==6.0.2", "ruff==0.11.3", # We add shellcheck-py not only for shell scripts and shell code blocks, From ec21fce34aee093aead46b1ad726a236e0769141 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 8 Apr 2025 10:34:43 +0000 Subject: [PATCH 0665/1003] Bump doccmd from 2025.4.4 to 2025.4.8 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.4.4 to 2025.4.8. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.04.04...2025.04.08) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2025.4.8 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index cd478f131..067d3f4c9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.23.0", "doc8==1.1.2", - "doccmd==2025.4.4", + "doccmd==2025.4.8", "docformatter==1.7.5", "freezegun==1.5.1", "furo==2024.8.6", From 418146ff50c32be014dc9748007bdc8785ab7f22 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 10 Apr 2025 10:38:17 +0000 Subject: [PATCH 0666/1003] Bump pyright from 1.1.398 to 1.1.399 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.398 to 1.1.399. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.398...v1.1.399) --- updated-dependencies: - dependency-name: pyright dependency-version: 1.1.399 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 067d3f4c9..73eac8540 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pylint==3.3.6", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.5.1", - "pyright==1.1.398", + "pyright==1.1.399", "pyroma==4.2", "pytest==8.3.5", "pytest-cov==6.1.1", From 306665dc8e554a5f595994bb94076340d1be1cc2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 11 Apr 2025 10:14:21 +0000 Subject: [PATCH 0667/1003] Bump ruff from 0.11.4 to 0.11.5 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.4 to 0.11.5. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.11.4...0.11.5) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.11.5 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 73eac8540..100a2c377 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -62,7 +62,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.1.1", "pyyaml==6.0.2", - "ruff==0.11.4", + "ruff==0.11.5", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From ec36c614377ced346eafc5fbcd60933354642e69 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 12 Apr 2025 19:23:13 +0100 Subject: [PATCH 0668/1003] Remove now-unnecessary wheel build dependency --- pyproject.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 100a2c377..ce2a2666f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -3,7 +3,6 @@ build-backend = "setuptools.build_meta" requires = [ "setuptools", "setuptools-scm>=8.1.0", - "wheel", ] [project] From 998576a319065d038011f70d463f08f57d9a5036 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 18 Apr 2025 10:29:12 +0000 Subject: [PATCH 0669/1003] Bump ruff from 0.11.5 to 0.11.6 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.5 to 0.11.6. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.11.5...0.11.6) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.11.6 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ce2a2666f..890c2c280 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.1.1", "pyyaml==6.0.2", - "ruff==0.11.5", + "ruff==0.11.6", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 39afe719ca7d60c1a0f986a31a59e07bf97c7ddc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 25 Apr 2025 10:13:00 +0000 Subject: [PATCH 0670/1003] Bump astral-sh/setup-uv from 5 to 6 Bumps [astral-sh/setup-uv](https://github.com/astral-sh/setup-uv) from 5 to 6. - [Release notes](https://github.com/astral-sh/setup-uv/releases) - [Commits](https://github.com/astral-sh/setup-uv/compare/v5...v6) --- updated-dependencies: - dependency-name: astral-sh/setup-uv dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- .github/workflows/lint.yml | 2 +- .github/workflows/release.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index deab0867e..de333f893 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -26,7 +26,7 @@ jobs: - uses: actions/checkout@v4 - name: Install uv - uses: astral-sh/setup-uv@v5 + uses: astral-sh/setup-uv@v6 with: enable-cache: true cache-dependency-glob: '**/pyproject.toml' diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 7637891d2..6f0dbc9c3 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -26,7 +26,7 @@ jobs: - uses: actions/checkout@v4 - name: Install uv - uses: astral-sh/setup-uv@v5 + uses: astral-sh/setup-uv@v6 with: enable-cache: true cache-dependency-glob: '**/pyproject.toml' diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index e44c847b8..f6c1579b4 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -34,7 +34,7 @@ jobs: fetch-depth: 0 - name: Install uv - uses: astral-sh/setup-uv@v5 + uses: astral-sh/setup-uv@v6 with: enable-cache: true cache-dependency-glob: '**/pyproject.toml' From 2abed5615454e92e75860dfce6e2bea7e394e374 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 25 Apr 2025 10:39:27 +0000 Subject: [PATCH 0671/1003] Bump pyright from 1.1.399 to 1.1.400 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.399 to 1.1.400. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.399...v1.1.400) --- updated-dependencies: - dependency-name: pyright dependency-version: 1.1.400 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 890c2c280..6ef7ac533 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pylint==3.3.6", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.5.1", - "pyright==1.1.399", + "pyright==1.1.400", "pyroma==4.2", "pytest==8.3.5", "pytest-cov==6.1.1", From 53de68b91751b97faa33ae0dbb1e610fe28efde0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 25 Apr 2025 10:39:46 +0000 Subject: [PATCH 0672/1003] Bump ruff from 0.11.6 to 0.11.7 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.6 to 0.11.7. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.11.6...0.11.7) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.11.7 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 890c2c280..3ae74da5a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.1.1", "pyyaml==6.0.2", - "ruff==0.11.6", + "ruff==0.11.7", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 4cba7d419f816ff19758e37410e1a03220c6c37a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 2 May 2025 10:22:12 +0000 Subject: [PATCH 0673/1003] Bump ruff from 0.11.7 to 0.11.8 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.7 to 0.11.8. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.11.7...0.11.8) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.11.8 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e27b18f9f..5f212ceca 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.1.1", "pyyaml==6.0.2", - "ruff==0.11.7", + "ruff==0.11.8", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 76fd44eea02dc6c946168c5a5dfa4a3d3c2fcf71 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 5 May 2025 11:02:39 +0000 Subject: [PATCH 0674/1003] Bump pylint from 3.3.6 to 3.3.7 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.3.6 to 3.3.7. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.3.6...v3.3.7) --- updated-dependencies: - dependency-name: pylint dependency-version: 3.3.7 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5f212ceca..f16860469 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pyenchant==3.3.0rc1", "pygments==2.19.1", - "pylint==3.3.6", + "pylint==3.3.7", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.5.1", "pyright==1.1.400", From 1e4c2e963e940e1dec4c949e67ee15dff12881f4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 8 May 2025 10:43:45 +0000 Subject: [PATCH 0675/1003] Bump docformatter from 1.7.5 to 1.7.6 Bumps [docformatter](https://github.com/PyCQA/docformatter) from 1.7.5 to 1.7.6. - [Release notes](https://github.com/PyCQA/docformatter/releases) - [Changelog](https://github.com/PyCQA/docformatter/blob/master/CHANGELOG.md) - [Commits](https://github.com/PyCQA/docformatter/compare/v1.7.5...v1.7.6) --- updated-dependencies: - dependency-name: docformatter dependency-version: 1.7.6 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f16860469..8f9f74c7e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "deptry==0.23.0", "doc8==1.1.2", "doccmd==2025.4.8", - "docformatter==1.7.5", + "docformatter==1.7.6", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", From af28076c7e70b030e0cf2a1c06a458b2af8cc913 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 12 May 2025 11:01:20 +0000 Subject: [PATCH 0676/1003] Bump docformatter from 1.7.6 to 1.7.7 Bumps [docformatter](https://github.com/PyCQA/docformatter) from 1.7.6 to 1.7.7. - [Release notes](https://github.com/PyCQA/docformatter/releases) - [Changelog](https://github.com/PyCQA/docformatter/blob/master/CHANGELOG.md) - [Commits](https://github.com/PyCQA/docformatter/compare/v1.7.6...v1.7.7) --- updated-dependencies: - dependency-name: docformatter dependency-version: 1.7.7 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8f9f74c7e..277ad86e7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -43,7 +43,7 @@ optional-dependencies.dev = [ "deptry==0.23.0", "doc8==1.1.2", "doccmd==2025.4.8", - "docformatter==1.7.6", + "docformatter==1.7.7", "freezegun==1.5.1", "furo==2024.8.6", "interrogate==1.7.0", From fd81b24e6b3501e3d260bacc5641804081708285 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 12 May 2025 11:01:32 +0000 Subject: [PATCH 0677/1003] Bump ruff from 0.11.8 to 0.11.9 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.8 to 0.11.9. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.11.8...0.11.9) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.11.9 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8f9f74c7e..f9a34c814 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.1.1", "pyyaml==6.0.2", - "ruff==0.11.8", + "ruff==0.11.9", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From a19799a23b5466fe7ee1d6d5040ed42ef8d3d9b3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 12 May 2025 11:04:15 +0000 Subject: [PATCH 0678/1003] Bump check-wheel-contents from 0.6.1 to 0.6.2 Bumps [check-wheel-contents](https://github.com/jwodder/check-wheel-contents) from 0.6.1 to 0.6.2. - [Release notes](https://github.com/jwodder/check-wheel-contents/releases) - [Changelog](https://github.com/jwodder/check-wheel-contents/blob/master/CHANGELOG.md) - [Commits](https://github.com/jwodder/check-wheel-contents/compare/v0.6.1...v0.6.2) --- updated-dependencies: - dependency-name: check-wheel-contents dependency-version: 0.6.2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8f9f74c7e..dcd082c94 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -80,7 +80,7 @@ optional-dependencies.dev = [ "vws-test-fixtures==2023.3.5", "yamlfix==1.17.0", ] -optional-dependencies.release = [ "check-wheel-contents==0.6.1" ] +optional-dependencies.release = [ "check-wheel-contents==0.6.2" ] urls.Documentation = "https://vws-python.github.io/vws-python/" urls.Source = "https://github.com/VWS-Python/vws-python" From 5f8ad966b3ac68bade989ad2f093752f98501182 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 15 May 2025 10:44:27 +0000 Subject: [PATCH 0679/1003] Bump types-requests from 2.32.0.20250328 to 2.32.0.20250515 Bumps [types-requests](https://github.com/typeshed-internal/stub_uploader) from 2.32.0.20250328 to 2.32.0.20250515. - [Commits](https://github.com/typeshed-internal/stub_uploader/commits) --- updated-dependencies: - dependency-name: types-requests dependency-version: 2.32.0.20250515 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c5d3cade9..d508b335a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -74,7 +74,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.4.3", "sphinxcontrib-spelling==8.0.1", "sybil==9.1.0", - "types-requests==2.32.0.20250328", + "types-requests==2.32.0.20250515", "vulture==2.14", "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", From f04d94b6da99ed1c7bb65dec7a178157c6bb41c1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 16 May 2025 10:31:32 +0000 Subject: [PATCH 0680/1003] Bump ruff from 0.11.9 to 0.11.10 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.9 to 0.11.10. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.11.9...0.11.10) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.11.10 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d508b335a..2b71c538f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.1.1", "pyyaml==6.0.2", - "ruff==0.11.9", + "ruff==0.11.10", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 32a39e3ba98ef33c3ee9b1caff19e50d06dd6fd8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 20 May 2025 10:09:34 +0000 Subject: [PATCH 0681/1003] Bump pyproject-fmt from 2.5.1 to 2.6.0 Bumps [pyproject-fmt](https://github.com/tox-dev/toml-fmt) from 2.5.1 to 2.6.0. - [Release notes](https://github.com/tox-dev/toml-fmt/releases) - [Commits](https://github.com/tox-dev/toml-fmt/compare/pyproject-fmt/2.5.1...pyproject-fmt/2.6.0) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-version: 2.6.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2b71c538f..08cb0d1c9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pygments==2.19.1", "pylint==3.3.7", "pylint-per-file-ignores==1.4.0", - "pyproject-fmt==2.5.1", + "pyproject-fmt==2.6.0", "pyright==1.1.400", "pyroma==4.2", "pytest==8.3.5", From 320ed1403fa37b5330d1c8df3b2ac22adcc002f7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 21 May 2025 10:47:32 +0000 Subject: [PATCH 0682/1003] Bump pyright from 1.1.400 to 1.1.401 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.400 to 1.1.401. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.400...v1.1.401) --- updated-dependencies: - dependency-name: pyright dependency-version: 1.1.401 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 08cb0d1c9..5dc79e599 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pylint==3.3.7", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.6.0", - "pyright==1.1.400", + "pyright==1.1.401", "pyroma==4.2", "pytest==8.3.5", "pytest-cov==6.1.1", From 30c5ae6fa01165054793fbf35bdb9a907257b74a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 23 May 2025 11:01:39 +0000 Subject: [PATCH 0683/1003] Bump ruff from 0.11.10 to 0.11.11 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.10 to 0.11.11. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.11.10...0.11.11) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.11.11 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5dc79e599..20f21b24a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.1.1", "pyyaml==6.0.2", - "ruff==0.11.10", + "ruff==0.11.11", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From e3f229789ef5da8f1756bea87e2307837c229bd4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 26 May 2025 11:34:30 +0000 Subject: [PATCH 0684/1003] Bump freezegun from 1.5.1 to 1.5.2 Bumps [freezegun](https://github.com/spulec/freezegun) from 1.5.1 to 1.5.2. - [Release notes](https://github.com/spulec/freezegun/releases) - [Changelog](https://github.com/spulec/freezegun/blob/master/CHANGELOG) - [Commits](https://github.com/spulec/freezegun/compare/1.5.1...1.5.2) --- updated-dependencies: - dependency-name: freezegun dependency-version: 1.5.2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 20f21b24a..dfa815588 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -44,7 +44,7 @@ optional-dependencies.dev = [ "doc8==1.1.2", "doccmd==2025.4.8", "docformatter==1.7.7", - "freezegun==1.5.1", + "freezegun==1.5.2", "furo==2024.8.6", "interrogate==1.7.0", "mypy[faster-cache]==1.15.0", From a0b72e8b98ea64283fb6630da853f9ae53cfed7c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 30 May 2025 10:59:33 +0000 Subject: [PATCH 0685/1003] Bump mypy[faster-cache] from 1.15.0 to 1.16.0 Bumps [mypy[faster-cache]](https://github.com/python/mypy) from 1.15.0 to 1.16.0. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.15.0...v1.16.0) --- updated-dependencies: - dependency-name: mypy[faster-cache] dependency-version: 1.16.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index dfa815588..1a456d8a8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -47,7 +47,7 @@ optional-dependencies.dev = [ "freezegun==1.5.2", "furo==2024.8.6", "interrogate==1.7.0", - "mypy[faster-cache]==1.15.0", + "mypy[faster-cache]==1.16.0", "mypy-strict-kwargs==2025.4.3", "pre-commit==4.2.0", "pydocstyle==6.3", From a60a495a201a64b309644432baf75adeec6b2be8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 30 May 2025 10:59:47 +0000 Subject: [PATCH 0686/1003] Bump ruff from 0.11.11 to 0.11.12 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.11 to 0.11.12. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.11.11...0.11.12) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.11.12 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index dfa815588..fd479b4c3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.3.5", "pytest-cov==6.1.1", "pyyaml==6.0.2", - "ruff==0.11.11", + "ruff==0.11.12", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 218f53a6d3e65d98fb60932767ba21ae56241c22 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 2 Jun 2025 11:40:40 +0000 Subject: [PATCH 0687/1003] Bump types-requests from 2.32.0.20250515 to 2.32.0.20250602 Bumps [types-requests](https://github.com/typeshed-internal/stub_uploader) from 2.32.0.20250515 to 2.32.0.20250602. - [Commits](https://github.com/typeshed-internal/stub_uploader/commits) --- updated-dependencies: - dependency-name: types-requests dependency-version: 2.32.0.20250602 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d8f6a0845..efbc9623e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -74,7 +74,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.4.3", "sphinxcontrib-spelling==8.0.1", "sybil==9.1.0", - "types-requests==2.32.0.20250515", + "types-requests==2.32.0.20250602", "vulture==2.14", "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", From 3362607d3b2a10b625fffe173cddeab4335c414b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 3 Jun 2025 10:56:44 +0000 Subject: [PATCH 0688/1003] Bump pytest from 8.3.5 to 8.4.0 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.3.5 to 8.4.0. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.3.5...8.4.0) --- updated-dependencies: - dependency-name: pytest dependency-version: 8.4.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index efbc9623e..db6e18781 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pyproject-fmt==2.6.0", "pyright==1.1.401", "pyroma==4.2", - "pytest==8.3.5", + "pytest==8.4.0", "pytest-cov==6.1.1", "pyyaml==6.0.2", "ruff==0.11.12", From be1e4289974cb9a63a6570fa123cd0ec06628eda Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 6 Jun 2025 10:06:12 +0000 Subject: [PATCH 0689/1003] Bump ruff from 0.11.12 to 0.11.13 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.12 to 0.11.13. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.11.12...0.11.13) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.11.13 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index db6e18781..f7dd6b0ac 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.4.0", "pytest-cov==6.1.1", "pyyaml==6.0.2", - "ruff==0.11.12", + "ruff==0.11.13", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 96072081932596e48d21cb80314c1c6513fc64de Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 9 Jun 2025 11:31:11 +0000 Subject: [PATCH 0690/1003] Bump sphinx-substitution-extensions from 2025.4.3 to 2025.6.6 Bumps [sphinx-substitution-extensions](https://github.com/adamtheturtle/sphinx-substitution-extensions) from 2025.4.3 to 2025.6.6. - [Release notes](https://github.com/adamtheturtle/sphinx-substitution-extensions/releases) - [Changelog](https://github.com/adamtheturtle/sphinx-substitution-extensions/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/sphinx-substitution-extensions/compare/2025.04.03...2025.06.06) --- updated-dependencies: - dependency-name: sphinx-substitution-extensions dependency-version: 2025.6.6 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f7dd6b0ac..476388c07 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -71,7 +71,7 @@ optional-dependencies.dev = [ "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.0", "sphinx-pyproject==0.3.0", - "sphinx-substitution-extensions==2025.4.3", + "sphinx-substitution-extensions==2025.6.6", "sphinxcontrib-spelling==8.0.1", "sybil==9.1.0", "types-requests==2.32.0.20250602", From 39c2e64574f274bfc28ddbbf719e743c3c1f8cc4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 11 Jun 2025 10:38:55 +0000 Subject: [PATCH 0691/1003] Bump types-requests from 2.32.0.20250602 to 2.32.4.20250611 Bumps [types-requests](https://github.com/typeshed-internal/stub_uploader) from 2.32.0.20250602 to 2.32.4.20250611. - [Commits](https://github.com/typeshed-internal/stub_uploader/commits) --- updated-dependencies: - dependency-name: types-requests dependency-version: 2.32.4.20250611 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 476388c07..5fce596b2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -74,7 +74,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.6.6", "sphinxcontrib-spelling==8.0.1", "sybil==9.1.0", - "types-requests==2.32.0.20250602", + "types-requests==2.32.4.20250611", "vulture==2.14", "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", From 7aeff5abcede031c688ded0ada5227934ea33940 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 11 Jun 2025 10:39:19 +0000 Subject: [PATCH 0692/1003] Bump pyright from 1.1.401 to 1.1.402 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.401 to 1.1.402. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.401...v1.1.402) --- updated-dependencies: - dependency-name: pyright dependency-version: 1.1.402 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 476388c07..7e57056b9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pylint==3.3.7", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.6.0", - "pyright==1.1.401", + "pyright==1.1.402", "pyroma==4.2", "pytest==8.4.0", "pytest-cov==6.1.1", From a548ac23414494751aa35542c546c56835464011 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 11 Jun 2025 10:57:42 +0000 Subject: [PATCH 0693/1003] Bump stefanzweifel/git-auto-commit-action from 5 to 6 Bumps [stefanzweifel/git-auto-commit-action](https://github.com/stefanzweifel/git-auto-commit-action) from 5 to 6. - [Release notes](https://github.com/stefanzweifel/git-auto-commit-action/releases) - [Changelog](https://github.com/stefanzweifel/git-auto-commit-action/blob/master/CHANGELOG.md) - [Commits](https://github.com/stefanzweifel/git-auto-commit-action/compare/v5...v6) --- updated-dependencies: - dependency-name: stefanzweifel/git-auto-commit-action dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index f6c1579b4..c00447040 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -63,7 +63,7 @@ jobs: include: CHANGELOG.rst regex: false - - uses: stefanzweifel/git-auto-commit-action@v5 + - uses: stefanzweifel/git-auto-commit-action@v6 id: commit with: commit_message: Bump CHANGELOG From 6928b370bdeb08a10dd1b5959e7f0b7d796c2041 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 12 Jun 2025 10:56:43 +0000 Subject: [PATCH 0694/1003] Bump pytest-cov from 6.1.1 to 6.2.1 Bumps [pytest-cov](https://github.com/pytest-dev/pytest-cov) from 6.1.1 to 6.2.1. - [Changelog](https://github.com/pytest-dev/pytest-cov/blob/master/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest-cov/compare/v6.1.1...v6.2.1) --- updated-dependencies: - dependency-name: pytest-cov dependency-version: 6.2.1 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 15250e07c..084501226 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pyright==1.1.402", "pyroma==4.2", "pytest==8.4.0", - "pytest-cov==6.1.1", + "pytest-cov==6.2.1", "pyyaml==6.0.2", "ruff==0.11.13", # We add shellcheck-py not only for shell scripts and shell code blocks, From 50b63b1c22b31e1de5d6545618b9d83a168c800a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 14 Jun 2025 08:52:48 +0100 Subject: [PATCH 0695/1003] Accept all IO[bytes] as image type --- CHANGELOG.rst | 3 +-- src/vws/query.py | 5 ++--- src/vws/vws.py | 5 ++--- tests/conftest.py | 4 ++-- tests/test_query.py | 21 ++++++++++----------- tests/test_vws.py | 30 +++++++++++++++--------------- 6 files changed, 32 insertions(+), 36 deletions(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 5527f9da1..4b0f026ea 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,8 +4,7 @@ Changelog Next ---- -2025.03.10.1 ------------- +* Be more flexible in the types of images accepted. 2025.03.10 ---------- diff --git a/src/vws/query.py b/src/vws/query.py index 96122aa14..65f72d16f 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -3,10 +3,9 @@ """ import datetime -import io import json from http import HTTPMethod, HTTPStatus -from typing import Any, BinaryIO +from typing import IO, Any from urllib.parse import urljoin import requests @@ -29,7 +28,7 @@ from vws.reports import QueryResult, TargetData from vws.response import Response -_ImageType = io.BytesIO | BinaryIO +_ImageType = IO[bytes] @beartype diff --git a/src/vws/vws.py b/src/vws/vws.py index 5dd7503db..fc33a6861 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -3,12 +3,11 @@ """ import base64 -import io import json import time from datetime import date from http import HTTPMethod, HTTPStatus -from typing import BinaryIO +from typing import IO from urllib.parse import urljoin import requests @@ -47,7 +46,7 @@ ) from vws.response import Response -_ImageType = io.BytesIO | BinaryIO +_ImageType = IO[bytes] @beartype diff --git a/tests/conftest.py b/tests/conftest.py index 74c6fc56d..3831755a8 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -5,7 +5,7 @@ import io from collections.abc import Generator from pathlib import Path -from typing import BinaryIO, Literal +from typing import IO, BinaryIO, Literal import pytest from mock_vws import MockVWS @@ -70,7 +70,7 @@ def image( request: pytest.FixtureRequest, high_quality_image: io.BytesIO, image_file: BinaryIO, -) -> io.BytesIO | BinaryIO: +) -> IO[bytes]: """ An image in any of the types that the API accepts. """ diff --git a/tests/test_query.py b/tests/test_query.py index e229cf95d..c255b0658 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -2,9 +2,8 @@ Tests for the ``CloudRecoService`` querying functionality. """ -import io import uuid -from typing import BinaryIO +from typing import IO from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase @@ -21,7 +20,7 @@ class TestQuery: @staticmethod def test_no_matches( cloud_reco_client: CloudRecoService, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ An empty list is returned if there are no matches. @@ -33,7 +32,7 @@ def test_no_matches( def test_match( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ Details of matching targets are returned. @@ -56,7 +55,7 @@ class TestCustomBaseVWQURL: """ @staticmethod - def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: + def test_custom_base_url(image: IO[bytes]) -> None: """ It is possible to use query a target to a database under a custom VWQ URL. @@ -101,7 +100,7 @@ class TestMaxNumResults: def test_default( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ By default the maximum number of results is 1. @@ -129,7 +128,7 @@ def test_default( def test_custom( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ It is possible to set a custom ``max_num_results``. @@ -175,7 +174,7 @@ class TestIncludeTargetData: def test_default( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ By default, target data is only returned in the top match. @@ -207,7 +206,7 @@ def test_default( def test_top( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ When ``CloudRecoIncludeTargetData.TOP`` is given, target data is only @@ -241,7 +240,7 @@ def test_top( def test_none( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ When ``CloudRecoIncludeTargetData.NONE`` is given, target data is not @@ -275,7 +274,7 @@ def test_none( def test_all( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ When ``CloudRecoIncludeTargetData.ALL`` is given, target data is diff --git a/tests/test_vws.py b/tests/test_vws.py index e16eff555..54391d95c 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -7,7 +7,7 @@ import io import secrets import uuid -from typing import BinaryIO +from typing import IO import pytest from freezegun import freeze_time @@ -37,7 +37,7 @@ class TestAddTarget: @pytest.mark.parametrize(argnames="active_flag", argvalues=[True, False]) def test_add_target( vws_client: VWS, - image: io.BytesIO | BinaryIO, + image: IO[bytes], application_metadata: bytes | None, cloud_reco_client: CloudRecoService, *, @@ -81,7 +81,7 @@ def test_add_target( @staticmethod def test_add_two_targets( vws_client: VWS, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """No exception is raised when adding two targets with different names. @@ -103,7 +103,7 @@ class TestCustomBaseVWSURL: """ @staticmethod - def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: + def test_custom_base_url(image: IO[bytes]) -> None: """ It is possible to use add a target to a database under a custom VWS URL. @@ -135,7 +135,7 @@ class TestListTargets: @staticmethod def test_list_targets( vws_client: VWS, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ It is possible to get a list of target IDs. @@ -165,7 +165,7 @@ class TestDelete: @staticmethod def test_delete_target( vws_client: VWS, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ It is possible to delete a target. @@ -192,7 +192,7 @@ class TestGetTargetSummaryReport: @staticmethod def test_get_target_summary_report( vws_client: VWS, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ Details of a target are returned by ``get_target_summary_report``. @@ -294,7 +294,7 @@ class TestGetTargetRecord: @staticmethod def test_get_target_record( vws_client: VWS, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ Details of a target are returned by ``get_target_record``. @@ -369,7 +369,7 @@ class TestWaitForTargetProcessed: @staticmethod def test_wait_for_target_processed( vws_client: VWS, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ It is possible to wait until a target is processed. @@ -389,7 +389,7 @@ def test_wait_for_target_processed( @staticmethod def test_default_seconds_between_requests( - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ By default, 0.2 seconds are waited between polling requests. @@ -441,7 +441,7 @@ def test_default_seconds_between_requests( @staticmethod def test_custom_seconds_between_requests( - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ It is possible to customize the time waited between polling requests. @@ -492,7 +492,7 @@ def test_custom_seconds_between_requests( assert report.request_usage == expected_requests @staticmethod - def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: + def test_custom_timeout(image: IO[bytes]) -> None: """ It is possible to set a maximum timeout. """ @@ -538,7 +538,7 @@ class TestGetDuplicateTargets: @staticmethod def test_get_duplicate_targets( vws_client: VWS, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ It is possible to get the IDs of similar targets. @@ -572,7 +572,7 @@ class TestUpdateTarget: @staticmethod def test_update_target( vws_client: VWS, - image: io.BytesIO | BinaryIO, + image: IO[bytes], different_high_quality_image: io.BytesIO, cloud_reco_client: CloudRecoService, ) -> None: @@ -633,7 +633,7 @@ def test_update_target( @staticmethod def test_no_fields_given( vws_client: VWS, - image: io.BytesIO | BinaryIO, + image: IO[bytes], ) -> None: """ It is possible to give no update fields. From 6382b7a64d38611de093a7ba25692153c5a75331 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 14 Jun 2025 22:01:50 +0100 Subject: [PATCH 0696/1003] Revert "Accept all IO[bytes] as image type" This reverts commit 50b63b1c22b31e1de5d6545618b9d83a168c800a. --- CHANGELOG.rst | 3 ++- src/vws/query.py | 5 +++-- src/vws/vws.py | 5 +++-- tests/conftest.py | 4 ++-- tests/test_query.py | 21 +++++++++++---------- tests/test_vws.py | 30 +++++++++++++++--------------- 6 files changed, 36 insertions(+), 32 deletions(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 4b0f026ea..5527f9da1 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,7 +4,8 @@ Changelog Next ---- -* Be more flexible in the types of images accepted. +2025.03.10.1 +------------ 2025.03.10 ---------- diff --git a/src/vws/query.py b/src/vws/query.py index 65f72d16f..96122aa14 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -3,9 +3,10 @@ """ import datetime +import io import json from http import HTTPMethod, HTTPStatus -from typing import IO, Any +from typing import Any, BinaryIO from urllib.parse import urljoin import requests @@ -28,7 +29,7 @@ from vws.reports import QueryResult, TargetData from vws.response import Response -_ImageType = IO[bytes] +_ImageType = io.BytesIO | BinaryIO @beartype diff --git a/src/vws/vws.py b/src/vws/vws.py index fc33a6861..5dd7503db 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -3,11 +3,12 @@ """ import base64 +import io import json import time from datetime import date from http import HTTPMethod, HTTPStatus -from typing import IO +from typing import BinaryIO from urllib.parse import urljoin import requests @@ -46,7 +47,7 @@ ) from vws.response import Response -_ImageType = IO[bytes] +_ImageType = io.BytesIO | BinaryIO @beartype diff --git a/tests/conftest.py b/tests/conftest.py index 3831755a8..74c6fc56d 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -5,7 +5,7 @@ import io from collections.abc import Generator from pathlib import Path -from typing import IO, BinaryIO, Literal +from typing import BinaryIO, Literal import pytest from mock_vws import MockVWS @@ -70,7 +70,7 @@ def image( request: pytest.FixtureRequest, high_quality_image: io.BytesIO, image_file: BinaryIO, -) -> IO[bytes]: +) -> io.BytesIO | BinaryIO: """ An image in any of the types that the API accepts. """ diff --git a/tests/test_query.py b/tests/test_query.py index c255b0658..e229cf95d 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -2,8 +2,9 @@ Tests for the ``CloudRecoService`` querying functionality. """ +import io import uuid -from typing import IO +from typing import BinaryIO from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase @@ -20,7 +21,7 @@ class TestQuery: @staticmethod def test_no_matches( cloud_reco_client: CloudRecoService, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ An empty list is returned if there are no matches. @@ -32,7 +33,7 @@ def test_no_matches( def test_match( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ Details of matching targets are returned. @@ -55,7 +56,7 @@ class TestCustomBaseVWQURL: """ @staticmethod - def test_custom_base_url(image: IO[bytes]) -> None: + def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: """ It is possible to use query a target to a database under a custom VWQ URL. @@ -100,7 +101,7 @@ class TestMaxNumResults: def test_default( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ By default the maximum number of results is 1. @@ -128,7 +129,7 @@ def test_default( def test_custom( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ It is possible to set a custom ``max_num_results``. @@ -174,7 +175,7 @@ class TestIncludeTargetData: def test_default( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ By default, target data is only returned in the top match. @@ -206,7 +207,7 @@ def test_default( def test_top( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ When ``CloudRecoIncludeTargetData.TOP`` is given, target data is only @@ -240,7 +241,7 @@ def test_top( def test_none( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ When ``CloudRecoIncludeTargetData.NONE`` is given, target data is not @@ -274,7 +275,7 @@ def test_none( def test_all( vws_client: VWS, cloud_reco_client: CloudRecoService, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ When ``CloudRecoIncludeTargetData.ALL`` is given, target data is diff --git a/tests/test_vws.py b/tests/test_vws.py index 54391d95c..e16eff555 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -7,7 +7,7 @@ import io import secrets import uuid -from typing import IO +from typing import BinaryIO import pytest from freezegun import freeze_time @@ -37,7 +37,7 @@ class TestAddTarget: @pytest.mark.parametrize(argnames="active_flag", argvalues=[True, False]) def test_add_target( vws_client: VWS, - image: IO[bytes], + image: io.BytesIO | BinaryIO, application_metadata: bytes | None, cloud_reco_client: CloudRecoService, *, @@ -81,7 +81,7 @@ def test_add_target( @staticmethod def test_add_two_targets( vws_client: VWS, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """No exception is raised when adding two targets with different names. @@ -103,7 +103,7 @@ class TestCustomBaseVWSURL: """ @staticmethod - def test_custom_base_url(image: IO[bytes]) -> None: + def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: """ It is possible to use add a target to a database under a custom VWS URL. @@ -135,7 +135,7 @@ class TestListTargets: @staticmethod def test_list_targets( vws_client: VWS, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ It is possible to get a list of target IDs. @@ -165,7 +165,7 @@ class TestDelete: @staticmethod def test_delete_target( vws_client: VWS, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ It is possible to delete a target. @@ -192,7 +192,7 @@ class TestGetTargetSummaryReport: @staticmethod def test_get_target_summary_report( vws_client: VWS, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ Details of a target are returned by ``get_target_summary_report``. @@ -294,7 +294,7 @@ class TestGetTargetRecord: @staticmethod def test_get_target_record( vws_client: VWS, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ Details of a target are returned by ``get_target_record``. @@ -369,7 +369,7 @@ class TestWaitForTargetProcessed: @staticmethod def test_wait_for_target_processed( vws_client: VWS, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ It is possible to wait until a target is processed. @@ -389,7 +389,7 @@ def test_wait_for_target_processed( @staticmethod def test_default_seconds_between_requests( - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ By default, 0.2 seconds are waited between polling requests. @@ -441,7 +441,7 @@ def test_default_seconds_between_requests( @staticmethod def test_custom_seconds_between_requests( - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ It is possible to customize the time waited between polling requests. @@ -492,7 +492,7 @@ def test_custom_seconds_between_requests( assert report.request_usage == expected_requests @staticmethod - def test_custom_timeout(image: IO[bytes]) -> None: + def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: """ It is possible to set a maximum timeout. """ @@ -538,7 +538,7 @@ class TestGetDuplicateTargets: @staticmethod def test_get_duplicate_targets( vws_client: VWS, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ It is possible to get the IDs of similar targets. @@ -572,7 +572,7 @@ class TestUpdateTarget: @staticmethod def test_update_target( vws_client: VWS, - image: IO[bytes], + image: io.BytesIO | BinaryIO, different_high_quality_image: io.BytesIO, cloud_reco_client: CloudRecoService, ) -> None: @@ -633,7 +633,7 @@ def test_update_target( @staticmethod def test_no_fields_given( vws_client: VWS, - image: IO[bytes], + image: io.BytesIO | BinaryIO, ) -> None: """ It is possible to give no update fields. From f1c2fb787cad1e65e94de7e40464f9914c366113 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Jun 2025 11:23:00 +0000 Subject: [PATCH 0697/1003] Bump doc8 from 1.1.2 to 2.0.0 Bumps [doc8](https://github.com/pycqa/doc8) from 1.1.2 to 2.0.0. - [Release notes](https://github.com/pycqa/doc8/releases) - [Commits](https://github.com/pycqa/doc8/compare/v1.1.2...v2.0.0) --- updated-dependencies: - dependency-name: doc8 dependency-version: 2.0.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 084501226..4dcc48d65 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "actionlint-py==1.7.7.23", "check-manifest==0.50", "deptry==0.23.0", - "doc8==1.1.2", + "doc8==2.0.0", "doccmd==2025.4.8", "docformatter==1.7.7", "freezegun==1.5.2", From 97148361c55550be5abeb73755d5c5d080eb015d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 17 Jun 2025 10:19:40 +0000 Subject: [PATCH 0698/1003] Bump mypy[faster-cache] from 1.16.0 to 1.16.1 Bumps [mypy[faster-cache]](https://github.com/python/mypy) from 1.16.0 to 1.16.1. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.16.0...v1.16.1) --- updated-dependencies: - dependency-name: mypy[faster-cache] dependency-version: 1.16.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4dcc48d65..c8e279439 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -47,7 +47,7 @@ optional-dependencies.dev = [ "freezegun==1.5.2", "furo==2024.8.6", "interrogate==1.7.0", - "mypy[faster-cache]==1.16.0", + "mypy[faster-cache]==1.16.1", "mypy-strict-kwargs==2025.4.3", "pre-commit==4.2.0", "pydocstyle==6.3", From da3350b638d89a5bbb00eaf385565de29f6e1753 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 18 Jun 2025 10:40:51 +0000 Subject: [PATCH 0699/1003] Bump ruff from 0.11.13 to 0.12.0 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.11.13 to 0.12.0. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.11.13...0.12.0) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.12.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c8e279439..f3f6b63f9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.4.0", "pytest-cov==6.2.1", "pyyaml==6.0.2", - "ruff==0.11.13", + "ruff==0.12.0", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From c40c5bc3826547686f4569fe6e89c98a05084f40 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 18 Jun 2025 10:41:03 +0000 Subject: [PATCH 0700/1003] Bump pytest from 8.4.0 to 8.4.1 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.4.0 to 8.4.1. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.4.0...8.4.1) --- updated-dependencies: - dependency-name: pytest dependency-version: 8.4.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c8e279439..5e386c6f4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pyproject-fmt==2.6.0", "pyright==1.1.402", "pyroma==4.2", - "pytest==8.4.0", + "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", "ruff==0.11.13", From 60df97d3c1fac0fdff03d57b2225e4ffff14bbc8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 23 Jun 2025 12:02:23 +0000 Subject: [PATCH 0701/1003] Bump pygments from 2.19.1 to 2.19.2 Bumps [pygments](https://github.com/pygments/pygments) from 2.19.1 to 2.19.2. - [Release notes](https://github.com/pygments/pygments/releases) - [Changelog](https://github.com/pygments/pygments/blob/master/CHANGES) - [Commits](https://github.com/pygments/pygments/compare/2.19.1...2.19.2) --- updated-dependencies: - dependency-name: pygments dependency-version: 2.19.2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2801ec9c3..fd8ca2e04 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pre-commit==4.2.0", "pydocstyle==6.3", "pyenchant==3.3.0rc1", - "pygments==2.19.1", + "pygments==2.19.2", "pylint==3.3.7", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.6.0", From d507540773872f198e0674ce47c374733d6edc59 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 27 Jun 2025 10:19:59 +0000 Subject: [PATCH 0702/1003] Bump ruff from 0.12.0 to 0.12.1 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.12.0 to 0.12.1. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.12.0...0.12.1) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.12.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index fd8ca2e04..03d1c5ca8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", - "ruff==0.12.0", + "ruff==0.12.1", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 48e722e15a74b7ce041ce4cde19ed972f82355cc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 2 Jul 2025 10:43:10 +0000 Subject: [PATCH 0703/1003] Bump pyroma from 4.2 to 4.3.2 Bumps [pyroma](https://github.com/regebro/pyroma) from 4.2 to 4.3.2. - [Changelog](https://github.com/regebro/pyroma/blob/master/CHANGES.txt) - [Commits](https://github.com/regebro/pyroma/compare/4.2...4.3.2) --- updated-dependencies: - dependency-name: pyroma dependency-version: 4.3.2 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 03d1c5ca8..7ac67bf35 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.6.0", "pyright==1.1.402", - "pyroma==4.2", + "pyroma==4.3.2", "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", From 7798b19e164eff0131df6ede00e794ccb5d9dcde Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 4 Jul 2025 10:16:13 +0000 Subject: [PATCH 0704/1003] Bump ruff from 0.12.1 to 0.12.2 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.12.1 to 0.12.2. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.12.1...0.12.2) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.12.2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7ac67bf35..d3ffe1fc6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", - "ruff==0.12.1", + "ruff==0.12.2", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 56be23315237cf4e4b64e8789ad1468d13f90f8f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 4 Jul 2025 10:16:21 +0000 Subject: [PATCH 0705/1003] Bump pyroma from 4.3.2 to 4.3.3 Bumps [pyroma](https://github.com/regebro/pyroma) from 4.3.2 to 4.3.3. - [Changelog](https://github.com/regebro/pyroma/blob/master/CHANGES.txt) - [Commits](https://github.com/regebro/pyroma/compare/4.3.2...4.3.3) --- updated-dependencies: - dependency-name: pyroma dependency-version: 4.3.3 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7ac67bf35..455d031a0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.6.0", "pyright==1.1.402", - "pyroma==4.3.2", + "pyroma==4.3.3", "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", From fd85000507bb36139603758fe743e362cdad9820 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 8 Jul 2025 10:38:44 +0000 Subject: [PATCH 0706/1003] Bump shfmt-py from 3.11.0.2 to 3.12.0.2 Bumps [shfmt-py](https://github.com/maxwinterstein/shfmt-py) from 3.11.0.2 to 3.12.0.2. - [Release notes](https://github.com/maxwinterstein/shfmt-py/releases) - [Commits](https://github.com/maxwinterstein/shfmt-py/commits) --- updated-dependencies: - dependency-name: shfmt-py dependency-version: 3.12.0.2 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a5bdaabe4..964720136 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -66,7 +66,7 @@ optional-dependencies.dev = [ # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. "shellcheck-py==0.10.0.1", - "shfmt-py==3.11.0.2", + "shfmt-py==3.12.0.2", "sphinx==8.2.3", "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.0", From fd163871d1ac98f6e0d593b89c84c61d1bf22571 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 9 Jul 2025 10:19:03 +0000 Subject: [PATCH 0707/1003] Bump pyright from 1.1.402 to 1.1.403 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.402 to 1.1.403. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.402...v1.1.403) --- updated-dependencies: - dependency-name: pyright dependency-version: 1.1.403 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 964720136..8dc7bbb83 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pylint==3.3.7", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.6.0", - "pyright==1.1.402", + "pyright==1.1.403", "pyroma==4.3.3", "pytest==8.4.1", "pytest-cov==6.2.1", From 6633e5f172b95c015ef340fce4d4170fb9811873 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 14 Jul 2025 12:00:07 +0000 Subject: [PATCH 0708/1003] Bump ruff from 0.12.2 to 0.12.3 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.12.2 to 0.12.3. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.12.2...0.12.3) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.12.3 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8dc7bbb83..bca4b1652 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", - "ruff==0.12.2", + "ruff==0.12.3", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From b2072bea50bdb4e0a838d7634780dd83ba0b8cd1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 14 Jul 2025 12:19:55 +0000 Subject: [PATCH 0709/1003] Bump freezegun from 1.5.2 to 1.5.3 Bumps [freezegun](https://github.com/spulec/freezegun) from 1.5.2 to 1.5.3. - [Release notes](https://github.com/spulec/freezegun/releases) - [Changelog](https://github.com/spulec/freezegun/blob/master/CHANGELOG) - [Commits](https://github.com/spulec/freezegun/compare/1.5.2...1.5.3) --- updated-dependencies: - dependency-name: freezegun dependency-version: 1.5.3 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8dc7bbb83..0f36ca419 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -44,7 +44,7 @@ optional-dependencies.dev = [ "doc8==2.0.0", "doccmd==2025.4.8", "docformatter==1.7.7", - "freezegun==1.5.2", + "freezegun==1.5.3", "furo==2024.8.6", "interrogate==1.7.0", "mypy[faster-cache]==1.16.1", From 4edd805cdc90ca3c85490e707b2b43b18cbad90c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 15 Jul 2025 10:11:06 +0000 Subject: [PATCH 0710/1003] Bump pyroma from 4.3.3 to 5.0 Bumps [pyroma](https://github.com/regebro/pyroma) from 4.3.3 to 5.0. - [Changelog](https://github.com/regebro/pyroma/blob/master/CHANGES.txt) - [Commits](https://github.com/regebro/pyroma/compare/4.3.3...5.0) --- updated-dependencies: - dependency-name: pyroma dependency-version: '5.0' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8891ba97e..8250d8fe3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.6.0", "pyright==1.1.403", - "pyroma==4.3.3", + "pyroma==5.0", "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", From b82469cc28a3f83d9b348600c345e0ee2f706439 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 15 Jul 2025 10:11:13 +0000 Subject: [PATCH 0711/1003] Bump mypy[faster-cache] from 1.16.1 to 1.17.0 Bumps [mypy[faster-cache]](https://github.com/python/mypy) from 1.16.1 to 1.17.0. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.16.1...v1.17.0) --- updated-dependencies: - dependency-name: mypy[faster-cache] dependency-version: 1.17.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8891ba97e..3304982af 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -47,7 +47,7 @@ optional-dependencies.dev = [ "freezegun==1.5.3", "furo==2024.8.6", "interrogate==1.7.0", - "mypy[faster-cache]==1.16.1", + "mypy[faster-cache]==1.17.0", "mypy-strict-kwargs==2025.4.3", "pre-commit==4.2.0", "pydocstyle==6.3", From 204adca8c5e0e29c64a072a3be56c60e3af4f932 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 18 Jul 2025 10:34:00 +0000 Subject: [PATCH 0712/1003] Bump ruff from 0.12.3 to 0.12.4 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.12.3 to 0.12.4. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.12.3...0.12.4) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.12.4 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 088e0dc76..98dc1f2db 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", - "ruff==0.12.3", + "ruff==0.12.4", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From d15a9a7eaf24a02752c5b443269e4bcee4e93d35 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 21 Jul 2025 12:09:24 +0000 Subject: [PATCH 0713/1003] Bump furo from 2024.8.6 to 2025.7.19 Bumps [furo](https://github.com/pradyunsg/furo) from 2024.8.6 to 2025.7.19. - [Release notes](https://github.com/pradyunsg/furo/releases) - [Changelog](https://github.com/pradyunsg/furo/blob/main/docs/changelog.md) - [Commits](https://github.com/pradyunsg/furo/compare/2024.08.06...2025.07.19) --- updated-dependencies: - dependency-name: furo dependency-version: 2025.7.19 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 98dc1f2db..732caca55 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -45,7 +45,7 @@ optional-dependencies.dev = [ "doccmd==2025.4.8", "docformatter==1.7.7", "freezegun==1.5.3", - "furo==2024.8.6", + "furo==2025.7.19", "interrogate==1.7.0", "mypy[faster-cache]==1.17.0", "mypy-strict-kwargs==2025.4.3", From bae3e79c21d19d91f1f2ec78a824055e7ca16949 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 25 Jul 2025 10:33:52 +0000 Subject: [PATCH 0714/1003] Bump ruff from 0.12.4 to 0.12.5 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.12.4 to 0.12.5. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.12.4...0.12.5) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.12.5 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 732caca55..0266370f1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", - "ruff==0.12.4", + "ruff==0.12.5", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From cd7e64cd32153265b915bf9aee40907efd414fdc Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 30 Jul 2025 10:40:24 +0000 Subject: [PATCH 0715/1003] Bump ruff from 0.12.5 to 0.12.7 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.12.5 to 0.12.7. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.12.5...0.12.7) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.12.7 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0266370f1..7f7c030af 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", - "ruff==0.12.5", + "ruff==0.12.7", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From b9ad8a0698666fe868997e21dbfb65cc0f3bd1b9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 31 Jul 2025 11:01:53 +0000 Subject: [PATCH 0716/1003] Bump freezegun from 1.5.3 to 1.5.4 Bumps [freezegun](https://github.com/spulec/freezegun) from 1.5.3 to 1.5.4. - [Release notes](https://github.com/spulec/freezegun/releases) - [Changelog](https://github.com/spulec/freezegun/blob/master/CHANGELOG) - [Commits](https://github.com/spulec/freezegun/compare/1.5.3...1.5.4) --- updated-dependencies: - dependency-name: freezegun dependency-version: 1.5.4 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7f7c030af..5e56da8b4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -44,7 +44,7 @@ optional-dependencies.dev = [ "doc8==2.0.0", "doccmd==2025.4.8", "docformatter==1.7.7", - "freezegun==1.5.3", + "freezegun==1.5.4", "furo==2025.7.19", "interrogate==1.7.0", "mypy[faster-cache]==1.17.0", From 5296aa6d312c1c221466302344a1c5d1b1405b70 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 31 Jul 2025 11:02:11 +0000 Subject: [PATCH 0717/1003] Bump mypy[faster-cache] from 1.17.0 to 1.17.1 Bumps [mypy[faster-cache]](https://github.com/python/mypy) from 1.17.0 to 1.17.1. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.17.0...v1.17.1) --- updated-dependencies: - dependency-name: mypy[faster-cache] dependency-version: 1.17.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7f7c030af..f19664862 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -47,7 +47,7 @@ optional-dependencies.dev = [ "freezegun==1.5.3", "furo==2025.7.19", "interrogate==1.7.0", - "mypy[faster-cache]==1.17.0", + "mypy[faster-cache]==1.17.1", "mypy-strict-kwargs==2025.4.3", "pre-commit==4.2.0", "pydocstyle==6.3", From f1698aad37ff4775f7aa27c649adb4ed23667dba Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 31 Jul 2025 11:02:17 +0000 Subject: [PATCH 0718/1003] Bump deptry from 0.23.0 to 0.23.1 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.23.0 to 0.23.1. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.23.0...0.23.1) --- updated-dependencies: - dependency-name: deptry dependency-version: 0.23.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7f7c030af..6c6148d01 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -40,7 +40,7 @@ dependencies = [ optional-dependencies.dev = [ "actionlint-py==1.7.7.23", "check-manifest==0.50", - "deptry==0.23.0", + "deptry==0.23.1", "doc8==2.0.0", "doccmd==2025.4.8", "docformatter==1.7.7", From 7d8811f7ac8cba09d46d38e4eab259a5cc282cca Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 4 Aug 2025 13:42:44 +0000 Subject: [PATCH 0719/1003] Bump check-wheel-contents from 0.6.2 to 0.6.3 Bumps [check-wheel-contents](https://github.com/jwodder/check-wheel-contents) from 0.6.2 to 0.6.3. - [Release notes](https://github.com/jwodder/check-wheel-contents/releases) - [Changelog](https://github.com/jwodder/check-wheel-contents/blob/master/CHANGELOG.md) - [Commits](https://github.com/jwodder/check-wheel-contents/compare/v0.6.2...v0.6.3) --- updated-dependencies: - dependency-name: check-wheel-contents dependency-version: 0.6.3 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 89c5af819..ed9d22865 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -80,7 +80,7 @@ optional-dependencies.dev = [ "vws-test-fixtures==2023.3.5", "yamlfix==1.17.0", ] -optional-dependencies.release = [ "check-wheel-contents==0.6.2" ] +optional-dependencies.release = [ "check-wheel-contents==0.6.3" ] urls.Documentation = "https://vws-python.github.io/vws-python/" urls.Source = "https://github.com/VWS-Python/vws-python" From c6cf9596845c600399c5219ac79c49f8dad79476 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 8 Aug 2025 10:49:23 +0000 Subject: [PATCH 0720/1003] Bump ruff from 0.12.7 to 0.12.8 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.12.7 to 0.12.8. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.12.7...0.12.8) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.12.8 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ed9d22865..44a1f850f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", - "ruff==0.12.7", + "ruff==0.12.8", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From aada8590139173dc4551969d9ed17f95a6381f25 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 8 Aug 2025 10:49:35 +0000 Subject: [PATCH 0721/1003] Bump sybil from 9.1.0 to 9.2.0 Bumps [sybil](https://github.com/simplistix/sybil) from 9.1.0 to 9.2.0. - [Changelog](https://github.com/simplistix/sybil/blob/master/CHANGELOG.rst) - [Commits](https://github.com/simplistix/sybil/compare/9.1.0...9.2.0) --- updated-dependencies: - dependency-name: sybil dependency-version: 9.2.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ed9d22865..d65cfcd2f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,7 +73,7 @@ optional-dependencies.dev = [ "sphinx-pyproject==0.3.0", "sphinx-substitution-extensions==2025.6.6", "sphinxcontrib-spelling==8.0.1", - "sybil==9.1.0", + "sybil==9.2.0", "types-requests==2.32.4.20250611", "vulture==2.14", "vws-python-mock==2025.3.10.1", From 825fc670bcb2c43f90e87f7e2544cccdf5de68f7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Aug 2025 14:36:56 +0000 Subject: [PATCH 0722/1003] Bump pre-commit from 4.2.0 to 4.3.0 Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 4.2.0 to 4.3.0. - [Release notes](https://github.com/pre-commit/pre-commit/releases) - [Changelog](https://github.com/pre-commit/pre-commit/blob/main/CHANGELOG.md) - [Commits](https://github.com/pre-commit/pre-commit/compare/v4.2.0...v4.3.0) --- updated-dependencies: - dependency-name: pre-commit dependency-version: 4.3.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4d19a6f77..f6c9ea55c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -49,7 +49,7 @@ optional-dependencies.dev = [ "interrogate==1.7.0", "mypy[faster-cache]==1.17.1", "mypy-strict-kwargs==2025.4.3", - "pre-commit==4.2.0", + "pre-commit==4.3.0", "pydocstyle==6.3", "pyenchant==3.3.0rc1", "pygments==2.19.2", From 1b0aeb321bb09b9c4cece24425fa5a4ee9f5e17b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Aug 2025 14:38:03 +0000 Subject: [PATCH 0723/1003] Bump freezegun from 1.5.4 to 1.5.5 Bumps [freezegun](https://github.com/spulec/freezegun) from 1.5.4 to 1.5.5. - [Release notes](https://github.com/spulec/freezegun/releases) - [Changelog](https://github.com/spulec/freezegun/blob/master/CHANGELOG) - [Commits](https://github.com/spulec/freezegun/compare/1.5.4...1.5.5) --- updated-dependencies: - dependency-name: freezegun dependency-version: 1.5.5 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4d19a6f77..bdf65c3ae 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -44,7 +44,7 @@ optional-dependencies.dev = [ "doc8==2.0.0", "doccmd==2025.4.8", "docformatter==1.7.7", - "freezegun==1.5.4", + "freezegun==1.5.5", "furo==2025.7.19", "interrogate==1.7.0", "mypy[faster-cache]==1.17.1", From a15757763f92e5d178ff540e30ef2c44c157fc8c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Aug 2025 15:44:46 +0000 Subject: [PATCH 0724/1003] Bump types-requests from 2.32.4.20250611 to 2.32.4.20250809 Bumps [types-requests](https://github.com/typeshed-internal/stub_uploader) from 2.32.4.20250611 to 2.32.4.20250809. - [Commits](https://github.com/typeshed-internal/stub_uploader/commits) --- updated-dependencies: - dependency-name: types-requests dependency-version: 2.32.4.20250809 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4d19a6f77..1294fe3fa 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -74,7 +74,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.6.6", "sphinxcontrib-spelling==8.0.1", "sybil==9.2.0", - "types-requests==2.32.4.20250611", + "types-requests==2.32.4.20250809", "vulture==2.14", "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", From b9765629f2819351e2cae586cd18300c35b80aa7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Aug 2025 16:03:52 +0000 Subject: [PATCH 0725/1003] Bump pylint from 3.3.7 to 3.3.8 Bumps [pylint](https://github.com/pylint-dev/pylint) from 3.3.7 to 3.3.8. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.3.7...v3.3.8) --- updated-dependencies: - dependency-name: pylint dependency-version: 3.3.8 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4d19a6f77..a575f81bf 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pyenchant==3.3.0rc1", "pygments==2.19.2", - "pylint==3.3.7", + "pylint==3.3.8", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.6.0", "pyright==1.1.403", From 32fea5f76c81a68b11f2fc2ae2ca75753b4de0ec Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Aug 2025 16:16:42 +0000 Subject: [PATCH 0726/1003] Bump shellcheck-py from 0.10.0.1 to 0.11.0.1 Bumps [shellcheck-py](https://github.com/ryanrhee/shellcheck-py) from 0.10.0.1 to 0.11.0.1. - [Commits](https://github.com/ryanrhee/shellcheck-py/compare/v0.10.0.1...v0.11.0.1) --- updated-dependencies: - dependency-name: shellcheck-py dependency-version: 0.11.0.1 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 4d19a6f77..85e4b6c06 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -65,7 +65,7 @@ optional-dependencies.dev = [ # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. - "shellcheck-py==0.10.0.1", + "shellcheck-py==0.11.0.1", "shfmt-py==3.12.0.2", "sphinx==8.2.3", "sphinx-copybutton==0.5.2", From a80be06d2511101c34ea35ec5c0e51037cca6c1e Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 11 Aug 2025 22:17:45 +0000 Subject: [PATCH 0727/1003] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/pre-commit-hooks: v5.0.0 → v6.0.0](https://github.com/pre-commit/pre-commit-hooks/compare/v5.0.0...v6.0.0) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c480de3e9..addfdb70e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -46,7 +46,7 @@ repos: hooks: - id: check-useless-excludes - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v5.0.0 + rev: v6.0.0 hooks: - id: check-added-large-files - id: check-case-conflict From 00d702af3815c78a6091605393f185a2b79fc68d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 12 Aug 2025 17:54:10 +0000 Subject: [PATCH 0728/1003] Bump actions/checkout from 4 to 5 Bumps [actions/checkout](https://github.com/actions/checkout) from 4 to 5. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v4...v5) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '5' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- .github/workflows/lint.yml | 2 +- .github/workflows/release.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index de333f893..e8e3da5a0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -23,7 +23,7 @@ jobs: runs-on: ${{ matrix.platform }} steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Install uv uses: astral-sh/setup-uv@v6 diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 6f0dbc9c3..71774a6d8 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -23,7 +23,7 @@ jobs: runs-on: ${{ matrix.platform }} steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - name: Install uv uses: astral-sh/setup-uv@v6 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c00447040..a19408730 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -21,7 +21,7 @@ jobs: contents: write steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 with: # See # https://github.com/stefanzweifel/git-auto-commit-action?tab=readme-ov-file#push-to-protected-branches From c923eccfdde3ce628514810d2c8dc2d51411bc88 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 15 Aug 2025 10:39:43 +0000 Subject: [PATCH 0729/1003] Bump ruff from 0.12.8 to 0.12.9 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.12.8 to 0.12.9. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.12.8...0.12.9) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.12.9 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a917ebc9f..8e29d5389 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", - "ruff==0.12.8", + "ruff==0.12.9", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 3859bad95c61410134fedc03eba02c81595b3d70 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 21 Aug 2025 10:22:41 +0000 Subject: [PATCH 0730/1003] Bump pyright from 1.1.403 to 1.1.404 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.403 to 1.1.404. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.403...v1.1.404) --- updated-dependencies: - dependency-name: pyright dependency-version: 1.1.404 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8e29d5389..f4e316b7a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pylint==3.3.8", "pylint-per-file-ignores==1.4.0", "pyproject-fmt==2.6.0", - "pyright==1.1.403", + "pyright==1.1.404", "pyroma==5.0", "pytest==8.4.1", "pytest-cov==6.2.1", From 5bf6193ec5a314b1f3e1a0ee58fbfc5cf55a43ed Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 22 Aug 2025 10:15:21 +0000 Subject: [PATCH 0731/1003] Bump ruff from 0.12.9 to 0.12.10 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.12.9 to 0.12.10. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.12.9...0.12.10) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.12.10 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f4e316b7a..624947f08 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", - "ruff==0.12.9", + "ruff==0.12.10", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From eb19b9083f7b61b31fe45f530e7b3bdacb4386c6 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 24 Aug 2025 17:04:52 +0100 Subject: [PATCH 0732/1003] Simplify specifying license --- LICENSE | 19 ------------------- pyproject.toml | 3 +-- 2 files changed, 1 insertion(+), 21 deletions(-) delete mode 100644 LICENSE diff --git a/LICENSE b/LICENSE deleted file mode 100644 index ef26969f8..000000000 --- a/LICENSE +++ /dev/null @@ -1,19 +0,0 @@ -The MIT License - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. diff --git a/pyproject.toml b/pyproject.toml index 624947f08..3bd00d717 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -14,7 +14,7 @@ keywords = [ "vuforia", "vws", ] -license = { file = "LICENSE" } +license = "MIT" authors = [ { name = "Adam Dangoor", email = "adamdangoor@gmail.com" }, ] @@ -22,7 +22,6 @@ requires-python = ">=3.13" classifiers = [ "Development Status :: 5 - Production/Stable", "Environment :: Web Environment", - "License :: OSI Approved :: MIT License", "Operating System :: Microsoft :: Windows", "Operating System :: POSIX", "Programming Language :: Python :: 3 :: Only", From 22a2cca62a9ff655eaad04cdcbf7173a42bd16d4 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 24 Aug 2025 17:47:50 +0100 Subject: [PATCH 0733/1003] Run pre-commit hooks on only one stage each --- .pre-commit-config.yaml | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index addfdb70e..5c164119e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -45,31 +45,49 @@ repos: - repo: meta hooks: - id: check-useless-excludes + stages: [pre-commit] - repo: https://github.com/pre-commit/pre-commit-hooks rev: v6.0.0 hooks: - id: check-added-large-files + stages: [pre-commit] - id: check-case-conflict + stages: [pre-commit] - id: check-executables-have-shebangs + stages: [pre-commit] - id: check-merge-conflict + stages: [pre-commit] - id: check-shebang-scripts-are-executable + stages: [pre-commit] - id: check-symlinks + stages: [pre-commit] - id: check-json + stages: [pre-commit] - id: check-toml + stages: [pre-commit] - id: check-vcs-permalinks + stages: [pre-commit] - id: check-yaml + stages: [pre-commit] - id: end-of-file-fixer + stages: [pre-commit] - id: file-contents-sorter files: spelling_private_dict\.txt$ + stages: [pre-commit] - id: trailing-whitespace + stages: [pre-commit] - repo: https://github.com/pre-commit/pygrep-hooks rev: v1.10.0 hooks: - id: rst-directive-colons + stages: [pre-commit] - id: rst-inline-touching-normal + stages: [pre-commit] - id: text-unicode-replacement-char + stages: [pre-commit] - id: rst-backticks + stages: [pre-commit] - repo: local hooks: - id: actionlint @@ -79,6 +97,7 @@ repos: pass_filenames: false types_or: [yaml] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: docformatter name: docformatter @@ -86,6 +105,7 @@ repos: language: python types_or: [python] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: shellcheck name: shellcheck @@ -93,6 +113,7 @@ repos: language: python types_or: [shell] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: shellcheck-docs name: shellcheck-docs @@ -101,6 +122,7 @@ repos: language: python types_or: [markdown, rst] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: shfmt name: shfmt @@ -108,6 +130,7 @@ repos: language: python types_or: [shell] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: shfmt-docs name: shfmt-docs @@ -116,6 +139,7 @@ repos: language: python types_or: [markdown, rst] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: mypy name: mypy @@ -166,6 +190,7 @@ repos: types_or: [python] pass_filenames: false additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: vulture-docs name: vulture docs @@ -173,6 +198,7 @@ repos: language: python types_or: [markdown, rst] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: pyroma name: pyroma @@ -181,6 +207,7 @@ repos: pass_filenames: false types_or: [toml] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: deptry name: deptry @@ -188,6 +215,7 @@ repos: language: python pass_filenames: false additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: pylint name: pylint @@ -211,6 +239,7 @@ repos: language: python types_or: [python] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: ruff-check-fix-docs name: Ruff check fix docs @@ -218,6 +247,7 @@ repos: language: python types_or: [markdown, rst] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: ruff-format-fix name: Ruff format @@ -225,6 +255,7 @@ repos: language: python types_or: [python] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: ruff-format-fix-docs name: Ruff format docs @@ -233,6 +264,7 @@ repos: language: python types_or: [markdown, rst] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: doc8 name: doc8 @@ -240,6 +272,7 @@ repos: language: python types_or: [rst] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: interrogate name: interrogate @@ -247,6 +280,7 @@ repos: language: python types_or: [python] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: interrogate-docs name: interrogate docs @@ -254,6 +288,7 @@ repos: language: python types_or: [markdown, rst] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: pyproject-fmt-fix name: pyproject-fmt @@ -262,6 +297,7 @@ repos: types_or: [toml] files: pyproject.toml additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: linkcheck name: linkcheck @@ -304,6 +340,7 @@ repos: language: python types_or: [yaml] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] - id: sphinx-lint name: sphinx-lint @@ -311,3 +348,4 @@ repos: language: python types_or: [rst] additional_dependencies: [uv==0.6.3] + stages: [pre-commit] From fcaa10d1f92199c06c2b312b301ceb29672ff968 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 27 Aug 2025 23:22:03 +0100 Subject: [PATCH 0734/1003] Bump pylint per-file-ignores --- pyproject.toml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 3bd00d717..cc10111b0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pyenchant==3.3.0rc1", "pygments==2.19.2", "pylint==3.3.8", - "pylint-per-file-ignores==1.4.0", + "pylint-per-file-ignores==2.0.3", "pyproject-fmt==2.6.0", "pyright==1.1.404", "pyroma==5.0", @@ -248,7 +248,8 @@ disable = [ # - We want to use global variables in documentation, which may not be uppercase. # - conf.py is a Sphinx configuration file which requires lowercase global variable names. per-file-ignores = [ - "docs/:invalid-name", + "docs/source/conf.py:invalid-name", + "docs/source/doccmd_*.py:invalid-name", "doccmd_README_rst.*.py:invalid-name", ] From af9bf7520cd87956fbae5de426958db1804eaa14 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 27 Aug 2025 23:29:26 +0100 Subject: [PATCH 0735/1003] Bump pylint per-file-ignores --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index cc10111b0..b5eeff047 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -250,7 +250,7 @@ disable = [ per-file-ignores = [ "docs/source/conf.py:invalid-name", "docs/source/doccmd_*.py:invalid-name", - "doccmd_README_rst.*.py:invalid-name", + "doccmd_README_rst_*.py:invalid-name", ] [tool.pylint.'FORMAT'] From a94bad5cf3e8ab95fd6f5d8f297c37d411c36678 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 29 Aug 2025 10:07:18 +0000 Subject: [PATCH 0736/1003] Bump ruff from 0.12.10 to 0.12.11 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.12.10 to 0.12.11. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.12.10...0.12.11) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.12.11 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b5eeff047..77de76c3e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ optional-dependencies.dev = [ "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", - "ruff==0.12.10", + "ruff==0.12.11", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 5b22fb36ad798133c46be65f898bdc6929006fb9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 4 Sep 2025 13:17:00 +0000 Subject: [PATCH 0737/1003] Bump pyright from 1.1.404 to 1.1.405 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.404 to 1.1.405. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.404...v1.1.405) --- updated-dependencies: - dependency-name: pyright dependency-version: 1.1.405 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 77de76c3e..15ca2a1d6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint==3.3.8", "pylint-per-file-ignores==2.0.3", "pyproject-fmt==2.6.0", - "pyright==1.1.404", + "pyright==1.1.405", "pyroma==5.0", "pytest==8.4.1", "pytest-cov==6.2.1", From 73686e48273d513e45e32bda249291be4a357b67 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 5 Sep 2025 10:06:46 +0000 Subject: [PATCH 0738/1003] Bump pytest from 8.4.1 to 8.4.2 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.4.1 to 8.4.2. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.4.1...8.4.2) --- updated-dependencies: - dependency-name: pytest dependency-version: 8.4.2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 15ca2a1d6..7c628a437 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -57,7 +57,7 @@ optional-dependencies.dev = [ "pyproject-fmt==2.6.0", "pyright==1.1.405", "pyroma==5.0", - "pytest==8.4.1", + "pytest==8.4.2", "pytest-cov==6.2.1", "pyyaml==6.0.2", "ruff==0.12.11", From eaac5dcdf2b356dcc79ef2f7a66f134fdcdff4ea Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 5 Sep 2025 10:07:02 +0000 Subject: [PATCH 0739/1003] Bump ruff from 0.12.11 to 0.12.12 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.12.11 to 0.12.12. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.12.11...0.12.12) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.12.12 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 15ca2a1d6..d95e0b17f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ optional-dependencies.dev = [ "pytest==8.4.1", "pytest-cov==6.2.1", "pyyaml==6.0.2", - "ruff==0.12.11", + "ruff==0.12.12", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 063b9d365dbf517b7a06df81e28ce989372b8daa Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Sep 2025 10:31:55 +0000 Subject: [PATCH 0740/1003] Bump pytest-cov from 6.2.1 to 6.3.0 Bumps [pytest-cov](https://github.com/pytest-dev/pytest-cov) from 6.2.1 to 6.3.0. - [Changelog](https://github.com/pytest-dev/pytest-cov/blob/master/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest-cov/compare/v6.2.1...v6.3.0) --- updated-dependencies: - dependency-name: pytest-cov dependency-version: 6.3.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d823ba952..c3f48e366 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pyright==1.1.405", "pyroma==5.0", "pytest==8.4.2", - "pytest-cov==6.2.1", + "pytest-cov==6.3.0", "pyyaml==6.0.2", "ruff==0.12.12", # We add shellcheck-py not only for shell scripts and shell code blocks, From 3a215e060f2c3caca35a791f256446c9d2ebb6e1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Sep 2025 10:33:49 +0000 Subject: [PATCH 0741/1003] Bump yamlfix from 1.17.0 to 1.18.0 Bumps [yamlfix](https://github.com/lyz-code/yamlfix) from 1.17.0 to 1.18.0. - [Changelog](https://github.com/lyz-code/yamlfix/blob/main/CHANGELOG.md) - [Commits](https://github.com/lyz-code/yamlfix/compare/1.17.0...1.18.0) --- updated-dependencies: - dependency-name: yamlfix dependency-version: 1.18.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d823ba952..a06268a8d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -77,7 +77,7 @@ optional-dependencies.dev = [ "vulture==2.14", "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", - "yamlfix==1.17.0", + "yamlfix==1.18.0", ] optional-dependencies.release = [ "check-wheel-contents==0.6.3" ] urls.Documentation = "https://vws-python.github.io/vws-python/" From faa21d2fc8535a6b90223203aab46d008e9c6db3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 10 Sep 2025 10:06:21 +0000 Subject: [PATCH 0742/1003] Bump pytest-cov from 6.3.0 to 7.0.0 Bumps [pytest-cov](https://github.com/pytest-dev/pytest-cov) from 6.3.0 to 7.0.0. - [Changelog](https://github.com/pytest-dev/pytest-cov/blob/master/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest-cov/compare/v6.3.0...v7.0.0) --- updated-dependencies: - dependency-name: pytest-cov dependency-version: 7.0.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 60bd5dbae..a1fa17472 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pyright==1.1.405", "pyroma==5.0", "pytest==8.4.2", - "pytest-cov==6.3.0", + "pytest-cov==7.0.0", "pyyaml==6.0.2", "ruff==0.12.12", # We add shellcheck-py not only for shell scripts and shell code blocks, From e6edf35d8cf00ad835c61090f9be6ad4d0f71b21 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 11 Sep 2025 10:07:17 +0000 Subject: [PATCH 0743/1003] Bump ruff from 0.12.12 to 0.13.0 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.12.12 to 0.13.0. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.12.12...0.13.0) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.13.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a1fa17472..88d6cdeba 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ optional-dependencies.dev = [ "pytest==8.4.2", "pytest-cov==7.0.0", "pyyaml==6.0.2", - "ruff==0.12.12", + "ruff==0.13.0", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From c9b5da269b2e6af16ee5e1d4ce1be783fc1a6429 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 12 Sep 2025 10:07:26 +0000 Subject: [PATCH 0744/1003] Bump mypy[faster-cache] from 1.17.1 to 1.18.1 Bumps [mypy[faster-cache]](https://github.com/python/mypy) from 1.17.1 to 1.18.1. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.17.1...v1.18.1) --- updated-dependencies: - dependency-name: mypy[faster-cache] dependency-version: 1.18.1 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 88d6cdeba..30d6da20a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -46,7 +46,7 @@ optional-dependencies.dev = [ "freezegun==1.5.5", "furo==2025.7.19", "interrogate==1.7.0", - "mypy[faster-cache]==1.17.1", + "mypy[faster-cache]==1.18.1", "mypy-strict-kwargs==2025.4.3", "pre-commit==4.3.0", "pydocstyle==6.3", From 91cccb574eebf16923c593adc3179ef1af2c898f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 14 Sep 2025 22:34:53 +0100 Subject: [PATCH 0745/1003] Remove direct pyenchant dependency now that 3.3.0 supports the latest macOS --- pyproject.toml | 1 - 1 file changed, 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 30d6da20a..8155d78c5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -50,7 +50,6 @@ optional-dependencies.dev = [ "mypy-strict-kwargs==2025.4.3", "pre-commit==4.3.0", "pydocstyle==6.3", - "pyenchant==3.3.0rc1", "pygments==2.19.2", "pylint==3.3.8", "pylint-per-file-ignores==2.0.3", From c3c9801d05f04662ba004f7049de387a1aa09a1f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 15 Sep 2025 03:29:50 +0100 Subject: [PATCH 0746/1003] Make pylint spelling dependency explicit --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8155d78c5..0f0a053a8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pre-commit==4.3.0", "pydocstyle==6.3", "pygments==2.19.2", - "pylint==3.3.8", + "pylint[spelling]==3.3.8", "pylint-per-file-ignores==2.0.3", "pyproject-fmt==2.6.0", "pyright==1.1.405", From 3b6658fe8dc4f3e05fc466a1eab29fb2ece13adb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 15 Sep 2025 10:35:09 +0000 Subject: [PATCH 0747/1003] Bump types-requests from 2.32.4.20250809 to 2.32.4.20250913 Bumps [types-requests](https://github.com/typeshed-internal/stub_uploader) from 2.32.4.20250809 to 2.32.4.20250913. - [Commits](https://github.com/typeshed-internal/stub_uploader/commits) --- updated-dependencies: - dependency-name: types-requests dependency-version: 2.32.4.20250913 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0f0a053a8..d3d24c834 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -72,7 +72,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.6.6", "sphinxcontrib-spelling==8.0.1", "sybil==9.2.0", - "types-requests==2.32.4.20250809", + "types-requests==2.32.4.20250913", "vulture==2.14", "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", From 8b1cdcbc391a2bdce36bc3dc827ee8e540996fa3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 19 Sep 2025 10:07:54 +0000 Subject: [PATCH 0748/1003] Bump doccmd from 2025.4.8 to 2025.9.19 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.4.8 to 2025.9.19. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.04.08...2025.09.19) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2025.9.19 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d3d24c834..83e974706 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.50", "deptry==0.23.1", "doc8==2.0.0", - "doccmd==2025.4.8", + "doccmd==2025.9.19", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.7.19", From c7f89faa312257ca277b3bd1ccad4cbce90a8ae4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 19 Sep 2025 10:36:18 +0000 Subject: [PATCH 0749/1003] Bump ruff from 0.13.0 to 0.13.1 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.13.0 to 0.13.1. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.13.0...0.13.1) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.13.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 83e974706..2d53e4755 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pytest==8.4.2", "pytest-cov==7.0.0", "pyyaml==6.0.2", - "ruff==0.13.0", + "ruff==0.13.1", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 4b1dafd48ef33ebc55a459c3238da0c848f8b34a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 19 Sep 2025 10:36:24 +0000 Subject: [PATCH 0750/1003] Bump mypy[faster-cache] from 1.18.1 to 1.18.2 Bumps [mypy[faster-cache]](https://github.com/python/mypy) from 1.18.1 to 1.18.2. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.18.1...v1.18.2) --- updated-dependencies: - dependency-name: mypy[faster-cache] dependency-version: 1.18.2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 83e974706..9f9c4d147 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -46,7 +46,7 @@ optional-dependencies.dev = [ "freezegun==1.5.5", "furo==2025.7.19", "interrogate==1.7.0", - "mypy[faster-cache]==1.18.1", + "mypy[faster-cache]==1.18.2", "mypy-strict-kwargs==2025.4.3", "pre-commit==4.3.0", "pydocstyle==6.3", From 95dc03e8f8df892f064e1192e3eec9d32193097f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 26 Sep 2025 10:07:07 +0000 Subject: [PATCH 0751/1003] Bump pyyaml from 6.0.2 to 6.0.3 Bumps [pyyaml](https://github.com/yaml/pyyaml) from 6.0.2 to 6.0.3. - [Release notes](https://github.com/yaml/pyyaml/releases) - [Changelog](https://github.com/yaml/pyyaml/blob/6.0.3/CHANGES) - [Commits](https://github.com/yaml/pyyaml/compare/6.0.2...6.0.3) --- updated-dependencies: - dependency-name: pyyaml dependency-version: 6.0.3 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 29e697a8f..7c6b82d34 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -58,7 +58,7 @@ optional-dependencies.dev = [ "pyroma==5.0", "pytest==8.4.2", "pytest-cov==7.0.0", - "pyyaml==6.0.2", + "pyyaml==6.0.3", "ruff==0.13.1", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will From 6885ac6ade117646c842399615bcdbf28a91d574 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 26 Sep 2025 10:07:35 +0000 Subject: [PATCH 0752/1003] Bump furo from 2025.7.19 to 2025.9.25 Bumps [furo](https://github.com/pradyunsg/furo) from 2025.7.19 to 2025.9.25. - [Release notes](https://github.com/pradyunsg/furo/releases) - [Changelog](https://github.com/pradyunsg/furo/blob/main/docs/changelog.md) - [Commits](https://github.com/pradyunsg/furo/compare/2025.07.19...2025.09.25) --- updated-dependencies: - dependency-name: furo dependency-version: 2025.9.25 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 29e697a8f..188de4b02 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -44,7 +44,7 @@ optional-dependencies.dev = [ "doccmd==2025.9.19", "docformatter==1.7.7", "freezegun==1.5.5", - "furo==2025.7.19", + "furo==2025.9.25", "interrogate==1.7.0", "mypy[faster-cache]==1.18.2", "mypy-strict-kwargs==2025.4.3", From b2fc84bd89cec895d83320b961be38333d8a6366 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 26 Sep 2025 10:11:42 +0000 Subject: [PATCH 0753/1003] Bump ruff from 0.13.1 to 0.13.2 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.13.1 to 0.13.2. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.13.1...0.13.2) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.13.2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7c6b82d34..735892aa2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pytest==8.4.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.13.1", + "ruff==0.13.2", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From d8e1a6cca688d2d6fe32c1e0d1716d25ea3ef2ea Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 2 Oct 2025 10:07:33 +0000 Subject: [PATCH 0754/1003] Bump pyright from 1.1.405 to 1.1.406 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.405 to 1.1.406. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.405...v1.1.406) --- updated-dependencies: - dependency-name: pyright dependency-version: 1.1.406 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 81cf71311..8020ea126 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pylint[spelling]==3.3.8", "pylint-per-file-ignores==2.0.3", "pyproject-fmt==2.6.0", - "pyright==1.1.405", + "pyright==1.1.406", "pyroma==5.0", "pytest==8.4.2", "pytest-cov==7.0.0", From 6b54a1d39908fe85d54a6db29925d7230e665693 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 2 Oct 2025 10:12:33 +0000 Subject: [PATCH 0755/1003] Bump pyproject-fmt from 2.6.0 to 2.7.0 Bumps [pyproject-fmt](https://github.com/tox-dev/toml-fmt) from 2.6.0 to 2.7.0. - [Release notes](https://github.com/tox-dev/toml-fmt/releases) - [Commits](https://github.com/tox-dev/toml-fmt/compare/pyproject-fmt/2.6.0...pyproject-fmt/2.7.0) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-version: 2.7.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8020ea126..85e1fc266 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pygments==2.19.2", "pylint[spelling]==3.3.8", "pylint-per-file-ignores==2.0.3", - "pyproject-fmt==2.6.0", + "pyproject-fmt==2.7.0", "pyright==1.1.406", "pyroma==5.0", "pytest==8.4.2", From 5e4a468ac77c7babc8063d224b317e0267bc082a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 3 Oct 2025 10:06:19 +0000 Subject: [PATCH 0756/1003] Bump ruff from 0.13.2 to 0.13.3 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.13.2 to 0.13.3. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.13.2...0.13.3) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.13.3 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 85e1fc266..020c8b7f5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pytest==8.4.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.13.2", + "ruff==0.13.3", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 2c7878dd67c512db71c38f95f2a5075cb9d89558 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 6 Oct 2025 10:51:43 +0000 Subject: [PATCH 0757/1003] Bump pylint[spelling] from 3.3.8 to 3.3.9 Bumps [pylint[spelling]](https://github.com/pylint-dev/pylint) from 3.3.8 to 3.3.9. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.3.8...v3.3.9) --- updated-dependencies: - dependency-name: pylint[spelling] dependency-version: 3.3.9 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 020c8b7f5..2eefdc34c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pre-commit==4.3.0", "pydocstyle==6.3", "pygments==2.19.2", - "pylint[spelling]==3.3.8", + "pylint[spelling]==3.3.9", "pylint-per-file-ignores==2.0.3", "pyproject-fmt==2.7.0", "pyright==1.1.406", From d21db3bbf61f79f88ed25218ca491a25bf43268a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 7 Oct 2025 07:32:36 +0100 Subject: [PATCH 0758/1003] Remove Codecov - it is flaky and doesn't provide much value --- .github/workflows/ci.yml | 8 +------- README.rst | 4 +--- codecov.yaml | 7 ------- pyproject.toml | 1 - 4 files changed, 2 insertions(+), 18 deletions(-) delete mode 100644 codecov.yaml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index e8e3da5a0..92a2848b8 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -35,13 +35,7 @@ jobs: run: | # We run tests against "." and not the tests directory as we test the README # and documentation. - uv run --extra=dev --python=${{ matrix.python-version }} pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests/ . --cov-report=xml - - - name: Upload coverage to Codecov - uses: codecov/codecov-action@v5 - with: - fail_ci_if_error: true - token: ${{ secrets.CODECOV_TOKEN }} + uv run --extra=dev --python=${{ matrix.python-version }} pytest -s -vvv --cov-fail-under 100 --cov=src/ --cov=tests/ . completion-ci: needs: build diff --git a/README.rst b/README.rst index 3cd5bb22c..dea6bb93d 100644 --- a/README.rst +++ b/README.rst @@ -1,4 +1,4 @@ -|Build Status| |codecov| |PyPI| +|Build Status| |PyPI| vws-python ========== @@ -71,8 +71,6 @@ See the `full documentation `__. .. |Build Status| image:: https://github.com/VWS-Python/vws-python/actions/workflows/ci.yml/badge.svg?branch=main :target: https://github.com/VWS-Python/vws-python/actions -.. |codecov| image:: https://codecov.io/gh/VWS-Python/vws-python/branch/main/graph/badge.svg - :target: https://codecov.io/gh/VWS-Python/vws-python .. |PyPI| image:: https://badge.fury.io/py/VWS-Python.svg :target: https://badge.fury.io/py/VWS-Python .. |minimum-python-version| replace:: 3.13 diff --git a/codecov.yaml b/codecov.yaml deleted file mode 100644 index 5c35baac9..000000000 --- a/codecov.yaml +++ /dev/null @@ -1,7 +0,0 @@ ---- -coverage: - status: - patch: - default: - # Require 100% test coverage. - target: 100% diff --git a/pyproject.toml b/pyproject.toml index 2eefdc34c..aac9f9969 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -288,7 +288,6 @@ ignore = [ "Makefile", "ci", "ci/**", - "codecov.yaml", "doc8.ini", "docs", "docs/**", From 4dd75bbd990351a4b8b5a3cacdc9f60e8c4491bd Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 8 Oct 2025 10:07:36 +0000 Subject: [PATCH 0759/1003] Bump astral-sh/setup-uv from 6 to 7 Bumps [astral-sh/setup-uv](https://github.com/astral-sh/setup-uv) from 6 to 7. - [Release notes](https://github.com/astral-sh/setup-uv/releases) - [Commits](https://github.com/astral-sh/setup-uv/compare/v6...v7) --- updated-dependencies: - dependency-name: astral-sh/setup-uv dependency-version: '7' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- .github/workflows/lint.yml | 2 +- .github/workflows/release.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 92a2848b8..b71569197 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -26,7 +26,7 @@ jobs: - uses: actions/checkout@v5 - name: Install uv - uses: astral-sh/setup-uv@v6 + uses: astral-sh/setup-uv@v7 with: enable-cache: true cache-dependency-glob: '**/pyproject.toml' diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 71774a6d8..d3bb9d802 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -26,7 +26,7 @@ jobs: - uses: actions/checkout@v5 - name: Install uv - uses: astral-sh/setup-uv@v6 + uses: astral-sh/setup-uv@v7 with: enable-cache: true cache-dependency-glob: '**/pyproject.toml' diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a19408730..8665829a5 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -34,7 +34,7 @@ jobs: fetch-depth: 0 - name: Install uv - uses: astral-sh/setup-uv@v6 + uses: astral-sh/setup-uv@v7 with: enable-cache: true cache-dependency-glob: '**/pyproject.toml' From 3dd98d7c572fcc423ae991b46a5364d1cd0254b8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 8 Oct 2025 10:08:09 +0000 Subject: [PATCH 0760/1003] Bump ruff from 0.13.3 to 0.14.0 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.13.3 to 0.14.0. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.13.3...0.14.0) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.14.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index aac9f9969..662d1c988 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pytest==8.4.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.13.3", + "ruff==0.14.0", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 86b2807633fd9db999a1cc5617ff7f4320b7162a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 9 Oct 2025 10:07:14 +0000 Subject: [PATCH 0761/1003] Bump pyproject-fmt from 2.7.0 to 2.10.0 Bumps [pyproject-fmt](https://github.com/tox-dev/toml-fmt) from 2.7.0 to 2.10.0. - [Release notes](https://github.com/tox-dev/toml-fmt/releases) - [Commits](https://github.com/tox-dev/toml-fmt/compare/pyproject-fmt/2.7.0...pyproject-fmt/2.10.0) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-version: 2.10.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 662d1c988..c733120c5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pygments==2.19.2", "pylint[spelling]==3.3.9", "pylint-per-file-ignores==2.0.3", - "pyproject-fmt==2.7.0", + "pyproject-fmt==2.10.0", "pyright==1.1.406", "pyroma==5.0", "pytest==8.4.2", From f62b24ca2058330d4104e2681ae133a20daedd6a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 Oct 2025 10:37:40 +0000 Subject: [PATCH 0762/1003] Bump actionlint-py from 1.7.7.23 to 1.7.8.24 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.7.7.23 to 1.7.8.24. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.7.7.23...v1.7.8.24) --- updated-dependencies: - dependency-name: actionlint-py dependency-version: 1.7.8.24 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c733120c5..8710c28af 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -37,7 +37,7 @@ dependencies = [ "vws-auth-tools>=2024.7.12", ] optional-dependencies.dev = [ - "actionlint-py==1.7.7.23", + "actionlint-py==1.7.8.24", "check-manifest==0.50", "deptry==0.23.1", "doc8==2.0.0", From ce7d4972c75e7fb4a1e015c1d38220054dc35ac1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 Oct 2025 10:45:51 +0000 Subject: [PATCH 0763/1003] Bump pylint-per-file-ignores from 2.0.3 to 3.1.0 Bumps [pylint-per-file-ignores](https://github.com/SAP/pylint-per-file-ignores) from 2.0.3 to 3.1.0. - [Release notes](https://github.com/SAP/pylint-per-file-ignores/releases) - [Changelog](https://github.com/SAP/pylint-per-file-ignores/blob/main/CHANGELOG.md) - [Commits](https://github.com/SAP/pylint-per-file-ignores/compare/v2.0.3...v3.1.0) --- updated-dependencies: - dependency-name: pylint-per-file-ignores dependency-version: 3.1.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c733120c5..101848b7b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pygments==2.19.2", "pylint[spelling]==3.3.9", - "pylint-per-file-ignores==2.0.3", + "pylint-per-file-ignores==3.1.0", "pyproject-fmt==2.10.0", "pyright==1.1.406", "pyroma==5.0", From 66fa29cb29e876c3a30fa17ae27d9855ff5527f6 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 Oct 2025 10:46:11 +0000 Subject: [PATCH 0764/1003] Bump yamlfix from 1.18.0 to 1.19.0 Bumps [yamlfix](https://github.com/lyz-code/yamlfix) from 1.18.0 to 1.19.0. - [Changelog](https://github.com/lyz-code/yamlfix/blob/main/CHANGELOG.md) - [Commits](https://github.com/lyz-code/yamlfix/commits) --- updated-dependencies: - dependency-name: yamlfix dependency-version: 1.19.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c733120c5..dc4390829 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -76,7 +76,7 @@ optional-dependencies.dev = [ "vulture==2.14", "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", - "yamlfix==1.18.0", + "yamlfix==1.19.0", ] optional-dependencies.release = [ "check-wheel-contents==0.6.3" ] urls.Documentation = "https://vws-python.github.io/vws-python/" From fde6d89b25ee3322da9830147a49eaac2a6e8e57 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 Oct 2025 10:54:41 +0000 Subject: [PATCH 0765/1003] Bump stefanzweifel/git-auto-commit-action from 6 to 7 Bumps [stefanzweifel/git-auto-commit-action](https://github.com/stefanzweifel/git-auto-commit-action) from 6 to 7. - [Release notes](https://github.com/stefanzweifel/git-auto-commit-action/releases) - [Changelog](https://github.com/stefanzweifel/git-auto-commit-action/blob/master/CHANGELOG.md) - [Commits](https://github.com/stefanzweifel/git-auto-commit-action/compare/v6...v7) --- updated-dependencies: - dependency-name: stefanzweifel/git-auto-commit-action dependency-version: '7' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 8665829a5..ca3d74491 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -63,7 +63,7 @@ jobs: include: CHANGELOG.rst regex: false - - uses: stefanzweifel/git-auto-commit-action@v6 + - uses: stefanzweifel/git-auto-commit-action@v7 id: commit with: commit_message: Bump CHANGELOG From 6110b1372df22d7e6c63d3c524fe737552eff435 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 Oct 2025 10:57:05 +0000 Subject: [PATCH 0766/1003] Bump pylint[spelling] from 3.3.9 to 4.0.0 Bumps [pylint[spelling]](https://github.com/pylint-dev/pylint) from 3.3.9 to 4.0.0. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v3.3.9...v4.0.0) --- updated-dependencies: - dependency-name: pylint[spelling] dependency-version: 4.0.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 28931851c..75385c471 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pre-commit==4.3.0", "pydocstyle==6.3", "pygments==2.19.2", - "pylint[spelling]==3.3.9", + "pylint[spelling]==4.0.0", "pylint-per-file-ignores==3.1.0", "pyproject-fmt==2.10.0", "pyright==1.1.406", From 7639d13bf94f9db9587202aea1d6ab43b589c06b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 15 Oct 2025 10:09:00 +0000 Subject: [PATCH 0767/1003] Bump pyproject-fmt from 2.10.0 to 2.11.0 Bumps [pyproject-fmt](https://github.com/tox-dev/toml-fmt) from 2.10.0 to 2.11.0. - [Release notes](https://github.com/tox-dev/toml-fmt/releases) - [Commits](https://github.com/tox-dev/toml-fmt/compare/pyproject-fmt/2.10.0...pyproject-fmt/2.11.0) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-version: 2.11.0 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 75385c471..8221ef96f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pygments==2.19.2", "pylint[spelling]==4.0.0", "pylint-per-file-ignores==3.1.0", - "pyproject-fmt==2.10.0", + "pyproject-fmt==2.11.0", "pyright==1.1.406", "pyroma==5.0", "pytest==8.4.2", From 158efeae3dafe8b5ffc8e82285faca0cb2e35d07 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 15 Oct 2025 10:09:16 +0000 Subject: [PATCH 0768/1003] Bump pylint[spelling] from 4.0.0 to 4.0.1 Bumps [pylint[spelling]](https://github.com/pylint-dev/pylint) from 4.0.0 to 4.0.1. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v4.0.0...v4.0.1) --- updated-dependencies: - dependency-name: pylint[spelling] dependency-version: 4.0.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 75385c471..22b645f2d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pre-commit==4.3.0", "pydocstyle==6.3", "pygments==2.19.2", - "pylint[spelling]==4.0.0", + "pylint[spelling]==4.0.1", "pylint-per-file-ignores==3.1.0", "pyproject-fmt==2.10.0", "pyright==1.1.406", From 1bcd0b372324e04017dcfc2935d812d2204dce8b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 16 Oct 2025 10:08:19 +0000 Subject: [PATCH 0769/1003] Bump check-manifest from 0.50 to 0.51 Bumps [check-manifest](https://github.com/mgedmin/check-manifest) from 0.50 to 0.51. - [Changelog](https://github.com/mgedmin/check-manifest/blob/master/CHANGES.rst) - [Commits](https://github.com/mgedmin/check-manifest/compare/0.50...0.51) --- updated-dependencies: - dependency-name: check-manifest dependency-version: '0.51' dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f5a4a96fd..26443a6c4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -38,7 +38,7 @@ dependencies = [ ] optional-dependencies.dev = [ "actionlint-py==1.7.8.24", - "check-manifest==0.50", + "check-manifest==0.51", "deptry==0.23.1", "doc8==2.0.0", "doccmd==2025.9.19", From 03280e551448d19f380c7952822102ffcec12513 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 17 Oct 2025 10:07:19 +0000 Subject: [PATCH 0770/1003] Bump ruff from 0.14.0 to 0.14.1 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.0 to 0.14.1. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.14.0...0.14.1) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.14.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 26443a6c4..d3da05490 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pytest==8.4.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.14.0", + "ruff==0.14.1", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 32fcb153a5867b7e7958b69291af5d7b41093383 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 20 Oct 2025 11:00:50 +0000 Subject: [PATCH 0771/1003] Bump doccmd from 2025.9.19 to 2025.10.18 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.9.19 to 2025.10.18. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.09.19...2025.10.18) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2025.10.18 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d3da05490..37e7ed7b6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.23.1", "doc8==2.0.0", - "doccmd==2025.9.19", + "doccmd==2025.10.18", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.9.25", From 8b1fd521869de717a6b4b7c6be9572874f186adb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 21 Oct 2025 10:08:34 +0000 Subject: [PATCH 0772/1003] Bump pylint[spelling] from 4.0.1 to 4.0.2 Bumps [pylint[spelling]](https://github.com/pylint-dev/pylint) from 4.0.1 to 4.0.2. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v4.0.1...v4.0.2) --- updated-dependencies: - dependency-name: pylint[spelling] dependency-version: 4.0.2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 37e7ed7b6..77c9ca89f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pre-commit==4.3.0", "pydocstyle==6.3", "pygments==2.19.2", - "pylint[spelling]==4.0.1", + "pylint[spelling]==4.0.2", "pylint-per-file-ignores==3.1.0", "pyproject-fmt==2.11.0", "pyright==1.1.406", From 53cf3a0e2f8473c101cf1d1fc9dde27e4d4a3436 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 24 Oct 2025 10:07:55 +0000 Subject: [PATCH 0773/1003] Bump sphinx-substitution-extensions from 2025.6.6 to 2025.10.24 Bumps [sphinx-substitution-extensions](https://github.com/adamtheturtle/sphinx-substitution-extensions) from 2025.6.6 to 2025.10.24. - [Release notes](https://github.com/adamtheturtle/sphinx-substitution-extensions/releases) - [Changelog](https://github.com/adamtheturtle/sphinx-substitution-extensions/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/sphinx-substitution-extensions/compare/2025.06.06...2025.10.24) --- updated-dependencies: - dependency-name: sphinx-substitution-extensions dependency-version: 2025.10.24 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 77c9ca89f..0d72ee5a4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -69,7 +69,7 @@ optional-dependencies.dev = [ "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.0", "sphinx-pyproject==0.3.0", - "sphinx-substitution-extensions==2025.6.6", + "sphinx-substitution-extensions==2025.10.24", "sphinxcontrib-spelling==8.0.1", "sybil==9.2.0", "types-requests==2.32.4.20250913", From aabdd340ce454dff1596fccda58ea9c466fa40a8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 24 Oct 2025 10:08:14 +0000 Subject: [PATCH 0774/1003] Bump ruff from 0.14.1 to 0.14.2 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.1 to 0.14.2. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.14.1...0.14.2) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.14.2 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 77c9ca89f..ea4ce5631 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pytest==8.4.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.14.1", + "ruff==0.14.2", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From ee5594fa58c94fc0c27edca4fd36c78fc79ab0e7 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 27 Oct 2025 02:08:39 +0000 Subject: [PATCH 0775/1003] Remove docs/Makefile and update pre-commit to use sphinx-build directly --- .pre-commit-config.yaml | 15 +++++++++------ docs/Makefile | 20 -------------------- 2 files changed, 9 insertions(+), 26 deletions(-) delete mode 100644 docs/Makefile diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 5c164119e..adc80ff7e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -117,7 +117,8 @@ repos: - id: shellcheck-docs name: shellcheck-docs - entry: uv run --extra=dev doccmd --language=shell --language=console --command="shellcheck + entry: + uv run --extra=dev doccmd --language=shell --language=console --command="shellcheck --shell=bash" language: python types_or: [markdown, rst] @@ -134,7 +135,8 @@ repos: - id: shfmt-docs name: shfmt-docs - entry: uv run --extra=dev doccmd --language=shell --language=console --skip-marker=shfmt + entry: + uv run --extra=dev doccmd --language=shell --language=console --skip-marker=shfmt --no-pad-file --command="shfmt --write --space-redirects --indent=4" language: python types_or: [markdown, rst] @@ -259,7 +261,8 @@ repos: - id: ruff-format-fix-docs name: Ruff format docs - entry: uv run --extra=dev doccmd --language=python --no-pad-file --command="ruff + entry: + uv run --extra=dev doccmd --language=python --no-pad-file --command="ruff format" language: python types_or: [markdown, rst] @@ -301,7 +304,7 @@ repos: - id: linkcheck name: linkcheck - entry: make -C docs/ linkcheck SPHINXOPTS=-W + entry: uv run --extra=dev sphinx-build -M linkcheck docs/source docs/build -W language: python types_or: [rst] stages: [manual] @@ -310,7 +313,7 @@ repos: - id: spelling name: spelling - entry: make -C docs/ spelling SPHINXOPTS=-W + entry: uv run --extra=dev sphinx-build -M spelling docs/source docs/build -W language: python types_or: [rst] stages: [manual] @@ -319,7 +322,7 @@ repos: - id: docs name: Build Documentation - entry: make docs + entry: uv run --extra=dev sphinx-build -M html docs/source docs/build language: python stages: [manual] pass_filenames: false diff --git a/docs/Makefile b/docs/Makefile deleted file mode 100644 index 15e9c44b1..000000000 --- a/docs/Makefile +++ /dev/null @@ -1,20 +0,0 @@ -# Minimal makefile for Sphinx documentation -# - -# You can set these variables from the command line. -SPHINXOPTS = -SPHINXBUILD = sphinx-build -SPHINXPROJ = VWSPYTHON -SOURCEDIR = source -BUILDDIR = build - -# Put it first so that "make" without argument is like "make help". -help: - @uv run --extra=dev $(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) - -.PHONY: help Makefile - -# Catch-all target: route all unknown targets to Sphinx using the new -# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). -%: Makefile - @uv run --extra=dev $(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) From 57db930a19e1a1a82db3723f58a6b8d9a2ea90e8 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 27 Oct 2025 02:12:14 +0000 Subject: [PATCH 0776/1003] Update base Makefile to use sphinx-build directly --- Makefile | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 216a25740..b4612b464 100644 --- a/Makefile +++ b/Makefile @@ -1,11 +1,7 @@ SHELL := /bin/bash -euxo pipefail - -# Treat Sphinx warnings as errors -SPHINXOPTS := -W - .PHONY: docs docs: - make -C docs clean html SPHINXOPTS=$(SPHINXOPTS) + uv run --extra=dev sphinx-build -M html docs/source docs/build -W .PHONY: open-docs open-docs: From 82faaf5752dfe3cf76b4f860a3df04cedae388f0 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Mon, 27 Oct 2025 02:14:08 +0000 Subject: [PATCH 0777/1003] [pre-commit.ci lite] apply automatic fixes --- .pre-commit-config.yaml | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index adc80ff7e..8a8e38b20 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -117,8 +117,7 @@ repos: - id: shellcheck-docs name: shellcheck-docs - entry: - uv run --extra=dev doccmd --language=shell --language=console --command="shellcheck + entry: uv run --extra=dev doccmd --language=shell --language=console --command="shellcheck --shell=bash" language: python types_or: [markdown, rst] @@ -135,8 +134,7 @@ repos: - id: shfmt-docs name: shfmt-docs - entry: - uv run --extra=dev doccmd --language=shell --language=console --skip-marker=shfmt + entry: uv run --extra=dev doccmd --language=shell --language=console --skip-marker=shfmt --no-pad-file --command="shfmt --write --space-redirects --indent=4" language: python types_or: [markdown, rst] @@ -261,8 +259,7 @@ repos: - id: ruff-format-fix-docs name: Ruff format docs - entry: - uv run --extra=dev doccmd --language=python --no-pad-file --command="ruff + entry: uv run --extra=dev doccmd --language=python --no-pad-file --command="ruff format" language: python types_or: [markdown, rst] @@ -304,7 +301,8 @@ repos: - id: linkcheck name: linkcheck - entry: uv run --extra=dev sphinx-build -M linkcheck docs/source docs/build -W + entry: uv run --extra=dev sphinx-build -M linkcheck docs/source docs/build + -W language: python types_or: [rst] stages: [manual] @@ -313,7 +311,8 @@ repos: - id: spelling name: spelling - entry: uv run --extra=dev sphinx-build -M spelling docs/source docs/build -W + entry: uv run --extra=dev sphinx-build -M spelling docs/source docs/build + -W language: python types_or: [rst] stages: [manual] From eb9fb0ff6cdd0895c426be2fdc248fce87b9a5fc Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 27 Oct 2025 02:22:55 +0000 Subject: [PATCH 0778/1003] Add -W flag to docs hook for consistent error handling --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 8a8e38b20..4236e1a68 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -321,7 +321,7 @@ repos: - id: docs name: Build Documentation - entry: uv run --extra=dev sphinx-build -M html docs/source docs/build + entry: uv run --extra=dev sphinx-build -M html docs/source docs/build -W language: python stages: [manual] pass_filenames: false From cc7bbe869276e7054a64ca551cf78ded97711723 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 27 Oct 2025 02:34:43 +0000 Subject: [PATCH 0779/1003] Add MIT LICENSE file --- LICENSE | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 LICENSE diff --git a/LICENSE b/LICENSE new file mode 100644 index 000000000..c9f18d1a3 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2025 Adam Dangoor + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. From 80ef1ad105705cd056b36839b1e09173b2fd5c00 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 27 Oct 2025 11:16:55 +0000 Subject: [PATCH 0780/1003] Bump doccmd from 2025.10.18 to 2025.10.25 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.10.18 to 2025.10.25. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.10.18...2025.10.25) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2025.10.25 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b83b042ac..e5f693e12 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.23.1", "doc8==2.0.0", - "doccmd==2025.10.18", + "doccmd==2025.10.25", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.9.25", From e725d98f9752834c2e59dd1b44fedc107b5ee2d8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 27 Oct 2025 11:19:22 +0000 Subject: [PATCH 0781/1003] Bump pyright from 1.1.406 to 1.1.407 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.406 to 1.1.407. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.406...v1.1.407) --- updated-dependencies: - dependency-name: pyright dependency-version: 1.1.407 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b83b042ac..80c0f3e90 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.2", "pylint-per-file-ignores==3.1.0", "pyproject-fmt==2.11.0", - "pyright==1.1.406", + "pyright==1.1.407", "pyroma==5.0", "pytest==8.4.2", "pytest-cov==7.0.0", From 3172d5e1d03178b6a76eadcbd0ff9ff5730554d3 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 27 Oct 2025 12:23:10 +0000 Subject: [PATCH 0782/1003] Add .prettierrc configuration MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Add Prettier configuration file with YAML single quote override from click-compose. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- .prettierrc | 10 ++++++++++ pyproject.toml | 1 + 2 files changed, 11 insertions(+) create mode 100644 .prettierrc diff --git a/.prettierrc b/.prettierrc new file mode 100644 index 000000000..3ab9aa054 --- /dev/null +++ b/.prettierrc @@ -0,0 +1,10 @@ +{ + "overrides": [ + { + "files": ["*.yaml", "*.yml"], + "options": { + "singleQuote": true + } + } + ] +} diff --git a/pyproject.toml b/pyproject.toml index b83b042ac..ecc36d8eb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -278,6 +278,7 @@ make-summary-multi-line = true ignore = [ ".checkmake-config.ini", + ".prettierrc", ".yamlfmt", "*.enc", ".pre-commit-config.yaml", From 82fdfe69f4d3ca3e292c76d170bc8216e7902745 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 27 Oct 2025 22:19:21 +0000 Subject: [PATCH 0783/1003] Remove Makefile and replace make commands with direct equivalents --- Makefile | 8 -------- docs/source/contributing.rst | 4 ++-- 2 files changed, 2 insertions(+), 10 deletions(-) delete mode 100644 Makefile diff --git a/Makefile b/Makefile deleted file mode 100644 index b4612b464..000000000 --- a/Makefile +++ /dev/null @@ -1,8 +0,0 @@ -SHELL := /bin/bash -euxo pipefail -.PHONY: docs -docs: - uv run --extra=dev sphinx-build -M html docs/source docs/build -W - -.PHONY: open-docs -open-docs: - python -c 'import os, webbrowser; webbrowser.open("file://" + os.path.abspath("docs/build/html/index.html"))' diff --git a/docs/source/contributing.rst b/docs/source/contributing.rst index 21e5dbe82..0e531220d 100644 --- a/docs/source/contributing.rst +++ b/docs/source/contributing.rst @@ -64,8 +64,8 @@ Run the following commands to build and view documentation locally: .. code-block:: console - $ make docs - $ make open-docs + $ uv run --extra=dev sphinx-build -M html docs/source docs/build -W + $ python -c 'import os, webbrowser; webbrowser.open("file://" + os.path.abspath("docs/build/html/index.html"))' Continuous integration ---------------------- From f4dc7328d8340caa110aa4087e0df9c799a5bda4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 28 Oct 2025 10:08:38 +0000 Subject: [PATCH 0784/1003] Bump doccmd from 2025.10.25 to 2025.10.27 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.10.25 to 2025.10.27. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.10.25...2025.10.27) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2025.10.27 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 48816b12d..778c8f743 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.23.1", "doc8==2.0.0", - "doccmd==2025.10.25", + "doccmd==2025.10.27", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.9.25", From 5347522b7c5bb079f5b2f419d28e2599dcda9189 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 28 Oct 2025 10:54:06 +0000 Subject: [PATCH 0785/1003] Bump uv to 0.9.5 --- .pre-commit-config.yaml | 62 ++++++++++++++++++++--------------------- 1 file changed, 31 insertions(+), 31 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 4236e1a68..3a653b355 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -96,7 +96,7 @@ repos: language: python pass_filenames: false types_or: [yaml] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: docformatter @@ -104,7 +104,7 @@ repos: entry: uv run --extra=dev -m docformatter --in-place language: python types_or: [python] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: shellcheck @@ -112,7 +112,7 @@ repos: entry: uv run --extra=dev shellcheck --shell=bash language: python types_or: [shell] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: shellcheck-docs @@ -121,7 +121,7 @@ repos: --shell=bash" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: shfmt @@ -129,7 +129,7 @@ repos: entry: uv run --extra=dev shfmt --write --space-redirects --indent=4 language: python types_or: [shell] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: shfmt-docs @@ -138,7 +138,7 @@ repos: --no-pad-file --command="shfmt --write --space-redirects --indent=4" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: mypy @@ -148,7 +148,7 @@ repos: language: python types_or: [python, toml] pass_filenames: false - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] - id: mypy-docs name: mypy-docs @@ -156,7 +156,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="mypy" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] - id: check-manifest name: check-manifest @@ -164,7 +164,7 @@ repos: entry: uv run --extra=dev -m check_manifest language: python pass_filenames: false - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] - id: pyright name: pyright @@ -173,7 +173,7 @@ repos: language: python types_or: [python, toml] pass_filenames: false - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] - id: pyright-docs name: pyright-docs @@ -181,7 +181,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="pyright" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] - id: vulture name: vulture @@ -189,7 +189,7 @@ repos: language: python types_or: [python] pass_filenames: false - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: vulture-docs @@ -197,7 +197,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="vulture" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: pyroma @@ -206,7 +206,7 @@ repos: language: python pass_filenames: false types_or: [toml] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: deptry @@ -214,7 +214,7 @@ repos: entry: uv run --extra=dev -m deptry src/ language: python pass_filenames: false - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: pylint @@ -223,7 +223,7 @@ repos: language: python stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] - id: pylint-docs name: pylint-docs @@ -231,14 +231,14 @@ repos: language: python stages: [manual] types_or: [markdown, rst] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] - id: ruff-check-fix name: Ruff check fix entry: uv run --extra=dev -m ruff check --fix language: python types_or: [python] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: ruff-check-fix-docs @@ -246,7 +246,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="ruff check --fix" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: ruff-format-fix @@ -254,7 +254,7 @@ repos: entry: uv run --extra=dev -m ruff format language: python types_or: [python] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: ruff-format-fix-docs @@ -263,7 +263,7 @@ repos: format" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: doc8 @@ -271,7 +271,7 @@ repos: entry: uv run --extra=dev -m doc8 language: python types_or: [rst] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: interrogate @@ -279,7 +279,7 @@ repos: entry: uv run --extra=dev -m interrogate language: python types_or: [python] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: interrogate-docs @@ -287,7 +287,7 @@ repos: entry: uv run --extra=dev doccmd --language=python --command="interrogate" language: python types_or: [markdown, rst] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: pyproject-fmt-fix @@ -296,7 +296,7 @@ repos: language: python types_or: [toml] files: pyproject.toml - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: linkcheck @@ -307,7 +307,7 @@ repos: types_or: [rst] stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] - id: spelling name: spelling @@ -317,7 +317,7 @@ repos: types_or: [rst] stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] - id: docs name: Build Documentation @@ -325,7 +325,7 @@ repos: language: python stages: [manual] pass_filenames: false - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] - id: pyright-verifytypes name: pyright-verifytypes @@ -334,14 +334,14 @@ repos: language: python pass_filenames: false types_or: [python] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] - id: yamlfix name: yamlfix entry: uv run --extra=dev yamlfix language: python types_or: [yaml] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] - id: sphinx-lint @@ -349,5 +349,5 @@ repos: entry: uv run --extra=dev sphinx-lint --enable=all --disable=line-too-long language: python types_or: [rst] - additional_dependencies: [uv==0.6.3] + additional_dependencies: [uv==0.9.5] stages: [pre-commit] From a0231fd59cfc58a30bf5c4b2dd4715fb25a272b3 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 28 Oct 2025 12:21:53 +0000 Subject: [PATCH 0786/1003] Add view and edit buttons to Sphinx docs --- docs/source/conf.py | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/source/conf.py b/docs/source/conf.py index 8c7e78f05..4bce31b24 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -60,6 +60,7 @@ html_show_sourcelink = False html_theme_options = { "sidebar_hide_name": False, + "top_of_page_buttons": ["view", "edit"], } # Output file base name for HTML help builder. From 2ed9e31ab765e7f4fd0d9a0fa233ffcb8d606325 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 28 Oct 2025 13:42:05 +0000 Subject: [PATCH 0787/1003] Configure Furo top-of-page buttons with repository details --- docs/source/conf.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/source/conf.py b/docs/source/conf.py index 4bce31b24..914bcb886 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -60,7 +60,9 @@ html_show_sourcelink = False html_theme_options = { "sidebar_hide_name": False, - "top_of_page_buttons": ["view", "edit"], + "source_repository": "https://github.com/VWS-Python/vws-python/", + "source_branch": "main", + "source_directory": "docs/source/", } # Output file base name for HTML help builder. From aefc8d7efd9c850bc4eee2c576eaa6e8acc2d30d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 29 Oct 2025 10:08:16 +0000 Subject: [PATCH 0788/1003] Bump sphinx-lint from 1.0.0 to 1.0.1 Bumps [sphinx-lint](https://github.com/sphinx-contrib/sphinx-lint) from 1.0.0 to 1.0.1. - [Release notes](https://github.com/sphinx-contrib/sphinx-lint/releases) - [Commits](https://github.com/sphinx-contrib/sphinx-lint/compare/v1.0.0...v1.0.1) --- updated-dependencies: - dependency-name: sphinx-lint dependency-version: 1.0.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 280218ea2..c05290470 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -67,7 +67,7 @@ optional-dependencies.dev = [ "shfmt-py==3.12.0.2", "sphinx==8.2.3", "sphinx-copybutton==0.5.2", - "sphinx-lint==1.0.0", + "sphinx-lint==1.0.1", "sphinx-pyproject==0.3.0", "sphinx-substitution-extensions==2025.10.24", "sphinxcontrib-spelling==8.0.1", From 9a94a5c41493e8efaa10d37a9a090e65a76dc977 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 31 Oct 2025 10:08:28 +0000 Subject: [PATCH 0789/1003] Bump ruff from 0.14.2 to 0.14.3 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.2 to 0.14.3. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.14.2...0.14.3) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.14.3 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c05290470..1d11449d2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pytest==8.4.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.14.2", + "ruff==0.14.3", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From ceb43b785390c9727aebc1dce84bb9712952a586 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 6 Nov 2025 10:07:53 +0000 Subject: [PATCH 0790/1003] Bump pyproject-fmt from 2.11.0 to 2.11.1 Bumps [pyproject-fmt](https://github.com/tox-dev/toml-fmt) from 2.11.0 to 2.11.1. - [Release notes](https://github.com/tox-dev/toml-fmt/releases) - [Commits](https://github.com/tox-dev/toml-fmt/commits) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-version: 2.11.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1d11449d2..ffcb7f329 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -53,7 +53,7 @@ optional-dependencies.dev = [ "pygments==2.19.2", "pylint[spelling]==4.0.2", "pylint-per-file-ignores==3.1.0", - "pyproject-fmt==2.11.0", + "pyproject-fmt==2.11.1", "pyright==1.1.407", "pyroma==5.0", "pytest==8.4.2", From 26b2a9c820a377f7354fb0abfac247ee5722866e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 7 Nov 2025 10:07:56 +0000 Subject: [PATCH 0791/1003] Bump ruff from 0.14.3 to 0.14.4 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.3 to 0.14.4. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.14.3...0.14.4) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.14.4 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ffcb7f329..8fd215533 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pytest==8.4.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.14.3", + "ruff==0.14.4", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From e9831945a81fbb3a41d4a17c56b7994275746785 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 8 Nov 2025 16:22:49 +0000 Subject: [PATCH 0792/1003] Add --no-write-to-file flag for read-only doccmd commands --- .pre-commit-config.yaml | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 3a653b355..1f5f92b50 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -117,8 +117,8 @@ repos: - id: shellcheck-docs name: shellcheck-docs - entry: uv run --extra=dev doccmd --language=shell --language=console --command="shellcheck - --shell=bash" + entry: uv run --extra=dev doccmd --no-write-to-file --language=shell --language=console + --command="shellcheck --shell=bash" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -153,7 +153,7 @@ repos: - id: mypy-docs name: mypy-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --language=python --command="mypy" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="mypy" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -178,7 +178,7 @@ repos: - id: pyright-docs name: pyright-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --language=python --command="pyright" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="pyright" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -194,7 +194,7 @@ repos: - id: vulture-docs name: vulture docs - entry: uv run --extra=dev doccmd --language=python --command="vulture" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="vulture" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -227,7 +227,7 @@ repos: - id: pylint-docs name: pylint-docs - entry: uv run --extra=dev doccmd --language=python --command="pylint" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="pylint" language: python stages: [manual] types_or: [markdown, rst] @@ -284,7 +284,7 @@ repos: - id: interrogate-docs name: interrogate docs - entry: uv run --extra=dev doccmd --language=python --command="interrogate" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="interrogate" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] From 3ba7058114bf5b7cab3568faa1a2d0fce9c83035 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 8 Nov 2025 19:54:48 +0000 Subject: [PATCH 0793/1003] Bump doccmd to 2025.11.8.1 and sybil-extras to 2025.11.8 --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8fd215533..3fe95ed38 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.23.1", "doc8==2.0.0", - "doccmd==2025.10.27", + "doccmd==2025.11.8", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.9.25", From bfbfc7e0d98eb863de3ca683d0d15248011bdb8f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 8 Nov 2025 20:13:34 +0000 Subject: [PATCH 0794/1003] Add --example-workers 0 to read-only doccmd hooks --- .pre-commit-config.yaml | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 1f5f92b50..fb99a708b 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -117,8 +117,8 @@ repos: - id: shellcheck-docs name: shellcheck-docs - entry: uv run --extra=dev doccmd --no-write-to-file --language=shell --language=console - --command="shellcheck --shell=bash" + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=shell + --language=console --command="shellcheck --shell=bash" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -153,7 +153,8 @@ repos: - id: mypy-docs name: mypy-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="mypy" + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + --command="mypy" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -178,7 +179,8 @@ repos: - id: pyright-docs name: pyright-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="pyright" + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + --command="pyright" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -194,7 +196,8 @@ repos: - id: vulture-docs name: vulture docs - entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="vulture" + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + --command="vulture" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -227,7 +230,8 @@ repos: - id: pylint-docs name: pylint-docs - entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="pylint" + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + --command="pylint" language: python stages: [manual] types_or: [markdown, rst] @@ -284,7 +288,8 @@ repos: - id: interrogate-docs name: interrogate docs - entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="interrogate" + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + --command="interrogate" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] From 1b6dd2cdde873c11d397704ae5be915cd7659b5b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 10 Nov 2025 11:26:06 +0000 Subject: [PATCH 0795/1003] Bump doccmd from 2025.11.8 to 2025.11.8.1 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.11.8 to 2025.11.8.1. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.11.08...2025.11.08.1) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2025.11.8.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3fe95ed38..dc7683977 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.23.1", "doc8==2.0.0", - "doccmd==2025.11.8", + "doccmd==2025.11.8.1", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.9.25", From 1a537631547a8beb70329d46b227673eacd050a5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 10 Nov 2025 11:26:14 +0000 Subject: [PATCH 0796/1003] Bump pytest from 8.4.2 to 9.0.0 Bumps [pytest](https://github.com/pytest-dev/pytest) from 8.4.2 to 9.0.0. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/8.4.2...9.0.0) --- updated-dependencies: - dependency-name: pytest dependency-version: 9.0.0 dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3fe95ed38..b46b4a360 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pyproject-fmt==2.11.1", "pyright==1.1.407", "pyroma==5.0", - "pytest==8.4.2", + "pytest==9.0.0", "pytest-cov==7.0.0", "pyyaml==6.0.3", "ruff==0.14.4", From 5b9a189e4154d88108440a5a31c61093d76b780b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 10 Nov 2025 11:26:28 +0000 Subject: [PATCH 0797/1003] Bump pre-commit from 4.3.0 to 4.4.0 Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 4.3.0 to 4.4.0. - [Release notes](https://github.com/pre-commit/pre-commit/releases) - [Changelog](https://github.com/pre-commit/pre-commit/blob/main/CHANGELOG.md) - [Commits](https://github.com/pre-commit/pre-commit/compare/v4.3.0...v4.4.0) --- updated-dependencies: - dependency-name: pre-commit dependency-version: 4.4.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3fe95ed38..c40855d60 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "interrogate==1.7.0", "mypy[faster-cache]==1.18.2", "mypy-strict-kwargs==2025.4.3", - "pre-commit==4.3.0", + "pre-commit==4.4.0", "pydocstyle==6.3", "pygments==2.19.2", "pylint[spelling]==4.0.2", From fac2dcda58555860d2099700c7d42dc2f59beb59 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 10 Nov 2025 11:26:35 +0000 Subject: [PATCH 0798/1003] Bump deptry from 0.23.1 to 0.24.0 Bumps [deptry](https://github.com/fpgmaas/deptry) from 0.23.1 to 0.24.0. - [Release notes](https://github.com/fpgmaas/deptry/releases) - [Changelog](https://github.com/fpgmaas/deptry/blob/main/CHANGELOG.md) - [Commits](https://github.com/fpgmaas/deptry/compare/0.23.1...0.24.0) --- updated-dependencies: - dependency-name: deptry dependency-version: 0.24.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3fe95ed38..d52f07008 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -39,7 +39,7 @@ dependencies = [ optional-dependencies.dev = [ "actionlint-py==1.7.8.24", "check-manifest==0.51", - "deptry==0.23.1", + "deptry==0.24.0", "doc8==2.0.0", "doccmd==2025.11.8", "docformatter==1.7.7", From 0d1f110142d6fdce9934dc161da0ec3720e8277a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 13 Nov 2025 10:08:25 +0000 Subject: [PATCH 0799/1003] Bump pytest from 9.0.0 to 9.0.1 Bumps [pytest](https://github.com/pytest-dev/pytest) from 9.0.0 to 9.0.1. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/9.0.0...9.0.1) --- updated-dependencies: - dependency-name: pytest dependency-version: 9.0.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 7b0e67fa0..1c33fd64c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pyproject-fmt==2.11.1", "pyright==1.1.407", "pyroma==5.0", - "pytest==9.0.0", + "pytest==9.0.1", "pytest-cov==7.0.0", "pyyaml==6.0.3", "ruff==0.14.4", From 87b26bc582df6843d37ee7c1a4c155d1faebf4d7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 14 Nov 2025 10:07:07 +0000 Subject: [PATCH 0800/1003] Bump pylint[spelling] from 4.0.2 to 4.0.3 Bumps [pylint[spelling]](https://github.com/pylint-dev/pylint) from 4.0.2 to 4.0.3. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v4.0.2...v4.0.3) --- updated-dependencies: - dependency-name: pylint[spelling] dependency-version: 4.0.3 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1c33fd64c..b3a393d15 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pre-commit==4.4.0", "pydocstyle==6.3", "pygments==2.19.2", - "pylint[spelling]==4.0.2", + "pylint[spelling]==4.0.3", "pylint-per-file-ignores==3.1.0", "pyproject-fmt==2.11.1", "pyright==1.1.407", From 56dffc291149b888d8f29e7c8b0c8761bae02ab5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 14 Nov 2025 10:07:31 +0000 Subject: [PATCH 0801/1003] Bump ruff from 0.14.4 to 0.14.5 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.4 to 0.14.5. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.14.4...0.14.5) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.14.5 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1c33fd64c..3f1bd9df9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pytest==9.0.1", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.14.4", + "ruff==0.14.5", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 3b1bdeb4cfde26afae8d4aa5a321a130cc3e9958 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 18 Nov 2025 10:10:29 +0000 Subject: [PATCH 0802/1003] Bump sphinx-substitution-extensions from 2025.10.24 to 2025.11.17 Bumps [sphinx-substitution-extensions](https://github.com/adamtheturtle/sphinx-substitution-extensions) from 2025.10.24 to 2025.11.17. - [Release notes](https://github.com/adamtheturtle/sphinx-substitution-extensions/releases) - [Changelog](https://github.com/adamtheturtle/sphinx-substitution-extensions/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/sphinx-substitution-extensions/compare/2025.10.24...2025.11.17) --- updated-dependencies: - dependency-name: sphinx-substitution-extensions dependency-version: 2025.11.17 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 12b6f57c9..ad3977ba3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -69,7 +69,7 @@ optional-dependencies.dev = [ "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.1", "sphinx-pyproject==0.3.0", - "sphinx-substitution-extensions==2025.10.24", + "sphinx-substitution-extensions==2025.11.17", "sphinxcontrib-spelling==8.0.1", "sybil==9.2.0", "types-requests==2.32.4.20250913", From 59e86d3e789f04a48e0c3fe93d81db51388bdca5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 19 Nov 2025 10:08:03 +0000 Subject: [PATCH 0803/1003] Bump sphinx-lint from 1.0.1 to 1.0.2 Bumps [sphinx-lint](https://github.com/sphinx-contrib/sphinx-lint) from 1.0.1 to 1.0.2. - [Release notes](https://github.com/sphinx-contrib/sphinx-lint/releases) - [Commits](https://github.com/sphinx-contrib/sphinx-lint/compare/v1.0.1...v1.0.2) --- updated-dependencies: - dependency-name: sphinx-lint dependency-version: 1.0.2 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ad3977ba3..bf32f1900 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -67,7 +67,7 @@ optional-dependencies.dev = [ "shfmt-py==3.12.0.2", "sphinx==8.2.3", "sphinx-copybutton==0.5.2", - "sphinx-lint==1.0.1", + "sphinx-lint==1.0.2", "sphinx-pyproject==0.3.0", "sphinx-substitution-extensions==2025.11.17", "sphinxcontrib-spelling==8.0.1", From bbe38af05e4fcf69b39da33fe7f1bde4dd3f668f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 20 Nov 2025 10:08:20 +0000 Subject: [PATCH 0804/1003] Bump doccmd from 2025.11.8.1 to 2025.11.20 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.11.8.1 to 2025.11.20. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.11.08.1...2025.11.20) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2025.11.20 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index bf32f1900..1ab667665 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2025.11.8.1", + "doccmd==2025.11.20", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.9.25", From 8b0901ead24fba4db3ae894f391531f29466f184 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 21 Nov 2025 10:06:36 +0000 Subject: [PATCH 0805/1003] Bump actions/checkout from 5 to 6 Bumps [actions/checkout](https://github.com/actions/checkout) from 5 to 6. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v5...v6) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/ci.yml | 2 +- .github/workflows/lint.yml | 2 +- .github/workflows/release.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b71569197..73e6ce82c 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -23,7 +23,7 @@ jobs: runs-on: ${{ matrix.platform }} steps: - - uses: actions/checkout@v5 + - uses: actions/checkout@v6 - name: Install uv uses: astral-sh/setup-uv@v7 diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index d3bb9d802..fbdc4c6ce 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -23,7 +23,7 @@ jobs: runs-on: ${{ matrix.platform }} steps: - - uses: actions/checkout@v5 + - uses: actions/checkout@v6 - name: Install uv uses: astral-sh/setup-uv@v7 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ca3d74491..2ccae040a 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -21,7 +21,7 @@ jobs: contents: write steps: - - uses: actions/checkout@v5 + - uses: actions/checkout@v6 with: # See # https://github.com/stefanzweifel/git-auto-commit-action?tab=readme-ov-file#push-to-protected-branches From b9a9e7fc3328f8db1a1e99e090637e9e429d16f5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Nov 2025 11:00:48 +0000 Subject: [PATCH 0806/1003] Bump ruff from 0.14.5 to 0.14.6 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.5 to 0.14.6. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.14.5...0.14.6) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.14.6 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1ab667665..e21e40d16 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pytest==9.0.1", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.14.5", + "ruff==0.14.6", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 0b16d8afe0534f3b9536b1141c4998cdd590db00 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Nov 2025 11:00:57 +0000 Subject: [PATCH 0807/1003] Bump pre-commit from 4.4.0 to 4.5.0 Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 4.4.0 to 4.5.0. - [Release notes](https://github.com/pre-commit/pre-commit/releases) - [Changelog](https://github.com/pre-commit/pre-commit/blob/main/CHANGELOG.md) - [Commits](https://github.com/pre-commit/pre-commit/compare/v4.4.0...v4.5.0) --- updated-dependencies: - dependency-name: pre-commit dependency-version: 4.5.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1ab667665..e72620c23 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "interrogate==1.7.0", "mypy[faster-cache]==1.18.2", "mypy-strict-kwargs==2025.4.3", - "pre-commit==4.4.0", + "pre-commit==4.5.0", "pydocstyle==6.3", "pygments==2.19.2", "pylint[spelling]==4.0.3", From 853ddae258071d037f702bd3070c6d7bc90b29e5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 24 Nov 2025 11:01:03 +0000 Subject: [PATCH 0808/1003] Bump actionlint-py from 1.7.8.24 to 1.7.9.24 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.7.8.24 to 1.7.9.24. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.7.8.24...v1.7.9.24) --- updated-dependencies: - dependency-name: actionlint-py dependency-version: 1.7.9.24 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 1ab667665..815ba085d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -37,7 +37,7 @@ dependencies = [ "vws-auth-tools>=2024.7.12", ] optional-dependencies.dev = [ - "actionlint-py==1.7.8.24", + "actionlint-py==1.7.9.24", "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", From 2e18e5431b27c089b21b7942bd04c4ecd37b1d5b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 26 Nov 2025 10:06:53 +0000 Subject: [PATCH 0809/1003] Bump pylint-per-file-ignores from 3.1.0 to 3.2.0 Bumps [pylint-per-file-ignores](https://github.com/SAP/pylint-per-file-ignores) from 3.1.0 to 3.2.0. - [Release notes](https://github.com/SAP/pylint-per-file-ignores/releases) - [Changelog](https://github.com/SAP/pylint-per-file-ignores/blob/main/CHANGELOG.md) - [Commits](https://github.com/SAP/pylint-per-file-ignores/compare/v3.1.0...v3.2.0) --- updated-dependencies: - dependency-name: pylint-per-file-ignores dependency-version: 3.2.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b6c742df5..30c82e995 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -52,7 +52,7 @@ optional-dependencies.dev = [ "pydocstyle==6.3", "pygments==2.19.2", "pylint[spelling]==4.0.3", - "pylint-per-file-ignores==3.1.0", + "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.11.1", "pyright==1.1.407", "pyroma==5.0", From 7631aae5f5bca321c70211ae01c5a17f5f56208e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 1 Dec 2025 12:35:39 +0000 Subject: [PATCH 0810/1003] Bump mypy[faster-cache] from 1.18.2 to 1.19.0 Bumps [mypy[faster-cache]](https://github.com/python/mypy) from 1.18.2 to 1.19.0. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.18.2...v1.19.0) --- updated-dependencies: - dependency-name: mypy[faster-cache] dependency-version: 1.19.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 30c82e995..e89705fa1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -46,7 +46,7 @@ optional-dependencies.dev = [ "freezegun==1.5.5", "furo==2025.9.25", "interrogate==1.7.0", - "mypy[faster-cache]==1.18.2", + "mypy[faster-cache]==1.19.0", "mypy-strict-kwargs==2025.4.3", "pre-commit==4.5.0", "pydocstyle==6.3", From 8af37ccca7e839af52ae2c334526fcd3e1171991 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 1 Dec 2025 12:35:48 +0000 Subject: [PATCH 0811/1003] Bump pylint[spelling] from 4.0.3 to 4.0.4 Bumps [pylint[spelling]](https://github.com/pylint-dev/pylint) from 4.0.3 to 4.0.4. - [Release notes](https://github.com/pylint-dev/pylint/releases) - [Commits](https://github.com/pylint-dev/pylint/compare/v4.0.3...v4.0.4) --- updated-dependencies: - dependency-name: pylint[spelling] dependency-version: 4.0.4 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 30c82e995..0905b4a76 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -51,7 +51,7 @@ optional-dependencies.dev = [ "pre-commit==4.5.0", "pydocstyle==6.3", "pygments==2.19.2", - "pylint[spelling]==4.0.3", + "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.11.1", "pyright==1.1.407", From 8318d6b97d0ed7573d9c346fecd148c8c08cca1e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 1 Dec 2025 12:36:03 +0000 Subject: [PATCH 0812/1003] Bump sphinxcontrib-spelling from 8.0.1 to 8.0.2 Bumps [sphinxcontrib-spelling](https://github.com/sphinx-contrib/spelling) from 8.0.1 to 8.0.2. - [Release notes](https://github.com/sphinx-contrib/spelling/releases) - [Commits](https://github.com/sphinx-contrib/spelling/compare/8.0.1...8.0.2) --- updated-dependencies: - dependency-name: sphinxcontrib-spelling dependency-version: 8.0.2 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 30c82e995..e0f7b7705 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -70,7 +70,7 @@ optional-dependencies.dev = [ "sphinx-lint==1.0.2", "sphinx-pyproject==0.3.0", "sphinx-substitution-extensions==2025.11.17", - "sphinxcontrib-spelling==8.0.1", + "sphinxcontrib-spelling==8.0.2", "sybil==9.2.0", "types-requests==2.32.4.20250913", "vulture==2.14", From 19936ad54596c7a66babbe067d6d79833a014962 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 1 Dec 2025 12:36:13 +0000 Subject: [PATCH 0813/1003] Bump ruff from 0.14.6 to 0.14.7 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.6 to 0.14.7. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.14.6...0.14.7) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.14.7 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 30c82e995..dd38c1a33 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pytest==9.0.1", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.14.6", + "ruff==0.14.7", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 3f68948742f8d2513452284b2b3dd902947f2e9c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 2 Dec 2025 10:07:49 +0000 Subject: [PATCH 0814/1003] Bump sybil from 9.2.0 to 9.3.0 Bumps [sybil](https://github.com/simplistix/sybil) from 9.2.0 to 9.3.0. - [Changelog](https://github.com/simplistix/sybil/blob/master/CHANGELOG.rst) - [Commits](https://github.com/simplistix/sybil/compare/9.2.0...9.3.0) --- updated-dependencies: - dependency-name: sybil dependency-version: 9.3.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 27218b970..8a4cf2e2d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -71,7 +71,7 @@ optional-dependencies.dev = [ "sphinx-pyproject==0.3.0", "sphinx-substitution-extensions==2025.11.17", "sphinxcontrib-spelling==8.0.2", - "sybil==9.2.0", + "sybil==9.3.0", "types-requests==2.32.4.20250913", "vulture==2.14", "vws-python-mock==2025.3.10.1", From 61ead975199d709d9910ae9bb96a27914347ad50 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 4 Dec 2025 10:07:39 +0000 Subject: [PATCH 0815/1003] Bump doccmd from 2025.11.20 to 2025.12.3 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.11.20 to 2025.12.3. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.11.20...2025.12.03) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2025.12.3 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 8a4cf2e2d..22244360a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2025.11.20", + "doccmd==2025.12.3", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.9.25", From 80d4d1d4386fe0d1f0f13805f689e630223db648 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 5 Dec 2025 10:06:57 +0000 Subject: [PATCH 0816/1003] Bump ruff from 0.14.7 to 0.14.8 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.7 to 0.14.8. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.14.7...0.14.8) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.14.8 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 22244360a..35be4b8dc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pytest==9.0.1", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.14.7", + "ruff==0.14.8", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From ba8e9c31e41f8c87aabcd50aba4f52010f37f1df Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 5 Dec 2025 10:07:04 +0000 Subject: [PATCH 0817/1003] Bump doccmd from 2025.12.3 to 2025.12.5 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.12.3 to 2025.12.5. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.12.03...2025.12.05) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2025.12.5 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 22244360a..00784ecf5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2025.12.3", + "doccmd==2025.12.5", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.9.25", From af3d68217fb3c98fc1ea0c2c00be3d71da1df79a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 8 Dec 2025 07:22:26 +0000 Subject: [PATCH 0818/1003] Add validation for gha-find-replace actions Fail the workflow if no files are modified during file updates. This prevents silent failures in the release process. --- .github/workflows/release.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 2ccae040a..60b4f9398 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -55,6 +55,7 @@ jobs: echo "underline=${underline}" >> "$GITHUB_OUTPUT" - name: Update changelog + id: update_changelog uses: jacobtomlinson/gha-find-replace@v3 with: find: "Next\n----" @@ -63,6 +64,12 @@ jobs: include: CHANGELOG.rst regex: false + - name: Check Update changelog was modified + run: | + if [ "${{ steps.update_changelog.outputs.modifiedFiles }}" = "0" ]; then + echo "Error: No files were modified when updating changelog" + exit 1 + fi - uses: stefanzweifel/git-auto-commit-action@v7 id: commit with: From 92e7b03224bb43b46b55e0b424238d141147b382 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Dec 2025 10:09:00 +0000 Subject: [PATCH 0819/1003] Bump pytest from 9.0.1 to 9.0.2 Bumps [pytest](https://github.com/pytest-dev/pytest) from 9.0.1 to 9.0.2. - [Release notes](https://github.com/pytest-dev/pytest/releases) - [Changelog](https://github.com/pytest-dev/pytest/blob/main/CHANGELOG.rst) - [Commits](https://github.com/pytest-dev/pytest/compare/9.0.1...9.0.2) --- updated-dependencies: - dependency-name: pytest dependency-version: 9.0.2 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ef165a9f5..db2c59e9d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -56,7 +56,7 @@ optional-dependencies.dev = [ "pyproject-fmt==2.11.1", "pyright==1.1.407", "pyroma==5.0", - "pytest==9.0.1", + "pytest==9.0.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", "ruff==0.14.8", From 27ec48f4068cc873013190326ff8c65603b1db7b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 8 Dec 2025 10:09:06 +0000 Subject: [PATCH 0820/1003] Bump doccmd from 2025.12.5 to 2025.12.8.5 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.12.5 to 2025.12.8.5. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.12.05...2025.12.08.5) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2025.12.8.5 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index ef165a9f5..9157ef37a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2025.12.5", + "doccmd==2025.12.8.5", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.9.25", From dd3dfb2ddc739a3324eab9af956bb4da4df4d1c2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 10 Dec 2025 10:08:47 +0000 Subject: [PATCH 0821/1003] Bump pyroma from 5.0 to 5.0.1 Bumps [pyroma](https://github.com/regebro/pyroma) from 5.0 to 5.0.1. - [Changelog](https://github.com/regebro/pyroma/blob/master/CHANGES.txt) - [Commits](https://github.com/regebro/pyroma/compare/5.0...5.0.1) --- updated-dependencies: - dependency-name: pyroma dependency-version: 5.0.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e1b5405c2..6bfdb8b2c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.11.1", "pyright==1.1.407", - "pyroma==5.0", + "pyroma==5.0.1", "pytest==9.0.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", From d8832258b02509285368ea9b81cf5e6508e4e19f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 11 Dec 2025 10:06:54 +0000 Subject: [PATCH 0822/1003] Bump doccmd from 2025.12.8.5 to 2025.12.10 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.12.8.5 to 2025.12.10. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.12.08.5...2025.12.10) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2025.12.10 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6bfdb8b2c..5c399ffce 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2025.12.8.5", + "doccmd==2025.12.10", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.9.25", From c9adeaef2a8df61209a3a3d8dd6f14505dbdb870 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 12 Dec 2025 10:06:23 +0000 Subject: [PATCH 0823/1003] Bump ruff from 0.14.8 to 0.14.9 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.8 to 0.14.9. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.14.8...0.14.9) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.14.9 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5c399ffce..aa8469e08 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pytest==9.0.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.14.8", + "ruff==0.14.9", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From e91723bfb0438b957412d137e091e02c33d46b17 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 13 Dec 2025 07:47:46 +0000 Subject: [PATCH 0824/1003] Bump beartype to 0.22.9 --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index aa8469e08..63c580c12 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -31,7 +31,7 @@ dynamic = [ "version", ] dependencies = [ - "beartype>=0.18.5", + "beartype>=0.22.9", "requests>=2.32.3", "urllib3>=2.2.3", "vws-auth-tools>=2024.7.12", From 394cc018b13c3a1bdafd296e816dde6919646c45 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 13 Dec 2025 08:46:40 +0000 Subject: [PATCH 0825/1003] Add ty to pre-commit --- .pre-commit-config.yaml | 20 ++++++++++++++++++++ pyproject.toml | 1 + 2 files changed, 21 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index fb99a708b..869dd167b 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -25,6 +25,8 @@ ci: - pyright - pyright-docs - pyright-verifytypes + - ty + - ty-docs - pyroma - ruff-check-fix - ruff-check-fix-docs @@ -341,6 +343,24 @@ repos: types_or: [python] additional_dependencies: [uv==0.9.5] + - id: ty + name: ty + stages: [pre-push] + entry: uv run --extra=dev ty check + language: python + types_or: [python, toml] + pass_filenames: false + additional_dependencies: [uv==0.9.5] + + - id: ty-docs + name: ty-docs + stages: [pre-push] + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + --command="ty check" + language: python + types_or: [markdown, rst] + additional_dependencies: [uv==0.9.5] + - id: yamlfix name: yamlfix entry: uv run --extra=dev yamlfix diff --git a/pyproject.toml b/pyproject.toml index 63c580c12..c55ab29cd 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -72,6 +72,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.11.17", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", + "ty==0.0.1a34", "types-requests==2.32.4.20250913", "vulture==2.14", "vws-python-mock==2025.3.10.1", From 39bd39bbf5cbbd54e15e1c93293ad4fe23ce22e7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 15 Dec 2025 10:07:12 +0000 Subject: [PATCH 0826/1003] Bump mypy[faster-cache] from 1.19.0 to 1.19.1 Bumps [mypy[faster-cache]](https://github.com/python/mypy) from 1.19.0 to 1.19.1. - [Changelog](https://github.com/python/mypy/blob/master/CHANGELOG.md) - [Commits](https://github.com/python/mypy/compare/v1.19.0...v1.19.1) --- updated-dependencies: - dependency-name: mypy[faster-cache] dependency-version: 1.19.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c55ab29cd..0c7d5b23d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -46,7 +46,7 @@ optional-dependencies.dev = [ "freezegun==1.5.5", "furo==2025.9.25", "interrogate==1.7.0", - "mypy[faster-cache]==1.19.0", + "mypy[faster-cache]==1.19.1", "mypy-strict-kwargs==2025.4.3", "pre-commit==4.5.0", "pydocstyle==6.3", From 4c4bcd7e8a6938b4666b6426d1f461fda2325251 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 15 Dec 2025 10:07:17 +0000 Subject: [PATCH 0827/1003] Bump doccmd from 2025.12.10 to 2025.12.13 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.12.10 to 2025.12.13. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.12.10...2025.12.13) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2025.12.13 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c55ab29cd..e004a6c1a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2025.12.10", + "doccmd==2025.12.13", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.9.25", From 66535b2d74b3cdda1113677b6a8e949719c18e9c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 15 Dec 2025 10:07:29 +0000 Subject: [PATCH 0828/1003] Bump sphinx-substitution-extensions from 2025.11.17 to 2025.12.15 Bumps [sphinx-substitution-extensions](https://github.com/adamtheturtle/sphinx-substitution-extensions) from 2025.11.17 to 2025.12.15. - [Release notes](https://github.com/adamtheturtle/sphinx-substitution-extensions/releases) - [Changelog](https://github.com/adamtheturtle/sphinx-substitution-extensions/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/sphinx-substitution-extensions/compare/2025.11.17...2025.12.15) --- updated-dependencies: - dependency-name: sphinx-substitution-extensions dependency-version: 2025.12.15 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c55ab29cd..db264822d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -69,7 +69,7 @@ optional-dependencies.dev = [ "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.2", "sphinx-pyproject==0.3.0", - "sphinx-substitution-extensions==2025.11.17", + "sphinx-substitution-extensions==2025.12.15", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", "ty==0.0.1a34", From 6b3eddb13067d339f394928fe642461d6cf32967 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 16 Dec 2025 10:07:37 +0000 Subject: [PATCH 0829/1003] Bump ty from 0.0.1a34 to 0.0.1a35 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.1a34 to 0.0.1a35. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.1-alpha.34...0.0.1-alpha.35) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.1a35 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c78c199b2..fbfc2d380 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -72,7 +72,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.12.15", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.1a34", + "ty==0.0.1a35", "types-requests==2.32.4.20250913", "vulture==2.14", "vws-python-mock==2025.3.10.1", From beaee0dd2d42b36956cbd988790f82cf893e374f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 17 Dec 2025 10:07:12 +0000 Subject: [PATCH 0830/1003] Bump pre-commit from 4.5.0 to 4.5.1 Bumps [pre-commit](https://github.com/pre-commit/pre-commit) from 4.5.0 to 4.5.1. - [Release notes](https://github.com/pre-commit/pre-commit/releases) - [Changelog](https://github.com/pre-commit/pre-commit/blob/main/CHANGELOG.md) - [Commits](https://github.com/pre-commit/pre-commit/compare/v4.5.0...v4.5.1) --- updated-dependencies: - dependency-name: pre-commit dependency-version: 4.5.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index fbfc2d380..6cc88f6ea 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "interrogate==1.7.0", "mypy[faster-cache]==1.19.1", "mypy-strict-kwargs==2025.4.3", - "pre-commit==4.5.0", + "pre-commit==4.5.1", "pydocstyle==6.3", "pygments==2.19.2", "pylint[spelling]==4.0.4", From 26fa111cbd1f1219241ac9c5a75b7eb986522228 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 17 Dec 2025 10:07:28 +0000 Subject: [PATCH 0831/1003] Bump ty from 0.0.1a35 to 0.0.2 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.1a35 to 0.0.2. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.1-alpha.35...0.0.2) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.2 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index fbfc2d380..12cee6d12 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -72,7 +72,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.12.15", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.1a35", + "ty==0.0.2", "types-requests==2.32.4.20250913", "vulture==2.14", "vws-python-mock==2025.3.10.1", From a536d6257f57d2464da9f40efd17f758e5b7387c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 18 Dec 2025 10:06:55 +0000 Subject: [PATCH 0832/1003] Bump yamlfix from 1.19.0 to 1.19.1 Bumps [yamlfix](https://github.com/lyz-code/yamlfix) from 1.19.0 to 1.19.1. - [Changelog](https://github.com/lyz-code/yamlfix/blob/main/CHANGELOG.md) - [Commits](https://github.com/lyz-code/yamlfix/compare/1.19.0...1.19.1) --- updated-dependencies: - dependency-name: yamlfix dependency-version: 1.19.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2a2a07f0f..d624a7acc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -77,7 +77,7 @@ optional-dependencies.dev = [ "vulture==2.14", "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", - "yamlfix==1.19.0", + "yamlfix==1.19.1", ] optional-dependencies.release = [ "check-wheel-contents==0.6.3" ] urls.Documentation = "https://vws-python.github.io/vws-python/" From 50dd267dc9f250847acaf2d8da3361554326e148 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 18 Dec 2025 10:07:07 +0000 Subject: [PATCH 0833/1003] Bump ty from 0.0.2 to 0.0.3 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.2 to 0.0.3. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.2...0.0.3) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.3 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2a2a07f0f..1f2180bc3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -72,7 +72,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.12.15", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.2", + "ty==0.0.3", "types-requests==2.32.4.20250913", "vulture==2.14", "vws-python-mock==2025.3.10.1", From 44ef2a77b8aa085c177c70b98f724fbd1b3880e0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 19 Dec 2025 10:06:31 +0000 Subject: [PATCH 0834/1003] Bump ruff from 0.14.9 to 0.14.10 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.9 to 0.14.10. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.14.9...0.14.10) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.14.10 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3bb297ad8..64b60edb2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -59,7 +59,7 @@ optional-dependencies.dev = [ "pytest==9.0.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.14.9", + "ruff==0.14.10", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From d6636bdad9cf3686abd731fb4b8feaf5bc8c052e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 19 Dec 2025 10:06:37 +0000 Subject: [PATCH 0835/1003] Bump ty from 0.0.3 to 0.0.4 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.3 to 0.0.4. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.3...0.0.4) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.4 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3bb297ad8..c04b49cb0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -72,7 +72,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.12.15", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.3", + "ty==0.0.4", "types-requests==2.32.4.20250913", "vulture==2.14", "vws-python-mock==2025.3.10.1", From 1bd3d3788e29a5f3237f564566494adcef9836b3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 19 Dec 2025 10:11:26 +0000 Subject: [PATCH 0836/1003] Bump sphinx from 8.2.3 to 9.0.4 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 8.2.3 to 9.0.4. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v8.2.3...v9.0.4) --- updated-dependencies: - dependency-name: sphinx dependency-version: 9.0.4 dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c04b49cb0..21f7d62fd 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -65,7 +65,7 @@ optional-dependencies.dev = [ # use it to lint shell commands in GitHub workflow files. "shellcheck-py==0.11.0.1", "shfmt-py==3.12.0.2", - "sphinx==8.2.3", + "sphinx==9.0.4", "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.2", "sphinx-pyproject==0.3.0", From 9723406fb1f2715b0be49193b486c659ed65b465 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 19 Dec 2025 20:00:44 +0000 Subject: [PATCH 0837/1003] Update furo package version to 2025.12.19 --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 21f7d62fd..88123bf98 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -44,7 +44,7 @@ optional-dependencies.dev = [ "doccmd==2025.12.13", "docformatter==1.7.7", "freezegun==1.5.5", - "furo==2025.9.25", + "furo==2025.12.19", "interrogate==1.7.0", "mypy[faster-cache]==1.19.1", "mypy-strict-kwargs==2025.4.3", From 88c8a17a56f3ace8352dc675e089b8422f687d9e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 22 Dec 2025 10:06:54 +0000 Subject: [PATCH 0838/1003] Bump furo from 2025.9.25 to 2025.12.19 Bumps [furo](https://github.com/pradyunsg/furo) from 2025.9.25 to 2025.12.19. - [Release notes](https://github.com/pradyunsg/furo/releases) - [Changelog](https://github.com/pradyunsg/furo/blob/main/docs/changelog.md) - [Commits](https://github.com/pradyunsg/furo/compare/2025.09.25...2025.12.19) --- updated-dependencies: - dependency-name: furo dependency-version: 2025.12.19 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index fbc8246f8..317f65c8d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -44,7 +44,7 @@ optional-dependencies.dev = [ "doccmd==2025.12.13", "docformatter==1.7.7", "freezegun==1.5.5", - "furo==2025.9.25", + "furo==2025.12.19", "interrogate==1.7.0", "mypy[faster-cache]==1.19.1", "mypy-strict-kwargs==2025.4.3", From ac207c1a8d55cf624374dae8028f582ad4aaef8f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 22 Dec 2025 10:07:09 +0000 Subject: [PATCH 0839/1003] Bump ty from 0.0.4 to 0.0.5 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.4 to 0.0.5. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.4...0.0.5) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.5 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index fbc8246f8..5d847450f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -72,7 +72,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.12.15", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.4", + "ty==0.0.5", "types-requests==2.32.4.20250913", "vulture==2.14", "vws-python-mock==2025.3.10.1", From e0a7faa6995fd78b42c83cef94d8a6276613ef2f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 24 Dec 2025 10:06:00 +0000 Subject: [PATCH 0840/1003] Bump ty from 0.0.5 to 0.0.6 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.5 to 0.0.6. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.5...0.0.6) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.6 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 53fa894f3..095963da1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -72,7 +72,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.12.15", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.5", + "ty==0.0.6", "types-requests==2.32.4.20250913", "vulture==2.14", "vws-python-mock==2025.3.10.1", From 0e55cc744253a9bb880728f6bc9c3db130565083 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 25 Dec 2025 10:06:37 +0000 Subject: [PATCH 0841/1003] Bump ty from 0.0.6 to 0.0.7 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.6 to 0.0.7. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.6...0.0.7) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.7 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 095963da1..0777cf4a1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -72,7 +72,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.12.15", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.6", + "ty==0.0.7", "types-requests==2.32.4.20250913", "vulture==2.14", "vws-python-mock==2025.3.10.1", From 235856347f8e614dbd4414f6d3e41cfefc568606 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 26 Dec 2025 14:24:52 +0000 Subject: [PATCH 0842/1003] Add pyrefly and pyrefly-docs configuration --- .pre-commit-config.yaml | 20 ++++++++++++++++++++ pyproject.toml | 1 + 2 files changed, 21 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 869dd167b..90934191b 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -40,6 +40,8 @@ ci: - vulture - vulture-docs - yamlfix + - pyrefly + - pyrefly-docs default_install_hook_types: [pre-commit, pre-push, commit-msg] @@ -376,3 +378,21 @@ repos: types_or: [rst] additional_dependencies: [uv==0.9.5] stages: [pre-commit] + + - id: pyrefly + name: pyrefly + stages: [pre-push] + entry: uv run --extra=dev pyrefly check + language: python + types_or: [python, toml] + pass_filenames: false + additional_dependencies: [uv==0.9.5] + + - id: pyrefly-docs + name: pyrefly-docs + stages: [pre-push] + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + --command="pyrefly check" + language: python + types_or: [markdown, rst] + additional_dependencies: [uv==0.9.5] diff --git a/pyproject.toml b/pyproject.toml index 53fa894f3..62a8733d6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,6 +54,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.11.1", + "pyrefly==0.46.1", "pyright==1.1.407", "pyroma==5.0.1", "pytest==9.0.2", From 47c76bda6095117739fb2eef4277c22f4b4828b8 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 26 Dec 2025 15:17:08 +0000 Subject: [PATCH 0843/1003] Fix pyrefly --- src/vws/vws.py | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/src/vws/vws.py b/src/vws/vws.py index 5dd7503db..bb05233c3 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -352,10 +352,10 @@ def get_target_record(self, target_id: str) -> TargetStatusAndRecord: target_record_dict = dict(result_data["target_record"]) target_record = TargetRecord( target_id=target_record_dict["target_id"], - active_flag=target_record_dict["active_flag"], + active_flag=bool(target_record_dict["active_flag"]), name=target_record_dict["name"], - width=target_record_dict["width"], - tracking_rating=target_record_dict["tracking_rating"], + width=float(target_record_dict["width"]), + tracking_rating=int(target_record_dict["tracking_rating"]), reco_rating=target_record_dict["reco_rating"], ) return TargetStatusAndRecord( @@ -485,11 +485,11 @@ def get_target_summary_report(self, target_id: str) -> TargetSummaryReport: database_name=result_data["database_name"], target_name=result_data["target_name"], upload_date=date.fromisoformat(result_data["upload_date"]), - active_flag=result_data["active_flag"], - tracking_rating=result_data["tracking_rating"], - total_recos=result_data["total_recos"], - current_month_recos=result_data["current_month_recos"], - previous_month_recos=result_data["previous_month_recos"], + active_flag=bool(result_data["active_flag"]), + tracking_rating=int(result_data["tracking_rating"]), + total_recos=int(result_data["total_recos"]), + current_month_recos=int(result_data["current_month_recos"]), + previous_month_recos=int(result_data["previous_month_recos"]), ) def get_database_summary_report(self) -> DatabaseSummaryReport: @@ -524,18 +524,18 @@ def get_database_summary_report(self) -> DatabaseSummaryReport: response_data = dict(json.loads(s=response.text)) return DatabaseSummaryReport( - active_images=response_data["active_images"], - current_month_recos=response_data["current_month_recos"], - failed_images=response_data["failed_images"], - inactive_images=response_data["inactive_images"], - name=response_data["name"], - previous_month_recos=response_data["previous_month_recos"], - processing_images=response_data["processing_images"], - reco_threshold=response_data["reco_threshold"], - request_quota=response_data["request_quota"], - request_usage=response_data["request_usage"], - target_quota=response_data["target_quota"], - total_recos=response_data["total_recos"], + active_images=int(response_data["active_images"]), + current_month_recos=int(response_data["current_month_recos"]), + failed_images=int(response_data["failed_images"]), + inactive_images=int(response_data["inactive_images"]), + name=str(response_data["name"]), + previous_month_recos=int(response_data["previous_month_recos"]), + processing_images=int(response_data["processing_images"]), + reco_threshold=int(response_data["reco_threshold"]), + request_quota=int(response_data["request_quota"]), + request_usage=int(response_data["request_usage"]), + target_quota=int(response_data["target_quota"]), + total_recos=int(response_data["total_recos"]), ) def delete_target(self, target_id: str) -> None: From 495f0048c6d5e923f001d43b729a79fca5937b37 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 26 Dec 2025 15:21:38 +0000 Subject: [PATCH 0844/1003] Fix mypy --- src/vws/vws.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vws/vws.py b/src/vws/vws.py index bb05233c3..8def19ed7 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -528,7 +528,7 @@ def get_database_summary_report(self) -> DatabaseSummaryReport: current_month_recos=int(response_data["current_month_recos"]), failed_images=int(response_data["failed_images"]), inactive_images=int(response_data["inactive_images"]), - name=str(response_data["name"]), + name=str(object=response_data["name"]), previous_month_recos=int(response_data["previous_month_recos"]), processing_images=int(response_data["processing_images"]), reco_threshold=int(response_data["reco_threshold"]), From ab3c1cbc0ed74693bd2566a07a79aa9d65f4cab8 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 29 Dec 2025 13:11:32 +0000 Subject: [PATCH 0845/1003] Add zizmor for GitHub Actions security linting --- .pre-commit-config.yaml | 10 ++++++++++ pyproject.toml | 1 + 2 files changed, 11 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 90934191b..f80c2aa4a 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -40,6 +40,7 @@ ci: - vulture - vulture-docs - yamlfix + - zizmor - pyrefly - pyrefly-docs @@ -371,6 +372,15 @@ repos: additional_dependencies: [uv==0.9.5] stages: [pre-commit] + - id: zizmor + name: zizmor + entry: uv run --extra=dev zizmor .github + language: python + pass_filenames: false + types_or: [yaml] + additional_dependencies: [uv==0.9.5] + stages: [pre-commit] + - id: sphinx-lint name: sphinx-lint entry: uv run --extra=dev sphinx-lint --enable=all --disable=line-too-long diff --git a/pyproject.toml b/pyproject.toml index fffc77ad5..c4fd55a7e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -79,6 +79,7 @@ optional-dependencies.dev = [ "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", "yamlfix==1.19.1", + "zizmor==1.19.0", ] optional-dependencies.release = [ "check-wheel-contents==0.6.3" ] urls.Documentation = "https://vws-python.github.io/vws-python/" From 8e33271b8df067abfb6f40170d644c0a79dd805e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 29 Dec 2025 13:42:59 +0000 Subject: [PATCH 0846/1003] Add zizmor config --- zizmor.yml | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 zizmor.yml diff --git a/zizmor.yml b/zizmor.yml new file mode 100644 index 000000000..fd4a958a9 --- /dev/null +++ b/zizmor.yml @@ -0,0 +1,4 @@ +--- +rules: + unpinned-uses: + disable: true From fb43e8b27a7f85b3250a39b7541aeed8d7d050c2 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 29 Dec 2025 14:36:32 +0000 Subject: [PATCH 0847/1003] Fix zizmor / ignore some errors --- .github/workflows/ci.yml | 6 ++++-- .github/workflows/dependabot-merge.yml | 1 - .github/workflows/lint.yml | 6 ++++-- .github/workflows/release.yml | 6 +++--- zizmor.yml | 8 ++++++++ 5 files changed, 19 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 73e6ce82c..ca86af4b1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,5 +1,4 @@ --- - name: Test on: @@ -12,9 +11,10 @@ on: # Run at 1:00 every day - cron: 0 1 * * * +permissions: {} + jobs: build: - strategy: matrix: python-version: ['3.13'] @@ -24,6 +24,8 @@ jobs: steps: - uses: actions/checkout@v6 + with: + persist-credentials: false - name: Install uv uses: astral-sh/setup-uv@v7 diff --git a/.github/workflows/dependabot-merge.yml b/.github/workflows/dependabot-merge.yml index 5238c9f68..4932493cf 100644 --- a/.github/workflows/dependabot-merge.yml +++ b/.github/workflows/dependabot-merge.yml @@ -1,5 +1,4 @@ --- - name: Dependabot auto-merge on: pull_request diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index fbdc4c6ce..4c01f743c 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -1,5 +1,4 @@ --- - name: Lint on: @@ -12,9 +11,10 @@ on: # Run at 1:00 every day - cron: 0 1 * * * +permissions: {} + jobs: build: - strategy: matrix: python-version: ['3.13'] @@ -24,6 +24,8 @@ jobs: steps: - uses: actions/checkout@v6 + with: + persist-credentials: false - name: Install uv uses: astral-sh/setup-uv@v7 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 60b4f9398..305cecb7b 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,5 +1,4 @@ --- - name: Release on: workflow_dispatch @@ -32,6 +31,7 @@ jobs: # Also, avoids # https://github.com/stefanzweifel/git-auto-commit-action/issues/99. fetch-depth: 0 + persist-credentials: false - name: Install uv uses: astral-sh/setup-uv@v7 @@ -59,8 +59,8 @@ jobs: uses: jacobtomlinson/gha-find-replace@v3 with: find: "Next\n----" - replace: "Next\n----\n\n${{ steps.calver.outputs.release }}\n${{ steps.changelog_underline.outputs.underline\ - \ }}" + replace: | + "Next\n----\n\n${{ steps.calver.outputs.release }}\n${{ steps.changelog_underline.outputs.underline }}" include: CHANGELOG.rst regex: false diff --git a/zizmor.yml b/zizmor.yml index fd4a958a9..f63e179d2 100644 --- a/zizmor.yml +++ b/zizmor.yml @@ -2,3 +2,11 @@ rules: unpinned-uses: disable: true + cache-poisoning: + disable: true + bot-conditions: + disable: true + dependabot-cooldown: + disable: true + template-injection: + disable: true From 502ec2e4c18d91ab4c4556bbe5354031f1d7fc17 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 29 Dec 2025 14:37:41 +0000 Subject: [PATCH 0848/1003] Ignore zizmor in check-manifest --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index c4fd55a7e..d1c81f7e7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -302,6 +302,7 @@ ignore = [ "tests/**", "vuforia_secrets.env.example", "lint.mk", + "zizmor.yml", ] [tool.deptry] From 30aee41db18d59beb0864ddef49bf181947a4460 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 29 Dec 2025 16:11:22 +0000 Subject: [PATCH 0849/1003] Fix bugbot issues --- .github/workflows/release.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 305cecb7b..8bbb38a09 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -21,7 +21,7 @@ jobs: steps: - uses: actions/checkout@v6 - with: + with: # zizmor: ignore[artipacked] git-auto-commit-action requires credentials # See # https://github.com/stefanzweifel/git-auto-commit-action?tab=readme-ov-file#push-to-protected-branches token: ${{ secrets.RELEASE_PAT }} @@ -31,7 +31,6 @@ jobs: # Also, avoids # https://github.com/stefanzweifel/git-auto-commit-action/issues/99. fetch-depth: 0 - persist-credentials: false - name: Install uv uses: astral-sh/setup-uv@v7 @@ -59,8 +58,8 @@ jobs: uses: jacobtomlinson/gha-find-replace@v3 with: find: "Next\n----" - replace: | - "Next\n----\n\n${{ steps.calver.outputs.release }}\n${{ steps.changelog_underline.outputs.underline }}" + replace: "Next\n----\n\n${{ steps.calver.outputs.release }}\n${{ steps.changelog_underline.outputs.underline\ + \ }}" include: CHANGELOG.rst regex: false From ba43cc99746c69c87521fcf0305766a7690357b1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 30 Dec 2025 10:05:49 +0000 Subject: [PATCH 0850/1003] Bump ty from 0.0.7 to 0.0.8 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.7 to 0.0.8. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.7...0.0.8) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.8 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d1c81f7e7..f6bce47c4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,7 +73,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.12.15", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.7", + "ty==0.0.8", "types-requests==2.32.4.20250913", "vulture==2.14", "vws-python-mock==2025.3.10.1", From 2781f1225cdcd1ce50dfc498c2917beda3ea187e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 30 Dec 2025 10:05:56 +0000 Subject: [PATCH 0851/1003] Bump pyrefly from 0.46.1 to 0.46.2 Bumps [pyrefly](https://github.com/facebook/pyrefly) from 0.46.1 to 0.46.2. - [Release notes](https://github.com/facebook/pyrefly/releases) - [Commits](https://github.com/facebook/pyrefly/compare/0.46.1...0.46.2) --- updated-dependencies: - dependency-name: pyrefly dependency-version: 0.46.2 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d1c81f7e7..daa3fedd5 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.11.1", - "pyrefly==0.46.1", + "pyrefly==0.46.2", "pyright==1.1.407", "pyroma==5.0.1", "pytest==9.0.2", From d40ba68247317001eb7a6c3cb79b4fcbd4728dba Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 31 Dec 2025 10:07:02 +0000 Subject: [PATCH 0852/1003] Bump pyrefly from 0.46.2 to 0.46.3 Bumps [pyrefly](https://github.com/facebook/pyrefly) from 0.46.2 to 0.46.3. - [Release notes](https://github.com/facebook/pyrefly/releases) - [Commits](https://github.com/facebook/pyrefly/compare/0.46.2...0.46.3) --- updated-dependencies: - dependency-name: pyrefly dependency-version: 0.46.3 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2c15b49b0..51b8d55c1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.11.1", - "pyrefly==0.46.2", + "pyrefly==0.46.3", "pyright==1.1.407", "pyroma==5.0.1", "pytest==9.0.2", From ed0c648710c592668c3c896f6fd290eddf0d7c0d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 2 Jan 2026 06:50:58 +0000 Subject: [PATCH 0853/1003] Switch from pre-commit to prek - Replace pre-commit with prek in pyproject.toml dev dependencies - Update .pre-commit-config.yaml to use prek builtin hooks - Remove pre-commit CI configuration (ci: section) - Update GitHub Actions workflow to use prek commands - Update contributing documentation for prek --- .github/workflows/lint.yml | 8 ++--- .pre-commit-config.yaml | 59 ++++++------------------------------ docs/source/contributing.rst | 10 +++--- pyproject.toml | 2 +- 4 files changed, 19 insertions(+), 60 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 4c01f743c..a2e604942 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -35,9 +35,9 @@ jobs: - name: Lint run: | - uv run --extra=dev pre-commit run --all-files --hook-stage pre-commit --verbose - uv run --extra=dev pre-commit run --all-files --hook-stage pre-push --verbose - uv run --extra=dev pre-commit run --all-files --hook-stage manual --verbose + uv run --extra=dev prek run --all-files --hook-stage pre-commit --verbose + uv run --extra=dev prek run --all-files --hook-stage pre-push --verbose + uv run --extra=dev prek run --all-files --hook-stage manual --verbose env: UV_PYTHON: ${{ matrix.python-version }} @@ -47,7 +47,7 @@ jobs: completion-lint: needs: build runs-on: ubuntu-latest - if: always() # Run even if one matrix job fails + if: always() # Run even if one matrix job fails steps: - name: Check matrix job status run: |- diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index f80c2aa4a..82eeb1116 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,58 +1,14 @@ --- fail_fast: true -# See https://pre-commit.com for more information -# See https://pre-commit.com/hooks.html for more hooks - -ci: - # We use system Python, with required dependencies specified in pyproject.toml. - # We therefore cannot use those dependencies in pre-commit CI. - skip: - - actionlint - - sphinx-lint - - check-manifest - - deptry - - doc8 - - docformatter - - docs - - interrogate - - interrogate-docs - - linkcheck - - mypy - - mypy-docs - - pylint - - pyproject-fmt-fix - - pyright - - pyright-docs - - pyright-verifytypes - - ty - - ty-docs - - pyroma - - ruff-check-fix - - ruff-check-fix-docs - - ruff-format-fix - - ruff-format-fix-docs - - shellcheck - - shellcheck-docs - - shfmt - - shfmt-docs - - spelling - - vulture - - vulture-docs - - yamlfix - - zizmor - - pyrefly - - pyrefly-docs +# See https://prek.j178.dev for more information + + default_install_hook_types: [pre-commit, pre-push, commit-msg] repos: - - repo: meta - hooks: - - id: check-useless-excludes - stages: [pre-commit] - - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v6.0.0 + - repo: builtin hooks: - id: check-added-large-files stages: [pre-commit] @@ -76,11 +32,14 @@ repos: stages: [pre-commit] - id: end-of-file-fixer stages: [pre-commit] + - id: trailing-whitespace + stages: [pre-commit] + - repo: https://github.com/pre-commit/pre-commit-hooks + rev: v6.0.0 + hooks: - id: file-contents-sorter files: spelling_private_dict\.txt$ stages: [pre-commit] - - id: trailing-whitespace - stages: [pre-commit] - repo: https://github.com/pre-commit/pygrep-hooks rev: v1.10.0 hooks: diff --git a/docs/source/contributing.rst b/docs/source/contributing.rst index 0e531220d..55d902399 100644 --- a/docs/source/contributing.rst +++ b/docs/source/contributing.rst @@ -27,11 +27,11 @@ and on Ubuntu with ``apt``: $ apt-get install -y enchant -Install ``pre-commit`` hooks: +Install ``prek`` hooks: .. code-block:: console - $ pre-commit install + $ prek install Linting ------- @@ -40,9 +40,9 @@ Run lint tools either by committing, or with: .. code-block:: console - $ pre-commit run --all-files --hook-stage pre-commit --verbose - $ pre-commit run --all-files --hook-stage pre-push --verbose - $ pre-commit run --all-files --hook-stage manual --verbose + $ prek run --all-files --hook-stage pre-commit --verbose + $ prek run --all-files --hook-stage pre-push --verbose + $ prek run --all-files --hook-stage manual --verbose .. _Homebrew: https://brew.sh diff --git a/pyproject.toml b/pyproject.toml index 51b8d55c1..2aa051145 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "interrogate==1.7.0", "mypy[faster-cache]==1.19.1", "mypy-strict-kwargs==2025.4.3", - "pre-commit==4.5.1", + "prek==0.2.25", "pydocstyle==6.3", "pygments==2.19.2", "pylint[spelling]==4.0.4", From 852127947726f91c4b4566c25bf3a26be3f2f38e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 2 Jan 2026 07:05:06 +0000 Subject: [PATCH 0854/1003] Undo some unnecessary changes --- .pre-commit-config.yaml | 45 ++++++++++++++++++++++++----------------- 1 file changed, 26 insertions(+), 19 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 82eeb1116..c18dc43f5 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -3,8 +3,6 @@ fail_fast: true # See https://prek.j178.dev for more information - - default_install_hook_types: [pre-commit, pre-push, commit-msg] repos: @@ -32,14 +30,11 @@ repos: stages: [pre-commit] - id: end-of-file-fixer stages: [pre-commit] - - id: trailing-whitespace - stages: [pre-commit] - - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v6.0.0 - hooks: - id: file-contents-sorter files: spelling_private_dict\.txt$ stages: [pre-commit] + - id: trailing-whitespace + stages: [pre-commit] - repo: https://github.com/pre-commit/pygrep-hooks rev: v1.10.0 hooks: @@ -81,7 +76,8 @@ repos: - id: shellcheck-docs name: shellcheck-docs - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=shell + entry: + uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=shell --language=console --command="shellcheck --shell=bash" language: python types_or: [markdown, rst] @@ -98,7 +94,8 @@ repos: - id: shfmt-docs name: shfmt-docs - entry: uv run --extra=dev doccmd --language=shell --language=console --skip-marker=shfmt + entry: + uv run --extra=dev doccmd --language=shell --language=console --skip-marker=shfmt --no-pad-file --command="shfmt --write --space-redirects --indent=4" language: python types_or: [markdown, rst] @@ -117,7 +114,8 @@ repos: - id: mypy-docs name: mypy-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + entry: + uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python --command="mypy" language: python types_or: [markdown, rst] @@ -143,7 +141,8 @@ repos: - id: pyright-docs name: pyright-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + entry: + uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python --command="pyright" language: python types_or: [markdown, rst] @@ -160,7 +159,8 @@ repos: - id: vulture-docs name: vulture docs - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + entry: + uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python --command="vulture" language: python types_or: [markdown, rst] @@ -194,7 +194,8 @@ repos: - id: pylint-docs name: pylint-docs - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + entry: + uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python --command="pylint" language: python stages: [manual] @@ -227,7 +228,8 @@ repos: - id: ruff-format-fix-docs name: Ruff format docs - entry: uv run --extra=dev doccmd --language=python --no-pad-file --command="ruff + entry: + uv run --extra=dev doccmd --language=python --no-pad-file --command="ruff format" language: python types_or: [markdown, rst] @@ -252,7 +254,8 @@ repos: - id: interrogate-docs name: interrogate docs - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + entry: + uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python --command="interrogate" language: python types_or: [markdown, rst] @@ -270,7 +273,8 @@ repos: - id: linkcheck name: linkcheck - entry: uv run --extra=dev sphinx-build -M linkcheck docs/source docs/build + entry: + uv run --extra=dev sphinx-build -M linkcheck docs/source docs/build -W language: python types_or: [rst] @@ -280,7 +284,8 @@ repos: - id: spelling name: spelling - entry: uv run --extra=dev sphinx-build -M spelling docs/source docs/build + entry: + uv run --extra=dev sphinx-build -M spelling docs/source docs/build -W language: python types_or: [rst] @@ -317,7 +322,8 @@ repos: - id: ty-docs name: ty-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + entry: + uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python --command="ty check" language: python types_or: [markdown, rst] @@ -360,7 +366,8 @@ repos: - id: pyrefly-docs name: pyrefly-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + entry: + uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python --command="pyrefly check" language: python types_or: [markdown, rst] From e2c817a172fb46354c735495fde48b39f9e4e944 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 2 Jan 2026 07:10:53 +0000 Subject: [PATCH 0855/1003] Remove stage --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c18dc43f5..3313df31a 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -3,7 +3,7 @@ fail_fast: true # See https://prek.j178.dev for more information -default_install_hook_types: [pre-commit, pre-push, commit-msg] +default_install_hook_types: [pre-commit, pre-push] repos: - repo: builtin From 1a622a69c12d664cc3d46d0f0d130ba3dc9d4654 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 2 Jan 2026 07:12:37 +0000 Subject: [PATCH 0856/1003] Remove changes --- .pre-commit-config.yaml | 86 ++++++++++++++++++++++++++++------------- 1 file changed, 60 insertions(+), 26 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 3313df31a..d9a702af3 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,12 +1,58 @@ --- fail_fast: true -# See https://prek.j178.dev for more information +# See https://pre-commit.com for more information +# See https://pre-commit.com/hooks.html for more hooks + +ci: + # We use system Python, with required dependencies specified in pyproject.toml. + # We therefore cannot use those dependencies in pre-commit CI. + skip: + - actionlint + - sphinx-lint + - check-manifest + - deptry + - doc8 + - docformatter + - docs + - interrogate + - interrogate-docs + - linkcheck + - mypy + - mypy-docs + - pylint + - pyproject-fmt-fix + - pyright + - pyright-docs + - pyright-verifytypes + - ty + - ty-docs + - pyroma + - ruff-check-fix + - ruff-check-fix-docs + - ruff-format-fix + - ruff-format-fix-docs + - shellcheck + - shellcheck-docs + - shfmt + - shfmt-docs + - spelling + - vulture + - vulture-docs + - yamlfix + - zizmor + - pyrefly + - pyrefly-docs default_install_hook_types: [pre-commit, pre-push] repos: - - repo: builtin + - repo: meta + hooks: + - id: check-useless-excludes + stages: [pre-commit] + - repo: https://github.com/pre-commit/pre-commit-hooks + rev: v6.0.0 hooks: - id: check-added-large-files stages: [pre-commit] @@ -76,8 +122,7 @@ repos: - id: shellcheck-docs name: shellcheck-docs - entry: - uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=shell + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=shell --language=console --command="shellcheck --shell=bash" language: python types_or: [markdown, rst] @@ -94,8 +139,7 @@ repos: - id: shfmt-docs name: shfmt-docs - entry: - uv run --extra=dev doccmd --language=shell --language=console --skip-marker=shfmt + entry: uv run --extra=dev doccmd --language=shell --language=console --skip-marker=shfmt --no-pad-file --command="shfmt --write --space-redirects --indent=4" language: python types_or: [markdown, rst] @@ -114,8 +158,7 @@ repos: - id: mypy-docs name: mypy-docs stages: [pre-push] - entry: - uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python --command="mypy" language: python types_or: [markdown, rst] @@ -141,8 +184,7 @@ repos: - id: pyright-docs name: pyright-docs stages: [pre-push] - entry: - uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python --command="pyright" language: python types_or: [markdown, rst] @@ -159,8 +201,7 @@ repos: - id: vulture-docs name: vulture docs - entry: - uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python --command="vulture" language: python types_or: [markdown, rst] @@ -194,8 +235,7 @@ repos: - id: pylint-docs name: pylint-docs - entry: - uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python --command="pylint" language: python stages: [manual] @@ -228,8 +268,7 @@ repos: - id: ruff-format-fix-docs name: Ruff format docs - entry: - uv run --extra=dev doccmd --language=python --no-pad-file --command="ruff + entry: uv run --extra=dev doccmd --language=python --no-pad-file --command="ruff format" language: python types_or: [markdown, rst] @@ -254,8 +293,7 @@ repos: - id: interrogate-docs name: interrogate docs - entry: - uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python --command="interrogate" language: python types_or: [markdown, rst] @@ -273,8 +311,7 @@ repos: - id: linkcheck name: linkcheck - entry: - uv run --extra=dev sphinx-build -M linkcheck docs/source docs/build + entry: uv run --extra=dev sphinx-build -M linkcheck docs/source docs/build -W language: python types_or: [rst] @@ -284,8 +321,7 @@ repos: - id: spelling name: spelling - entry: - uv run --extra=dev sphinx-build -M spelling docs/source docs/build + entry: uv run --extra=dev sphinx-build -M spelling docs/source docs/build -W language: python types_or: [rst] @@ -322,8 +358,7 @@ repos: - id: ty-docs name: ty-docs stages: [pre-push] - entry: - uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python --command="ty check" language: python types_or: [markdown, rst] @@ -366,8 +401,7 @@ repos: - id: pyrefly-docs name: pyrefly-docs stages: [pre-push] - entry: - uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python --command="pyrefly check" language: python types_or: [markdown, rst] From dee2727aa1c8f7462c99c17ca6acf01b2ad0b9c1 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 2 Jan 2026 07:12:59 +0000 Subject: [PATCH 0857/1003] Test a change --- src/vws/exceptions/vws_exceptions.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index 482223766..e0e268e29 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -127,7 +127,7 @@ class ProjectInactiveError(VWSError): @beartype class MetadataTooLargeError(VWSError): """ - Exception raised when Vuforia returns a response with a result code + Exception raised when Vuforia returns responses with a result code 'MetadataTooLarge'. """ From bcb26d17a371a82c5a25754e9199ed2a80c0fe22 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 2 Jan 2026 07:13:08 +0000 Subject: [PATCH 0858/1003] Undo a change --- src/vws/exceptions/vws_exceptions.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index e0e268e29..482223766 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -127,7 +127,7 @@ class ProjectInactiveError(VWSError): @beartype class MetadataTooLargeError(VWSError): """ - Exception raised when Vuforia returns responses with a result code + Exception raised when Vuforia returns a response with a result code 'MetadataTooLarge'. """ From 833c51f2a8ac442a80dbd4d8189e6df605b74775 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Fri, 2 Jan 2026 07:14:39 +0000 Subject: [PATCH 0859/1003] [pre-commit.ci lite] apply automatic fixes --- .github/workflows/lint.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index a2e604942..0a9661f41 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -47,7 +47,7 @@ jobs: completion-lint: needs: build runs-on: ubuntu-latest - if: always() # Run even if one matrix job fails + if: always() # Run even if one matrix job fails steps: - name: Check matrix job status run: |- From 86f85f2c052ab368e78a58bb31a5244f7eee94b4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 2 Jan 2026 10:06:16 +0000 Subject: [PATCH 0860/1003] Bump actionlint-py from 1.7.9.24 to 1.7.10.24 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.7.9.24 to 1.7.10.24. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.7.9.24...v1.7.10.24) --- updated-dependencies: - dependency-name: actionlint-py dependency-version: 1.7.10.24 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2aa051145..aa0509965 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -37,7 +37,7 @@ dependencies = [ "vws-auth-tools>=2024.7.12", ] optional-dependencies.dev = [ - "actionlint-py==1.7.9.24", + "actionlint-py==1.7.10.24", "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", From bca8178e917fc97c4c3930fd3686be3ab93591f5 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 3 Jan 2026 07:26:15 +0000 Subject: [PATCH 0861/1003] Make prettier printWidth more compatible with yamlfix --- .prettierrc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.prettierrc b/.prettierrc index 3ab9aa054..4a36aae89 100644 --- a/.prettierrc +++ b/.prettierrc @@ -3,7 +3,8 @@ { "files": ["*.yaml", "*.yml"], "options": { - "singleQuote": true + "singleQuote": true, + "printWidth": 100 } } ] From 2b14da712b5473f4ddb7795a79a5e051de813222 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 3 Jan 2026 07:37:14 +0000 Subject: [PATCH 0862/1003] Make prettier more compatible with yamlfix --- .prettierrc | 1 + 1 file changed, 1 insertion(+) diff --git a/.prettierrc b/.prettierrc index 4a36aae89..e0af3cff2 100644 --- a/.prettierrc +++ b/.prettierrc @@ -4,6 +4,7 @@ "files": ["*.yaml", "*.yml"], "options": { "singleQuote": true, + "printWidth": 100", "printWidth": 100 } } From 63942af74d3513bc9c33ea54fb688fb10a052537 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 3 Jan 2026 07:46:50 +0000 Subject: [PATCH 0863/1003] Fix prettier config --- .prettierrc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.prettierrc b/.prettierrc index e0af3cff2..a6c3428b7 100644 --- a/.prettierrc +++ b/.prettierrc @@ -4,7 +4,7 @@ "files": ["*.yaml", "*.yml"], "options": { "singleQuote": true, - "printWidth": 100", + "printWidth": 100, "printWidth": 100 } } From c0c781fb624d6ab0c811921945ca4193746fb328 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 3 Jan 2026 08:14:11 +0000 Subject: [PATCH 0864/1003] Make zizmor collection strict --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index d9a702af3..1ed243a7a 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -374,7 +374,7 @@ repos: - id: zizmor name: zizmor - entry: uv run --extra=dev zizmor .github + entry: uv run --extra=dev zizmor --strict-collection .github language: python pass_filenames: false types_or: [yaml] From 7de5dbbf4b415e06cc201aeea7d311709e3d847c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 3 Jan 2026 08:15:10 +0000 Subject: [PATCH 0865/1003] Remove duplicate key --- .prettierrc | 1 - 1 file changed, 1 deletion(-) diff --git a/.prettierrc b/.prettierrc index a6c3428b7..4a36aae89 100644 --- a/.prettierrc +++ b/.prettierrc @@ -4,7 +4,6 @@ "files": ["*.yaml", "*.yml"], "options": { "singleQuote": true, - "printWidth": 100, "printWidth": 100 } } From d06536eaa00a3ba326e326b55b405ba424b3f15c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 3 Jan 2026 08:47:44 +0000 Subject: [PATCH 0866/1003] Fix zizmor warning in release workflow --- .github/workflows/release.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 8bbb38a09..1c092f518 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -58,8 +58,8 @@ jobs: uses: jacobtomlinson/gha-find-replace@v3 with: find: "Next\n----" - replace: "Next\n----\n\n${{ steps.calver.outputs.release }}\n${{ steps.changelog_underline.outputs.underline\ - \ }}" + replace: |- + Next\n----\n\n${{ steps.calver.outputs.release }}\n${{ steps.changelog_underline.outputs.underline }}\n include: CHANGELOG.rst regex: false From 8d50b7c22d43cf7bdacd70141ea18ec7c86deb2d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 3 Jan 2026 09:05:54 +0000 Subject: [PATCH 0867/1003] Fix block scalar newline interpretation in release workflow --- .github/workflows/release.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 1c092f518..685e0a9bb 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -58,8 +58,7 @@ jobs: uses: jacobtomlinson/gha-find-replace@v3 with: find: "Next\n----" - replace: |- - Next\n----\n\n${{ steps.calver.outputs.release }}\n${{ steps.changelog_underline.outputs.underline }}\n + replace: "Next\n----\n\n${{ steps.calver.outputs.release }}\n${{ steps.changelog_underline.outputs.underline }}\n" include: CHANGELOG.rst regex: false From 345aef02c5d608bd6c7fb94410a19a266b497ce1 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Sat, 3 Jan 2026 09:12:31 +0000 Subject: [PATCH 0868/1003] [pre-commit.ci lite] apply automatic fixes --- .github/workflows/release.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 685e0a9bb..8e655a8a0 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -58,7 +58,8 @@ jobs: uses: jacobtomlinson/gha-find-replace@v3 with: find: "Next\n----" - replace: "Next\n----\n\n${{ steps.calver.outputs.release }}\n${{ steps.changelog_underline.outputs.underline }}\n" + replace: "Next\n----\n\n${{ steps.calver.outputs.release }}\n${{ steps.changelog_underline.outputs.underline\ + \ }}\n" include: CHANGELOG.rst regex: false From 75b82221014b5f19bf172d3d8e9b6559c3343217 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 5 Jan 2026 10:06:22 +0000 Subject: [PATCH 0869/1003] Bump doccmd from 2025.12.13 to 2026.1.3.2 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2025.12.13 to 2026.1.3.2. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2025.12.13...2026.01.03.2) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2026.1.3.2 dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index aa0509965..69fc622d7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2025.12.13", + "doccmd==2026.1.3.2", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.12.19", From af376fc361b240c36e98da5ca197a8ed8243fbc3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 6 Jan 2026 10:08:51 +0000 Subject: [PATCH 0870/1003] Bump ty from 0.0.8 to 0.0.9 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.8 to 0.0.9. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.8...0.0.9) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.9 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 69fc622d7..e31b01609 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,7 +73,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.12.15", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.8", + "ty==0.0.9", "types-requests==2.32.4.20250913", "vulture==2.14", "vws-python-mock==2025.3.10.1", From 1edb010db619b933d63371322c28a48c38bac4e1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 6 Jan 2026 10:08:56 +0000 Subject: [PATCH 0871/1003] Bump pyrefly from 0.46.3 to 0.47.0 Bumps [pyrefly](https://github.com/facebook/pyrefly) from 0.46.3 to 0.47.0. - [Release notes](https://github.com/facebook/pyrefly/releases) - [Commits](https://github.com/facebook/pyrefly/compare/0.46.3...0.47.0) --- updated-dependencies: - dependency-name: pyrefly dependency-version: 0.47.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 69fc622d7..13651363d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.11.1", - "pyrefly==0.46.3", + "pyrefly==0.47.0", "pyright==1.1.407", "pyroma==5.0.1", "pytest==9.0.2", From e654679ecf7997c5edadc7321ece4141d795bee6 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 6 Jan 2026 10:09:18 +0000 Subject: [PATCH 0872/1003] Bump zizmor from 1.19.0 to 1.20.0 Bumps [zizmor](https://github.com/zizmorcore/zizmor) from 1.19.0 to 1.20.0. - [Release notes](https://github.com/zizmorcore/zizmor/releases) - [Changelog](https://github.com/zizmorcore/zizmor/blob/main/docs/release-notes.md) - [Commits](https://github.com/zizmorcore/zizmor/compare/v1.19.0...v1.20.0) --- updated-dependencies: - dependency-name: zizmor dependency-version: 1.20.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 69fc622d7..e6e7250dc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -79,7 +79,7 @@ optional-dependencies.dev = [ "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", "yamlfix==1.19.1", - "zizmor==1.19.0", + "zizmor==1.20.0", ] optional-dependencies.release = [ "check-wheel-contents==0.6.3" ] urls.Documentation = "https://vws-python.github.io/vws-python/" From e66ebb4cf271489a7f1b3d456a1f846f0419d736 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 7 Jan 2026 10:10:40 +0000 Subject: [PATCH 0873/1003] Bump types-requests from 2.32.4.20250913 to 2.32.4.20260107 Bumps [types-requests](https://github.com/typeshed-internal/stub_uploader) from 2.32.4.20250913 to 2.32.4.20260107. - [Commits](https://github.com/typeshed-internal/stub_uploader/commits) --- updated-dependencies: - dependency-name: types-requests dependency-version: 2.32.4.20260107 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 779fc7e80..2c91b8116 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -74,7 +74,7 @@ optional-dependencies.dev = [ "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", "ty==0.0.9", - "types-requests==2.32.4.20250913", + "types-requests==2.32.4.20260107", "vulture==2.14", "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", From c96a3da27556606ecfd3cbea41df72a3854e08ca Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 7 Jan 2026 21:46:10 +0000 Subject: [PATCH 0874/1003] Bump prek from 0.2.25 to 0.2.27 Bumps [prek](https://github.com/j178/prek) from 0.2.25 to 0.2.27. - [Release notes](https://github.com/j178/prek/releases) - [Changelog](https://github.com/j178/prek/blob/master/CHANGELOG.md) - [Commits](https://github.com/j178/prek/compare/v0.2.25...v0.2.27) --- updated-dependencies: - dependency-name: prek dependency-version: 0.2.27 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2c91b8116..2516a3caa 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "interrogate==1.7.0", "mypy[faster-cache]==1.19.1", "mypy-strict-kwargs==2025.4.3", - "prek==0.2.25", + "prek==0.2.27", "pydocstyle==6.3", "pygments==2.19.2", "pylint[spelling]==4.0.4", From c6979f1ba097daa9b45acac3ecb0df02e6aaf86e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 8 Jan 2026 10:31:59 +0000 Subject: [PATCH 0875/1003] Bump pyright from 1.1.407 to 1.1.408 Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.407 to 1.1.408. - [Release notes](https://github.com/RobertCraigie/pyright-python/releases) - [Commits](https://github.com/RobertCraigie/pyright-python/compare/v1.1.407...v1.1.408) --- updated-dependencies: - dependency-name: pyright dependency-version: 1.1.408 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2516a3caa..1c4a71770 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.11.1", "pyrefly==0.47.0", - "pyright==1.1.407", + "pyright==1.1.408", "pyroma==5.0.1", "pytest==9.0.2", "pytest-cov==7.0.0", From 3d89fa80ff2f3a40dafdf91187b2cb00b8e3c036 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 8 Jan 2026 10:32:08 +0000 Subject: [PATCH 0876/1003] Bump ty from 0.0.9 to 0.0.10 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.9 to 0.0.10. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.9...0.0.10) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.10 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2516a3caa..2cd83f5ce 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,7 +73,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.12.15", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.9", + "ty==0.0.10", "types-requests==2.32.4.20260107", "vulture==2.14", "vws-python-mock==2025.3.10.1", From aa46135c99a55def1a1a6394a610555b5d1bbf1b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 9 Jan 2026 10:38:01 +0000 Subject: [PATCH 0877/1003] Bump ruff from 0.14.10 to 0.14.11 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.10 to 0.14.11. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.14.10...0.14.11) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.14.11 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 37398cc75..e7202bd8c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ optional-dependencies.dev = [ "pytest==9.0.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.14.10", + "ruff==0.14.11", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 7795bb4b0066777daabe200ddc80375928a05558 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 12 Jan 2026 12:34:02 +0000 Subject: [PATCH 0878/1003] Bump sphinx-substitution-extensions from 2025.12.15 to 2026.1.12 Bumps [sphinx-substitution-extensions](https://github.com/adamtheturtle/sphinx-substitution-extensions) from 2025.12.15 to 2026.1.12. - [Release notes](https://github.com/adamtheturtle/sphinx-substitution-extensions/releases) - [Changelog](https://github.com/adamtheturtle/sphinx-substitution-extensions/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/sphinx-substitution-extensions/compare/2025.12.15...2026.01.12) --- updated-dependencies: - dependency-name: sphinx-substitution-extensions dependency-version: 2026.1.12 dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e7202bd8c..cfeaf5906 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -70,7 +70,7 @@ optional-dependencies.dev = [ "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.2", "sphinx-pyproject==0.3.0", - "sphinx-substitution-extensions==2025.12.15", + "sphinx-substitution-extensions==2026.1.12", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", "ty==0.0.10", From 5352d8fa2df773b301f81e46d48529b86323efe9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 12 Jan 2026 12:34:11 +0000 Subject: [PATCH 0879/1003] Bump mypy-strict-kwargs from 2025.4.3 to 2026.1.12 Bumps [mypy-strict-kwargs](https://github.com/adamtheturtle/mypy-strict-kwargs) from 2025.4.3 to 2026.1.12. - [Release notes](https://github.com/adamtheturtle/mypy-strict-kwargs/releases) - [Changelog](https://github.com/adamtheturtle/mypy-strict-kwargs/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/mypy-strict-kwargs/compare/2025.04.03...2026.01.12) --- updated-dependencies: - dependency-name: mypy-strict-kwargs dependency-version: 2026.1.12 dependency-type: direct:development update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e7202bd8c..30af2dcd2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -47,7 +47,7 @@ optional-dependencies.dev = [ "furo==2025.12.19", "interrogate==1.7.0", "mypy[faster-cache]==1.19.1", - "mypy-strict-kwargs==2025.4.3", + "mypy-strict-kwargs==2026.1.12", "prek==0.2.27", "pydocstyle==6.3", "pygments==2.19.2", From 59071162cc24648136663e4e4eb1afb6e064270b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 12 Jan 2026 12:34:20 +0000 Subject: [PATCH 0880/1003] Bump ty from 0.0.10 to 0.0.11 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.10 to 0.0.11. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.10...0.0.11) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.11 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e7202bd8c..9c89f308d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,7 +73,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2025.12.15", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.10", + "ty==0.0.11", "types-requests==2.32.4.20260107", "vulture==2.14", "vws-python-mock==2025.3.10.1", From c5f4eadbcd741164f39152960d3fba50ec2b3c13 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 12 Jan 2026 14:17:13 +0000 Subject: [PATCH 0881/1003] Switch from docformatter to pydocstringformatter --- .pre-commit-config.yaml | 8 ++++---- pyproject.toml | 9 +++++---- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 1ed243a7a..6b48bc64c 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -13,7 +13,7 @@ ci: - check-manifest - deptry - doc8 - - docformatter + - pydocstringformatter - docs - interrogate - interrogate-docs @@ -104,9 +104,9 @@ repos: additional_dependencies: [uv==0.9.5] stages: [pre-commit] - - id: docformatter - name: docformatter - entry: uv run --extra=dev -m docformatter --in-place + - id: pydocstringformatter + name: pydocstringformatter + entry: uv run --extra=dev pydocstringformatter language: python types_or: [python] additional_dependencies: [uv==0.9.5] diff --git a/pyproject.toml b/pyproject.toml index 3f7f5df0a..d4a6cbd29 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -42,13 +42,13 @@ optional-dependencies.dev = [ "deptry==0.24.0", "doc8==2.0.0", "doccmd==2026.1.3.2", - "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.12.19", "interrogate==1.7.0", "mypy[faster-cache]==1.19.1", "mypy-strict-kwargs==2026.1.12", "prek==0.2.27", + "pydocstringformatter==0.7.3", "pydocstyle==6.3", "pygments==2.19.2", "pylint[spelling]==4.0.4", @@ -274,9 +274,6 @@ spelling-private-dict-file = 'spelling_private_dict.txt' # --spelling-private-dict-file option instead of raising a message. spelling-store-unknown-words = 'no' -[tool.docformatter] -make-summary-multi-line = true - [tool.check-manifest] ignore = [ @@ -346,6 +343,10 @@ enableTypeIgnoreComments = false reportUnnecessaryTypeIgnoreComment = true typeCheckingMode = "strict" +[tool.pydocstringformatter] +write = true +split-summary-body = false + [tool.interrogate] fail-under = 100 omit-covered-files = true From e4126ee5441f4afdae41339aad26f77c04bc4638 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Mon, 12 Jan 2026 14:18:45 +0000 Subject: [PATCH 0882/1003] [pre-commit.ci lite] apply automatic fixes --- conftest.py | 8 +- docs/source/__init__.py | 4 +- docs/source/conf.py | 4 +- src/vws/__init__.py | 4 +- src/vws/exceptions/__init__.py | 4 +- src/vws/exceptions/base_exceptions.py | 12 +-- src/vws/exceptions/cloud_reco_exceptions.py | 16 +--- src/vws/exceptions/custom_exceptions.py | 20 +--- src/vws/exceptions/vws_exceptions.py | 68 ++++--------- src/vws/include_target_data.py | 4 +- src/vws/query.py | 12 +-- src/vws/reports.py | 8 +- src/vws/response.py | 8 +- src/vws/vws.py | 12 +-- tests/__init__.py | 4 +- tests/conftest.py | 24 ++--- tests/test_cloud_reco_exceptions.py | 8 +- tests/test_query.py | 40 ++------ tests/test_vws.py | 100 +++++--------------- tests/test_vws_exceptions.py | 20 +--- 20 files changed, 100 insertions(+), 280 deletions(-) diff --git a/conftest.py b/conftest.py index 1d776f8db..0e579a4db 100644 --- a/conftest.py +++ b/conftest.py @@ -1,6 +1,4 @@ -""" -Setup for Sybil. -""" +"""Setup for Sybil.""" import io import uuid @@ -21,9 +19,7 @@ def pytest_collection_modifyitems(items: list[pytest.Item]) -> None: - """ - Apply the beartype decorator to all collected test functions. - """ + """Apply the beartype decorator to all collected test functions.""" for item in items: if isinstance(item, pytest.Function): item.obj = beartype(obj=item.obj) diff --git a/docs/source/__init__.py b/docs/source/__init__.py index b63eed5fb..535ceb2ec 100644 --- a/docs/source/__init__.py +++ b/docs/source/__init__.py @@ -1,3 +1 @@ -""" -Documentation. -""" +"""Documentation.""" diff --git a/docs/source/conf.py b/docs/source/conf.py index 914bcb886..920ba1a4b 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -1,7 +1,5 @@ #!/usr/bin/env python3 -""" -Configuration for Sphinx. -""" +"""Configuration for Sphinx.""" import importlib.metadata from pathlib import Path diff --git a/src/vws/__init__.py b/src/vws/__init__.py index 42788b92d..bfd96d6c2 100644 --- a/src/vws/__init__.py +++ b/src/vws/__init__.py @@ -1,6 +1,4 @@ -""" -A library for Vuforia Web Services. -""" +"""A library for Vuforia Web Services.""" from .query import CloudRecoService from .vws import VWS diff --git a/src/vws/exceptions/__init__.py b/src/vws/exceptions/__init__.py index a1e3cd91c..7260ffdbb 100644 --- a/src/vws/exceptions/__init__.py +++ b/src/vws/exceptions/__init__.py @@ -1,3 +1 @@ -""" -Custom exceptions raised by this package. -""" +"""Custom exceptions raised by this package.""" diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index 943323bfd..c86080593 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -10,9 +10,7 @@ @beartype class CloudRecoError(Exception): - """ - Base class for Vuforia Cloud Recognition Web API exceptions. - """ + """Base class for Vuforia Cloud Recognition Web API exceptions.""" def __init__(self, response: Response) -> None: """ @@ -24,9 +22,7 @@ def __init__(self, response: Response) -> None: @property def response(self) -> Response: - """ - The response returned by Vuforia which included this error. - """ + """The response returned by Vuforia which included this error.""" return self._response @@ -48,7 +44,5 @@ def __init__(self, response: Response) -> None: @property def response(self) -> Response: - """ - The response returned by Vuforia which included this error. - """ + """The response returned by Vuforia which included this error.""" return self._response diff --git a/src/vws/exceptions/cloud_reco_exceptions.py b/src/vws/exceptions/cloud_reco_exceptions.py index ff5dde209..2b20a7220 100644 --- a/src/vws/exceptions/cloud_reco_exceptions.py +++ b/src/vws/exceptions/cloud_reco_exceptions.py @@ -1,6 +1,4 @@ -""" -Exceptions which match errors raised by the Vuforia Cloud Recognition Web APIs. -""" +"""Exceptions which match errors raised by the Vuforia Cloud Recognition Web APIs.""" from beartype import beartype @@ -17,31 +15,27 @@ class MaxNumResultsOutOfRangeError(CloudRecoError): @beartype class InactiveProjectError(CloudRecoError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'InactiveProject'. """ @beartype class BadImageError(CloudRecoError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'BadImage'. """ @beartype class AuthenticationFailureError(CloudRecoError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'AuthenticationFailure'. """ @beartype class RequestTimeTooSkewedError(CloudRecoError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'RequestTimeTooSkewed'. """ diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index 694e98c30..466dfd1cd 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -11,9 +11,7 @@ @beartype class RequestEntityTooLargeError(Exception): - """ - Exception raised when the given image is too large. - """ + """Exception raised when the given image is too large.""" def __init__(self, response: Response) -> None: """ @@ -25,24 +23,18 @@ def __init__(self, response: Response) -> None: @property def response(self) -> Response: - """ - The response returned by Vuforia which included this error. - """ + """The response returned by Vuforia which included this error.""" return self._response @beartype class TargetProcessingTimeoutError(Exception): - """ - Exception raised when waiting for a target to be processed times out. - """ + """Exception raised when waiting for a target to be processed times out.""" @beartype class ServerError(Exception): # pragma: no cover - """ - Exception raised when VWS returns a server error. - """ + """Exception raised when VWS returns a server error.""" def __init__(self, response: Response) -> None: """ @@ -54,7 +46,5 @@ def __init__(self, response: Response) -> None: @property def response(self) -> Response: - """ - The response returned by Vuforia which included this error. - """ + """The response returned by Vuforia which included this error.""" return self._response diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index 482223766..a25c2261b 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -14,16 +14,13 @@ @beartype class UnknownTargetError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'UnknownTarget'. """ @property def target_id(self) -> str: - """ - The unknown target ID. - """ + """The unknown target ID.""" path = urlparse(url=self.response.url).path # Every HTTP path which can raise this error is in the format # `/something/{target_id}`. @@ -32,23 +29,19 @@ def target_id(self) -> str: @beartype class FailError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code 'Fail'. - """ + """Exception raised when Vuforia returns a response with a result code 'Fail'.""" @beartype class BadImageError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'BadImage'. """ @beartype class AuthenticationFailureError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'AuthenticationFailure'. """ @@ -56,24 +49,20 @@ class AuthenticationFailureError(VWSError): # See https://github.com/VWS-Python/vws-python/issues/822. @beartype class RequestQuotaReachedError(VWSError): # pragma: no cover - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'RequestQuotaReached'. """ @beartype class TargetStatusProcessingError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'TargetStatusProcessing'. """ @property def target_id(self) -> str: - """ - The processing target ID. - """ + """The processing target ID.""" path = urlparse(url=self.response.url).path # Every HTTP path which can raise this error is in the format # `/something/{target_id}`. @@ -83,8 +72,7 @@ def target_id(self) -> str: # This is not simulated by the mock. @beartype class DateRangeError(VWSError): # pragma: no cover - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'DateRangeError'. """ @@ -92,8 +80,7 @@ class DateRangeError(VWSError): # pragma: no cover # This is not simulated by the mock. @beartype class TargetQuotaReachedError(VWSError): # pragma: no cover - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'TargetQuotaReached'. """ @@ -101,8 +88,7 @@ class TargetQuotaReachedError(VWSError): # pragma: no cover # This is not simulated by the mock. @beartype class ProjectSuspendedError(VWSError): # pragma: no cover - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'ProjectSuspended'. """ @@ -110,48 +96,41 @@ class ProjectSuspendedError(VWSError): # pragma: no cover # This is not simulated by the mock. @beartype class ProjectHasNoAPIAccessError(VWSError): # pragma: no cover - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'ProjectHasNoAPIAccess'. """ @beartype class ProjectInactiveError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'ProjectInactive'. """ @beartype class MetadataTooLargeError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'MetadataTooLarge'. """ @beartype class RequestTimeTooSkewedError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'RequestTimeTooSkewed'. """ @beartype class TargetNameExistError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'TargetNameExist'. """ @property def target_name(self) -> str: - """ - The target name which already exists. - """ + """The target name which already exists.""" response_body = self.response.request_body or b"" request_json = json.loads(s=response_body) return str(object=request_json["name"]) @@ -159,24 +138,20 @@ def target_name(self) -> str: @beartype class ImageTooLargeError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'ImageTooLarge'. """ @beartype class TargetStatusNotSuccessError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'TargetStatusNotSuccess'. """ @property def target_id(self) -> str: - """ - The unknown target ID. - """ + """The unknown target ID.""" path = urlparse(url=self.response.url).path # Every HTTP path which can raise this error is in the format # `/something/{target_id}`. @@ -185,7 +160,6 @@ def target_id(self) -> str: @beartype class TooManyRequestsError(VWSError): # pragma: no cover - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'TooManyRequests'. """ diff --git a/src/vws/include_target_data.py b/src/vws/include_target_data.py index 37682e08a..0692a1e40 100644 --- a/src/vws/include_target_data.py +++ b/src/vws/include_target_data.py @@ -1,6 +1,4 @@ -""" -Tools for managing ``CloudRecoService.query``'s ``include_target_data``. -""" +"""Tools for managing ``CloudRecoService.query``'s ``include_target_data``.""" from enum import StrEnum, auto, unique diff --git a/src/vws/query.py b/src/vws/query.py index 96122aa14..ab449c614 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -1,6 +1,4 @@ -""" -Tools for interacting with the Vuforia Cloud Recognition Web APIs. -""" +"""Tools for interacting with the Vuforia Cloud Recognition Web APIs.""" import datetime import io @@ -34,9 +32,7 @@ @beartype def _get_image_data(image: _ImageType) -> bytes: - """ - Get the data of an image file. - """ + """Get the data of an image file.""" original_tell = image.tell() image.seek(0) image_data = image.read() @@ -46,9 +42,7 @@ def _get_image_data(image: _ImageType) -> bytes: @beartype class CloudRecoService: - """ - An interface to the Vuforia Cloud Recognition Web APIs. - """ + """An interface to the Vuforia Cloud Recognition Web APIs.""" def __init__( self, diff --git a/src/vws/reports.py b/src/vws/reports.py index f6a77133c..e59408aad 100644 --- a/src/vws/reports.py +++ b/src/vws/reports.py @@ -1,6 +1,4 @@ -""" -Classes for representing Vuforia reports. -""" +"""Classes for representing Vuforia reports.""" import datetime from dataclasses import dataclass @@ -86,9 +84,7 @@ class TargetRecord: @beartype @dataclass(frozen=True) class TargetData: - """ - The target data optionally included with a query match. - """ + """The target data optionally included with a query match.""" name: str application_metadata: str | None diff --git a/src/vws/response.py b/src/vws/response.py index 269f2e23f..e2060cb9e 100644 --- a/src/vws/response.py +++ b/src/vws/response.py @@ -1,6 +1,4 @@ -""" -Responses for requests to VWS and VWQ. -""" +"""Responses for requests to VWS and VWQ.""" from dataclasses import dataclass @@ -10,9 +8,7 @@ @dataclass(frozen=True) @beartype class Response: - """ - A response from a request. - """ + """A response from a request.""" text: str url: str diff --git a/src/vws/vws.py b/src/vws/vws.py index 8def19ed7..1191ee7df 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -1,6 +1,4 @@ -""" -Tools for interacting with Vuforia APIs. -""" +"""Tools for interacting with Vuforia APIs.""" import base64 import io @@ -52,9 +50,7 @@ @beartype def _get_image_data(image: _ImageType) -> bytes: - """ - Get the data of an image file. - """ + """Get the data of an image file.""" original_tell = image.tell() image.seek(0) image_data = image.read() @@ -131,9 +127,7 @@ def _target_api_request( @beartype(conf=BeartypeConf(is_pep484_tower=True)) class VWS: - """ - An interface to Vuforia Web Services APIs. - """ + """An interface to Vuforia Web Services APIs.""" def __init__( self, diff --git a/tests/__init__.py b/tests/__init__.py index c7e38a862..3502d86d5 100644 --- a/tests/__init__.py +++ b/tests/__init__.py @@ -1,3 +1 @@ -""" -Tests for ``vws``. -""" +"""Tests for ``vws``.""" diff --git a/tests/conftest.py b/tests/conftest.py index 74c6fc56d..7c0647786 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -1,6 +1,4 @@ -""" -Configuration, plugins and fixtures for `pytest`. -""" +"""Configuration, plugins and fixtures for `pytest`.""" import io from collections.abc import Generator @@ -16,9 +14,7 @@ @pytest.fixture(name="_mock_database") def fixture_mock_database() -> Generator[VuforiaDatabase]: - """ - Yield a mock ``VuforiaDatabase``. - """ + """Yield a mock ``VuforiaDatabase``.""" # We use a low processing time so that tests run quickly. with MockVWS(processing_time_seconds=0.2) as mock: database = VuforiaDatabase() @@ -28,9 +24,7 @@ def fixture_mock_database() -> Generator[VuforiaDatabase]: @pytest.fixture def vws_client(_mock_database: VuforiaDatabase) -> VWS: - """ - A VWS client which connects to a mock database. - """ + """A VWS client which connects to a mock database.""" return VWS( server_access_key=_mock_database.server_access_key, server_secret_key=_mock_database.server_secret_key, @@ -39,9 +33,7 @@ def vws_client(_mock_database: VuforiaDatabase) -> VWS: @pytest.fixture def cloud_reco_client(_mock_database: VuforiaDatabase) -> CloudRecoService: - """ - A ``CloudRecoService`` client which connects to a mock database. - """ + """A ``CloudRecoService`` client which connects to a mock database.""" return CloudRecoService( client_access_key=_mock_database.client_access_key, client_secret_key=_mock_database.client_secret_key, @@ -54,9 +46,7 @@ def fixture_image_file( tmp_path: Path, request: pytest.FixtureRequest, ) -> Generator[BinaryIO]: - """ - An image file object. - """ + """An image file object.""" file = tmp_path / "image.jpg" buffer = high_quality_image.getvalue() file.write_bytes(data=buffer) @@ -71,9 +61,7 @@ def image( high_quality_image: io.BytesIO, image_file: BinaryIO, ) -> io.BytesIO | BinaryIO: - """ - An image in any of the types that the API accepts. - """ + """An image in any of the types that the API accepts.""" if request.param == "high_quality_image": return high_quality_image return image_file diff --git a/tests/test_cloud_reco_exceptions.py b/tests/test_cloud_reco_exceptions.py index 3515b0d22..d4c8cb0f7 100644 --- a/tests/test_cloud_reco_exceptions.py +++ b/tests/test_cloud_reco_exceptions.py @@ -1,6 +1,4 @@ -""" -Tests for exceptions raised when using the CloudRecoService. -""" +"""Tests for exceptions raised when using the CloudRecoService.""" import io import uuid @@ -63,9 +61,7 @@ def test_image_too_large( def test_cloudrecoexception_inheritance() -> None: - """ - CloudRecoService-specific exceptions inherit from CloudRecoException. - """ + """CloudRecoService-specific exceptions inherit from CloudRecoException.""" subclasses = [ MaxNumResultsOutOfRangeError, InactiveProjectError, diff --git a/tests/test_query.py b/tests/test_query.py index e229cf95d..11b803eb5 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -1,6 +1,4 @@ -""" -Tests for the ``CloudRecoService`` querying functionality. -""" +"""Tests for the ``CloudRecoService`` querying functionality.""" import io import uuid @@ -14,18 +12,14 @@ class TestQuery: - """ - Tests for making image queries. - """ + """Tests for making image queries.""" @staticmethod def test_no_matches( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """ - An empty list is returned if there are no matches. - """ + """An empty list is returned if there are no matches.""" result = cloud_reco_client.query(image=image) assert result == [] @@ -35,9 +29,7 @@ def test_match( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """ - Details of matching targets are returned. - """ + """Details of matching targets are returned.""" target_id = vws_client.add_target( name="x", width=1, @@ -51,9 +43,7 @@ def test_match( class TestCustomBaseVWQURL: - """ - Tests for using a custom base VWQ URL. - """ + """Tests for using a custom base VWQ URL.""" @staticmethod def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: @@ -93,9 +83,7 @@ def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: class TestMaxNumResults: - """ - Tests for the ``max_num_results`` parameter of ``query``. - """ + """Tests for the ``max_num_results`` parameter of ``query``.""" @staticmethod def test_default( @@ -103,9 +91,7 @@ def test_default( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """ - By default the maximum number of results is 1. - """ + """By default the maximum number of results is 1.""" target_id = vws_client.add_target( name=uuid.uuid4().hex, width=1, @@ -131,9 +117,7 @@ def test_custom( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """ - It is possible to set a custom ``max_num_results``. - """ + """It is possible to set a custom ``max_num_results``.""" target_id = vws_client.add_target( name=uuid.uuid4().hex, width=1, @@ -167,9 +151,7 @@ def test_custom( class TestIncludeTargetData: - """ - Tests for the ``include_target_data`` parameter of ``query``. - """ + """Tests for the ``include_target_data`` parameter of ``query``.""" @staticmethod def test_default( @@ -177,9 +159,7 @@ def test_default( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """ - By default, target data is only returned in the top match. - """ + """By default, target data is only returned in the top match.""" target_id = vws_client.add_target( name=uuid.uuid4().hex, width=1, diff --git a/tests/test_vws.py b/tests/test_vws.py index e16eff555..d427e1c9b 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -1,6 +1,4 @@ -""" -Tests for helper functions for managing a Vuforia database. -""" +"""Tests for helper functions for managing a Vuforia database.""" import base64 import datetime @@ -25,9 +23,7 @@ class TestAddTarget: - """ - Tests for adding a target. - """ + """Tests for adding a target.""" @staticmethod @pytest.mark.parametrize( @@ -43,9 +39,7 @@ def test_add_target( *, active_flag: bool, ) -> None: - """ - No exception is raised when adding one target. - """ + """No exception is raised when adding one target.""" name = "x" width = 1 if application_metadata is None: @@ -98,9 +92,7 @@ def test_add_two_targets( class TestCustomBaseVWSURL: - """ - Tests for using a custom base VWS URL. - """ + """Tests for using a custom base VWS URL.""" @staticmethod def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: @@ -128,18 +120,14 @@ def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: class TestListTargets: - """ - Tests for listing targets. - """ + """Tests for listing targets.""" @staticmethod def test_list_targets( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - It is possible to get a list of target IDs. - """ + """It is possible to get a list of target IDs.""" id_1 = vws_client.add_target( name="x", width=1, @@ -158,18 +146,14 @@ def test_list_targets( class TestDelete: - """ - Test for deleting a target. - """ + """Test for deleting a target.""" @staticmethod def test_delete_target( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - It is possible to delete a target. - """ + """It is possible to delete a target.""" target_id = vws_client.add_target( name="x", width=1, @@ -185,18 +169,14 @@ def test_delete_target( class TestGetTargetSummaryReport: - """ - Tests for getting a summary report for a target. - """ + """Tests for getting a summary report for a target.""" @staticmethod def test_get_target_summary_report( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - Details of a target are returned by ``get_target_summary_report``. - """ + """Details of a target are returned by ``get_target_summary_report``.""" date = "2018-04-25" target_name = uuid.uuid4().hex with freeze_time(time_to_freeze=date): @@ -240,15 +220,11 @@ def test_get_target_summary_report( class TestGetDatabaseSummaryReport: - """ - Tests for getting a summary report for a database. - """ + """Tests for getting a summary report for a database.""" @staticmethod def test_get_target(vws_client: VWS) -> None: - """ - Details of a database are returned by ``get_database_summary_report``. - """ + """Details of a database are returned by ``get_database_summary_report``.""" report = vws_client.get_database_summary_report() expected_report = DatabaseSummaryReport( @@ -287,18 +263,14 @@ def test_get_target(vws_client: VWS) -> None: class TestGetTargetRecord: - """ - Tests for getting a record of a target. - """ + """Tests for getting a record of a target.""" @staticmethod def test_get_target_record( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - Details of a target are returned by ``get_target_record``. - """ + """Details of a target are returned by ``get_target_record``.""" target_id = vws_client.add_target( name="x", width=1, @@ -344,9 +316,7 @@ def test_get_failed( vws_client: VWS, image_file_failed_state: io.BytesIO, ) -> None: - """ - Check that the report works with a failed target. - """ + """Check that the report works with a failed target.""" target_id = vws_client.add_target( name="x", width=1, @@ -362,18 +332,14 @@ def test_get_failed( class TestWaitForTargetProcessed: - """ - Tests for waiting for a target to be processed. - """ + """Tests for waiting for a target to be processed.""" @staticmethod def test_wait_for_target_processed( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - It is possible to wait until a target is processed. - """ + """It is possible to wait until a target is processed.""" target_id = vws_client.add_target( name="x", width=1, @@ -391,9 +357,7 @@ def test_wait_for_target_processed( def test_default_seconds_between_requests( image: io.BytesIO | BinaryIO, ) -> None: - """ - By default, 0.2 seconds are waited between polling requests. - """ + """By default, 0.2 seconds are waited between polling requests.""" with MockVWS(processing_time_seconds=0.5) as mock: database = VuforiaDatabase() mock.add_database(database=database) @@ -443,9 +407,7 @@ def test_default_seconds_between_requests( def test_custom_seconds_between_requests( image: io.BytesIO | BinaryIO, ) -> None: - """ - It is possible to customize the time waited between polling requests. - """ + """It is possible to customize the time waited between polling requests.""" with MockVWS(processing_time_seconds=0.5) as mock: database = VuforiaDatabase() mock.add_database(database=database) @@ -493,9 +455,7 @@ def test_custom_seconds_between_requests( @staticmethod def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: - """ - It is possible to set a maximum timeout. - """ + """It is possible to set a maximum timeout.""" with MockVWS(processing_time_seconds=0.5) as mock: database = VuforiaDatabase() mock.add_database(database=database) @@ -531,18 +491,14 @@ def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: class TestGetDuplicateTargets: - """ - Tests for getting duplicate targets. - """ + """Tests for getting duplicate targets.""" @staticmethod def test_get_duplicate_targets( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - It is possible to get the IDs of similar targets. - """ + """It is possible to get the IDs of similar targets.""" target_id = vws_client.add_target( name="x", width=1, @@ -565,9 +521,7 @@ def test_get_duplicate_targets( class TestUpdateTarget: - """ - Tests for updating a target. - """ + """Tests for updating a target.""" @staticmethod def test_update_target( @@ -576,9 +530,7 @@ def test_update_target( different_high_quality_image: io.BytesIO, cloud_reco_client: CloudRecoService, ) -> None: - """ - It is possible to update a target. - """ + """It is possible to update a target.""" old_name = uuid.uuid4().hex old_width = secrets.choice(seq=range(1, 5000)) / 100 target_id = vws_client.add_target( @@ -635,9 +587,7 @@ def test_no_fields_given( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - It is possible to give no update fields. - """ + """It is possible to give no update fields.""" target_id = vws_client.add_target( name="x", width=1, diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 86da66040..eb5b12a6f 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -1,6 +1,4 @@ -""" -Tests for VWS exceptions. -""" +"""Tests for VWS exceptions.""" import io import uuid @@ -98,9 +96,7 @@ def test_request_quota_reached() -> None: def test_fail(high_quality_image: io.BytesIO) -> None: - """ - A ``Fail`` exception is raised when the server access key does not exist. - """ + """A ``Fail`` exception is raised when the server access key does not exist.""" with MockVWS(): vws_client = VWS( server_access_key=uuid.uuid4().hex, @@ -120,9 +116,7 @@ def test_fail(high_quality_image: io.BytesIO) -> None: def test_bad_image(vws_client: VWS) -> None: - """ - A ``BadImage`` exception is raised when a non-image is given. - """ + """A ``BadImage`` exception is raised when a non-image is given.""" not_an_image = io.BytesIO(initial_bytes=b"Not an image") with pytest.raises(expected_exception=BadImageError) as exc: vws_client.add_target( @@ -325,9 +319,7 @@ def test_target_status_not_success( def test_vwsexception_inheritance() -> None: - """ - VWS-related exceptions should inherit from VWSException. - """ + """VWS-related exceptions should inherit from VWSException.""" subclasses = [ AuthenticationFailureError, BadImageError, @@ -354,9 +346,7 @@ def test_base_exception( vws_client: VWS, high_quality_image: io.BytesIO, ) -> None: - """ - ``VWSException``s has a response property. - """ + """``VWSException``s has a response property.""" with pytest.raises(expected_exception=VWSError) as exc: vws_client.get_target_record(target_id="a") From b57ba660dc68b9c917b91fe720d5bd223280745d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 12 Jan 2026 14:23:57 +0000 Subject: [PATCH 0883/1003] Configure pydocstringformatter to make minimal changes --- pyproject.toml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index d4a6cbd29..f83bea5bb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -346,6 +346,8 @@ typeCheckingMode = "strict" [tool.pydocstringformatter] write = true split-summary-body = false +beginning-quotes = false +closing-quotes = false [tool.interrogate] fail-under = 100 From 6c82f4a9543f22170b369090744d872742ae8630 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 12 Jan 2026 14:24:43 +0000 Subject: [PATCH 0884/1003] Switch from pydocstringformatter --- conftest.py | 8 +- docs/source/__init__.py | 4 +- docs/source/conf.py | 4 +- pyproject.toml | 2 - src/vws/__init__.py | 4 +- src/vws/exceptions/__init__.py | 4 +- src/vws/exceptions/base_exceptions.py | 12 ++- src/vws/exceptions/cloud_reco_exceptions.py | 16 +++- src/vws/exceptions/custom_exceptions.py | 20 +++- src/vws/exceptions/vws_exceptions.py | 68 +++++++++---- src/vws/include_target_data.py | 4 +- src/vws/query.py | 12 ++- src/vws/reports.py | 8 +- src/vws/response.py | 8 +- src/vws/vws.py | 12 ++- tests/__init__.py | 4 +- tests/conftest.py | 24 +++-- tests/test_cloud_reco_exceptions.py | 8 +- tests/test_query.py | 40 ++++++-- tests/test_vws.py | 100 +++++++++++++++----- tests/test_vws_exceptions.py | 20 +++- 21 files changed, 280 insertions(+), 102 deletions(-) diff --git a/conftest.py b/conftest.py index 0e579a4db..1d776f8db 100644 --- a/conftest.py +++ b/conftest.py @@ -1,4 +1,6 @@ -"""Setup for Sybil.""" +""" +Setup for Sybil. +""" import io import uuid @@ -19,7 +21,9 @@ def pytest_collection_modifyitems(items: list[pytest.Item]) -> None: - """Apply the beartype decorator to all collected test functions.""" + """ + Apply the beartype decorator to all collected test functions. + """ for item in items: if isinstance(item, pytest.Function): item.obj = beartype(obj=item.obj) diff --git a/docs/source/__init__.py b/docs/source/__init__.py index 535ceb2ec..b63eed5fb 100644 --- a/docs/source/__init__.py +++ b/docs/source/__init__.py @@ -1 +1,3 @@ -"""Documentation.""" +""" +Documentation. +""" diff --git a/docs/source/conf.py b/docs/source/conf.py index 920ba1a4b..914bcb886 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -1,5 +1,7 @@ #!/usr/bin/env python3 -"""Configuration for Sphinx.""" +""" +Configuration for Sphinx. +""" import importlib.metadata from pathlib import Path diff --git a/pyproject.toml b/pyproject.toml index f83bea5bb..d4a6cbd29 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -346,8 +346,6 @@ typeCheckingMode = "strict" [tool.pydocstringformatter] write = true split-summary-body = false -beginning-quotes = false -closing-quotes = false [tool.interrogate] fail-under = 100 diff --git a/src/vws/__init__.py b/src/vws/__init__.py index bfd96d6c2..42788b92d 100644 --- a/src/vws/__init__.py +++ b/src/vws/__init__.py @@ -1,4 +1,6 @@ -"""A library for Vuforia Web Services.""" +""" +A library for Vuforia Web Services. +""" from .query import CloudRecoService from .vws import VWS diff --git a/src/vws/exceptions/__init__.py b/src/vws/exceptions/__init__.py index 7260ffdbb..a1e3cd91c 100644 --- a/src/vws/exceptions/__init__.py +++ b/src/vws/exceptions/__init__.py @@ -1 +1,3 @@ -"""Custom exceptions raised by this package.""" +""" +Custom exceptions raised by this package. +""" diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index c86080593..943323bfd 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -10,7 +10,9 @@ @beartype class CloudRecoError(Exception): - """Base class for Vuforia Cloud Recognition Web API exceptions.""" + """ + Base class for Vuforia Cloud Recognition Web API exceptions. + """ def __init__(self, response: Response) -> None: """ @@ -22,7 +24,9 @@ def __init__(self, response: Response) -> None: @property def response(self) -> Response: - """The response returned by Vuforia which included this error.""" + """ + The response returned by Vuforia which included this error. + """ return self._response @@ -44,5 +48,7 @@ def __init__(self, response: Response) -> None: @property def response(self) -> Response: - """The response returned by Vuforia which included this error.""" + """ + The response returned by Vuforia which included this error. + """ return self._response diff --git a/src/vws/exceptions/cloud_reco_exceptions.py b/src/vws/exceptions/cloud_reco_exceptions.py index 2b20a7220..ff5dde209 100644 --- a/src/vws/exceptions/cloud_reco_exceptions.py +++ b/src/vws/exceptions/cloud_reco_exceptions.py @@ -1,4 +1,6 @@ -"""Exceptions which match errors raised by the Vuforia Cloud Recognition Web APIs.""" +""" +Exceptions which match errors raised by the Vuforia Cloud Recognition Web APIs. +""" from beartype import beartype @@ -15,27 +17,31 @@ class MaxNumResultsOutOfRangeError(CloudRecoError): @beartype class InactiveProjectError(CloudRecoError): - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'InactiveProject'. """ @beartype class BadImageError(CloudRecoError): - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'BadImage'. """ @beartype class AuthenticationFailureError(CloudRecoError): - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'AuthenticationFailure'. """ @beartype class RequestTimeTooSkewedError(CloudRecoError): - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'RequestTimeTooSkewed'. """ diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index 466dfd1cd..694e98c30 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -11,7 +11,9 @@ @beartype class RequestEntityTooLargeError(Exception): - """Exception raised when the given image is too large.""" + """ + Exception raised when the given image is too large. + """ def __init__(self, response: Response) -> None: """ @@ -23,18 +25,24 @@ def __init__(self, response: Response) -> None: @property def response(self) -> Response: - """The response returned by Vuforia which included this error.""" + """ + The response returned by Vuforia which included this error. + """ return self._response @beartype class TargetProcessingTimeoutError(Exception): - """Exception raised when waiting for a target to be processed times out.""" + """ + Exception raised when waiting for a target to be processed times out. + """ @beartype class ServerError(Exception): # pragma: no cover - """Exception raised when VWS returns a server error.""" + """ + Exception raised when VWS returns a server error. + """ def __init__(self, response: Response) -> None: """ @@ -46,5 +54,7 @@ def __init__(self, response: Response) -> None: @property def response(self) -> Response: - """The response returned by Vuforia which included this error.""" + """ + The response returned by Vuforia which included this error. + """ return self._response diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index a25c2261b..482223766 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -14,13 +14,16 @@ @beartype class UnknownTargetError(VWSError): - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'UnknownTarget'. """ @property def target_id(self) -> str: - """The unknown target ID.""" + """ + The unknown target ID. + """ path = urlparse(url=self.response.url).path # Every HTTP path which can raise this error is in the format # `/something/{target_id}`. @@ -29,19 +32,23 @@ def target_id(self) -> str: @beartype class FailError(VWSError): - """Exception raised when Vuforia returns a response with a result code 'Fail'.""" + """ + Exception raised when Vuforia returns a response with a result code 'Fail'. + """ @beartype class BadImageError(VWSError): - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'BadImage'. """ @beartype class AuthenticationFailureError(VWSError): - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'AuthenticationFailure'. """ @@ -49,20 +56,24 @@ class AuthenticationFailureError(VWSError): # See https://github.com/VWS-Python/vws-python/issues/822. @beartype class RequestQuotaReachedError(VWSError): # pragma: no cover - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'RequestQuotaReached'. """ @beartype class TargetStatusProcessingError(VWSError): - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'TargetStatusProcessing'. """ @property def target_id(self) -> str: - """The processing target ID.""" + """ + The processing target ID. + """ path = urlparse(url=self.response.url).path # Every HTTP path which can raise this error is in the format # `/something/{target_id}`. @@ -72,7 +83,8 @@ def target_id(self) -> str: # This is not simulated by the mock. @beartype class DateRangeError(VWSError): # pragma: no cover - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'DateRangeError'. """ @@ -80,7 +92,8 @@ class DateRangeError(VWSError): # pragma: no cover # This is not simulated by the mock. @beartype class TargetQuotaReachedError(VWSError): # pragma: no cover - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'TargetQuotaReached'. """ @@ -88,7 +101,8 @@ class TargetQuotaReachedError(VWSError): # pragma: no cover # This is not simulated by the mock. @beartype class ProjectSuspendedError(VWSError): # pragma: no cover - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'ProjectSuspended'. """ @@ -96,41 +110,48 @@ class ProjectSuspendedError(VWSError): # pragma: no cover # This is not simulated by the mock. @beartype class ProjectHasNoAPIAccessError(VWSError): # pragma: no cover - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'ProjectHasNoAPIAccess'. """ @beartype class ProjectInactiveError(VWSError): - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'ProjectInactive'. """ @beartype class MetadataTooLargeError(VWSError): - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'MetadataTooLarge'. """ @beartype class RequestTimeTooSkewedError(VWSError): - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'RequestTimeTooSkewed'. """ @beartype class TargetNameExistError(VWSError): - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'TargetNameExist'. """ @property def target_name(self) -> str: - """The target name which already exists.""" + """ + The target name which already exists. + """ response_body = self.response.request_body or b"" request_json = json.loads(s=response_body) return str(object=request_json["name"]) @@ -138,20 +159,24 @@ def target_name(self) -> str: @beartype class ImageTooLargeError(VWSError): - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'ImageTooLarge'. """ @beartype class TargetStatusNotSuccessError(VWSError): - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'TargetStatusNotSuccess'. """ @property def target_id(self) -> str: - """The unknown target ID.""" + """ + The unknown target ID. + """ path = urlparse(url=self.response.url).path # Every HTTP path which can raise this error is in the format # `/something/{target_id}`. @@ -160,6 +185,7 @@ def target_id(self) -> str: @beartype class TooManyRequestsError(VWSError): # pragma: no cover - """Exception raised when Vuforia returns a response with a result code + """ + Exception raised when Vuforia returns a response with a result code 'TooManyRequests'. """ diff --git a/src/vws/include_target_data.py b/src/vws/include_target_data.py index 0692a1e40..37682e08a 100644 --- a/src/vws/include_target_data.py +++ b/src/vws/include_target_data.py @@ -1,4 +1,6 @@ -"""Tools for managing ``CloudRecoService.query``'s ``include_target_data``.""" +""" +Tools for managing ``CloudRecoService.query``'s ``include_target_data``. +""" from enum import StrEnum, auto, unique diff --git a/src/vws/query.py b/src/vws/query.py index ab449c614..96122aa14 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -1,4 +1,6 @@ -"""Tools for interacting with the Vuforia Cloud Recognition Web APIs.""" +""" +Tools for interacting with the Vuforia Cloud Recognition Web APIs. +""" import datetime import io @@ -32,7 +34,9 @@ @beartype def _get_image_data(image: _ImageType) -> bytes: - """Get the data of an image file.""" + """ + Get the data of an image file. + """ original_tell = image.tell() image.seek(0) image_data = image.read() @@ -42,7 +46,9 @@ def _get_image_data(image: _ImageType) -> bytes: @beartype class CloudRecoService: - """An interface to the Vuforia Cloud Recognition Web APIs.""" + """ + An interface to the Vuforia Cloud Recognition Web APIs. + """ def __init__( self, diff --git a/src/vws/reports.py b/src/vws/reports.py index e59408aad..f6a77133c 100644 --- a/src/vws/reports.py +++ b/src/vws/reports.py @@ -1,4 +1,6 @@ -"""Classes for representing Vuforia reports.""" +""" +Classes for representing Vuforia reports. +""" import datetime from dataclasses import dataclass @@ -84,7 +86,9 @@ class TargetRecord: @beartype @dataclass(frozen=True) class TargetData: - """The target data optionally included with a query match.""" + """ + The target data optionally included with a query match. + """ name: str application_metadata: str | None diff --git a/src/vws/response.py b/src/vws/response.py index e2060cb9e..269f2e23f 100644 --- a/src/vws/response.py +++ b/src/vws/response.py @@ -1,4 +1,6 @@ -"""Responses for requests to VWS and VWQ.""" +""" +Responses for requests to VWS and VWQ. +""" from dataclasses import dataclass @@ -8,7 +10,9 @@ @dataclass(frozen=True) @beartype class Response: - """A response from a request.""" + """ + A response from a request. + """ text: str url: str diff --git a/src/vws/vws.py b/src/vws/vws.py index 1191ee7df..8def19ed7 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -1,4 +1,6 @@ -"""Tools for interacting with Vuforia APIs.""" +""" +Tools for interacting with Vuforia APIs. +""" import base64 import io @@ -50,7 +52,9 @@ @beartype def _get_image_data(image: _ImageType) -> bytes: - """Get the data of an image file.""" + """ + Get the data of an image file. + """ original_tell = image.tell() image.seek(0) image_data = image.read() @@ -127,7 +131,9 @@ def _target_api_request( @beartype(conf=BeartypeConf(is_pep484_tower=True)) class VWS: - """An interface to Vuforia Web Services APIs.""" + """ + An interface to Vuforia Web Services APIs. + """ def __init__( self, diff --git a/tests/__init__.py b/tests/__init__.py index 3502d86d5..c7e38a862 100644 --- a/tests/__init__.py +++ b/tests/__init__.py @@ -1 +1,3 @@ -"""Tests for ``vws``.""" +""" +Tests for ``vws``. +""" diff --git a/tests/conftest.py b/tests/conftest.py index 7c0647786..74c6fc56d 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -1,4 +1,6 @@ -"""Configuration, plugins and fixtures for `pytest`.""" +""" +Configuration, plugins and fixtures for `pytest`. +""" import io from collections.abc import Generator @@ -14,7 +16,9 @@ @pytest.fixture(name="_mock_database") def fixture_mock_database() -> Generator[VuforiaDatabase]: - """Yield a mock ``VuforiaDatabase``.""" + """ + Yield a mock ``VuforiaDatabase``. + """ # We use a low processing time so that tests run quickly. with MockVWS(processing_time_seconds=0.2) as mock: database = VuforiaDatabase() @@ -24,7 +28,9 @@ def fixture_mock_database() -> Generator[VuforiaDatabase]: @pytest.fixture def vws_client(_mock_database: VuforiaDatabase) -> VWS: - """A VWS client which connects to a mock database.""" + """ + A VWS client which connects to a mock database. + """ return VWS( server_access_key=_mock_database.server_access_key, server_secret_key=_mock_database.server_secret_key, @@ -33,7 +39,9 @@ def vws_client(_mock_database: VuforiaDatabase) -> VWS: @pytest.fixture def cloud_reco_client(_mock_database: VuforiaDatabase) -> CloudRecoService: - """A ``CloudRecoService`` client which connects to a mock database.""" + """ + A ``CloudRecoService`` client which connects to a mock database. + """ return CloudRecoService( client_access_key=_mock_database.client_access_key, client_secret_key=_mock_database.client_secret_key, @@ -46,7 +54,9 @@ def fixture_image_file( tmp_path: Path, request: pytest.FixtureRequest, ) -> Generator[BinaryIO]: - """An image file object.""" + """ + An image file object. + """ file = tmp_path / "image.jpg" buffer = high_quality_image.getvalue() file.write_bytes(data=buffer) @@ -61,7 +71,9 @@ def image( high_quality_image: io.BytesIO, image_file: BinaryIO, ) -> io.BytesIO | BinaryIO: - """An image in any of the types that the API accepts.""" + """ + An image in any of the types that the API accepts. + """ if request.param == "high_quality_image": return high_quality_image return image_file diff --git a/tests/test_cloud_reco_exceptions.py b/tests/test_cloud_reco_exceptions.py index d4c8cb0f7..3515b0d22 100644 --- a/tests/test_cloud_reco_exceptions.py +++ b/tests/test_cloud_reco_exceptions.py @@ -1,4 +1,6 @@ -"""Tests for exceptions raised when using the CloudRecoService.""" +""" +Tests for exceptions raised when using the CloudRecoService. +""" import io import uuid @@ -61,7 +63,9 @@ def test_image_too_large( def test_cloudrecoexception_inheritance() -> None: - """CloudRecoService-specific exceptions inherit from CloudRecoException.""" + """ + CloudRecoService-specific exceptions inherit from CloudRecoException. + """ subclasses = [ MaxNumResultsOutOfRangeError, InactiveProjectError, diff --git a/tests/test_query.py b/tests/test_query.py index 11b803eb5..e229cf95d 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -1,4 +1,6 @@ -"""Tests for the ``CloudRecoService`` querying functionality.""" +""" +Tests for the ``CloudRecoService`` querying functionality. +""" import io import uuid @@ -12,14 +14,18 @@ class TestQuery: - """Tests for making image queries.""" + """ + Tests for making image queries. + """ @staticmethod def test_no_matches( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """An empty list is returned if there are no matches.""" + """ + An empty list is returned if there are no matches. + """ result = cloud_reco_client.query(image=image) assert result == [] @@ -29,7 +35,9 @@ def test_match( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """Details of matching targets are returned.""" + """ + Details of matching targets are returned. + """ target_id = vws_client.add_target( name="x", width=1, @@ -43,7 +51,9 @@ def test_match( class TestCustomBaseVWQURL: - """Tests for using a custom base VWQ URL.""" + """ + Tests for using a custom base VWQ URL. + """ @staticmethod def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: @@ -83,7 +93,9 @@ def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: class TestMaxNumResults: - """Tests for the ``max_num_results`` parameter of ``query``.""" + """ + Tests for the ``max_num_results`` parameter of ``query``. + """ @staticmethod def test_default( @@ -91,7 +103,9 @@ def test_default( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """By default the maximum number of results is 1.""" + """ + By default the maximum number of results is 1. + """ target_id = vws_client.add_target( name=uuid.uuid4().hex, width=1, @@ -117,7 +131,9 @@ def test_custom( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """It is possible to set a custom ``max_num_results``.""" + """ + It is possible to set a custom ``max_num_results``. + """ target_id = vws_client.add_target( name=uuid.uuid4().hex, width=1, @@ -151,7 +167,9 @@ def test_custom( class TestIncludeTargetData: - """Tests for the ``include_target_data`` parameter of ``query``.""" + """ + Tests for the ``include_target_data`` parameter of ``query``. + """ @staticmethod def test_default( @@ -159,7 +177,9 @@ def test_default( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """By default, target data is only returned in the top match.""" + """ + By default, target data is only returned in the top match. + """ target_id = vws_client.add_target( name=uuid.uuid4().hex, width=1, diff --git a/tests/test_vws.py b/tests/test_vws.py index d427e1c9b..e16eff555 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -1,4 +1,6 @@ -"""Tests for helper functions for managing a Vuforia database.""" +""" +Tests for helper functions for managing a Vuforia database. +""" import base64 import datetime @@ -23,7 +25,9 @@ class TestAddTarget: - """Tests for adding a target.""" + """ + Tests for adding a target. + """ @staticmethod @pytest.mark.parametrize( @@ -39,7 +43,9 @@ def test_add_target( *, active_flag: bool, ) -> None: - """No exception is raised when adding one target.""" + """ + No exception is raised when adding one target. + """ name = "x" width = 1 if application_metadata is None: @@ -92,7 +98,9 @@ def test_add_two_targets( class TestCustomBaseVWSURL: - """Tests for using a custom base VWS URL.""" + """ + Tests for using a custom base VWS URL. + """ @staticmethod def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: @@ -120,14 +128,18 @@ def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: class TestListTargets: - """Tests for listing targets.""" + """ + Tests for listing targets. + """ @staticmethod def test_list_targets( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """It is possible to get a list of target IDs.""" + """ + It is possible to get a list of target IDs. + """ id_1 = vws_client.add_target( name="x", width=1, @@ -146,14 +158,18 @@ def test_list_targets( class TestDelete: - """Test for deleting a target.""" + """ + Test for deleting a target. + """ @staticmethod def test_delete_target( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """It is possible to delete a target.""" + """ + It is possible to delete a target. + """ target_id = vws_client.add_target( name="x", width=1, @@ -169,14 +185,18 @@ def test_delete_target( class TestGetTargetSummaryReport: - """Tests for getting a summary report for a target.""" + """ + Tests for getting a summary report for a target. + """ @staticmethod def test_get_target_summary_report( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """Details of a target are returned by ``get_target_summary_report``.""" + """ + Details of a target are returned by ``get_target_summary_report``. + """ date = "2018-04-25" target_name = uuid.uuid4().hex with freeze_time(time_to_freeze=date): @@ -220,11 +240,15 @@ def test_get_target_summary_report( class TestGetDatabaseSummaryReport: - """Tests for getting a summary report for a database.""" + """ + Tests for getting a summary report for a database. + """ @staticmethod def test_get_target(vws_client: VWS) -> None: - """Details of a database are returned by ``get_database_summary_report``.""" + """ + Details of a database are returned by ``get_database_summary_report``. + """ report = vws_client.get_database_summary_report() expected_report = DatabaseSummaryReport( @@ -263,14 +287,18 @@ def test_get_target(vws_client: VWS) -> None: class TestGetTargetRecord: - """Tests for getting a record of a target.""" + """ + Tests for getting a record of a target. + """ @staticmethod def test_get_target_record( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """Details of a target are returned by ``get_target_record``.""" + """ + Details of a target are returned by ``get_target_record``. + """ target_id = vws_client.add_target( name="x", width=1, @@ -316,7 +344,9 @@ def test_get_failed( vws_client: VWS, image_file_failed_state: io.BytesIO, ) -> None: - """Check that the report works with a failed target.""" + """ + Check that the report works with a failed target. + """ target_id = vws_client.add_target( name="x", width=1, @@ -332,14 +362,18 @@ def test_get_failed( class TestWaitForTargetProcessed: - """Tests for waiting for a target to be processed.""" + """ + Tests for waiting for a target to be processed. + """ @staticmethod def test_wait_for_target_processed( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """It is possible to wait until a target is processed.""" + """ + It is possible to wait until a target is processed. + """ target_id = vws_client.add_target( name="x", width=1, @@ -357,7 +391,9 @@ def test_wait_for_target_processed( def test_default_seconds_between_requests( image: io.BytesIO | BinaryIO, ) -> None: - """By default, 0.2 seconds are waited between polling requests.""" + """ + By default, 0.2 seconds are waited between polling requests. + """ with MockVWS(processing_time_seconds=0.5) as mock: database = VuforiaDatabase() mock.add_database(database=database) @@ -407,7 +443,9 @@ def test_default_seconds_between_requests( def test_custom_seconds_between_requests( image: io.BytesIO | BinaryIO, ) -> None: - """It is possible to customize the time waited between polling requests.""" + """ + It is possible to customize the time waited between polling requests. + """ with MockVWS(processing_time_seconds=0.5) as mock: database = VuforiaDatabase() mock.add_database(database=database) @@ -455,7 +493,9 @@ def test_custom_seconds_between_requests( @staticmethod def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: - """It is possible to set a maximum timeout.""" + """ + It is possible to set a maximum timeout. + """ with MockVWS(processing_time_seconds=0.5) as mock: database = VuforiaDatabase() mock.add_database(database=database) @@ -491,14 +531,18 @@ def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: class TestGetDuplicateTargets: - """Tests for getting duplicate targets.""" + """ + Tests for getting duplicate targets. + """ @staticmethod def test_get_duplicate_targets( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """It is possible to get the IDs of similar targets.""" + """ + It is possible to get the IDs of similar targets. + """ target_id = vws_client.add_target( name="x", width=1, @@ -521,7 +565,9 @@ def test_get_duplicate_targets( class TestUpdateTarget: - """Tests for updating a target.""" + """ + Tests for updating a target. + """ @staticmethod def test_update_target( @@ -530,7 +576,9 @@ def test_update_target( different_high_quality_image: io.BytesIO, cloud_reco_client: CloudRecoService, ) -> None: - """It is possible to update a target.""" + """ + It is possible to update a target. + """ old_name = uuid.uuid4().hex old_width = secrets.choice(seq=range(1, 5000)) / 100 target_id = vws_client.add_target( @@ -587,7 +635,9 @@ def test_no_fields_given( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """It is possible to give no update fields.""" + """ + It is possible to give no update fields. + """ target_id = vws_client.add_target( name="x", width=1, diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index eb5b12a6f..86da66040 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -1,4 +1,6 @@ -"""Tests for VWS exceptions.""" +""" +Tests for VWS exceptions. +""" import io import uuid @@ -96,7 +98,9 @@ def test_request_quota_reached() -> None: def test_fail(high_quality_image: io.BytesIO) -> None: - """A ``Fail`` exception is raised when the server access key does not exist.""" + """ + A ``Fail`` exception is raised when the server access key does not exist. + """ with MockVWS(): vws_client = VWS( server_access_key=uuid.uuid4().hex, @@ -116,7 +120,9 @@ def test_fail(high_quality_image: io.BytesIO) -> None: def test_bad_image(vws_client: VWS) -> None: - """A ``BadImage`` exception is raised when a non-image is given.""" + """ + A ``BadImage`` exception is raised when a non-image is given. + """ not_an_image = io.BytesIO(initial_bytes=b"Not an image") with pytest.raises(expected_exception=BadImageError) as exc: vws_client.add_target( @@ -319,7 +325,9 @@ def test_target_status_not_success( def test_vwsexception_inheritance() -> None: - """VWS-related exceptions should inherit from VWSException.""" + """ + VWS-related exceptions should inherit from VWSException. + """ subclasses = [ AuthenticationFailureError, BadImageError, @@ -346,7 +354,9 @@ def test_base_exception( vws_client: VWS, high_quality_image: io.BytesIO, ) -> None: - """``VWSException``s has a response property.""" + """ + ``VWSException``s has a response property. + """ with pytest.raises(expected_exception=VWSError) as exc: vws_client.get_target_record(target_id="a") From 848686798b4cd9b7617d973b77ef25fbdc69c10a Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Mon, 12 Jan 2026 14:27:40 +0000 Subject: [PATCH 0885/1003] [pre-commit.ci lite] apply automatic fixes --- conftest.py | 8 +- docs/source/__init__.py | 4 +- docs/source/conf.py | 4 +- src/vws/__init__.py | 4 +- src/vws/exceptions/__init__.py | 4 +- src/vws/exceptions/base_exceptions.py | 12 +-- src/vws/exceptions/cloud_reco_exceptions.py | 16 +--- src/vws/exceptions/custom_exceptions.py | 20 +--- src/vws/exceptions/vws_exceptions.py | 68 ++++--------- src/vws/include_target_data.py | 4 +- src/vws/query.py | 12 +-- src/vws/reports.py | 8 +- src/vws/response.py | 8 +- src/vws/vws.py | 12 +-- tests/__init__.py | 4 +- tests/conftest.py | 24 ++--- tests/test_cloud_reco_exceptions.py | 8 +- tests/test_query.py | 40 ++------ tests/test_vws.py | 100 +++++--------------- tests/test_vws_exceptions.py | 20 +--- 20 files changed, 100 insertions(+), 280 deletions(-) diff --git a/conftest.py b/conftest.py index 1d776f8db..0e579a4db 100644 --- a/conftest.py +++ b/conftest.py @@ -1,6 +1,4 @@ -""" -Setup for Sybil. -""" +"""Setup for Sybil.""" import io import uuid @@ -21,9 +19,7 @@ def pytest_collection_modifyitems(items: list[pytest.Item]) -> None: - """ - Apply the beartype decorator to all collected test functions. - """ + """Apply the beartype decorator to all collected test functions.""" for item in items: if isinstance(item, pytest.Function): item.obj = beartype(obj=item.obj) diff --git a/docs/source/__init__.py b/docs/source/__init__.py index b63eed5fb..535ceb2ec 100644 --- a/docs/source/__init__.py +++ b/docs/source/__init__.py @@ -1,3 +1 @@ -""" -Documentation. -""" +"""Documentation.""" diff --git a/docs/source/conf.py b/docs/source/conf.py index 914bcb886..920ba1a4b 100755 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -1,7 +1,5 @@ #!/usr/bin/env python3 -""" -Configuration for Sphinx. -""" +"""Configuration for Sphinx.""" import importlib.metadata from pathlib import Path diff --git a/src/vws/__init__.py b/src/vws/__init__.py index 42788b92d..bfd96d6c2 100644 --- a/src/vws/__init__.py +++ b/src/vws/__init__.py @@ -1,6 +1,4 @@ -""" -A library for Vuforia Web Services. -""" +"""A library for Vuforia Web Services.""" from .query import CloudRecoService from .vws import VWS diff --git a/src/vws/exceptions/__init__.py b/src/vws/exceptions/__init__.py index a1e3cd91c..7260ffdbb 100644 --- a/src/vws/exceptions/__init__.py +++ b/src/vws/exceptions/__init__.py @@ -1,3 +1 @@ -""" -Custom exceptions raised by this package. -""" +"""Custom exceptions raised by this package.""" diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index 943323bfd..c86080593 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -10,9 +10,7 @@ @beartype class CloudRecoError(Exception): - """ - Base class for Vuforia Cloud Recognition Web API exceptions. - """ + """Base class for Vuforia Cloud Recognition Web API exceptions.""" def __init__(self, response: Response) -> None: """ @@ -24,9 +22,7 @@ def __init__(self, response: Response) -> None: @property def response(self) -> Response: - """ - The response returned by Vuforia which included this error. - """ + """The response returned by Vuforia which included this error.""" return self._response @@ -48,7 +44,5 @@ def __init__(self, response: Response) -> None: @property def response(self) -> Response: - """ - The response returned by Vuforia which included this error. - """ + """The response returned by Vuforia which included this error.""" return self._response diff --git a/src/vws/exceptions/cloud_reco_exceptions.py b/src/vws/exceptions/cloud_reco_exceptions.py index ff5dde209..2b20a7220 100644 --- a/src/vws/exceptions/cloud_reco_exceptions.py +++ b/src/vws/exceptions/cloud_reco_exceptions.py @@ -1,6 +1,4 @@ -""" -Exceptions which match errors raised by the Vuforia Cloud Recognition Web APIs. -""" +"""Exceptions which match errors raised by the Vuforia Cloud Recognition Web APIs.""" from beartype import beartype @@ -17,31 +15,27 @@ class MaxNumResultsOutOfRangeError(CloudRecoError): @beartype class InactiveProjectError(CloudRecoError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'InactiveProject'. """ @beartype class BadImageError(CloudRecoError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'BadImage'. """ @beartype class AuthenticationFailureError(CloudRecoError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'AuthenticationFailure'. """ @beartype class RequestTimeTooSkewedError(CloudRecoError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'RequestTimeTooSkewed'. """ diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index 694e98c30..466dfd1cd 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -11,9 +11,7 @@ @beartype class RequestEntityTooLargeError(Exception): - """ - Exception raised when the given image is too large. - """ + """Exception raised when the given image is too large.""" def __init__(self, response: Response) -> None: """ @@ -25,24 +23,18 @@ def __init__(self, response: Response) -> None: @property def response(self) -> Response: - """ - The response returned by Vuforia which included this error. - """ + """The response returned by Vuforia which included this error.""" return self._response @beartype class TargetProcessingTimeoutError(Exception): - """ - Exception raised when waiting for a target to be processed times out. - """ + """Exception raised when waiting for a target to be processed times out.""" @beartype class ServerError(Exception): # pragma: no cover - """ - Exception raised when VWS returns a server error. - """ + """Exception raised when VWS returns a server error.""" def __init__(self, response: Response) -> None: """ @@ -54,7 +46,5 @@ def __init__(self, response: Response) -> None: @property def response(self) -> Response: - """ - The response returned by Vuforia which included this error. - """ + """The response returned by Vuforia which included this error.""" return self._response diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index 482223766..a25c2261b 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -14,16 +14,13 @@ @beartype class UnknownTargetError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'UnknownTarget'. """ @property def target_id(self) -> str: - """ - The unknown target ID. - """ + """The unknown target ID.""" path = urlparse(url=self.response.url).path # Every HTTP path which can raise this error is in the format # `/something/{target_id}`. @@ -32,23 +29,19 @@ def target_id(self) -> str: @beartype class FailError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code 'Fail'. - """ + """Exception raised when Vuforia returns a response with a result code 'Fail'.""" @beartype class BadImageError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'BadImage'. """ @beartype class AuthenticationFailureError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'AuthenticationFailure'. """ @@ -56,24 +49,20 @@ class AuthenticationFailureError(VWSError): # See https://github.com/VWS-Python/vws-python/issues/822. @beartype class RequestQuotaReachedError(VWSError): # pragma: no cover - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'RequestQuotaReached'. """ @beartype class TargetStatusProcessingError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'TargetStatusProcessing'. """ @property def target_id(self) -> str: - """ - The processing target ID. - """ + """The processing target ID.""" path = urlparse(url=self.response.url).path # Every HTTP path which can raise this error is in the format # `/something/{target_id}`. @@ -83,8 +72,7 @@ def target_id(self) -> str: # This is not simulated by the mock. @beartype class DateRangeError(VWSError): # pragma: no cover - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'DateRangeError'. """ @@ -92,8 +80,7 @@ class DateRangeError(VWSError): # pragma: no cover # This is not simulated by the mock. @beartype class TargetQuotaReachedError(VWSError): # pragma: no cover - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'TargetQuotaReached'. """ @@ -101,8 +88,7 @@ class TargetQuotaReachedError(VWSError): # pragma: no cover # This is not simulated by the mock. @beartype class ProjectSuspendedError(VWSError): # pragma: no cover - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'ProjectSuspended'. """ @@ -110,48 +96,41 @@ class ProjectSuspendedError(VWSError): # pragma: no cover # This is not simulated by the mock. @beartype class ProjectHasNoAPIAccessError(VWSError): # pragma: no cover - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'ProjectHasNoAPIAccess'. """ @beartype class ProjectInactiveError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'ProjectInactive'. """ @beartype class MetadataTooLargeError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'MetadataTooLarge'. """ @beartype class RequestTimeTooSkewedError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'RequestTimeTooSkewed'. """ @beartype class TargetNameExistError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'TargetNameExist'. """ @property def target_name(self) -> str: - """ - The target name which already exists. - """ + """The target name which already exists.""" response_body = self.response.request_body or b"" request_json = json.loads(s=response_body) return str(object=request_json["name"]) @@ -159,24 +138,20 @@ def target_name(self) -> str: @beartype class ImageTooLargeError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'ImageTooLarge'. """ @beartype class TargetStatusNotSuccessError(VWSError): - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'TargetStatusNotSuccess'. """ @property def target_id(self) -> str: - """ - The unknown target ID. - """ + """The unknown target ID.""" path = urlparse(url=self.response.url).path # Every HTTP path which can raise this error is in the format # `/something/{target_id}`. @@ -185,7 +160,6 @@ def target_id(self) -> str: @beartype class TooManyRequestsError(VWSError): # pragma: no cover - """ - Exception raised when Vuforia returns a response with a result code + """Exception raised when Vuforia returns a response with a result code 'TooManyRequests'. """ diff --git a/src/vws/include_target_data.py b/src/vws/include_target_data.py index 37682e08a..0692a1e40 100644 --- a/src/vws/include_target_data.py +++ b/src/vws/include_target_data.py @@ -1,6 +1,4 @@ -""" -Tools for managing ``CloudRecoService.query``'s ``include_target_data``. -""" +"""Tools for managing ``CloudRecoService.query``'s ``include_target_data``.""" from enum import StrEnum, auto, unique diff --git a/src/vws/query.py b/src/vws/query.py index 96122aa14..ab449c614 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -1,6 +1,4 @@ -""" -Tools for interacting with the Vuforia Cloud Recognition Web APIs. -""" +"""Tools for interacting with the Vuforia Cloud Recognition Web APIs.""" import datetime import io @@ -34,9 +32,7 @@ @beartype def _get_image_data(image: _ImageType) -> bytes: - """ - Get the data of an image file. - """ + """Get the data of an image file.""" original_tell = image.tell() image.seek(0) image_data = image.read() @@ -46,9 +42,7 @@ def _get_image_data(image: _ImageType) -> bytes: @beartype class CloudRecoService: - """ - An interface to the Vuforia Cloud Recognition Web APIs. - """ + """An interface to the Vuforia Cloud Recognition Web APIs.""" def __init__( self, diff --git a/src/vws/reports.py b/src/vws/reports.py index f6a77133c..e59408aad 100644 --- a/src/vws/reports.py +++ b/src/vws/reports.py @@ -1,6 +1,4 @@ -""" -Classes for representing Vuforia reports. -""" +"""Classes for representing Vuforia reports.""" import datetime from dataclasses import dataclass @@ -86,9 +84,7 @@ class TargetRecord: @beartype @dataclass(frozen=True) class TargetData: - """ - The target data optionally included with a query match. - """ + """The target data optionally included with a query match.""" name: str application_metadata: str | None diff --git a/src/vws/response.py b/src/vws/response.py index 269f2e23f..e2060cb9e 100644 --- a/src/vws/response.py +++ b/src/vws/response.py @@ -1,6 +1,4 @@ -""" -Responses for requests to VWS and VWQ. -""" +"""Responses for requests to VWS and VWQ.""" from dataclasses import dataclass @@ -10,9 +8,7 @@ @dataclass(frozen=True) @beartype class Response: - """ - A response from a request. - """ + """A response from a request.""" text: str url: str diff --git a/src/vws/vws.py b/src/vws/vws.py index 8def19ed7..1191ee7df 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -1,6 +1,4 @@ -""" -Tools for interacting with Vuforia APIs. -""" +"""Tools for interacting with Vuforia APIs.""" import base64 import io @@ -52,9 +50,7 @@ @beartype def _get_image_data(image: _ImageType) -> bytes: - """ - Get the data of an image file. - """ + """Get the data of an image file.""" original_tell = image.tell() image.seek(0) image_data = image.read() @@ -131,9 +127,7 @@ def _target_api_request( @beartype(conf=BeartypeConf(is_pep484_tower=True)) class VWS: - """ - An interface to Vuforia Web Services APIs. - """ + """An interface to Vuforia Web Services APIs.""" def __init__( self, diff --git a/tests/__init__.py b/tests/__init__.py index c7e38a862..3502d86d5 100644 --- a/tests/__init__.py +++ b/tests/__init__.py @@ -1,3 +1 @@ -""" -Tests for ``vws``. -""" +"""Tests for ``vws``.""" diff --git a/tests/conftest.py b/tests/conftest.py index 74c6fc56d..7c0647786 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -1,6 +1,4 @@ -""" -Configuration, plugins and fixtures for `pytest`. -""" +"""Configuration, plugins and fixtures for `pytest`.""" import io from collections.abc import Generator @@ -16,9 +14,7 @@ @pytest.fixture(name="_mock_database") def fixture_mock_database() -> Generator[VuforiaDatabase]: - """ - Yield a mock ``VuforiaDatabase``. - """ + """Yield a mock ``VuforiaDatabase``.""" # We use a low processing time so that tests run quickly. with MockVWS(processing_time_seconds=0.2) as mock: database = VuforiaDatabase() @@ -28,9 +24,7 @@ def fixture_mock_database() -> Generator[VuforiaDatabase]: @pytest.fixture def vws_client(_mock_database: VuforiaDatabase) -> VWS: - """ - A VWS client which connects to a mock database. - """ + """A VWS client which connects to a mock database.""" return VWS( server_access_key=_mock_database.server_access_key, server_secret_key=_mock_database.server_secret_key, @@ -39,9 +33,7 @@ def vws_client(_mock_database: VuforiaDatabase) -> VWS: @pytest.fixture def cloud_reco_client(_mock_database: VuforiaDatabase) -> CloudRecoService: - """ - A ``CloudRecoService`` client which connects to a mock database. - """ + """A ``CloudRecoService`` client which connects to a mock database.""" return CloudRecoService( client_access_key=_mock_database.client_access_key, client_secret_key=_mock_database.client_secret_key, @@ -54,9 +46,7 @@ def fixture_image_file( tmp_path: Path, request: pytest.FixtureRequest, ) -> Generator[BinaryIO]: - """ - An image file object. - """ + """An image file object.""" file = tmp_path / "image.jpg" buffer = high_quality_image.getvalue() file.write_bytes(data=buffer) @@ -71,9 +61,7 @@ def image( high_quality_image: io.BytesIO, image_file: BinaryIO, ) -> io.BytesIO | BinaryIO: - """ - An image in any of the types that the API accepts. - """ + """An image in any of the types that the API accepts.""" if request.param == "high_quality_image": return high_quality_image return image_file diff --git a/tests/test_cloud_reco_exceptions.py b/tests/test_cloud_reco_exceptions.py index 3515b0d22..d4c8cb0f7 100644 --- a/tests/test_cloud_reco_exceptions.py +++ b/tests/test_cloud_reco_exceptions.py @@ -1,6 +1,4 @@ -""" -Tests for exceptions raised when using the CloudRecoService. -""" +"""Tests for exceptions raised when using the CloudRecoService.""" import io import uuid @@ -63,9 +61,7 @@ def test_image_too_large( def test_cloudrecoexception_inheritance() -> None: - """ - CloudRecoService-specific exceptions inherit from CloudRecoException. - """ + """CloudRecoService-specific exceptions inherit from CloudRecoException.""" subclasses = [ MaxNumResultsOutOfRangeError, InactiveProjectError, diff --git a/tests/test_query.py b/tests/test_query.py index e229cf95d..11b803eb5 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -1,6 +1,4 @@ -""" -Tests for the ``CloudRecoService`` querying functionality. -""" +"""Tests for the ``CloudRecoService`` querying functionality.""" import io import uuid @@ -14,18 +12,14 @@ class TestQuery: - """ - Tests for making image queries. - """ + """Tests for making image queries.""" @staticmethod def test_no_matches( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """ - An empty list is returned if there are no matches. - """ + """An empty list is returned if there are no matches.""" result = cloud_reco_client.query(image=image) assert result == [] @@ -35,9 +29,7 @@ def test_match( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """ - Details of matching targets are returned. - """ + """Details of matching targets are returned.""" target_id = vws_client.add_target( name="x", width=1, @@ -51,9 +43,7 @@ def test_match( class TestCustomBaseVWQURL: - """ - Tests for using a custom base VWQ URL. - """ + """Tests for using a custom base VWQ URL.""" @staticmethod def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: @@ -93,9 +83,7 @@ def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: class TestMaxNumResults: - """ - Tests for the ``max_num_results`` parameter of ``query``. - """ + """Tests for the ``max_num_results`` parameter of ``query``.""" @staticmethod def test_default( @@ -103,9 +91,7 @@ def test_default( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """ - By default the maximum number of results is 1. - """ + """By default the maximum number of results is 1.""" target_id = vws_client.add_target( name=uuid.uuid4().hex, width=1, @@ -131,9 +117,7 @@ def test_custom( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """ - It is possible to set a custom ``max_num_results``. - """ + """It is possible to set a custom ``max_num_results``.""" target_id = vws_client.add_target( name=uuid.uuid4().hex, width=1, @@ -167,9 +151,7 @@ def test_custom( class TestIncludeTargetData: - """ - Tests for the ``include_target_data`` parameter of ``query``. - """ + """Tests for the ``include_target_data`` parameter of ``query``.""" @staticmethod def test_default( @@ -177,9 +159,7 @@ def test_default( cloud_reco_client: CloudRecoService, image: io.BytesIO | BinaryIO, ) -> None: - """ - By default, target data is only returned in the top match. - """ + """By default, target data is only returned in the top match.""" target_id = vws_client.add_target( name=uuid.uuid4().hex, width=1, diff --git a/tests/test_vws.py b/tests/test_vws.py index e16eff555..d427e1c9b 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -1,6 +1,4 @@ -""" -Tests for helper functions for managing a Vuforia database. -""" +"""Tests for helper functions for managing a Vuforia database.""" import base64 import datetime @@ -25,9 +23,7 @@ class TestAddTarget: - """ - Tests for adding a target. - """ + """Tests for adding a target.""" @staticmethod @pytest.mark.parametrize( @@ -43,9 +39,7 @@ def test_add_target( *, active_flag: bool, ) -> None: - """ - No exception is raised when adding one target. - """ + """No exception is raised when adding one target.""" name = "x" width = 1 if application_metadata is None: @@ -98,9 +92,7 @@ def test_add_two_targets( class TestCustomBaseVWSURL: - """ - Tests for using a custom base VWS URL. - """ + """Tests for using a custom base VWS URL.""" @staticmethod def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: @@ -128,18 +120,14 @@ def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: class TestListTargets: - """ - Tests for listing targets. - """ + """Tests for listing targets.""" @staticmethod def test_list_targets( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - It is possible to get a list of target IDs. - """ + """It is possible to get a list of target IDs.""" id_1 = vws_client.add_target( name="x", width=1, @@ -158,18 +146,14 @@ def test_list_targets( class TestDelete: - """ - Test for deleting a target. - """ + """Test for deleting a target.""" @staticmethod def test_delete_target( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - It is possible to delete a target. - """ + """It is possible to delete a target.""" target_id = vws_client.add_target( name="x", width=1, @@ -185,18 +169,14 @@ def test_delete_target( class TestGetTargetSummaryReport: - """ - Tests for getting a summary report for a target. - """ + """Tests for getting a summary report for a target.""" @staticmethod def test_get_target_summary_report( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - Details of a target are returned by ``get_target_summary_report``. - """ + """Details of a target are returned by ``get_target_summary_report``.""" date = "2018-04-25" target_name = uuid.uuid4().hex with freeze_time(time_to_freeze=date): @@ -240,15 +220,11 @@ def test_get_target_summary_report( class TestGetDatabaseSummaryReport: - """ - Tests for getting a summary report for a database. - """ + """Tests for getting a summary report for a database.""" @staticmethod def test_get_target(vws_client: VWS) -> None: - """ - Details of a database are returned by ``get_database_summary_report``. - """ + """Details of a database are returned by ``get_database_summary_report``.""" report = vws_client.get_database_summary_report() expected_report = DatabaseSummaryReport( @@ -287,18 +263,14 @@ def test_get_target(vws_client: VWS) -> None: class TestGetTargetRecord: - """ - Tests for getting a record of a target. - """ + """Tests for getting a record of a target.""" @staticmethod def test_get_target_record( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - Details of a target are returned by ``get_target_record``. - """ + """Details of a target are returned by ``get_target_record``.""" target_id = vws_client.add_target( name="x", width=1, @@ -344,9 +316,7 @@ def test_get_failed( vws_client: VWS, image_file_failed_state: io.BytesIO, ) -> None: - """ - Check that the report works with a failed target. - """ + """Check that the report works with a failed target.""" target_id = vws_client.add_target( name="x", width=1, @@ -362,18 +332,14 @@ def test_get_failed( class TestWaitForTargetProcessed: - """ - Tests for waiting for a target to be processed. - """ + """Tests for waiting for a target to be processed.""" @staticmethod def test_wait_for_target_processed( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - It is possible to wait until a target is processed. - """ + """It is possible to wait until a target is processed.""" target_id = vws_client.add_target( name="x", width=1, @@ -391,9 +357,7 @@ def test_wait_for_target_processed( def test_default_seconds_between_requests( image: io.BytesIO | BinaryIO, ) -> None: - """ - By default, 0.2 seconds are waited between polling requests. - """ + """By default, 0.2 seconds are waited between polling requests.""" with MockVWS(processing_time_seconds=0.5) as mock: database = VuforiaDatabase() mock.add_database(database=database) @@ -443,9 +407,7 @@ def test_default_seconds_between_requests( def test_custom_seconds_between_requests( image: io.BytesIO | BinaryIO, ) -> None: - """ - It is possible to customize the time waited between polling requests. - """ + """It is possible to customize the time waited between polling requests.""" with MockVWS(processing_time_seconds=0.5) as mock: database = VuforiaDatabase() mock.add_database(database=database) @@ -493,9 +455,7 @@ def test_custom_seconds_between_requests( @staticmethod def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: - """ - It is possible to set a maximum timeout. - """ + """It is possible to set a maximum timeout.""" with MockVWS(processing_time_seconds=0.5) as mock: database = VuforiaDatabase() mock.add_database(database=database) @@ -531,18 +491,14 @@ def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: class TestGetDuplicateTargets: - """ - Tests for getting duplicate targets. - """ + """Tests for getting duplicate targets.""" @staticmethod def test_get_duplicate_targets( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - It is possible to get the IDs of similar targets. - """ + """It is possible to get the IDs of similar targets.""" target_id = vws_client.add_target( name="x", width=1, @@ -565,9 +521,7 @@ def test_get_duplicate_targets( class TestUpdateTarget: - """ - Tests for updating a target. - """ + """Tests for updating a target.""" @staticmethod def test_update_target( @@ -576,9 +530,7 @@ def test_update_target( different_high_quality_image: io.BytesIO, cloud_reco_client: CloudRecoService, ) -> None: - """ - It is possible to update a target. - """ + """It is possible to update a target.""" old_name = uuid.uuid4().hex old_width = secrets.choice(seq=range(1, 5000)) / 100 target_id = vws_client.add_target( @@ -635,9 +587,7 @@ def test_no_fields_given( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """ - It is possible to give no update fields. - """ + """It is possible to give no update fields.""" target_id = vws_client.add_target( name="x", width=1, diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 86da66040..eb5b12a6f 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -1,6 +1,4 @@ -""" -Tests for VWS exceptions. -""" +"""Tests for VWS exceptions.""" import io import uuid @@ -98,9 +96,7 @@ def test_request_quota_reached() -> None: def test_fail(high_quality_image: io.BytesIO) -> None: - """ - A ``Fail`` exception is raised when the server access key does not exist. - """ + """A ``Fail`` exception is raised when the server access key does not exist.""" with MockVWS(): vws_client = VWS( server_access_key=uuid.uuid4().hex, @@ -120,9 +116,7 @@ def test_fail(high_quality_image: io.BytesIO) -> None: def test_bad_image(vws_client: VWS) -> None: - """ - A ``BadImage`` exception is raised when a non-image is given. - """ + """A ``BadImage`` exception is raised when a non-image is given.""" not_an_image = io.BytesIO(initial_bytes=b"Not an image") with pytest.raises(expected_exception=BadImageError) as exc: vws_client.add_target( @@ -325,9 +319,7 @@ def test_target_status_not_success( def test_vwsexception_inheritance() -> None: - """ - VWS-related exceptions should inherit from VWSException. - """ + """VWS-related exceptions should inherit from VWSException.""" subclasses = [ AuthenticationFailureError, BadImageError, @@ -354,9 +346,7 @@ def test_base_exception( vws_client: VWS, high_quality_image: io.BytesIO, ) -> None: - """ - ``VWSException``s has a response property. - """ + """``VWSException``s has a response property.""" with pytest.raises(expected_exception=VWSError) as exc: vws_client.get_target_record(target_id="a") From 945db40a65fdb13147c726da0a2a087654b7ae9a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 13 Jan 2026 10:47:57 +0000 Subject: [PATCH 0886/1003] Bump doccmd from 2026.1.3.2 to 2026.1.12 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2026.1.3.2 to 2026.1.12. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2026.01.03.2...2026.01.12) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2026.1.12 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3f7f5df0a..d874c44da 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2026.1.3.2", + "doccmd==2026.1.12", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.12.19", From 7478c49044f21f350c1db4ca0a1863823ce78fab Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 13 Jan 2026 10:48:08 +0000 Subject: [PATCH 0887/1003] Bump pyrefly from 0.47.0 to 0.48.0 Bumps [pyrefly](https://github.com/facebook/pyrefly) from 0.47.0 to 0.48.0. - [Release notes](https://github.com/facebook/pyrefly/releases) - [Commits](https://github.com/facebook/pyrefly/compare/0.47.0...0.48.0) --- updated-dependencies: - dependency-name: pyrefly dependency-version: 0.48.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3f7f5df0a..610bfaa4d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.11.1", - "pyrefly==0.47.0", + "pyrefly==0.48.0", "pyright==1.1.408", "pyroma==5.0.1", "pytest==9.0.2", From 9039ba75145fd1d0f17a90de71f67d1dc5300c8e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 14 Jan 2026 10:33:29 +0000 Subject: [PATCH 0888/1003] Bump prek from 0.2.27 to 0.2.28 Bumps [prek](https://github.com/j178/prek) from 0.2.27 to 0.2.28. - [Release notes](https://github.com/j178/prek/releases) - [Changelog](https://github.com/j178/prek/blob/master/CHANGELOG.md) - [Commits](https://github.com/j178/prek/compare/v0.2.27...v0.2.28) --- updated-dependencies: - dependency-name: prek dependency-version: 0.2.28 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 36d0acb22..0fbeab8f2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "interrogate==1.7.0", "mypy[faster-cache]==1.19.1", "mypy-strict-kwargs==2026.1.12", - "prek==0.2.27", + "prek==0.2.28", "pydocstyle==6.3", "pygments==2.19.2", "pylint[spelling]==4.0.4", From b17fdfd6c22125d139abc9154e9d8b490b106bd8 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 15 Jan 2026 10:33:39 +0000 Subject: [PATCH 0889/1003] Bump ty from 0.0.11 to 0.0.12 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.11 to 0.0.12. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.11...0.0.12) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.12 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0fbeab8f2..2b9f2ef24 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,7 +73,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2026.1.12", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.11", + "ty==0.0.12", "types-requests==2.32.4.20260107", "vulture==2.14", "vws-python-mock==2025.3.10.1", From 2e312c4064e509a7dcd64ea00e70a8a6687e08d1 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 16 Jan 2026 10:33:26 +0000 Subject: [PATCH 0890/1003] Bump zizmor from 1.20.0 to 1.21.0 Bumps [zizmor](https://github.com/zizmorcore/zizmor) from 1.20.0 to 1.21.0. - [Release notes](https://github.com/zizmorcore/zizmor/releases) - [Changelog](https://github.com/zizmorcore/zizmor/blob/main/docs/release-notes.md) - [Commits](https://github.com/zizmorcore/zizmor/compare/v1.20.0...v1.21.0) --- updated-dependencies: - dependency-name: zizmor dependency-version: 1.21.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2b9f2ef24..06a1d0d86 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -79,7 +79,7 @@ optional-dependencies.dev = [ "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", "yamlfix==1.19.1", - "zizmor==1.20.0", + "zizmor==1.21.0", ] optional-dependencies.release = [ "check-wheel-contents==0.6.3" ] urls.Documentation = "https://vws-python.github.io/vws-python/" From 6d3b483bd9bf2da8d6ff8ba2be1ef60f2c34f409 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 16 Jan 2026 10:33:39 +0000 Subject: [PATCH 0891/1003] Bump ruff from 0.14.11 to 0.14.13 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.11 to 0.14.13. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.14.11...0.14.13) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.14.13 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2b9f2ef24..e2b49e137 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ optional-dependencies.dev = [ "pytest==9.0.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.14.11", + "ruff==0.14.13", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From fc0837e96106557f57bc41068fac7601936a353c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 16 Jan 2026 10:33:50 +0000 Subject: [PATCH 0892/1003] Bump pyrefly from 0.48.0 to 0.48.1 Bumps [pyrefly](https://github.com/facebook/pyrefly) from 0.48.0 to 0.48.1. - [Release notes](https://github.com/facebook/pyrefly/releases) - [Commits](https://github.com/facebook/pyrefly/compare/0.48.0...0.48.1) --- updated-dependencies: - dependency-name: pyrefly dependency-version: 0.48.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2b9f2ef24..8d922aa34 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.11.1", - "pyrefly==0.48.0", + "pyrefly==0.48.1", "pyright==1.1.408", "pyroma==5.0.1", "pytest==9.0.2", From 23d947e07bfca1279087f06c81106a0dd9379f04 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 19 Jan 2026 12:03:18 +0000 Subject: [PATCH 0893/1003] Bump sphinx from 9.0.4 to 9.1.0 Bumps [sphinx](https://github.com/sphinx-doc/sphinx) from 9.0.4 to 9.1.0. - [Release notes](https://github.com/sphinx-doc/sphinx/releases) - [Changelog](https://github.com/sphinx-doc/sphinx/blob/master/CHANGES.rst) - [Commits](https://github.com/sphinx-doc/sphinx/compare/v9.0.4...v9.1.0) --- updated-dependencies: - dependency-name: sphinx dependency-version: 9.1.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6c79db287..11864b58c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -66,7 +66,7 @@ optional-dependencies.dev = [ # use it to lint shell commands in GitHub workflow files. "shellcheck-py==0.11.0.1", "shfmt-py==3.12.0.2", - "sphinx==9.0.4", + "sphinx==9.1.0", "sphinx-copybutton==0.5.2", "sphinx-lint==1.0.2", "sphinx-pyproject==0.3.0", From 4e56a7d0e7c1a23fa8c93cf5587ada8704ce58e9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 19 Jan 2026 12:03:25 +0000 Subject: [PATCH 0894/1003] Bump zizmor from 1.21.0 to 1.22.0 Bumps [zizmor](https://github.com/zizmorcore/zizmor) from 1.21.0 to 1.22.0. - [Release notes](https://github.com/zizmorcore/zizmor/releases) - [Changelog](https://github.com/zizmorcore/zizmor/blob/main/docs/release-notes.md) - [Commits](https://github.com/zizmorcore/zizmor/compare/v1.21.0...v1.22.0) --- updated-dependencies: - dependency-name: zizmor dependency-version: 1.22.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6c79db287..e092671fd 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -79,7 +79,7 @@ optional-dependencies.dev = [ "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", "yamlfix==1.19.1", - "zizmor==1.21.0", + "zizmor==1.22.0", ] optional-dependencies.release = [ "check-wheel-contents==0.6.3" ] urls.Documentation = "https://vws-python.github.io/vws-python/" From 35e943c0e7d1d4215dc64ce8c979ecca29f8120a Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 19 Jan 2026 12:03:32 +0000 Subject: [PATCH 0895/1003] Bump prek from 0.2.28 to 0.2.30 Bumps [prek](https://github.com/j178/prek) from 0.2.28 to 0.2.30. - [Release notes](https://github.com/j178/prek/releases) - [Changelog](https://github.com/j178/prek/blob/master/CHANGELOG.md) - [Commits](https://github.com/j178/prek/compare/v0.2.28...v0.2.30) --- updated-dependencies: - dependency-name: prek dependency-version: 0.2.30 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6c79db287..14fcad18f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "interrogate==1.7.0", "mypy[faster-cache]==1.19.1", "mypy-strict-kwargs==2026.1.12", - "prek==0.2.28", + "prek==0.2.30", "pydocstyle==6.3", "pygments==2.19.2", "pylint[spelling]==4.0.4", From a3258f9fe66afc5c4e9dac1ef54be1638ffea95e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 19 Jan 2026 12:03:39 +0000 Subject: [PATCH 0896/1003] Bump doccmd from 2026.1.12 to 2026.1.18 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2026.1.12 to 2026.1.18. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2026.01.12...2026.01.18) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2026.1.18 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6c79db287..de7350677 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2026.1.12", + "doccmd==2026.1.18", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.12.19", From 6ea2afc8233a4c7263ec4eab5dbc2884a6b4ad82 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 19 Jan 2026 12:03:45 +0000 Subject: [PATCH 0897/1003] Bump pyrefly from 0.48.1 to 0.48.2 Bumps [pyrefly](https://github.com/facebook/pyrefly) from 0.48.1 to 0.48.2. - [Release notes](https://github.com/facebook/pyrefly/releases) - [Commits](https://github.com/facebook/pyrefly/compare/0.48.1...0.48.2) --- updated-dependencies: - dependency-name: pyrefly dependency-version: 0.48.2 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 6c79db287..a0c047b0c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.11.1", - "pyrefly==0.48.1", + "pyrefly==0.48.2", "pyright==1.1.408", "pyroma==5.0.1", "pytest==9.0.2", From 3f381a829f30a55ac2a598db8f976869db2b0b47 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 21 Jan 2026 10:33:13 +0000 Subject: [PATCH 0898/1003] Bump pyrefly from 0.48.2 to 0.49.0 Bumps [pyrefly](https://github.com/facebook/pyrefly) from 0.48.2 to 0.49.0. - [Release notes](https://github.com/facebook/pyrefly/releases) - [Commits](https://github.com/facebook/pyrefly/compare/0.48.2...0.49.0) --- updated-dependencies: - dependency-name: pyrefly dependency-version: 0.49.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d4af4571f..dac0450a4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.11.1", - "pyrefly==0.48.2", + "pyrefly==0.49.0", "pyright==1.1.408", "pyroma==5.0.1", "pytest==9.0.2", From 40b14bb7e46129662fdf68db6d7aaba68ede89bb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 22 Jan 2026 10:33:30 +0000 Subject: [PATCH 0899/1003] Bump prek from 0.2.30 to 0.3.0 Bumps [prek](https://github.com/j178/prek) from 0.2.30 to 0.3.0. - [Release notes](https://github.com/j178/prek/releases) - [Changelog](https://github.com/j178/prek/blob/master/CHANGELOG.md) - [Commits](https://github.com/j178/prek/compare/v0.2.30...v0.3.0) --- updated-dependencies: - dependency-name: prek dependency-version: 0.3.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index dac0450a4..271d191a4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "interrogate==1.7.0", "mypy[faster-cache]==1.19.1", "mypy-strict-kwargs==2026.1.12", - "prek==0.2.30", + "prek==0.3.0", "pydocstyle==6.3", "pygments==2.19.2", "pylint[spelling]==4.0.4", From 8ec4f829753f3bf977a1f5a87f1c306f538c1ff9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 22 Jan 2026 10:33:38 +0000 Subject: [PATCH 0900/1003] Bump ty from 0.0.12 to 0.0.13 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.12 to 0.0.13. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.12...0.0.13) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.13 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index dac0450a4..c9cf18b4e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -73,7 +73,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2026.1.12", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.12", + "ty==0.0.13", "types-requests==2.32.4.20260107", "vulture==2.14", "vws-python-mock==2025.3.10.1", From 46b0a4fc0263ebabd584e1daaa9d9a3281a46f76 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 22 Jan 2026 10:33:50 +0000 Subject: [PATCH 0901/1003] Bump doccmd from 2026.1.18 to 2026.1.21.2 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2026.1.18 to 2026.1.21.2. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2026.01.18...2026.01.21.2) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2026.1.21.2 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index dac0450a4..0cedb1bf2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2026.1.18", + "doccmd==2026.1.21.2", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.12.19", From a130d1beed1315ced58d536005a8e93860102c99 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 22 Jan 2026 17:40:40 +0000 Subject: [PATCH 0902/1003] Use bash shell for Lint step to ensure early failure PowerShell does not fail on intermediate command failures by default. By using bash shell, we ensure that any failing command causes the step to fail immediately. --- .github/workflows/lint.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 0a9661f41..f4c94be57 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -34,6 +34,9 @@ jobs: cache-dependency-glob: '**/pyproject.toml' - name: Lint + # Use bash to ensure the step fails if any command fails. + # PowerShell does not fail on intermediate command failures by default. + shell: bash run: | uv run --extra=dev prek run --all-files --hook-stage pre-commit --verbose uv run --extra=dev prek run --all-files --hook-stage pre-push --verbose From 780a1b13ea766df310f037119c27237ebaaf50b6 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 23 Jan 2026 10:33:14 +0000 Subject: [PATCH 0903/1003] Bump doccmd from 2026.1.21.2 to 2026.1.22.1 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2026.1.21.2 to 2026.1.22.1. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2026.01.21.2...2026.01.22.1) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2026.1.22.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 470b5cd13..1e9cd363e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2026.1.21.2", + "doccmd==2026.1.22.1", "docformatter==1.7.7", "freezegun==1.5.5", "furo==2025.12.19", From 89f628fc9d74cdb25e42e151a3ede8c53ca57823 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 23 Jan 2026 10:33:30 +0000 Subject: [PATCH 0904/1003] Bump ruff from 0.14.13 to 0.14.14 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.13 to 0.14.14. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.14.13...0.14.14) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.14.14 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 470b5cd13..34b9c6d09 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ optional-dependencies.dev = [ "pytest==9.0.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.14.13", + "ruff==0.14.14", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 0ed9be617a157ece3114f783b3d9a5bbfbb9380b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 26 Jan 2026 09:26:34 +0000 Subject: [PATCH 0905/1003] Linewrap with pydocstringformatter --- pyproject.toml | 2 ++ src/vws/exceptions/cloud_reco_exceptions.py | 4 +++- src/vws/exceptions/custom_exceptions.py | 7 +++++-- src/vws/exceptions/vws_exceptions.py | 7 +++++-- tests/test_cloud_reco_exceptions.py | 7 +++++-- tests/test_query.py | 9 ++++++--- tests/test_vws.py | 12 +++++++++--- tests/test_vws_exceptions.py | 19 +++++++++++++------ 8 files changed, 48 insertions(+), 19 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index d4a6cbd29..3998bc1a9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -346,6 +346,8 @@ typeCheckingMode = "strict" [tool.pydocstringformatter] write = true split-summary-body = false +max-line-length = 79 +linewrap-full-docstring = true [tool.interrogate] fail-under = 100 diff --git a/src/vws/exceptions/cloud_reco_exceptions.py b/src/vws/exceptions/cloud_reco_exceptions.py index 2b20a7220..a59335f14 100644 --- a/src/vws/exceptions/cloud_reco_exceptions.py +++ b/src/vws/exceptions/cloud_reco_exceptions.py @@ -1,4 +1,6 @@ -"""Exceptions which match errors raised by the Vuforia Cloud Recognition Web APIs.""" +"""Exceptions which match errors raised by the Vuforia Cloud Recognition Web +APIs. +""" from beartype import beartype diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index 466dfd1cd..e06c20a19 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -1,6 +1,7 @@ """ Exceptions which do not map to errors at -https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#result-codes +https://developer.vuforia.com/library/web-api/cloud-targets-web-services- +api#result-codes or simple errors given by the cloud recognition service. """ @@ -29,7 +30,9 @@ def response(self) -> Response: @beartype class TargetProcessingTimeoutError(Exception): - """Exception raised when waiting for a target to be processed times out.""" + """Exception raised when waiting for a target to be processed times + out. + """ @beartype diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index a25c2261b..892f6e12f 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -1,7 +1,8 @@ """ Exception raised when Vuforia returns a response with a result code matching one of those documented at -https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#result-codes. +https://developer.vuforia.com/library/web-api/cloud-targets-web-services- +api#result-codes. """ import json @@ -29,7 +30,9 @@ def target_id(self) -> str: @beartype class FailError(VWSError): - """Exception raised when Vuforia returns a response with a result code 'Fail'.""" + """Exception raised when Vuforia returns a response with a result code + 'Fail'. + """ @beartype diff --git a/tests/test_cloud_reco_exceptions.py b/tests/test_cloud_reco_exceptions.py index d4c8cb0f7..a9e25338f 100644 --- a/tests/test_cloud_reco_exceptions.py +++ b/tests/test_cloud_reco_exceptions.py @@ -61,7 +61,9 @@ def test_image_too_large( def test_cloudrecoexception_inheritance() -> None: - """CloudRecoService-specific exceptions inherit from CloudRecoException.""" + """CloudRecoService-specific exceptions inherit from + CloudRecoException. + """ subclasses = [ MaxNumResultsOutOfRangeError, InactiveProjectError, @@ -77,7 +79,8 @@ def test_authentication_failure( high_quality_image: io.BytesIO, ) -> None: """ - An ``AuthenticationFailure`` exception is raised when the client access key + An ``AuthenticationFailure`` exception is raised when the client access + key exists but the client secret key is incorrect. """ database = VuforiaDatabase() diff --git a/tests/test_query.py b/tests/test_query.py index 11b803eb5..10fff3a8c 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -48,7 +48,8 @@ class TestCustomBaseVWQURL: @staticmethod def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: """ - It is possible to use query a target to a database under a custom VWQ + It is possible to use query a target to a database under a custom + VWQ URL. """ base_vwq_url = "http://example.com" @@ -190,7 +191,8 @@ def test_top( image: io.BytesIO | BinaryIO, ) -> None: """ - When ``CloudRecoIncludeTargetData.TOP`` is given, target data is only + When ``CloudRecoIncludeTargetData.TOP`` is given, target data is + only returned in the top match. """ target_id = vws_client.add_target( @@ -224,7 +226,8 @@ def test_none( image: io.BytesIO | BinaryIO, ) -> None: """ - When ``CloudRecoIncludeTargetData.NONE`` is given, target data is not + When ``CloudRecoIncludeTargetData.NONE`` is given, target data is + not returned in any match. """ target_id = vws_client.add_target( diff --git a/tests/test_vws.py b/tests/test_vws.py index d427e1c9b..73d8e1fdf 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -176,7 +176,9 @@ def test_get_target_summary_report( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """Details of a target are returned by ``get_target_summary_report``.""" + """Details of a target are returned by + ``get_target_summary_report``. + """ date = "2018-04-25" target_name = uuid.uuid4().hex with freeze_time(time_to_freeze=date): @@ -224,7 +226,9 @@ class TestGetDatabaseSummaryReport: @staticmethod def test_get_target(vws_client: VWS) -> None: - """Details of a database are returned by ``get_database_summary_report``.""" + """Details of a database are returned by + ``get_database_summary_report``. + """ report = vws_client.get_database_summary_report() expected_report = DatabaseSummaryReport( @@ -407,7 +411,9 @@ def test_default_seconds_between_requests( def test_custom_seconds_between_requests( image: io.BytesIO | BinaryIO, ) -> None: - """It is possible to customize the time waited between polling requests.""" + """It is possible to customize the time waited between polling + requests. + """ with MockVWS(processing_time_seconds=0.5) as mock: database = VuforiaDatabase() mock.add_database(database=database) diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index eb5b12a6f..496243274 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -40,7 +40,8 @@ def test_image_too_large( png_too_large: io.BytesIO | io.BufferedRandom, ) -> None: """ - When giving an image which is too large, an ``ImageTooLarge`` exception is + When giving an image which is too large, an ``ImageTooLarge`` exception + is raised. """ with pytest.raises(expected_exception=ImageTooLargeError) as exc: @@ -69,7 +70,8 @@ def test_invalid_given_id(vws_client: VWS) -> None: def test_add_bad_name(vws_client: VWS, high_quality_image: io.BytesIO) -> None: """ - When a name with a bad character is given, a ``ServerError`` exception is + When a name with a bad character is given, a ``ServerError`` exception + is raised. """ max_char_value = 65535 @@ -96,7 +98,9 @@ def test_request_quota_reached() -> None: def test_fail(high_quality_image: io.BytesIO) -> None: - """A ``Fail`` exception is raised when the server access key does not exist.""" + """A ``Fail`` exception is raised when the server access key does not + exist. + """ with MockVWS(): vws_client = VWS( server_access_key=uuid.uuid4().hex, @@ -135,7 +139,8 @@ def test_target_name_exist( high_quality_image: io.BytesIO, ) -> None: """ - A ``TargetNameExist`` exception is raised after adding two targets with the + A ``TargetNameExist`` exception is raised after adding two targets with + the same name. """ vws_client.add_target( @@ -162,7 +167,8 @@ def test_project_inactive( high_quality_image: io.BytesIO, ) -> None: """ - A ``ProjectInactive`` exception is raised if adding a target to an inactive + A ``ProjectInactive`` exception is raised if adding a target to an + inactive database. """ database = VuforiaDatabase(state=States.PROJECT_INACTIVE) @@ -267,7 +273,8 @@ def test_authentication_failure( high_quality_image: io.BytesIO, ) -> None: """ - An ``AuthenticationFailure`` exception is raised when the server access key + An ``AuthenticationFailure`` exception is raised when the server access + key exists but the server secret key is incorrect, or when a client key is incorrect. """ From e446e04b4352f3d4d1ed82994bec513d0d5cf64d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 26 Jan 2026 09:50:09 +0000 Subject: [PATCH 0906/1003] Un-break URLs --- pyproject.toml | 2 +- src/vws/exceptions/custom_exceptions.py | 3 +-- src/vws/exceptions/vws_exceptions.py | 3 +-- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 3998bc1a9..a37ece588 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -344,7 +344,7 @@ reportUnnecessaryTypeIgnoreComment = true typeCheckingMode = "strict" [tool.pydocstringformatter] -write = true +write = false split-summary-body = false max-line-length = 79 linewrap-full-docstring = true diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index e06c20a19..ff20c1b6d 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -1,7 +1,6 @@ """ Exceptions which do not map to errors at -https://developer.vuforia.com/library/web-api/cloud-targets-web-services- -api#result-codes +https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#result-codes or simple errors given by the cloud recognition service. """ diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index 892f6e12f..c68107d00 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -1,8 +1,7 @@ """ Exception raised when Vuforia returns a response with a result code matching one of those documented at -https://developer.vuforia.com/library/web-api/cloud-targets-web-services- -api#result-codes. +https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#result-codes. """ import json From 06de28f492912c6c6cea349964fadc130429f89e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 26 Jan 2026 10:46:10 +0000 Subject: [PATCH 0907/1003] Work around pydocstringformatter issue --- src/vws/exceptions/custom_exceptions.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vws/exceptions/custom_exceptions.py b/src/vws/exceptions/custom_exceptions.py index ff20c1b6d..cf3902264 100644 --- a/src/vws/exceptions/custom_exceptions.py +++ b/src/vws/exceptions/custom_exceptions.py @@ -1,7 +1,7 @@ -""" -Exceptions which do not map to errors at +"""Exceptions which do not map to errors at the following URL, or simple +errors given by the cloud recognition service. + https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#result-codes -or simple errors given by the cloud recognition service. """ from beartype import beartype From a820dbdcfabf5fc81a4580e8421dc47f4ea73b98 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 26 Jan 2026 10:50:31 +0000 Subject: [PATCH 0908/1003] Fix ruff ignore comment --- pyproject.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index a37ece588..77640c0ba 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -119,8 +119,8 @@ lint.select = [ lint.ignore = [ # Ruff warns that this conflicts with the formatter. "COM812", - # Allow our chosen docstring line-style - no one-line summary. - "D200", + # Allow our chosen docstring line-style - pydocstringformatter handles formatting + # but doesn't enforce D205 (blank line after summary) or D212 (summary on first line). "D205", "D212", # Ruff warns that this conflicts with the formatter. From d4fe42e32a2351b9025f0ce53ec04a04dbd712ef Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 26 Jan 2026 10:52:41 +0000 Subject: [PATCH 0909/1003] Write fixes --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 77640c0ba..32edef2a4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -344,7 +344,7 @@ reportUnnecessaryTypeIgnoreComment = true typeCheckingMode = "strict" [tool.pydocstringformatter] -write = false +write = true split-summary-body = false max-line-length = 79 linewrap-full-docstring = true From 31dfe8c1839343f38272d5b4f08fa67c3525bc45 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 26 Jan 2026 11:03:05 +0000 Subject: [PATCH 0910/1003] Re-add D200 to ruff ignores - conflicts with pydocstringformatter at line-length boundary --- pyproject.toml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 15fb0e3cf..9843058be 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -120,7 +120,9 @@ lint.ignore = [ # Ruff warns that this conflicts with the formatter. "COM812", # Allow our chosen docstring line-style - pydocstringformatter handles formatting - # but doesn't enforce D205 (blank line after summary) or D212 (summary on first line). + # but may conflict with D200 at the line-length boundary, and doesn't enforce + # D205 (blank line after summary) or D212 (summary on first line). + "D200", "D205", "D212", # Ruff warns that this conflicts with the formatter. From 114e0835579deb7d0727a12bb158cefdaa3b235a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 26 Jan 2026 11:03:51 +0000 Subject: [PATCH 0911/1003] Remove D200 ignore by lowering pydocstringformatter line length to 75 --- bun.lock | 14 +++++++++++ example.txt | 0 issue.txt | 28 +++++++++++++++++++++ package.json | 6 +++++ pyproject.toml | 9 ++++--- src/vws/exceptions/base_exceptions.py | 3 ++- src/vws/exceptions/cloud_reco_exceptions.py | 3 ++- src/vws/exceptions/vws_exceptions.py | 6 +++-- src/vws/query.py | 3 ++- src/vws/vws.py | 3 ++- tests/test_cloud_reco_exceptions.py | 6 +++-- tests/test_query.py | 6 +++-- tests/test_vws.py | 6 +++-- tests/test_vws_exceptions.py | 27 +++++++++++++------- 14 files changed, 95 insertions(+), 25 deletions(-) create mode 100644 bun.lock create mode 100644 example.txt create mode 100644 issue.txt create mode 100644 package.json diff --git a/bun.lock b/bun.lock new file mode 100644 index 000000000..45f73b81b --- /dev/null +++ b/bun.lock @@ -0,0 +1,14 @@ +{ + "lockfileVersion": 1, + "configVersion": 1, + "workspaces": { + "": { + "devDependencies": { + "prettier": "3.7.4", + }, + }, + }, + "packages": { + "prettier": ["prettier@3.7.4", "", { "bin": { "prettier": "bin/prettier.cjs" } }, "sha512-v6UNi1+3hSlVvv8fSaoUbggEM5VErKmmpGA7Pl3HF8V6uKY7rvClBOJlH6yNwQtfTueNkGVpOv/mtWL9L4bgRA=="], + } +} diff --git a/example.txt b/example.txt new file mode 100644 index 000000000..e69de29bb diff --git a/issue.txt b/issue.txt new file mode 100644 index 000000000..abe88bb9b --- /dev/null +++ b/issue.txt @@ -0,0 +1,28 @@ +URLs are broken when reflowing paragraphs + +## Version + +0.7.3 + +## Example + +Input file: + +```python +"""For more information see https://example.com/documentation/api/v2/reference/getting-started#authentication or contact support.""" +``` + +Output after running `pydocstringformatter --linewrap-full-docstring`: + +```diff +--- issue.py ++++ issue.py +@@ -1,2 +1,5 @@ +-"""For more information see https://example.com/documentation/api/v2/reference/getting-started#authentication or contact support.""" ++"""For more information see https://example.com/documentation/api/v2/reference/getting-. ++ ++started#authentication or contact support. ++""" +``` + +The URL is broken across two lines, making it impossible to click. diff --git a/package.json b/package.json new file mode 100644 index 000000000..71b8ee1ef --- /dev/null +++ b/package.json @@ -0,0 +1,6 @@ +{ + "dependencies": {}, + "devDependencies": { + "prettier": "3.7.4" + } +} diff --git a/pyproject.toml b/pyproject.toml index 9843058be..55238906d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -120,9 +120,7 @@ lint.ignore = [ # Ruff warns that this conflicts with the formatter. "COM812", # Allow our chosen docstring line-style - pydocstringformatter handles formatting - # but may conflict with D200 at the line-length boundary, and doesn't enforce - # D205 (blank line after summary) or D212 (summary on first line). - "D200", + # but doesn't enforce D205 (blank line after summary) or D212 (summary on first line). "D205", "D212", # Ruff warns that this conflicts with the formatter. @@ -348,7 +346,10 @@ typeCheckingMode = "strict" [tool.pydocstringformatter] write = true split-summary-body = false -max-line-length = 79 +# Use a lower line length than ruff (79) to avoid conflicts with D200 - +# pydocstringformatter would otherwise split docstrings at exactly 79 chars +# which ruff considers should stay on one line. +max-line-length = 75 linewrap-full-docstring = true [tool.interrogate] diff --git a/src/vws/exceptions/base_exceptions.py b/src/vws/exceptions/base_exceptions.py index c86080593..fa031838a 100644 --- a/src/vws/exceptions/base_exceptions.py +++ b/src/vws/exceptions/base_exceptions.py @@ -1,5 +1,6 @@ """ -Base exceptions for errors returned by Vuforia Web Services or the Vuforia +Base exceptions for errors returned by Vuforia Web Services or the +Vuforia Cloud Recognition Web API. """ diff --git a/src/vws/exceptions/cloud_reco_exceptions.py b/src/vws/exceptions/cloud_reco_exceptions.py index a59335f14..b2e3ee67f 100644 --- a/src/vws/exceptions/cloud_reco_exceptions.py +++ b/src/vws/exceptions/cloud_reco_exceptions.py @@ -1,4 +1,5 @@ -"""Exceptions which match errors raised by the Vuforia Cloud Recognition Web +"""Exceptions which match errors raised by the Vuforia Cloud Recognition +Web APIs. """ diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index c68107d00..6b1447577 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -1,7 +1,9 @@ """ -Exception raised when Vuforia returns a response with a result code matching +Exception raised when Vuforia returns a response with a result code +matching one of those documented at -https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#result-codes. +https://developer.vuforia.com/library/web-api/cloud-targets-web-services- +api#result-codes. """ import json diff --git a/src/vws/query.py b/src/vws/query.py index ab449c614..6c2dc481e 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -68,7 +68,8 @@ def query( CloudRecoIncludeTargetData.TOP ), ) -> list[QueryResult]: - """Use the Vuforia Web Query API to make an Image Recognition Query. + """Use the Vuforia Web Query API to make an Image Recognition + Query. See https://developer.vuforia.com/library/web-api/vuforia-query-web-api diff --git a/src/vws/vws.py b/src/vws/vws.py index 1191ee7df..9b3d19b4e 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -567,7 +567,8 @@ def delete_target(self, target_id: str) -> None: ) def get_duplicate_targets(self, target_id: str) -> list[str]: - """Get targets which may be considered duplicates of a given target. + """Get targets which may be considered duplicates of a given + target. See https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api#check. diff --git a/tests/test_cloud_reco_exceptions.py b/tests/test_cloud_reco_exceptions.py index a9e25338f..5576f4d40 100644 --- a/tests/test_cloud_reco_exceptions.py +++ b/tests/test_cloud_reco_exceptions.py @@ -49,7 +49,8 @@ def test_image_too_large( png_too_large: io.BytesIO | io.BufferedRandom, ) -> None: """ - A ``RequestEntityTooLarge`` exception is raised if an image which is too + A ``RequestEntityTooLarge`` exception is raised if an image which is + too large is given. """ with pytest.raises(expected_exception=RequestEntityTooLargeError) as exc: @@ -79,7 +80,8 @@ def test_authentication_failure( high_quality_image: io.BytesIO, ) -> None: """ - An ``AuthenticationFailure`` exception is raised when the client access + An ``AuthenticationFailure`` exception is raised when the client + access key exists but the client secret key is incorrect. """ diff --git a/tests/test_query.py b/tests/test_query.py index 10fff3a8c..a79a712c0 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -48,7 +48,8 @@ class TestCustomBaseVWQURL: @staticmethod def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: """ - It is possible to use query a target to a database under a custom + It is possible to use query a target to a database under a + custom VWQ URL. """ @@ -226,7 +227,8 @@ def test_none( image: io.BytesIO | BinaryIO, ) -> None: """ - When ``CloudRecoIncludeTargetData.NONE`` is given, target data is + When ``CloudRecoIncludeTargetData.NONE`` is given, target data + is not returned in any match. """ diff --git a/tests/test_vws.py b/tests/test_vws.py index 73d8e1fdf..00936bde8 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -77,7 +77,8 @@ def test_add_two_targets( vws_client: VWS, image: io.BytesIO | BinaryIO, ) -> None: - """No exception is raised when adding two targets with different names. + """No exception is raised when adding two targets with different + names. This demonstrates that the image seek position is not changed. """ @@ -97,7 +98,8 @@ class TestCustomBaseVWSURL: @staticmethod def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: """ - It is possible to use add a target to a database under a custom VWS + It is possible to use add a target to a database under a custom + VWS URL. """ base_vws_url = "http://example.com" diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 496243274..4262b3ea6 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -40,7 +40,8 @@ def test_image_too_large( png_too_large: io.BytesIO | io.BufferedRandom, ) -> None: """ - When giving an image which is too large, an ``ImageTooLarge`` exception + When giving an image which is too large, an ``ImageTooLarge`` + exception is raised. """ @@ -58,7 +59,8 @@ def test_image_too_large( def test_invalid_given_id(vws_client: VWS) -> None: """ - Giving an invalid ID to a helper which requires a target ID to be given + Giving an invalid ID to a helper which requires a target ID to be + given causes an ``UnknownTarget`` exception to be raised. """ target_id = "12345abc" @@ -70,7 +72,8 @@ def test_invalid_given_id(vws_client: VWS) -> None: def test_add_bad_name(vws_client: VWS, high_quality_image: io.BytesIO) -> None: """ - When a name with a bad character is given, a ``ServerError`` exception + When a name with a bad character is given, a ``ServerError`` + exception is raised. """ @@ -139,7 +142,8 @@ def test_target_name_exist( high_quality_image: io.BytesIO, ) -> None: """ - A ``TargetNameExist`` exception is raised after adding two targets with + A ``TargetNameExist`` exception is raised after adding two targets + with the same name. """ @@ -196,7 +200,8 @@ def test_target_status_processing( high_quality_image: io.BytesIO, ) -> None: """ - A ``TargetStatusProcessing`` exception is raised if trying to delete a + A ``TargetStatusProcessing`` exception is raised if trying to delete + a target which is processing. """ target_id = vws_client.add_target( @@ -219,7 +224,8 @@ def test_metadata_too_large( high_quality_image: io.BytesIO, ) -> None: """ - A ``MetadataTooLarge`` exception is raised if the metadata given is too + A ``MetadataTooLarge`` exception is raised if the metadata given is + too large. """ with pytest.raises(expected_exception=MetadataTooLargeError) as exc: @@ -239,7 +245,8 @@ def test_request_time_too_skewed( high_quality_image: io.BytesIO, ) -> None: """ - A ``RequestTimeTooSkewed`` exception is raised when the request time is + A ``RequestTimeTooSkewed`` exception is raised when the request time + is more than five minutes different from the server time. """ target_id = vws_client.add_target( @@ -273,7 +280,8 @@ def test_authentication_failure( high_quality_image: io.BytesIO, ) -> None: """ - An ``AuthenticationFailure`` exception is raised when the server access + An ``AuthenticationFailure`` exception is raised when the server + access key exists but the server secret key is incorrect, or when a client key is incorrect. @@ -307,7 +315,8 @@ def test_target_status_not_success( high_quality_image: io.BytesIO, ) -> None: """ - A ``TargetStatusNotSuccess`` exception is raised when updating a target + A ``TargetStatusNotSuccess`` exception is raised when updating a + target which has a status which is not "Success". """ target_id = vws_client.add_target( From 7f330219e793b08895ff78a54052b950d3fc3254 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 26 Jan 2026 11:04:20 +0000 Subject: [PATCH 0912/1003] Remove unrelated test files --- bun.lock | 14 -------------- example.txt | 0 issue.txt | 28 ---------------------------- package.json | 6 ------ 4 files changed, 48 deletions(-) delete mode 100644 bun.lock delete mode 100644 example.txt delete mode 100644 issue.txt delete mode 100644 package.json diff --git a/bun.lock b/bun.lock deleted file mode 100644 index 45f73b81b..000000000 --- a/bun.lock +++ /dev/null @@ -1,14 +0,0 @@ -{ - "lockfileVersion": 1, - "configVersion": 1, - "workspaces": { - "": { - "devDependencies": { - "prettier": "3.7.4", - }, - }, - }, - "packages": { - "prettier": ["prettier@3.7.4", "", { "bin": { "prettier": "bin/prettier.cjs" } }, "sha512-v6UNi1+3hSlVvv8fSaoUbggEM5VErKmmpGA7Pl3HF8V6uKY7rvClBOJlH6yNwQtfTueNkGVpOv/mtWL9L4bgRA=="], - } -} diff --git a/example.txt b/example.txt deleted file mode 100644 index e69de29bb..000000000 diff --git a/issue.txt b/issue.txt deleted file mode 100644 index abe88bb9b..000000000 --- a/issue.txt +++ /dev/null @@ -1,28 +0,0 @@ -URLs are broken when reflowing paragraphs - -## Version - -0.7.3 - -## Example - -Input file: - -```python -"""For more information see https://example.com/documentation/api/v2/reference/getting-started#authentication or contact support.""" -``` - -Output after running `pydocstringformatter --linewrap-full-docstring`: - -```diff ---- issue.py -+++ issue.py -@@ -1,2 +1,5 @@ --"""For more information see https://example.com/documentation/api/v2/reference/getting-started#authentication or contact support.""" -+"""For more information see https://example.com/documentation/api/v2/reference/getting-. -+ -+started#authentication or contact support. -+""" -``` - -The URL is broken across two lines, making it impossible to click. diff --git a/package.json b/package.json deleted file mode 100644 index 71b8ee1ef..000000000 --- a/package.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "dependencies": {}, - "devDependencies": { - "prettier": "3.7.4" - } -} From 98aae9197c8181b2f85e10501391cf6c6e00a8a7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 26 Jan 2026 11:37:16 +0000 Subject: [PATCH 0913/1003] Bump doccmd from 2026.1.22.1 to 2026.1.25 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2026.1.22.1 to 2026.1.25. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2026.01.22.1...2026.01.25) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2026.1.25 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 55238906d..c40ae9b46 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -41,7 +41,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2026.1.22.1", + "doccmd==2026.1.25", "freezegun==1.5.5", "furo==2025.12.19", "interrogate==1.7.0", From 1d9fb85fb1d106930476ce6d385f6878d748cd16 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 26 Jan 2026 11:37:24 +0000 Subject: [PATCH 0914/1003] Bump pydocstringformatter from 0.7.3 to 0.7.5 Bumps [pydocstringformatter](https://github.com/DanielNoord/pydocstringformatter) from 0.7.3 to 0.7.5. - [Release notes](https://github.com/DanielNoord/pydocstringformatter/releases) - [Commits](https://github.com/DanielNoord/pydocstringformatter/compare/v0.7.3...v0.7.5) --- updated-dependencies: - dependency-name: pydocstringformatter dependency-version: 0.7.5 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 55238906d..8af403249 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "mypy[faster-cache]==1.19.1", "mypy-strict-kwargs==2026.1.12", "prek==0.3.0", - "pydocstringformatter==0.7.3", + "pydocstringformatter==0.7.5", "pydocstyle==6.3", "pygments==2.19.2", "pylint[spelling]==4.0.4", From 099a85381d6547554c43b99c1cdfa2bb41b35c7a Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 26 Jan 2026 12:23:38 +0000 Subject: [PATCH 0915/1003] Remove --example-workers 0 due to mypy bug See https://github.com/python/mypy/issues/18283 --- .pre-commit-config.yaml | 29 +++++++++++++---------------- 1 file changed, 13 insertions(+), 16 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 6b48bc64c..49e946718 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,6 +1,8 @@ --- fail_fast: true +# We do not use --example-workers 0 due to https://github.com/python/mypy/issues/18283 + # See https://pre-commit.com for more information # See https://pre-commit.com/hooks.html for more hooks @@ -122,8 +124,8 @@ repos: - id: shellcheck-docs name: shellcheck-docs - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=shell - --language=console --command="shellcheck --shell=bash" + entry: uv run --extra=dev doccmd --no-write-to-file --language=shell --language=console + --command="shellcheck --shell=bash" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -158,8 +160,7 @@ repos: - id: mypy-docs name: mypy-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python - --command="mypy" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="mypy" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -184,8 +185,7 @@ repos: - id: pyright-docs name: pyright-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python - --command="pyright" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="pyright" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -201,8 +201,7 @@ repos: - id: vulture-docs name: vulture docs - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python - --command="vulture" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="vulture" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -235,8 +234,7 @@ repos: - id: pylint-docs name: pylint-docs - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python - --command="pylint" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="pylint" language: python stages: [manual] types_or: [markdown, rst] @@ -293,8 +291,7 @@ repos: - id: interrogate-docs name: interrogate docs - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python - --command="interrogate" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="interrogate" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -358,8 +355,8 @@ repos: - id: ty-docs name: ty-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python - --command="ty check" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="ty + check" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -401,8 +398,8 @@ repos: - id: pyrefly-docs name: pyrefly-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python - --command="pyrefly check" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="pyrefly + check" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] From fce3a97d981c50cb42a704de6f8b2f8d92aafb07 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 26 Jan 2026 12:40:25 +0000 Subject: [PATCH 0916/1003] Fix: Remove --example-workers 0 only from mypy-docs hook This reverts the previous incorrect change that removed --example-workers 0 from all hooks, and correctly removes it only from mypy-docs. See https://github.com/python/mypy/issues/18283 --- .pre-commit-config.yaml | 29 ++++++++++++++++------------- 1 file changed, 16 insertions(+), 13 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 49e946718..0126b809a 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,8 +1,6 @@ --- fail_fast: true -# We do not use --example-workers 0 due to https://github.com/python/mypy/issues/18283 - # See https://pre-commit.com for more information # See https://pre-commit.com/hooks.html for more hooks @@ -124,8 +122,8 @@ repos: - id: shellcheck-docs name: shellcheck-docs - entry: uv run --extra=dev doccmd --no-write-to-file --language=shell --language=console - --command="shellcheck --shell=bash" + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=shell + --language=console --command="shellcheck --shell=bash" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -160,7 +158,8 @@ repos: - id: mypy-docs name: mypy-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="mypy" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python + --command="mypy" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -185,7 +184,8 @@ repos: - id: pyright-docs name: pyright-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="pyright" + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + --command="pyright" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -201,7 +201,8 @@ repos: - id: vulture-docs name: vulture docs - entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="vulture" + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + --command="vulture" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -234,7 +235,8 @@ repos: - id: pylint-docs name: pylint-docs - entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="pylint" + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + --command="pylint" language: python stages: [manual] types_or: [markdown, rst] @@ -291,7 +293,8 @@ repos: - id: interrogate-docs name: interrogate docs - entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="interrogate" + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + --command="interrogate" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -355,8 +358,8 @@ repos: - id: ty-docs name: ty-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="ty - check" + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + --command="ty check" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] @@ -398,8 +401,8 @@ repos: - id: pyrefly-docs name: pyrefly-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="pyrefly - check" + entry: uv run --extra=dev doccmd --no-write-to-file --example-workers 0 --language=python + --command="pyrefly check" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] From 4a5ce8e7c7572ce6809784976f2cffdc3346aeef Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Mon, 26 Jan 2026 12:42:29 +0000 Subject: [PATCH 0917/1003] [pre-commit.ci lite] apply automatic fixes --- .pre-commit-config.yaml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 0126b809a..9bb1ad683 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -158,8 +158,7 @@ repos: - id: mypy-docs name: mypy-docs stages: [pre-push] - entry: uv run --extra=dev doccmd --no-write-to-file --language=python - --command="mypy" + entry: uv run --extra=dev doccmd --no-write-to-file --language=python --command="mypy" language: python types_or: [markdown, rst] additional_dependencies: [uv==0.9.5] From 2a9c9f60296dc392004d5d8fdbee2f2ed6d2d094 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 26 Jan 2026 12:46:08 +0000 Subject: [PATCH 0918/1003] Add comment explaining why --example-workers 0 is not used for mypy-docs --- .pre-commit-config.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 9bb1ad683..c64693b9d 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -155,6 +155,7 @@ repos: pass_filenames: false additional_dependencies: [uv==0.9.5] + # We do not use --example-workers 0 due to https://github.com/python/mypy/issues/18283 - id: mypy-docs name: mypy-docs stages: [pre-push] From 90cd53bb3a690f83d6c1edc3e42db6b4dc3f61a1 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 27 Jan 2026 04:31:17 +0000 Subject: [PATCH 0919/1003] Support Python 3.14 --- .github/workflows/ci.yml | 2 +- pyproject.toml | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ca86af4b1..2bec50283 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -17,7 +17,7 @@ jobs: build: strategy: matrix: - python-version: ['3.13'] + python-version: ['3.13', '3.14'] platform: [ubuntu-latest, windows-latest] runs-on: ${{ matrix.platform }} diff --git a/pyproject.toml b/pyproject.toml index 3d1113d2c..3b6366fb6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -26,6 +26,7 @@ classifiers = [ "Operating System :: POSIX", "Programming Language :: Python :: 3 :: Only", "Programming Language :: Python :: 3.13", + "Programming Language :: Python :: 3.14", ] dynamic = [ "version", @@ -311,7 +312,7 @@ pep621_dev_dependency_groups = [ [tool.pyproject-fmt] indent = 4 keep_full_version = true -max_supported_python = "3.13" +max_supported_python = "3.14" [tool.pytest.ini_options] From 03aea77ffa3add893acce8b0152a3d5238742c98 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 27 Jan 2026 10:31:24 +0000 Subject: [PATCH 0920/1003] Bump doccmd from 2026.1.25 to 2026.1.27.2 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2026.1.25 to 2026.1.27.2. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2026.01.25...2026.01.27.2) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2026.1.27.2 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3b6366fb6..1787e4339 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -42,7 +42,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2026.1.25", + "doccmd==2026.1.27.2", "freezegun==1.5.5", "furo==2025.12.19", "interrogate==1.7.0", From 37d14fb090552481e9eceb495c972c35b8c16625 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 27 Jan 2026 10:31:36 +0000 Subject: [PATCH 0921/1003] Bump ty from 0.0.13 to 0.0.14 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.13 to 0.0.14. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.13...0.0.14) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.14 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3b6366fb6..6edd655cb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -74,7 +74,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2026.1.12", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.13", + "ty==0.0.14", "types-requests==2.32.4.20260107", "vulture==2.14", "vws-python-mock==2025.3.10.1", From ae28c2d82d69580211ab889d3b3cc78cceea10e2 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 27 Jan 2026 10:31:41 +0000 Subject: [PATCH 0922/1003] Bump pyrefly from 0.49.0 to 0.50.0 Bumps [pyrefly](https://github.com/facebook/pyrefly) from 0.49.0 to 0.50.0. - [Release notes](https://github.com/facebook/pyrefly/releases) - [Commits](https://github.com/facebook/pyrefly/compare/0.49.0...0.50.0) --- updated-dependencies: - dependency-name: pyrefly dependency-version: 0.50.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3b6366fb6..a9b0825ec 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.11.1", - "pyrefly==0.49.0", + "pyrefly==0.50.0", "pyright==1.1.408", "pyroma==5.0.1", "pytest==9.0.2", From 5945d15615a27ad04ae4267e19a16a19e188be7d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 28 Jan 2026 10:33:09 +0000 Subject: [PATCH 0923/1003] Bump doccmd from 2026.1.27.2 to 2026.1.28 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2026.1.27.2 to 2026.1.28. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2026.01.27.2...2026.01.28) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2026.1.28 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index d1971da3c..3d34fe0f9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -42,7 +42,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2026.1.27.2", + "doccmd==2026.1.28", "freezegun==1.5.5", "furo==2025.12.19", "interrogate==1.7.0", From e3f97fd96995842c48480fae8c124431b353b969 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 29 Jan 2026 10:33:07 +0000 Subject: [PATCH 0924/1003] Bump pyrefly from 0.50.0 to 0.50.1 Bumps [pyrefly](https://github.com/facebook/pyrefly) from 0.50.0 to 0.50.1. - [Release notes](https://github.com/facebook/pyrefly/releases) - [Commits](https://github.com/facebook/pyrefly/compare/0.50.0...0.50.1) --- updated-dependencies: - dependency-name: pyrefly dependency-version: 0.50.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 3d34fe0f9..9f1747298 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.11.1", - "pyrefly==0.50.0", + "pyrefly==0.50.1", "pyright==1.1.408", "pyroma==5.0.1", "pytest==9.0.2", From 13376509e7e766b0953355279b65ddaefdfdf0f8 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 2 Feb 2026 11:40:32 +0000 Subject: [PATCH 0925/1003] Add custom request timeout support for VWS and CloudRecoService Allow users to configure request timeouts instead of using a hardcoded 30-second default. Both VWS and CloudRecoService now accept an optional request_timeout_seconds parameter during initialization, with proper defaults and documentation. Co-Authored-By: Claude Haiku 4.5 --- src/vws/query.py | 7 +++++-- src/vws/vws.py | 10 ++++++++-- tests/test_query.py | 48 +++++++++++++++++++++++++++++++++++++++++++++ tests/test_vws.py | 41 ++++++++++++++++++++++++++++++++++++++ 4 files changed, 102 insertions(+), 4 deletions(-) diff --git a/src/vws/query.py b/src/vws/query.py index 6c2dc481e..b9d42d4c8 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -49,16 +49,20 @@ def __init__( client_access_key: str, client_secret_key: str, base_vwq_url: str = "https://cloudreco.vuforia.com", + request_timeout_seconds: float = 30.0, ) -> None: """ Args: client_access_key: A VWS client access key. client_secret_key: A VWS client secret key. base_vwq_url: The base URL for the VWQ API. + request_timeout_seconds: The timeout in seconds for each HTTP + request made to the Cloud Reco API. """ self._client_access_key = client_access_key self._client_secret_key = client_secret_key self._base_vwq_url = base_vwq_url + self.request_timeout_seconds = request_timeout_seconds def query( self, @@ -141,8 +145,7 @@ def query( url=urljoin(base=self._base_vwq_url, url=request_path), headers=headers, data=content, - # We should make the timeout customizable. - timeout=30, + timeout=self.request_timeout_seconds, ) response = Response( text=requests_response.text, diff --git a/src/vws/vws.py b/src/vws/vws.py index 9b3d19b4e..82eb7c5bc 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -68,6 +68,7 @@ def _target_api_request( data: bytes, request_path: str, base_vws_url: str, + request_timeout_seconds: float, ) -> Response: """Make a request to the Vuforia Target API. @@ -82,6 +83,7 @@ def _target_api_request( request_path: The path to the endpoint which will be used in the request. base_vws_url: The base URL for the VWS API. + request_timeout_seconds: The timeout in seconds for the request. Returns: The response to the request made by `requests`. @@ -111,8 +113,7 @@ def _target_api_request( url=url, headers=headers, data=data, - # We should make the timeout customizable. - timeout=30, + timeout=request_timeout_seconds, ) return Response( @@ -134,16 +135,20 @@ def __init__( server_access_key: str, server_secret_key: str, base_vws_url: str = "https://vws.vuforia.com", + request_timeout_seconds: float = 30.0, ) -> None: """ Args: server_access_key: A VWS server access key. server_secret_key: A VWS server secret key. base_vws_url: The base URL for the VWS API. + request_timeout_seconds: The timeout in seconds for each HTTP + request made to the VWS API. """ self._server_access_key = server_access_key self._server_secret_key = server_secret_key self._base_vws_url = base_vws_url + self.request_timeout_seconds = request_timeout_seconds def make_request( self, @@ -187,6 +192,7 @@ def make_request( data=data, request_path=request_path, base_vws_url=self._base_vws_url, + request_timeout_seconds=self.request_timeout_seconds, ) if ( diff --git a/tests/test_query.py b/tests/test_query.py index a79a712c0..af9d19799 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -42,6 +42,54 @@ def test_match( assert matching_target.target_id == target_id +class TestCustomRequestTimeout: + """Tests for using a custom request timeout.""" + + @staticmethod + def test_default_timeout() -> None: + """By default, the request timeout is 30 seconds.""" + default_timeout_seconds = 30.0 + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + cloud_reco_client = CloudRecoService( + client_access_key=database.client_access_key, + client_secret_key=database.client_secret_key, + ) + expected = default_timeout_seconds + assert cloud_reco_client.request_timeout_seconds == expected + + @staticmethod + def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: + """It is possible to set a custom request timeout.""" + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + ) + custom_timeout = 60.5 + cloud_reco_client = CloudRecoService( + client_access_key=database.client_access_key, + client_secret_key=database.client_secret_key, + request_timeout_seconds=custom_timeout, + ) + assert cloud_reco_client.request_timeout_seconds == custom_timeout + + # Verify requests work with the custom timeout + target_id = vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + vws_client.wait_for_target_processed(target_id=target_id) + matches = cloud_reco_client.query(image=image) + assert len(matches) == 1 + + class TestCustomBaseVWQURL: """Tests for using a custom base VWQ URL.""" diff --git a/tests/test_vws.py b/tests/test_vws.py index 00936bde8..25fe7227e 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -92,6 +92,47 @@ def test_add_two_targets( ) +class TestCustomRequestTimeout: + """Tests for using a custom request timeout.""" + + @staticmethod + def test_default_timeout() -> None: + """By default, the request timeout is 30 seconds.""" + default_timeout_seconds = 30.0 + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + ) + expected = default_timeout_seconds + assert vws_client.request_timeout_seconds == expected + + @staticmethod + def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: + """It is possible to set a custom request timeout.""" + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + custom_timeout = 60.5 + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + request_timeout_seconds=custom_timeout, + ) + assert vws_client.request_timeout_seconds == custom_timeout + + # Verify requests work with the custom timeout + vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + + class TestCustomBaseVWSURL: """Tests for using a custom base VWS URL.""" From 5e1f289b1b491558dc44298e6701d1f27e56d59b Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 2 Feb 2026 11:49:50 +0000 Subject: [PATCH 0926/1003] Bump prek from 0.3.0 to 0.3.1 Bumps [prek](https://github.com/j178/prek) from 0.3.0 to 0.3.1. - [Release notes](https://github.com/j178/prek/releases) - [Changelog](https://github.com/j178/prek/blob/master/CHANGELOG.md) - [Commits](https://github.com/j178/prek/compare/v0.3.0...v0.3.1) --- updated-dependencies: - dependency-name: prek dependency-version: 0.3.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9f1747298..c01f056ab 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "interrogate==1.7.0", "mypy[faster-cache]==1.19.1", "mypy-strict-kwargs==2026.1.12", - "prek==0.3.0", + "prek==0.3.1", "pydocstringformatter==0.7.5", "pydocstyle==6.3", "pygments==2.19.2", From 2504ba117f6b5208e62a714c84e8ff2ba0db68d3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 2 Feb 2026 11:49:56 +0000 Subject: [PATCH 0927/1003] Bump doccmd from 2026.1.28 to 2026.1.31.3 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2026.1.28 to 2026.1.31.3. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2026.01.28...2026.01.31.3) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2026.1.31.3 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9f1747298..9196881ef 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -42,7 +42,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2026.1.28", + "doccmd==2026.1.31.3", "freezegun==1.5.5", "furo==2025.12.19", "interrogate==1.7.0", From 32c7e2bc767d735827b6a6ef15ed4634764470e5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 2 Feb 2026 11:50:08 +0000 Subject: [PATCH 0928/1003] Bump pyproject-fmt from 2.11.1 to 2.12.1 Bumps [pyproject-fmt](https://github.com/tox-dev/toml-fmt) from 2.11.1 to 2.12.1. - [Release notes](https://github.com/tox-dev/toml-fmt/releases) - [Commits](https://github.com/tox-dev/toml-fmt/compare/pyproject-fmt/2.11.1...pyproject-fmt/2.12.1) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-version: 2.12.1 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9f1747298..b24fc8ef8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pygments==2.19.2", "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", - "pyproject-fmt==2.11.1", + "pyproject-fmt==2.12.1", "pyrefly==0.50.1", "pyright==1.1.408", "pyroma==5.0.1", From 7f0990fc6cfabefd54e88a485dccf39d9b75ff1c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 2 Feb 2026 11:54:49 +0000 Subject: [PATCH 0929/1003] Add tests that verify timeout is actually enforced Add test_timeout_raises_on_slow_response and test_longer_timeout_succeeds tests to both VWS and CloudRecoService. These tests simulate slow server responses and verify that short timeouts actually raise Timeout exceptions. Co-Authored-By: Claude Opus 4.5 --- tests/test_query.py | 104 ++++++++++++++++++++++++++++++++++++++++++++ tests/test_vws.py | 89 +++++++++++++++++++++++++++++++++++++ 2 files changed, 193 insertions(+) diff --git a/tests/test_query.py b/tests/test_query.py index af9d19799..a3f4c0331 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -1,9 +1,13 @@ """Tests for the ``CloudRecoService`` querying functionality.""" import io +import time import uuid from typing import BinaryIO +from unittest.mock import patch +import pytest +import requests from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase @@ -89,6 +93,106 @@ def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: matches = cloud_reco_client.query(image=image) assert len(matches) == 1 + @staticmethod + def test_timeout_raises_on_slow_response( + image: io.BytesIO | BinaryIO, + ) -> None: + """A short timeout raises an error when the server is slow.""" + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + ) + cloud_reco_client = CloudRecoService( + client_access_key=database.client_access_key, + client_secret_key=database.client_secret_key, + request_timeout_seconds=0.1, + ) + + target_id = vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + vws_client.wait_for_target_processed(target_id=target_id) + + simulated_slow_threshold = 0.5 + original_request = requests.request + + def slow_request( + *args: object, + **kwargs: float | None, + ) -> requests.Response: + """Simulate a slow server response.""" + timeout = kwargs.get("timeout") + if timeout is not None and timeout < simulated_slow_threshold: + time.sleep(0.2) + raise requests.exceptions.Timeout + return original_request(*args, **kwargs) # type: ignore[arg-type] + + with ( + patch.object( + requests, + "request", + side_effect=slow_request, + ), + pytest.raises(requests.exceptions.Timeout), + ): + cloud_reco_client.query(image=image) + + @staticmethod + def test_longer_timeout_succeeds(image: io.BytesIO | BinaryIO) -> None: + """A longer timeout allows slow responses to complete.""" + simulated_slow_threshold = 0.5 + + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + ) + cloud_reco_client = CloudRecoService( + client_access_key=database.client_access_key, + client_secret_key=database.client_secret_key, + request_timeout_seconds=1.0, + ) + + target_id = vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + vws_client.wait_for_target_processed(target_id=target_id) + + original_request = requests.request + + def slow_request( + *args: object, + **kwargs: float | None, + ) -> requests.Response: + """Simulate a slow server response.""" + timeout = kwargs.get("timeout") + if timeout is not None and timeout < simulated_slow_threshold: + time.sleep(0.2) + raise requests.exceptions.Timeout + return original_request(*args, **kwargs) # type: ignore[arg-type] + + with patch.object( + requests, + "request", + side_effect=slow_request, + ): + # This should succeed because timeout is 1.0 > 0.5 + matches = cloud_reco_client.query(image=image) + assert len(matches) == 1 + class TestCustomBaseVWQURL: """Tests for using a custom base VWQ URL.""" diff --git a/tests/test_vws.py b/tests/test_vws.py index 25fe7227e..03b5818b3 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -4,10 +4,13 @@ import datetime import io import secrets +import time import uuid from typing import BinaryIO +from unittest.mock import patch import pytest +import requests from freezegun import freeze_time from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase @@ -132,6 +135,92 @@ def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: application_metadata=None, ) + @staticmethod + def test_timeout_raises_on_slow_response( + image: io.BytesIO | BinaryIO, + ) -> None: + """A short timeout raises an error when the server is slow.""" + simulated_slow_threshold = 0.5 + + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + request_timeout_seconds=0.1, + ) + + original_request = requests.request + + def slow_request( + *args: object, + **kwargs: float | None, + ) -> requests.Response: + """Simulate a slow server response.""" + timeout = kwargs.get("timeout") + if timeout is not None and timeout < simulated_slow_threshold: + time.sleep(0.2) + raise requests.exceptions.Timeout + return original_request(*args, **kwargs) # type: ignore[arg-type] + + with ( + patch.object( + requests, + "request", + side_effect=slow_request, + ), + pytest.raises(requests.exceptions.Timeout), + ): + vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + + @staticmethod + def test_longer_timeout_succeeds(image: io.BytesIO | BinaryIO) -> None: + """A longer timeout allows slow responses to complete.""" + simulated_slow_threshold = 0.5 + + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + request_timeout_seconds=1.0, + ) + + original_request = requests.request + + def slow_request( + *args: object, + **kwargs: float | None, + ) -> requests.Response: + """Simulate a slow server response.""" + timeout = kwargs.get("timeout") + if timeout is not None and timeout < simulated_slow_threshold: + time.sleep(0.2) + raise requests.exceptions.Timeout + return original_request(*args, **kwargs) # type: ignore[arg-type] + + with patch.object( + requests, + "request", + side_effect=slow_request, + ): + # This should succeed because timeout is 1.0 > 0.5 + vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + class TestCustomBaseVWSURL: """Tests for using a custom base VWS URL.""" From 1a930ea8c1c3ac4e1ef130a26592a75815af28ac Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 2 Feb 2026 11:56:10 +0000 Subject: [PATCH 0930/1003] Fix mypy errors in timeout tests Use keyword arguments for patch.object and pytest.raises to satisfy mypy's type checking. Co-Authored-By: Claude Opus 4.5 --- tests/test_query.py | 10 +++++----- tests/test_vws.py | 10 +++++----- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/tests/test_query.py b/tests/test_query.py index a3f4c0331..6e8247ab1 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -136,11 +136,11 @@ def slow_request( with ( patch.object( - requests, - "request", + target=requests, + attribute="request", side_effect=slow_request, ), - pytest.raises(requests.exceptions.Timeout), + pytest.raises(expected_exception=requests.exceptions.Timeout), ): cloud_reco_client.query(image=image) @@ -185,8 +185,8 @@ def slow_request( return original_request(*args, **kwargs) # type: ignore[arg-type] with patch.object( - requests, - "request", + target=requests, + attribute="request", side_effect=slow_request, ): # This should succeed because timeout is 1.0 > 0.5 diff --git a/tests/test_vws.py b/tests/test_vws.py index 03b5818b3..0f03a1ccf 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -166,11 +166,11 @@ def slow_request( with ( patch.object( - requests, - "request", + target=requests, + attribute="request", side_effect=slow_request, ), - pytest.raises(requests.exceptions.Timeout), + pytest.raises(expected_exception=requests.exceptions.Timeout), ): vws_client.add_target( name="x", @@ -208,8 +208,8 @@ def slow_request( return original_request(*args, **kwargs) # type: ignore[arg-type] with patch.object( - requests, - "request", + target=requests, + attribute="request", side_effect=slow_request, ): # This should succeed because timeout is 1.0 > 0.5 From a0b073dc1f3e3c6a77be8425fa65cac5a49b43df Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 2 Feb 2026 11:56:45 +0000 Subject: [PATCH 0931/1003] Add pyright ignore comments for type checking Co-Authored-By: Claude Opus 4.5 --- tests/test_query.py | 4 ++-- tests/test_vws.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tests/test_query.py b/tests/test_query.py index 6e8247ab1..85b2d03ab 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -132,7 +132,7 @@ def slow_request( if timeout is not None and timeout < simulated_slow_threshold: time.sleep(0.2) raise requests.exceptions.Timeout - return original_request(*args, **kwargs) # type: ignore[arg-type] + return original_request(*args, **kwargs) # type: ignore[arg-type] # pyright: ignore[reportArgumentType] with ( patch.object( @@ -182,7 +182,7 @@ def slow_request( if timeout is not None and timeout < simulated_slow_threshold: time.sleep(0.2) raise requests.exceptions.Timeout - return original_request(*args, **kwargs) # type: ignore[arg-type] + return original_request(*args, **kwargs) # type: ignore[arg-type] # pyright: ignore[reportArgumentType] with patch.object( target=requests, diff --git a/tests/test_vws.py b/tests/test_vws.py index 0f03a1ccf..bbf157b4b 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -162,7 +162,7 @@ def slow_request( if timeout is not None and timeout < simulated_slow_threshold: time.sleep(0.2) raise requests.exceptions.Timeout - return original_request(*args, **kwargs) # type: ignore[arg-type] + return original_request(*args, **kwargs) # type: ignore[arg-type] # pyright: ignore[reportArgumentType] with ( patch.object( @@ -205,7 +205,7 @@ def slow_request( if timeout is not None and timeout < simulated_slow_threshold: time.sleep(0.2) raise requests.exceptions.Timeout - return original_request(*args, **kwargs) # type: ignore[arg-type] + return original_request(*args, **kwargs) # type: ignore[arg-type] # pyright: ignore[reportArgumentType] with patch.object( target=requests, From 06af721e61a9c9c287d86af354479cf546e6c481 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 3 Feb 2026 09:42:35 +0000 Subject: [PATCH 0932/1003] Apply pyproject-fmt formatting changes --- pyproject.toml | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index b24fc8ef8..706eec1bb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -89,16 +89,16 @@ urls.Source = "https://github.com/VWS-Python/vws-python" [tool.setuptools] zip-safe = false -[tool.setuptools.packages.find] -where = [ - "src", -] - [tool.setuptools.package-data] vws = [ "py.typed", ] +[tool.setuptools.packages.find] +where = [ + "src", +] + [tool.distutils.bdist_wheel] universal = true @@ -156,6 +156,12 @@ lint.pydocstyle.convention = "google" [tool.pylint] +[tool.pylint.'FORMAT'] + +# Allow the body of an if to be on the same line as the test if there is no +# else. +single-line-if-stmt = false + [tool.pylint.'MASTER'] # Pickle collected data for later comparisons. @@ -256,12 +262,6 @@ per-file-ignores = [ "doccmd_README_rst_*.py:invalid-name", ] -[tool.pylint.'FORMAT'] - -# Allow the body of an if to be on the same line as the test if there is no -# else. -single-line-if-stmt = false - [tool.pylint.'SPELLING'] # Spelling dictionary name. Available dictionaries: none. To make it working @@ -319,15 +319,15 @@ max_supported_python = "3.14" xfail_strict = true log_cli = true -[tool.coverage.run] - -branch = true - [tool.coverage.report] exclude_also = [ "if TYPE_CHECKING:", ] +[tool.coverage.run] + +branch = true + [tool.mypy] strict = true From a0091087ce92a6121f720380d92b13d19b820e03 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 3 Feb 2026 10:35:06 +0000 Subject: [PATCH 0933/1003] Bump pyrefly from 0.50.1 to 0.51.0 Bumps [pyrefly](https://github.com/facebook/pyrefly) from 0.50.1 to 0.51.0. - [Release notes](https://github.com/facebook/pyrefly/releases) - [Commits](https://github.com/facebook/pyrefly/compare/0.50.1...0.51.0) --- updated-dependencies: - dependency-name: pyrefly dependency-version: 0.51.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index e082d0dad..2b8127c7a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.12.1", - "pyrefly==0.50.1", + "pyrefly==0.51.0", "pyright==1.1.408", "pyroma==5.0.1", "pytest==9.0.2", From 62c1d7b547e48efa401afd6ea13e5fa1c4aa4516 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 4 Feb 2026 10:33:23 +0000 Subject: [PATCH 0934/1003] Bump ruff from 0.14.14 to 0.15.0 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.14.14 to 0.15.0. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.14.14...0.15.0) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.15.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2b8127c7a..86a1c0567 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==9.0.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.14.14", + "ruff==0.15.0", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 669eeb63db602acce9403e55bd6377df19a7e9a3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 5 Feb 2026 10:33:25 +0000 Subject: [PATCH 0935/1003] Bump ty from 0.0.14 to 0.0.15 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.14 to 0.0.15. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.14...0.0.15) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.15 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 86a1c0567..a72a70214 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -74,7 +74,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2026.1.12", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.14", + "ty==0.0.15", "types-requests==2.32.4.20260107", "vulture==2.14", "vws-python-mock==2025.3.10.1", From 5de56fc8482bbbf5299bdfe4055d1d29b1871b66 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 6 Feb 2026 10:33:19 +0000 Subject: [PATCH 0936/1003] Bump pyrefly from 0.51.0 to 0.51.1 Bumps [pyrefly](https://github.com/facebook/pyrefly) from 0.51.0 to 0.51.1. - [Release notes](https://github.com/facebook/pyrefly/releases) - [Commits](https://github.com/facebook/pyrefly/compare/0.51.0...0.51.1) --- updated-dependencies: - dependency-name: pyrefly dependency-version: 0.51.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index a72a70214..c8d5296f0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.12.1", - "pyrefly==0.51.0", + "pyrefly==0.51.1", "pyright==1.1.408", "pyroma==5.0.1", "pytest==9.0.2", From cb4b09565ee4de781443466d12239317830091f0 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 8 Feb 2026 13:26:26 +0000 Subject: [PATCH 0937/1003] Work around toml-fmt array comment bugs Avoid tox-dev/toml-fmt#184 (double quotes in comments corrupt arrays) by using single quotes in comments, and avoid tox-dev/toml-fmt#186 (single-quoted strings in arrays with comments get corrupted) by converting to double quotes. Co-Authored-By: Claude Opus 4.6 --- pyproject.toml | 74 +++++++++++++++++++++++++------------------------- 1 file changed, 37 insertions(+), 37 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index c8d5296f0..2d1e49c43 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -126,7 +126,7 @@ lint.ignore = [ "D212", # Ruff warns that this conflicts with the formatter. "ISC001", - # Ignore "too-many-*" errors as they seem to get in the way more than + # Ignore 'too-many-*' errors as they seem to get in the way more than # helping. "PLR0913", ] @@ -181,21 +181,21 @@ jobs = 0 # as they seemed to get in the way. load-plugins = [ "pylint_per_file_ignores", - 'pylint.extensions.bad_builtin', - 'pylint.extensions.comparison_placement', - 'pylint.extensions.consider_refactoring_into_while_condition', - 'pylint.extensions.docparams', - 'pylint.extensions.dunder', - 'pylint.extensions.eq_without_hash', - 'pylint.extensions.for_any_all', - 'pylint.extensions.mccabe', - 'pylint.extensions.no_self_use', - 'pylint.extensions.overlapping_exceptions', - 'pylint.extensions.private_import', - 'pylint.extensions.redefined_loop_name', - 'pylint.extensions.redefined_variable_type', - 'pylint.extensions.set_membership', - 'pylint.extensions.typing', + "pylint.extensions.bad_builtin", + "pylint.extensions.comparison_placement", + "pylint.extensions.consider_refactoring_into_while_condition", + "pylint.extensions.docparams", + "pylint.extensions.dunder", + "pylint.extensions.eq_without_hash", + "pylint.extensions.for_any_all", + "pylint.extensions.mccabe", + "pylint.extensions.no_self_use", + "pylint.extensions.overlapping_exceptions", + "pylint.extensions.private_import", + "pylint.extensions.redefined_loop_name", + "pylint.extensions.redefined_variable_type", + "pylint.extensions.set_membership", + "pylint.extensions.typing", ] # Allow loading of arbitrary C extensions. Extensions are imported into the @@ -209,12 +209,12 @@ unsafe-load-any-extension = false # multiple time (only on the command line, not in the configuration file where # it should appear only once). See also the "--disable" option for examples. enable = [ - 'bad-inline-option', - 'deprecated-pragma', - 'file-ignored', - 'spelling', - 'use-symbolic-message-instead', - 'useless-suppression', + "bad-inline-option", + "deprecated-pragma", + "file-ignored", + "spelling", + "use-symbolic-message-instead", + "useless-suppression", ] # Disable the message, report, category or checker with the given id(s). You @@ -228,28 +228,28 @@ enable = [ # --disable=W" disable = [ - 'too-few-public-methods', - 'too-many-locals', - 'too-many-arguments', - 'too-many-instance-attributes', - 'too-many-return-statements', - 'too-many-lines', - 'locally-disabled', + "too-few-public-methods", + "too-many-locals", + "too-many-arguments", + "too-many-instance-attributes", + "too-many-return-statements", + "too-many-lines", + "locally-disabled", # Let ruff handle long lines - 'line-too-long', + "line-too-long", # Let ruff handle unused imports - 'unused-import', + "unused-import", # Let ruff deal with sorting - 'ungrouped-imports', + "ungrouped-imports", # We don't need everything to be documented because of mypy - 'missing-type-doc', - 'missing-return-type-doc', + "missing-type-doc", + "missing-return-type-doc", # Too difficult to please - 'duplicate-code', + "duplicate-code", # Let ruff handle imports - 'wrong-import-order', + "wrong-import-order", # mypy does not want untyped parameters. - 'useless-type-doc', + "useless-type-doc", ] # We ignore invalid names because: From 7721f7c3699de06751116058bc0967b5181f9348 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 8 Feb 2026 13:26:26 +0000 Subject: [PATCH 0938/1003] Bump pyproject-fmt to 2.14.0 and apply formatting Co-Authored-By: Claude Opus 4.6 --- pyproject.toml | 101 +++++++++++++++---------------------------------- 1 file changed, 31 insertions(+), 70 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 2d1e49c43..47c38d627 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pygments==2.19.2", "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", - "pyproject-fmt==2.12.1", + "pyproject-fmt==2.14.0", "pyrefly==0.51.1", "pyright==1.1.408", "pyroma==5.0.1", @@ -62,10 +62,6 @@ optional-dependencies.dev = [ "pytest-cov==7.0.0", "pyyaml==6.0.3", "ruff==0.15.0", - # We add shellcheck-py not only for shell scripts and shell code blocks, - # but also because having it installed means that ``actionlint-py`` will - # use it to lint shell commands in GitHub workflow files. - "shellcheck-py==0.11.0.1", "shfmt-py==3.12.0.2", "sphinx==9.1.0", "sphinx-copybutton==0.5.2", @@ -79,6 +75,10 @@ optional-dependencies.dev = [ "vulture==2.14", "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", + # We add shellcheck-py not only for shell scripts and shell code blocks, + # but also because having it installed means that ``actionlint-py`` will + # use it to lint shell commands in GitHub workflow files. + "shellcheck-py==0.11.0.1", "yamlfix==1.19.1", "zizmor==1.22.0", ] @@ -88,22 +88,17 @@ urls.Source = "https://github.com/VWS-Python/vws-python" [tool.setuptools] zip-safe = false - -[tool.setuptools.package-data] -vws = [ +package-data.vws = [ "py.typed", ] - -[tool.setuptools.packages.find] -where = [ +packages.find.where = [ "src", ] -[tool.distutils.bdist_wheel] -universal = true +[tool.distutils] +bdist_wheel.universal = true [tool.setuptools_scm] - # This keeps the start of the version the same as the last release. # This is useful for our documentation to include e.g. binary links # to the latest released binary. @@ -113,39 +108,34 @@ version_scheme = "post-release" [tool.ruff] line-length = 79 - lint.select = [ "ALL", ] lint.ignore = [ - # Ruff warns that this conflicts with the formatter. - "COM812", # Allow our chosen docstring line-style - pydocstringformatter handles formatting # but doesn't enforce D205 (blank line after summary) or D212 (summary on first line). "D205", - "D212", - # Ruff warns that this conflicts with the formatter. - "ISC001", # Ignore 'too-many-*' errors as they seem to get in the way more than # helping. "PLR0913", + # Ruff warns that this conflicts with the formatter. + "COM812", + # Ruff warns that this conflicts with the formatter. + "ISC001", + "D212", ] - lint.per-file-ignores."doccmd_*.py" = [ # Allow asserts in docs. "S101", ] - lint.per-file-ignores."docs/source/*.py" = [ # Allow asserts in docs. "S101", ] - lint.per-file-ignores."tests/*.py" = [ # Allow asserts in tests. "S101", ] - # Do not automatically remove commented out code. # We comment out code during development, and with VSCode auto-save, this code # is sometimes annoyingly removed. @@ -155,21 +145,13 @@ lint.unfixable = [ lint.pydocstyle.convention = "google" [tool.pylint] - -[tool.pylint.'FORMAT'] - # Allow the body of an if to be on the same line as the test if there is no # else. -single-line-if-stmt = false - -[tool.pylint.'MASTER'] - +"FORMAT".single-line-if-stmt = false # Pickle collected data for later comparisons. -persistent = true - +"MASTER".persistent = true # Use multiple processes to speed up Pylint. -jobs = 0 - +"MASTER".jobs = 0 # List of plugins (as comma separated values of python modules names) to load, # usually to register additional checkers. # See https://chezsoi.org/lucas/blog/pylint-strict-base-configuration.html. @@ -179,7 +161,7 @@ jobs = 0 # - pylint.extensions.magic_value # - pylint.extensions.while_used # as they seemed to get in the way. -load-plugins = [ +"MASTER".load-plugins = [ "pylint_per_file_ignores", "pylint.extensions.bad_builtin", "pylint.extensions.comparison_placement", @@ -197,18 +179,14 @@ load-plugins = [ "pylint.extensions.set_membership", "pylint.extensions.typing", ] - # Allow loading of arbitrary C extensions. Extensions are imported into the # active Python interpreter and may run arbitrary code. -unsafe-load-any-extension = false - -[tool.pylint.'MESSAGES CONTROL'] - +"MASTER".unsafe-load-any-extension = false # Enable the message, report, category or checker with the given id(s). You can # either give multiple identifier separated by comma (,) or put this option # multiple time (only on the command line, not in the configuration file where # it should appear only once). See also the "--disable" option for examples. -enable = [ +"MESSAGES CONTROL".enable = [ "bad-inline-option", "deprecated-pragma", "file-ignored", @@ -216,7 +194,6 @@ enable = [ "use-symbolic-message-instead", "useless-suppression", ] - # Disable the message, report, category or checker with the given id(s). You # can either give multiple identifiers separated by comma (,) or put this # option multiple times (only on the command line, not in the configuration @@ -226,8 +203,7 @@ enable = [ # --enable=similarities". If you want to run only the classes checker, but have # no Warning level messages displayed, use"--disable=all --enable=classes # --disable=W" - -disable = [ +"MESSAGES CONTROL".disable = [ "too-few-public-methods", "too-many-locals", "too-many-arguments", @@ -251,32 +227,25 @@ disable = [ # mypy does not want untyped parameters. "useless-type-doc", ] - # We ignore invalid names because: # - We want to use generated module names, which may not be valid, but are never seen. # - We want to use global variables in documentation, which may not be uppercase. # - conf.py is a Sphinx configuration file which requires lowercase global variable names. -per-file-ignores = [ +"MESSAGES CONTROL".per-file-ignores = [ "docs/source/conf.py:invalid-name", "docs/source/doccmd_*.py:invalid-name", "doccmd_README_rst_*.py:invalid-name", ] - -[tool.pylint.'SPELLING'] - # Spelling dictionary name. Available dictionaries: none. To make it working # install python-enchant package. -spelling-dict = 'en_US' - +"SPELLING".spelling-dict = "en_US" # A path to a file that contains private dictionary; one word per line. -spelling-private-dict-file = 'spelling_private_dict.txt' - +"SPELLING".spelling-private-dict-file = "spelling_private_dict.txt" # Tells whether to store unknown words to indicated private dictionary in # --spelling-private-dict-file option instead of raising a message. -spelling-store-unknown-words = 'no' +"SPELLING".spelling-store-unknown-words = "no" [tool.check-manifest] - ignore = [ ".checkmake-config.ini", ".prettierrc", @@ -314,22 +283,17 @@ indent = 4 keep_full_version = true max_supported_python = "3.14" -[tool.pytest.ini_options] - -xfail_strict = true -log_cli = true +[tool.pytest] +ini_options.xfail_strict = true +ini_options.log_cli = true -[tool.coverage.report] -exclude_also = [ +[tool.coverage] +report.exclude_also = [ "if TYPE_CHECKING:", ] - -[tool.coverage.run] - -branch = true +run.branch = true [tool.mypy] - strict = true files = [ "." ] exclude = [ "build" ] @@ -339,7 +303,6 @@ plugins = [ ] [tool.pyright] - enableTypeIgnoreComments = false reportUnnecessaryTypeIgnoreComment = true typeCheckingMode = "strict" @@ -359,7 +322,6 @@ omit-covered-files = true verbose = 2 [tool.doc8] - max_line_length = 2000 ignore_path = [ "./.eggs", @@ -408,7 +370,6 @@ ignore_names = [ "templates_path", "warning_is_error", ] - # Duplicate some of .gitignore exclude = [ ".venv" ] From 28780e38e30338b74a5bed80b1221ff6157420ac Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Mon, 9 Feb 2026 10:47:25 +0000 Subject: [PATCH 0939/1003] Bump pyproject-fmt to 2.14.2 --- pyproject.toml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 47c38d627..5dd6a685a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pygments==2.19.2", "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", - "pyproject-fmt==2.14.0", + "pyproject-fmt==2.14.2", "pyrefly==0.51.1", "pyright==1.1.408", "pyroma==5.0.1", @@ -62,6 +62,10 @@ optional-dependencies.dev = [ "pytest-cov==7.0.0", "pyyaml==6.0.3", "ruff==0.15.0", + # We add shellcheck-py not only for shell scripts and shell code blocks, + # but also because having it installed means that ``actionlint-py`` will + # use it to lint shell commands in GitHub workflow files. + "shellcheck-py==0.11.0.1", "shfmt-py==3.12.0.2", "sphinx==9.1.0", "sphinx-copybutton==0.5.2", @@ -75,10 +79,6 @@ optional-dependencies.dev = [ "vulture==2.14", "vws-python-mock==2025.3.10.1", "vws-test-fixtures==2023.3.5", - # We add shellcheck-py not only for shell scripts and shell code blocks, - # but also because having it installed means that ``actionlint-py`` will - # use it to lint shell commands in GitHub workflow files. - "shellcheck-py==0.11.0.1", "yamlfix==1.19.1", "zizmor==1.22.0", ] @@ -112,17 +112,17 @@ lint.select = [ "ALL", ] lint.ignore = [ + # Ruff warns that this conflicts with the formatter. + "COM812", # Allow our chosen docstring line-style - pydocstringformatter handles formatting # but doesn't enforce D205 (blank line after summary) or D212 (summary on first line). "D205", + "D212", + # Ruff warns that this conflicts with the formatter. + "ISC001", # Ignore 'too-many-*' errors as they seem to get in the way more than # helping. "PLR0913", - # Ruff warns that this conflicts with the formatter. - "COM812", - # Ruff warns that this conflicts with the formatter. - "ISC001", - "D212", ] lint.per-file-ignores."doccmd_*.py" = [ # Allow asserts in docs. From a4478f35a67cf32cc7faab486e28ea8ec46e190e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 9 Feb 2026 11:42:27 +0000 Subject: [PATCH 0940/1003] Bump pyrefly from 0.51.1 to 0.51.2 Bumps [pyrefly](https://github.com/facebook/pyrefly) from 0.51.1 to 0.51.2. - [Release notes](https://github.com/facebook/pyrefly/releases) - [Commits](https://github.com/facebook/pyrefly/commits) --- updated-dependencies: - dependency-name: pyrefly dependency-version: 0.51.2 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5dd6a685a..bc7a0ec98 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.14.2", - "pyrefly==0.51.1", + "pyrefly==0.51.2", "pyright==1.1.408", "pyroma==5.0.1", "pytest==9.0.2", From 8cc2e58df6658fbfc28eae7d51a3ca99ec7dcbc0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 9 Feb 2026 11:42:39 +0000 Subject: [PATCH 0941/1003] Bump prek from 0.3.1 to 0.3.2 Bumps [prek](https://github.com/j178/prek) from 0.3.1 to 0.3.2. - [Release notes](https://github.com/j178/prek/releases) - [Changelog](https://github.com/j178/prek/blob/master/CHANGELOG.md) - [Commits](https://github.com/j178/prek/compare/v0.3.1...v0.3.2) --- updated-dependencies: - dependency-name: prek dependency-version: 0.3.2 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 5dd6a685a..6ba414452 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "interrogate==1.7.0", "mypy[faster-cache]==1.19.1", "mypy-strict-kwargs==2026.1.12", - "prek==0.3.1", + "prek==0.3.2", "pydocstringformatter==0.7.5", "pydocstyle==6.3", "pygments==2.19.2", From baa97f9e121d261444064ddff394417b893fabd7 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 10 Feb 2026 10:33:11 +0000 Subject: [PATCH 0942/1003] Bump pyrefly from 0.51.2 to 0.52.0 Bumps [pyrefly](https://github.com/facebook/pyrefly) from 0.51.2 to 0.52.0. - [Release notes](https://github.com/facebook/pyrefly/releases) - [Commits](https://github.com/facebook/pyrefly/commits/0.52.0) --- updated-dependencies: - dependency-name: pyrefly dependency-version: 0.52.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b9db7f6b8..32c854a40 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.14.2", - "pyrefly==0.51.2", + "pyrefly==0.52.0", "pyright==1.1.408", "pyroma==5.0.1", "pytest==9.0.2", From 17d7ac377ea891feceebc753dabb3277dc8b0f82 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 10 Feb 2026 10:33:16 +0000 Subject: [PATCH 0943/1003] Bump pyproject-fmt from 2.14.2 to 2.15.1 Bumps [pyproject-fmt](https://github.com/tox-dev/toml-fmt) from 2.14.2 to 2.15.1. - [Release notes](https://github.com/tox-dev/toml-fmt/releases) - [Commits](https://github.com/tox-dev/toml-fmt/compare/pyproject-fmt/2.14.2...pyproject-fmt/2.15.1) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-version: 2.15.1 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index b9db7f6b8..22287017f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pygments==2.19.2", "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", - "pyproject-fmt==2.14.2", + "pyproject-fmt==2.15.1", "pyrefly==0.51.2", "pyright==1.1.408", "pyroma==5.0.1", From b5087fbd447928b2a598e8233265d002fcb21afb Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Tue, 10 Feb 2026 10:39:19 +0000 Subject: [PATCH 0944/1003] Re-format pyproject.toml with pyproject-fmt 2.15.0 --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 22287017f..4046c5f44 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -288,10 +288,10 @@ ini_options.xfail_strict = true ini_options.log_cli = true [tool.coverage] +run.branch = true report.exclude_also = [ "if TYPE_CHECKING:", ] -run.branch = true [tool.mypy] strict = true From 3264eea681160f63114499ce70de382d767a8b56 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 11 Feb 2026 09:14:23 +0000 Subject: [PATCH 0945/1003] Update pyproject-fmt to 2.15.2 --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2919be653..9100eb182 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pygments==2.19.2", "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", - "pyproject-fmt==2.15.1", + "pyproject-fmt==2.15.2", "pyrefly==0.52.0", "pyright==1.1.408", "pyroma==5.0.1", From 72eaa04ad32c25aadb89d2ccd0fb2447c6577733 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 11 Feb 2026 10:33:32 +0000 Subject: [PATCH 0946/1003] Bump ty from 0.0.15 to 0.0.16 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.15 to 0.0.16. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.15...0.0.16) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.16 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 9100eb182..126fb24d2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -74,7 +74,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2026.1.12", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.15", + "ty==0.0.16", "types-requests==2.32.4.20260107", "vulture==2.14", "vws-python-mock==2025.3.10.1", From 75edda24ae41cbd83f611545584c1aef72a2d7f5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 12 Feb 2026 10:33:20 +0000 Subject: [PATCH 0947/1003] Bump pyproject-fmt from 2.15.2 to 2.15.3 Bumps [pyproject-fmt](https://github.com/tox-dev/toml-fmt) from 2.15.2 to 2.15.3. - [Release notes](https://github.com/tox-dev/toml-fmt/releases) - [Commits](https://github.com/tox-dev/toml-fmt/compare/pyproject-fmt/2.15.2...pyproject-fmt/2.15.3) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-version: 2.15.3 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 126fb24d2..c699fdc14 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pygments==2.19.2", "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", - "pyproject-fmt==2.15.2", + "pyproject-fmt==2.15.3", "pyrefly==0.52.0", "pyright==1.1.408", "pyroma==5.0.1", From f4e3dc1f7525ca75b47b31428bb47af24d9be950 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 13 Feb 2026 10:33:20 +0000 Subject: [PATCH 0948/1003] Bump pyproject-fmt from 2.15.3 to 2.16.0 Bumps [pyproject-fmt](https://github.com/tox-dev/toml-fmt) from 2.15.3 to 2.16.0. - [Release notes](https://github.com/tox-dev/toml-fmt/releases) - [Commits](https://github.com/tox-dev/toml-fmt/compare/pyproject-fmt/2.15.3...pyproject-fmt/2.16.0) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-version: 2.16.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c699fdc14..54eb5f3fd 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pygments==2.19.2", "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", - "pyproject-fmt==2.15.3", + "pyproject-fmt==2.16.0", "pyrefly==0.52.0", "pyright==1.1.408", "pyroma==5.0.1", From 615d5798a840f19f968930f0651f32ea7f310f85 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 13 Feb 2026 10:33:40 +0000 Subject: [PATCH 0949/1003] Bump ruff from 0.15.0 to 0.15.1 Bumps [ruff](https://github.com/astral-sh/ruff) from 0.15.0 to 0.15.1. - [Release notes](https://github.com/astral-sh/ruff/releases) - [Changelog](https://github.com/astral-sh/ruff/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ruff/compare/0.15.0...0.15.1) --- updated-dependencies: - dependency-name: ruff dependency-version: 0.15.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c699fdc14..1e7fdedf0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -61,7 +61,7 @@ optional-dependencies.dev = [ "pytest==9.0.2", "pytest-cov==7.0.0", "pyyaml==6.0.3", - "ruff==0.15.0", + "ruff==0.15.1", # We add shellcheck-py not only for shell scripts and shell code blocks, # but also because having it installed means that ``actionlint-py`` will # use it to lint shell commands in GitHub workflow files. From 8217323d13e44f8fa65f5a7ffe30288feb47a036 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 07:59:41 +0000 Subject: [PATCH 0950/1003] Accept tuple for request_timeout_seconds to match requests API The timeout parameter now accepts either a float (applied to both connect and read timeouts) or a (connect, read) tuple, matching the requests library's timeout interface. Updated docstrings to reference requests. Co-Authored-By: Claude Opus 4.6 --- src/vws/query.py | 8 +++++--- src/vws/vws.py | 14 +++++++++----- tests/test_query.py | 31 ++++++++++++++++++++++++++++++- tests/test_vws.py | 24 +++++++++++++++++++++++- 4 files changed, 67 insertions(+), 10 deletions(-) diff --git a/src/vws/query.py b/src/vws/query.py index b9d42d4c8..0e4e33d04 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -49,15 +49,17 @@ def __init__( client_access_key: str, client_secret_key: str, base_vwq_url: str = "https://cloudreco.vuforia.com", - request_timeout_seconds: float = 30.0, + request_timeout_seconds: float | tuple[float, float] = 30.0, ) -> None: """ Args: client_access_key: A VWS client access key. client_secret_key: A VWS client secret key. base_vwq_url: The base URL for the VWQ API. - request_timeout_seconds: The timeout in seconds for each HTTP - request made to the Cloud Reco API. + request_timeout_seconds: The timeout for each HTTP request, as + used by ``requests.request``. This can be a float to set + both the connect and read timeouts, or a (connect, read) + tuple. """ self._client_access_key = client_access_key self._client_secret_key = client_secret_key diff --git a/src/vws/vws.py b/src/vws/vws.py index 82eb7c5bc..dfb868cff 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -68,7 +68,7 @@ def _target_api_request( data: bytes, request_path: str, base_vws_url: str, - request_timeout_seconds: float, + request_timeout_seconds: float | tuple[float, float], ) -> Response: """Make a request to the Vuforia Target API. @@ -83,7 +83,9 @@ def _target_api_request( request_path: The path to the endpoint which will be used in the request. base_vws_url: The base URL for the VWS API. - request_timeout_seconds: The timeout in seconds for the request. + request_timeout_seconds: The timeout for the request, as used by + ``requests.request``. This can be a float to set both the + connect and read timeouts, or a (connect, read) tuple. Returns: The response to the request made by `requests`. @@ -135,15 +137,17 @@ def __init__( server_access_key: str, server_secret_key: str, base_vws_url: str = "https://vws.vuforia.com", - request_timeout_seconds: float = 30.0, + request_timeout_seconds: float | tuple[float, float] = 30.0, ) -> None: """ Args: server_access_key: A VWS server access key. server_secret_key: A VWS server secret key. base_vws_url: The base URL for the VWS API. - request_timeout_seconds: The timeout in seconds for each HTTP - request made to the VWS API. + request_timeout_seconds: The timeout for each HTTP request, as + used by ``requests.request``. This can be a float to set + both the connect and read timeouts, or a (connect, read) + tuple. """ self._server_access_key = server_access_key self._server_secret_key = server_secret_key diff --git a/tests/test_query.py b/tests/test_query.py index 85b2d03ab..d1e13f2cf 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -65,7 +65,7 @@ def test_default_timeout() -> None: @staticmethod def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: - """It is possible to set a custom request timeout.""" + """It is possible to set a custom request timeout as a float.""" with MockVWS() as mock: database = VuforiaDatabase() mock.add_database(database=database) @@ -93,6 +93,35 @@ def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: matches = cloud_reco_client.query(image=image) assert len(matches) == 1 + @staticmethod + def test_custom_timeout_tuple(image: io.BytesIO | BinaryIO) -> None: + """It is possible to set separate connect and read timeouts.""" + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + ) + custom_timeout = (5.0, 30.0) + cloud_reco_client = CloudRecoService( + client_access_key=database.client_access_key, + client_secret_key=database.client_secret_key, + request_timeout_seconds=custom_timeout, + ) + assert cloud_reco_client.request_timeout_seconds == custom_timeout + + target_id = vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + vws_client.wait_for_target_processed(target_id=target_id) + matches = cloud_reco_client.query(image=image) + assert len(matches) == 1 + @staticmethod def test_timeout_raises_on_slow_response( image: io.BytesIO | BinaryIO, diff --git a/tests/test_vws.py b/tests/test_vws.py index bbf157b4b..2350ca365 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -114,7 +114,7 @@ def test_default_timeout() -> None: @staticmethod def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: - """It is possible to set a custom request timeout.""" + """It is possible to set a custom request timeout as a float.""" with MockVWS() as mock: database = VuforiaDatabase() mock.add_database(database=database) @@ -135,6 +135,28 @@ def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: application_metadata=None, ) + @staticmethod + def test_custom_timeout_tuple(image: io.BytesIO | BinaryIO) -> None: + """It is possible to set separate connect and read timeouts.""" + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + custom_timeout = (5.0, 30.0) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + request_timeout_seconds=custom_timeout, + ) + assert vws_client.request_timeout_seconds == custom_timeout + + vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + @staticmethod def test_timeout_raises_on_slow_response( image: io.BytesIO | BinaryIO, From 1b2001ecdf413e236a9ab625df3f4a23324f7eee Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 08:05:28 +0000 Subject: [PATCH 0951/1003] Fix integer timeouts failing at request time _target_api_request used plain @beartype which rejects int for float, while VWS.__init__ used is_pep484_tower=True which accepts it. This caused integer timeouts to pass construction but fail on first request. Enable is_pep484_tower on _target_api_request and CloudRecoService too. Co-Authored-By: Claude Opus 4.6 --- src/vws/query.py | 4 ++-- src/vws/vws.py | 2 +- tests/test_query.py | 29 +++++++++++++++++++++++++++++ tests/test_vws.py | 22 ++++++++++++++++++++++ 4 files changed, 54 insertions(+), 3 deletions(-) diff --git a/src/vws/query.py b/src/vws/query.py index 0e4e33d04..db1945b11 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -8,7 +8,7 @@ from urllib.parse import urljoin import requests -from beartype import beartype +from beartype import BeartypeConf, beartype from urllib3.filepost import encode_multipart_formdata from vws_auth_tools import authorization_header, rfc_1123_date @@ -40,7 +40,7 @@ def _get_image_data(image: _ImageType) -> bytes: return image_data -@beartype +@beartype(conf=BeartypeConf(is_pep484_tower=True)) class CloudRecoService: """An interface to the Vuforia Cloud Recognition Web APIs.""" diff --git a/src/vws/vws.py b/src/vws/vws.py index dfb868cff..cdff3f906 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -58,7 +58,7 @@ def _get_image_data(image: _ImageType) -> bytes: return image_data -@beartype +@beartype(conf=BeartypeConf(is_pep484_tower=True)) def _target_api_request( *, content_type: str, diff --git a/tests/test_query.py b/tests/test_query.py index d1e13f2cf..5516a0ea4 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -93,6 +93,35 @@ def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: matches = cloud_reco_client.query(image=image) assert len(matches) == 1 + @staticmethod + def test_custom_timeout_int(image: io.BytesIO | BinaryIO) -> None: + """It is possible to set a custom request timeout as an int.""" + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + ) + custom_timeout = 60 + cloud_reco_client = CloudRecoService( + client_access_key=database.client_access_key, + client_secret_key=database.client_secret_key, + request_timeout_seconds=custom_timeout, + ) + assert cloud_reco_client.request_timeout_seconds == custom_timeout + + target_id = vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + vws_client.wait_for_target_processed(target_id=target_id) + matches = cloud_reco_client.query(image=image) + assert len(matches) == 1 + @staticmethod def test_custom_timeout_tuple(image: io.BytesIO | BinaryIO) -> None: """It is possible to set separate connect and read timeouts.""" diff --git a/tests/test_vws.py b/tests/test_vws.py index 2350ca365..db3b88b5d 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -135,6 +135,28 @@ def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: application_metadata=None, ) + @staticmethod + def test_custom_timeout_int(image: io.BytesIO | BinaryIO) -> None: + """It is possible to set a custom request timeout as an int.""" + with MockVWS() as mock: + database = VuforiaDatabase() + mock.add_database(database=database) + custom_timeout = 60 + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + request_timeout_seconds=custom_timeout, + ) + assert vws_client.request_timeout_seconds == custom_timeout + + vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + @staticmethod def test_custom_timeout_tuple(image: io.BytesIO | BinaryIO) -> None: """It is possible to set separate connect and read timeouts.""" From 7123758816b61dce6b9f132d8625c8a9f31f0266 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 08:18:06 +0000 Subject: [PATCH 0952/1003] Fix CI failures in timeout tests - Remove branching and time.sleep from slow_request mocks, fixing coverage gaps (partial branches) and Windows CI timeouts - Remove test_longer_timeout_succeeds (redundant with test_custom_timeout) - Assert the timeout value is passed correctly instead of branching - Remove unused time import and unused *args parameter Co-Authored-By: Claude Opus 4.6 --- tests/test_query.py | 66 ++++----------------------------------------- tests/test_vws.py | 59 ++++------------------------------------ 2 files changed, 10 insertions(+), 115 deletions(-) diff --git a/tests/test_query.py b/tests/test_query.py index 5516a0ea4..43af56711 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -1,7 +1,6 @@ """Tests for the ``CloudRecoService`` querying functionality.""" import io -import time import uuid from typing import BinaryIO from unittest.mock import patch @@ -156,6 +155,7 @@ def test_timeout_raises_on_slow_response( image: io.BytesIO | BinaryIO, ) -> None: """A short timeout raises an error when the server is slow.""" + custom_timeout = 0.1 with MockVWS() as mock: database = VuforiaDatabase() mock.add_database(database=database) @@ -166,7 +166,7 @@ def test_timeout_raises_on_slow_response( cloud_reco_client = CloudRecoService( client_access_key=database.client_access_key, client_secret_key=database.client_secret_key, - request_timeout_seconds=0.1, + request_timeout_seconds=custom_timeout, ) target_id = vws_client.add_target( @@ -178,19 +178,12 @@ def test_timeout_raises_on_slow_response( ) vws_client.wait_for_target_processed(target_id=target_id) - simulated_slow_threshold = 0.5 - original_request = requests.request - def slow_request( - *args: object, **kwargs: float | None, ) -> requests.Response: - """Simulate a slow server response.""" - timeout = kwargs.get("timeout") - if timeout is not None and timeout < simulated_slow_threshold: - time.sleep(0.2) - raise requests.exceptions.Timeout - return original_request(*args, **kwargs) # type: ignore[arg-type] # pyright: ignore[reportArgumentType] + """Simulate a server that is too slow to respond.""" + assert kwargs["timeout"] == custom_timeout + raise requests.exceptions.Timeout with ( patch.object( @@ -202,55 +195,6 @@ def slow_request( ): cloud_reco_client.query(image=image) - @staticmethod - def test_longer_timeout_succeeds(image: io.BytesIO | BinaryIO) -> None: - """A longer timeout allows slow responses to complete.""" - simulated_slow_threshold = 0.5 - - with MockVWS() as mock: - database = VuforiaDatabase() - mock.add_database(database=database) - vws_client = VWS( - server_access_key=database.server_access_key, - server_secret_key=database.server_secret_key, - ) - cloud_reco_client = CloudRecoService( - client_access_key=database.client_access_key, - client_secret_key=database.client_secret_key, - request_timeout_seconds=1.0, - ) - - target_id = vws_client.add_target( - name="x", - width=1, - image=image, - active_flag=True, - application_metadata=None, - ) - vws_client.wait_for_target_processed(target_id=target_id) - - original_request = requests.request - - def slow_request( - *args: object, - **kwargs: float | None, - ) -> requests.Response: - """Simulate a slow server response.""" - timeout = kwargs.get("timeout") - if timeout is not None and timeout < simulated_slow_threshold: - time.sleep(0.2) - raise requests.exceptions.Timeout - return original_request(*args, **kwargs) # type: ignore[arg-type] # pyright: ignore[reportArgumentType] - - with patch.object( - target=requests, - attribute="request", - side_effect=slow_request, - ): - # This should succeed because timeout is 1.0 > 0.5 - matches = cloud_reco_client.query(image=image) - assert len(matches) == 1 - class TestCustomBaseVWQURL: """Tests for using a custom base VWQ URL.""" diff --git a/tests/test_vws.py b/tests/test_vws.py index db3b88b5d..e141b041c 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -4,7 +4,6 @@ import datetime import io import secrets -import time import uuid from typing import BinaryIO from unittest.mock import patch @@ -184,29 +183,22 @@ def test_timeout_raises_on_slow_response( image: io.BytesIO | BinaryIO, ) -> None: """A short timeout raises an error when the server is slow.""" - simulated_slow_threshold = 0.5 - + custom_timeout = 0.1 with MockVWS() as mock: database = VuforiaDatabase() mock.add_database(database=database) vws_client = VWS( server_access_key=database.server_access_key, server_secret_key=database.server_secret_key, - request_timeout_seconds=0.1, + request_timeout_seconds=custom_timeout, ) - original_request = requests.request - def slow_request( - *args: object, **kwargs: float | None, ) -> requests.Response: - """Simulate a slow server response.""" - timeout = kwargs.get("timeout") - if timeout is not None and timeout < simulated_slow_threshold: - time.sleep(0.2) - raise requests.exceptions.Timeout - return original_request(*args, **kwargs) # type: ignore[arg-type] # pyright: ignore[reportArgumentType] + """Simulate a server that is too slow to respond.""" + assert kwargs["timeout"] == custom_timeout + raise requests.exceptions.Timeout with ( patch.object( @@ -224,47 +216,6 @@ def slow_request( application_metadata=None, ) - @staticmethod - def test_longer_timeout_succeeds(image: io.BytesIO | BinaryIO) -> None: - """A longer timeout allows slow responses to complete.""" - simulated_slow_threshold = 0.5 - - with MockVWS() as mock: - database = VuforiaDatabase() - mock.add_database(database=database) - vws_client = VWS( - server_access_key=database.server_access_key, - server_secret_key=database.server_secret_key, - request_timeout_seconds=1.0, - ) - - original_request = requests.request - - def slow_request( - *args: object, - **kwargs: float | None, - ) -> requests.Response: - """Simulate a slow server response.""" - timeout = kwargs.get("timeout") - if timeout is not None and timeout < simulated_slow_threshold: - time.sleep(0.2) - raise requests.exceptions.Timeout - return original_request(*args, **kwargs) # type: ignore[arg-type] # pyright: ignore[reportArgumentType] - - with patch.object( - target=requests, - attribute="request", - side_effect=slow_request, - ): - # This should succeed because timeout is 1.0 > 0.5 - vws_client.add_target( - name="x", - width=1, - image=image, - active_flag=True, - application_metadata=None, - ) - class TestCustomBaseVWSURL: """Tests for using a custom base VWS URL.""" From 74763f3b207b4e6c206b55bf56907d7eefcb2e43 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 08:25:35 +0000 Subject: [PATCH 0953/1003] Matrix lint workflow by hook stage --- .github/workflows/lint.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index f4c94be57..c6f0c8074 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -19,6 +19,7 @@ jobs: matrix: python-version: ['3.13'] platform: [ubuntu-latest, windows-latest] + hook-stage: [pre-commit, pre-push, manual] runs-on: ${{ matrix.platform }} @@ -37,10 +38,8 @@ jobs: # Use bash to ensure the step fails if any command fails. # PowerShell does not fail on intermediate command failures by default. shell: bash - run: | - uv run --extra=dev prek run --all-files --hook-stage pre-commit --verbose - uv run --extra=dev prek run --all-files --hook-stage pre-push --verbose - uv run --extra=dev prek run --all-files --hook-stage manual --verbose + run: uv run --extra=dev prek run --all-files --hook-stage ${{ matrix.hook-stage }} + --verbose env: UV_PYTHON: ${{ matrix.python-version }} From 16c4604eb208167feeffe1ebfdcc8dd30e2bc2b8 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 08:55:52 +0000 Subject: [PATCH 0954/1003] Bump vws-python-mock from 2025.3.10.1 to 2026.2.15 Co-Authored-By: Claude Opus 4.6 --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 15ca13f24..2b0fb465f 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -77,7 +77,7 @@ optional-dependencies.dev = [ "ty==0.0.16", "types-requests==2.32.4.20260107", "vulture==2.14", - "vws-python-mock==2025.3.10.1", + "vws-python-mock==2026.2.15", "vws-test-fixtures==2023.3.5", "yamlfix==1.19.1", "zizmor==1.22.0", From 5d0a72941fdde8e783e56d1ff9e3281ffa785c73 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 08:59:13 +0000 Subject: [PATCH 0955/1003] Use vws-python-mock response_delay_seconds for timeout tests Upgrade vws-python-mock to 2026.2.15 which adds response_delay_seconds parameter. Replace unittest.mock.patch-based timeout simulation with MockVWS(response_delay_seconds=0.5), testing the real timeout mechanism end-to-end. Co-Authored-By: Claude Opus 4.6 --- pyproject.toml | 2 +- tests/test_query.py | 22 +++------------------- tests/test_vws.py | 22 +++------------------- 3 files changed, 7 insertions(+), 39 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 9f1747298..68f237322 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -77,7 +77,7 @@ optional-dependencies.dev = [ "ty==0.0.14", "types-requests==2.32.4.20260107", "vulture==2.14", - "vws-python-mock==2025.3.10.1", + "vws-python-mock==2026.2.15", "vws-test-fixtures==2023.3.5", "yamlfix==1.19.1", "zizmor==1.22.0", diff --git a/tests/test_query.py b/tests/test_query.py index 43af56711..29a9b3b4e 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -3,7 +3,6 @@ import io import uuid from typing import BinaryIO -from unittest.mock import patch import pytest import requests @@ -155,8 +154,7 @@ def test_timeout_raises_on_slow_response( image: io.BytesIO | BinaryIO, ) -> None: """A short timeout raises an error when the server is slow.""" - custom_timeout = 0.1 - with MockVWS() as mock: + with MockVWS(response_delay_seconds=0.5) as mock: database = VuforiaDatabase() mock.add_database(database=database) vws_client = VWS( @@ -166,7 +164,7 @@ def test_timeout_raises_on_slow_response( cloud_reco_client = CloudRecoService( client_access_key=database.client_access_key, client_secret_key=database.client_secret_key, - request_timeout_seconds=custom_timeout, + request_timeout_seconds=0.1, ) target_id = vws_client.add_target( @@ -178,21 +176,7 @@ def test_timeout_raises_on_slow_response( ) vws_client.wait_for_target_processed(target_id=target_id) - def slow_request( - **kwargs: float | None, - ) -> requests.Response: - """Simulate a server that is too slow to respond.""" - assert kwargs["timeout"] == custom_timeout - raise requests.exceptions.Timeout - - with ( - patch.object( - target=requests, - attribute="request", - side_effect=slow_request, - ), - pytest.raises(expected_exception=requests.exceptions.Timeout), - ): + with pytest.raises(expected_exception=requests.exceptions.Timeout): cloud_reco_client.query(image=image) diff --git a/tests/test_vws.py b/tests/test_vws.py index e141b041c..5d2a58f89 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -6,7 +6,6 @@ import secrets import uuid from typing import BinaryIO -from unittest.mock import patch import pytest import requests @@ -183,31 +182,16 @@ def test_timeout_raises_on_slow_response( image: io.BytesIO | BinaryIO, ) -> None: """A short timeout raises an error when the server is slow.""" - custom_timeout = 0.1 - with MockVWS() as mock: + with MockVWS(response_delay_seconds=0.5) as mock: database = VuforiaDatabase() mock.add_database(database=database) vws_client = VWS( server_access_key=database.server_access_key, server_secret_key=database.server_secret_key, - request_timeout_seconds=custom_timeout, + request_timeout_seconds=0.1, ) - def slow_request( - **kwargs: float | None, - ) -> requests.Response: - """Simulate a server that is too slow to respond.""" - assert kwargs["timeout"] == custom_timeout - raise requests.exceptions.Timeout - - with ( - patch.object( - target=requests, - attribute="request", - side_effect=slow_request, - ), - pytest.raises(expected_exception=requests.exceptions.Timeout), - ): + with pytest.raises(expected_exception=requests.exceptions.Timeout): vws_client.add_target( name="x", width=1, From 90c8285c54c3f74bc161d2a46437b088fa529970 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 09:01:21 +0000 Subject: [PATCH 0956/1003] Add changelog entry for custom request timeout support Co-Authored-By: Claude Opus 4.6 --- CHANGELOG.rst | 2 ++ 1 file changed, 2 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 5527f9da1..174256880 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,8 @@ Changelog Next ---- +* Add ``request_timeout_seconds`` parameter to ``VWS`` and ``CloudRecoService``, allowing customization of the request timeout. This accepts a float or a ``(connect, read)`` tuple, matching the ``requests`` library's timeout interface. The default remains 30 seconds. + 2025.03.10.1 ------------ From 88e1d775cf54e3d65280334bfbd4b3565de7b76e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 09:12:18 +0000 Subject: [PATCH 0957/1003] Parametrize custom timeout tests Co-Authored-By: Claude Opus 4.6 --- tests/test_query.py | 74 +++++++-------------------------------------- tests/test_vws.py | 60 +++++++----------------------------- 2 files changed, 22 insertions(+), 112 deletions(-) diff --git a/tests/test_query.py b/tests/test_query.py index 29a9b3b4e..dafe5a738 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -62,67 +62,15 @@ def test_default_timeout() -> None: assert cloud_reco_client.request_timeout_seconds == expected @staticmethod - def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: - """It is possible to set a custom request timeout as a float.""" - with MockVWS() as mock: - database = VuforiaDatabase() - mock.add_database(database=database) - vws_client = VWS( - server_access_key=database.server_access_key, - server_secret_key=database.server_secret_key, - ) - custom_timeout = 60.5 - cloud_reco_client = CloudRecoService( - client_access_key=database.client_access_key, - client_secret_key=database.client_secret_key, - request_timeout_seconds=custom_timeout, - ) - assert cloud_reco_client.request_timeout_seconds == custom_timeout - - # Verify requests work with the custom timeout - target_id = vws_client.add_target( - name="x", - width=1, - image=image, - active_flag=True, - application_metadata=None, - ) - vws_client.wait_for_target_processed(target_id=target_id) - matches = cloud_reco_client.query(image=image) - assert len(matches) == 1 - - @staticmethod - def test_custom_timeout_int(image: io.BytesIO | BinaryIO) -> None: - """It is possible to set a custom request timeout as an int.""" - with MockVWS() as mock: - database = VuforiaDatabase() - mock.add_database(database=database) - vws_client = VWS( - server_access_key=database.server_access_key, - server_secret_key=database.server_secret_key, - ) - custom_timeout = 60 - cloud_reco_client = CloudRecoService( - client_access_key=database.client_access_key, - client_secret_key=database.client_secret_key, - request_timeout_seconds=custom_timeout, - ) - assert cloud_reco_client.request_timeout_seconds == custom_timeout - - target_id = vws_client.add_target( - name="x", - width=1, - image=image, - active_flag=True, - application_metadata=None, - ) - vws_client.wait_for_target_processed(target_id=target_id) - matches = cloud_reco_client.query(image=image) - assert len(matches) == 1 - - @staticmethod - def test_custom_timeout_tuple(image: io.BytesIO | BinaryIO) -> None: - """It is possible to set separate connect and read timeouts.""" + @pytest.mark.parametrize( + argnames="custom_timeout", + argvalues=[60.5, 60, (5.0, 30.0)], + ) + def test_custom_timeout( + image: io.BytesIO | BinaryIO, + custom_timeout: int | float | tuple[float, float], # noqa: PYI041 + ) -> None: + """It is possible to set a custom request timeout.""" with MockVWS() as mock: database = VuforiaDatabase() mock.add_database(database=database) @@ -130,13 +78,13 @@ def test_custom_timeout_tuple(image: io.BytesIO | BinaryIO) -> None: server_access_key=database.server_access_key, server_secret_key=database.server_secret_key, ) - custom_timeout = (5.0, 30.0) cloud_reco_client = CloudRecoService( client_access_key=database.client_access_key, client_secret_key=database.client_secret_key, request_timeout_seconds=custom_timeout, ) - assert cloud_reco_client.request_timeout_seconds == custom_timeout + expected = custom_timeout + assert cloud_reco_client.request_timeout_seconds == expected target_id = vws_client.add_target( name="x", diff --git a/tests/test_vws.py b/tests/test_vws.py index 5d2a58f89..9fe63dc21 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -111,63 +111,25 @@ def test_default_timeout() -> None: assert vws_client.request_timeout_seconds == expected @staticmethod - def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: - """It is possible to set a custom request timeout as a float.""" - with MockVWS() as mock: - database = VuforiaDatabase() - mock.add_database(database=database) - custom_timeout = 60.5 - vws_client = VWS( - server_access_key=database.server_access_key, - server_secret_key=database.server_secret_key, - request_timeout_seconds=custom_timeout, - ) - assert vws_client.request_timeout_seconds == custom_timeout - - # Verify requests work with the custom timeout - vws_client.add_target( - name="x", - width=1, - image=image, - active_flag=True, - application_metadata=None, - ) - - @staticmethod - def test_custom_timeout_int(image: io.BytesIO | BinaryIO) -> None: - """It is possible to set a custom request timeout as an int.""" - with MockVWS() as mock: - database = VuforiaDatabase() - mock.add_database(database=database) - custom_timeout = 60 - vws_client = VWS( - server_access_key=database.server_access_key, - server_secret_key=database.server_secret_key, - request_timeout_seconds=custom_timeout, - ) - assert vws_client.request_timeout_seconds == custom_timeout - - vws_client.add_target( - name="x", - width=1, - image=image, - active_flag=True, - application_metadata=None, - ) - - @staticmethod - def test_custom_timeout_tuple(image: io.BytesIO | BinaryIO) -> None: - """It is possible to set separate connect and read timeouts.""" + @pytest.mark.parametrize( + argnames="custom_timeout", + argvalues=[60.5, 60, (5.0, 30.0)], + ) + def test_custom_timeout( + image: io.BytesIO | BinaryIO, + custom_timeout: int | float | tuple[float, float], # noqa: PYI041 + ) -> None: + """It is possible to set a custom request timeout.""" with MockVWS() as mock: database = VuforiaDatabase() mock.add_database(database=database) - custom_timeout = (5.0, 30.0) vws_client = VWS( server_access_key=database.server_access_key, server_secret_key=database.server_secret_key, request_timeout_seconds=custom_timeout, ) - assert vws_client.request_timeout_seconds == custom_timeout + expected = custom_timeout + assert vws_client.request_timeout_seconds == expected vws_client.add_target( name="x", From 605d27c4c81ca670e23b25ff2bcdded8cf20db14 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 10:42:29 +0000 Subject: [PATCH 0958/1003] Update timeout behavior and default-timeout tests --- src/vws/query.py | 4 ++-- src/vws/vws.py | 4 ++-- tests/test_query.py | 33 +++++++++++++++++++++++++++------ tests/test_vws.py | 43 +++++++++++++++++++++++++++++++++++++------ 4 files changed, 68 insertions(+), 16 deletions(-) diff --git a/src/vws/query.py b/src/vws/query.py index db1945b11..dd36e8f21 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -64,7 +64,7 @@ def __init__( self._client_access_key = client_access_key self._client_secret_key = client_secret_key self._base_vwq_url = base_vwq_url - self.request_timeout_seconds = request_timeout_seconds + self._request_timeout_seconds = request_timeout_seconds def query( self, @@ -147,7 +147,7 @@ def query( url=urljoin(base=self._base_vwq_url, url=request_path), headers=headers, data=content, - timeout=self.request_timeout_seconds, + timeout=self._request_timeout_seconds, ) response = Response( text=requests_response.text, diff --git a/src/vws/vws.py b/src/vws/vws.py index cdff3f906..4cb75ca32 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -152,7 +152,7 @@ def __init__( self._server_access_key = server_access_key self._server_secret_key = server_secret_key self._base_vws_url = base_vws_url - self.request_timeout_seconds = request_timeout_seconds + self._request_timeout_seconds = request_timeout_seconds def make_request( self, @@ -196,7 +196,7 @@ def make_request( data=data, request_path=request_path, base_vws_url=self._base_vws_url, - request_timeout_seconds=self.request_timeout_seconds, + request_timeout_seconds=self._request_timeout_seconds, ) if ( diff --git a/tests/test_query.py b/tests/test_query.py index dafe5a738..fd014cadf 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -6,6 +6,7 @@ import pytest import requests +from freezegun import freeze_time from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase @@ -48,18 +49,38 @@ class TestCustomRequestTimeout: """Tests for using a custom request timeout.""" @staticmethod - def test_default_timeout() -> None: - """By default, the request timeout is 30 seconds.""" - default_timeout_seconds = 30.0 - with MockVWS() as mock: + @pytest.mark.parametrize( + argnames=("response_delay_seconds", "expect_timeout"), + argvalues=[(29, False), (31, True)], + ) + def test_default_timeout( + image: io.BytesIO | BinaryIO, + *, + response_delay_seconds: int, + expect_timeout: bool, + ) -> None: + """At 29 seconds there is no error; at 31 seconds there is a + timeout. + """ + with ( + freeze_time(auto_tick_seconds=1), + MockVWS(response_delay_seconds=response_delay_seconds) as mock, + ): database = VuforiaDatabase() mock.add_database(database=database) cloud_reco_client = CloudRecoService( client_access_key=database.client_access_key, client_secret_key=database.client_secret_key, ) - expected = default_timeout_seconds - assert cloud_reco_client.request_timeout_seconds == expected + + if expect_timeout: + with pytest.raises( + expected_exception=requests.exceptions.Timeout, + ): + cloud_reco_client.query(image=image) + else: + matches = cloud_reco_client.query(image=image) + assert matches == [] @staticmethod @pytest.mark.parametrize( diff --git a/tests/test_vws.py b/tests/test_vws.py index 9fe63dc21..03dc796c9 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -97,18 +97,49 @@ class TestCustomRequestTimeout: """Tests for using a custom request timeout.""" @staticmethod - def test_default_timeout() -> None: - """By default, the request timeout is 30 seconds.""" - default_timeout_seconds = 30.0 - with MockVWS() as mock: + @pytest.mark.parametrize( + argnames=("response_delay_seconds", "expect_timeout"), + argvalues=[(29, False), (31, True)], + ) + def test_default_timeout( + image: io.BytesIO | BinaryIO, + *, + response_delay_seconds: int, + expect_timeout: bool, + ) -> None: + """At 29 seconds there is no error; at 31 seconds there is a + timeout. + """ + with ( + freeze_time(auto_tick_seconds=1), + MockVWS(response_delay_seconds=response_delay_seconds) as mock, + ): database = VuforiaDatabase() mock.add_database(database=database) vws_client = VWS( server_access_key=database.server_access_key, server_secret_key=database.server_secret_key, ) - expected = default_timeout_seconds - assert vws_client.request_timeout_seconds == expected + + if expect_timeout: + with pytest.raises( + expected_exception=requests.exceptions.Timeout, + ): + vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + else: + vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) @staticmethod @pytest.mark.parametrize( From 2af9315334564b8685a13d3180bd67682ed258dd Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 10:43:05 +0000 Subject: [PATCH 0959/1003] Remove mypy-invalid timeout attribute assertions --- tests/test_query.py | 2 -- tests/test_vws.py | 2 -- 2 files changed, 4 deletions(-) diff --git a/tests/test_query.py b/tests/test_query.py index fd014cadf..32c07989b 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -104,8 +104,6 @@ def test_custom_timeout( client_secret_key=database.client_secret_key, request_timeout_seconds=custom_timeout, ) - expected = custom_timeout - assert cloud_reco_client.request_timeout_seconds == expected target_id = vws_client.add_target( name="x", diff --git a/tests/test_vws.py b/tests/test_vws.py index 03dc796c9..bb71a0236 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -159,8 +159,6 @@ def test_custom_timeout( server_secret_key=database.server_secret_key, request_timeout_seconds=custom_timeout, ) - expected = custom_timeout - assert vws_client.request_timeout_seconds == expected vws_client.add_target( name="x", From 1c987da7c138b886d92fd49a50173338cc3eb422 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 10:48:13 +0000 Subject: [PATCH 0960/1003] Fix pylint empty-list comparison in timeout test --- tests/test_query.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/test_query.py b/tests/test_query.py index 32c07989b..3c78e7f77 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -80,16 +80,16 @@ def test_default_timeout( cloud_reco_client.query(image=image) else: matches = cloud_reco_client.query(image=image) - assert matches == [] + assert not matches @staticmethod @pytest.mark.parametrize( argnames="custom_timeout", - argvalues=[60.5, 60, (5.0, 30.0)], + argvalues=[60.5, 60.0, (5.0, 30.0)], ) def test_custom_timeout( image: io.BytesIO | BinaryIO, - custom_timeout: int | float | tuple[float, float], # noqa: PYI041 + custom_timeout: float | tuple[float, float], ) -> None: """It is possible to set a custom request timeout.""" with MockVWS() as mock: From 80c214b77f2ebaee417c45b63ef974ce420cdf95 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 10:51:47 +0000 Subject: [PATCH 0961/1003] Align timeout test parameter types --- tests/test_vws.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/test_vws.py b/tests/test_vws.py index bb71a0236..be4dd7a7e 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -144,11 +144,11 @@ def test_default_timeout( @staticmethod @pytest.mark.parametrize( argnames="custom_timeout", - argvalues=[60.5, 60, (5.0, 30.0)], + argvalues=[60.5, 60.0, (5.0, 30.0)], ) def test_custom_timeout( image: io.BytesIO | BinaryIO, - custom_timeout: int | float | tuple[float, float], # noqa: PYI041 + custom_timeout: float | tuple[float, float], ) -> None: """It is possible to set a custom request timeout.""" with MockVWS() as mock: From bdaacd891b766e5a5fafd3cef2c9e4b22e4f2ce8 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 11:59:12 +0000 Subject: [PATCH 0962/1003] Bump mock-vws and use sleep_fn in timeout tests --- pyproject.toml | 2 +- tests/test_query.py | 44 ++++++++------------------------------------ tests/test_vws.py | 36 +++++++----------------------------- 3 files changed, 16 insertions(+), 66 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 2b0fb465f..2f5a29b78 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -77,7 +77,7 @@ optional-dependencies.dev = [ "ty==0.0.16", "types-requests==2.32.4.20260107", "vulture==2.14", - "vws-python-mock==2026.2.15", + "vws-python-mock==2026.2.15.4", "vws-test-fixtures==2023.3.5", "yamlfix==1.19.1", "zizmor==1.22.0", diff --git a/tests/test_query.py b/tests/test_query.py index 3c78e7f77..4e7ccb86d 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -1,5 +1,6 @@ """Tests for the ``CloudRecoService`` querying functionality.""" +import datetime import io import uuid from typing import BinaryIO @@ -63,8 +64,13 @@ def test_default_timeout( timeout. """ with ( - freeze_time(auto_tick_seconds=1), - MockVWS(response_delay_seconds=response_delay_seconds) as mock, + freeze_time() as frozen_datetime, + MockVWS( + response_delay_seconds=response_delay_seconds, + sleep_fn=lambda seconds: frozen_datetime.tick( + delta=datetime.timedelta(seconds=seconds), + ), + ) as mock, ): database = VuforiaDatabase() mock.add_database(database=database) @@ -82,40 +88,6 @@ def test_default_timeout( matches = cloud_reco_client.query(image=image) assert not matches - @staticmethod - @pytest.mark.parametrize( - argnames="custom_timeout", - argvalues=[60.5, 60.0, (5.0, 30.0)], - ) - def test_custom_timeout( - image: io.BytesIO | BinaryIO, - custom_timeout: float | tuple[float, float], - ) -> None: - """It is possible to set a custom request timeout.""" - with MockVWS() as mock: - database = VuforiaDatabase() - mock.add_database(database=database) - vws_client = VWS( - server_access_key=database.server_access_key, - server_secret_key=database.server_secret_key, - ) - cloud_reco_client = CloudRecoService( - client_access_key=database.client_access_key, - client_secret_key=database.client_secret_key, - request_timeout_seconds=custom_timeout, - ) - - target_id = vws_client.add_target( - name="x", - width=1, - image=image, - active_flag=True, - application_metadata=None, - ) - vws_client.wait_for_target_processed(target_id=target_id) - matches = cloud_reco_client.query(image=image) - assert len(matches) == 1 - @staticmethod def test_timeout_raises_on_slow_response( image: io.BytesIO | BinaryIO, diff --git a/tests/test_vws.py b/tests/test_vws.py index be4dd7a7e..e93c35063 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -111,8 +111,13 @@ def test_default_timeout( timeout. """ with ( - freeze_time(auto_tick_seconds=1), - MockVWS(response_delay_seconds=response_delay_seconds) as mock, + freeze_time() as frozen_datetime, + MockVWS( + response_delay_seconds=response_delay_seconds, + sleep_fn=lambda seconds: frozen_datetime.tick( + delta=datetime.timedelta(seconds=seconds), + ), + ) as mock, ): database = VuforiaDatabase() mock.add_database(database=database) @@ -141,33 +146,6 @@ def test_default_timeout( application_metadata=None, ) - @staticmethod - @pytest.mark.parametrize( - argnames="custom_timeout", - argvalues=[60.5, 60.0, (5.0, 30.0)], - ) - def test_custom_timeout( - image: io.BytesIO | BinaryIO, - custom_timeout: float | tuple[float, float], - ) -> None: - """It is possible to set a custom request timeout.""" - with MockVWS() as mock: - database = VuforiaDatabase() - mock.add_database(database=database) - vws_client = VWS( - server_access_key=database.server_access_key, - server_secret_key=database.server_secret_key, - request_timeout_seconds=custom_timeout, - ) - - vws_client.add_target( - name="x", - width=1, - image=image, - active_flag=True, - application_metadata=None, - ) - @staticmethod def test_timeout_raises_on_slow_response( image: io.BytesIO | BinaryIO, From ff977797212068c55040d02ae4326992eba2d1b1 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 11:59:50 +0000 Subject: [PATCH 0963/1003] Fix sleep_fn return type for mypy --- tests/test_query.py | 9 ++++++--- tests/test_vws.py | 9 ++++++--- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/tests/test_query.py b/tests/test_query.py index 4e7ccb86d..8c6a73769 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -67,9 +67,12 @@ def test_default_timeout( freeze_time() as frozen_datetime, MockVWS( response_delay_seconds=response_delay_seconds, - sleep_fn=lambda seconds: frozen_datetime.tick( - delta=datetime.timedelta(seconds=seconds), - ), + sleep_fn=lambda seconds: ( + frozen_datetime.tick( + delta=datetime.timedelta(seconds=seconds), + ), + None, + )[1], ) as mock, ): database = VuforiaDatabase() diff --git a/tests/test_vws.py b/tests/test_vws.py index e93c35063..6bb771f14 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -114,9 +114,12 @@ def test_default_timeout( freeze_time() as frozen_datetime, MockVWS( response_delay_seconds=response_delay_seconds, - sleep_fn=lambda seconds: frozen_datetime.tick( - delta=datetime.timedelta(seconds=seconds), - ), + sleep_fn=lambda seconds: ( + frozen_datetime.tick( + delta=datetime.timedelta(seconds=seconds), + ), + None, + )[1], ) as mock, ): database = VuforiaDatabase() From a8b8800f4c19b1d7c2d10063bd2e398154b296ec Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 12:03:14 +0000 Subject: [PATCH 0964/1003] Bump vws-python-mock to 2026.2.15.4 Co-Authored-By: Claude Haiku 4.5 --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 2b0fb465f..2f5a29b78 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -77,7 +77,7 @@ optional-dependencies.dev = [ "ty==0.0.16", "types-requests==2.32.4.20260107", "vulture==2.14", - "vws-python-mock==2026.2.15", + "vws-python-mock==2026.2.15.4", "vws-test-fixtures==2023.3.5", "yamlfix==1.19.1", "zizmor==1.22.0", From 2d64771065a113a59c3dd65fa44f50577fe8b4b5 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 12:07:32 +0000 Subject: [PATCH 0965/1003] Add tests for the default 30-second request timeout Test that VWS and CloudRecoService requests succeed at 29 seconds and time out at 31 seconds, verifying the existing default timeout behavior. Co-Authored-By: Claude Opus 4.6 --- tests/test_query.py | 50 ++++++++++++++++++++++++++++++++++++++ tests/test_vws.py | 58 +++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 108 insertions(+) diff --git a/tests/test_query.py b/tests/test_query.py index a79a712c0..31284325d 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -1,9 +1,13 @@ """Tests for the ``CloudRecoService`` querying functionality.""" +import datetime import io import uuid from typing import BinaryIO +import pytest +import requests +from freezegun import freeze_time from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase @@ -42,6 +46,52 @@ def test_match( assert matching_target.target_id == target_id +class TestDefaultRequestTimeout: + """Tests for the default request timeout.""" + + @staticmethod + @pytest.mark.parametrize( + argnames=("response_delay_seconds", "expect_timeout"), + argvalues=[(29, False), (31, True)], + ) + def test_default_timeout( + image: io.BytesIO | BinaryIO, + *, + response_delay_seconds: int, + expect_timeout: bool, + ) -> None: + """At 29 seconds there is no error; at 31 seconds there is a + timeout. + """ + with ( + freeze_time() as frozen_datetime, + MockVWS( + response_delay_seconds=response_delay_seconds, + sleep_fn=lambda seconds: ( + frozen_datetime.tick( + delta=datetime.timedelta(seconds=seconds), + ), + None, + )[1], + ) as mock, + ): + database = VuforiaDatabase() + mock.add_database(database=database) + cloud_reco_client = CloudRecoService( + client_access_key=database.client_access_key, + client_secret_key=database.client_secret_key, + ) + + if expect_timeout: + with pytest.raises( + expected_exception=requests.exceptions.Timeout, + ): + cloud_reco_client.query(image=image) + else: + matches = cloud_reco_client.query(image=image) + assert not matches + + class TestCustomBaseVWQURL: """Tests for using a custom base VWQ URL.""" diff --git a/tests/test_vws.py b/tests/test_vws.py index 00936bde8..9a1c8ded9 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -8,6 +8,7 @@ from typing import BinaryIO import pytest +import requests from freezegun import freeze_time from mock_vws import MockVWS from mock_vws.database import VuforiaDatabase @@ -92,6 +93,63 @@ def test_add_two_targets( ) +class TestDefaultRequestTimeout: + """Tests for the default request timeout.""" + + @staticmethod + @pytest.mark.parametrize( + argnames=("response_delay_seconds", "expect_timeout"), + argvalues=[(29, False), (31, True)], + ) + def test_default_timeout( + image: io.BytesIO | BinaryIO, + *, + response_delay_seconds: int, + expect_timeout: bool, + ) -> None: + """At 29 seconds there is no error; at 31 seconds there is a + timeout. + """ + with ( + freeze_time() as frozen_datetime, + MockVWS( + response_delay_seconds=response_delay_seconds, + sleep_fn=lambda seconds: ( + frozen_datetime.tick( + delta=datetime.timedelta(seconds=seconds), + ), + None, + )[1], + ) as mock, + ): + database = VuforiaDatabase() + mock.add_database(database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + ) + + if expect_timeout: + with pytest.raises( + expected_exception=requests.exceptions.Timeout, + ): + vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + else: + vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + + class TestCustomBaseVWSURL: """Tests for using a custom base VWS URL.""" From 26b9256dcaca967567f75b28b0720ed22a03cbde Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 12:16:17 +0000 Subject: [PATCH 0966/1003] Add pyrefly non-exhaustive match as error --- pyproject.toml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index 2f5a29b78..2dadc4af3 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -376,3 +376,6 @@ exclude = [ ".venv" ] [tool.yamlfix] section_whitelines = 1 whitelines = 1 + +[tool.pyrefly] +errors.non-exhaustive-match = "error" From 495fad3cd48a71698a9e0f3518727682fd4505bd Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Sun, 15 Feb 2026 12:20:06 +0000 Subject: [PATCH 0967/1003] [pre-commit.ci lite] apply automatic fixes --- pyproject.toml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index 2dadc4af3..ed1e46588 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -302,6 +302,9 @@ plugins = [ "mypy_strict_kwargs", ] +[tool.pyrefly] +errors.non-exhaustive-match = "error" + [tool.pyright] enableTypeIgnoreComments = false reportUnnecessaryTypeIgnoreComment = true @@ -376,6 +379,3 @@ exclude = [ ".venv" ] [tool.yamlfix] section_whitelines = 1 whitelines = 1 - -[tool.pyrefly] -errors.non-exhaustive-match = "error" From a69677c294e8fd5ce4db907594cf17cba163b034 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 12:32:59 +0000 Subject: [PATCH 0968/1003] Add fast tests for custom request timeouts --- tests/test_query.py | 55 +++++++++++++++++++++++++++++++++++++ tests/test_vws.py | 66 +++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 121 insertions(+) diff --git a/tests/test_query.py b/tests/test_query.py index 31284325d..d7b64aff2 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -92,6 +92,61 @@ def test_default_timeout( assert not matches +class TestCustomRequestTimeout: + """Tests for custom request timeout values.""" + + @staticmethod + @pytest.mark.parametrize( + argnames=( + "custom_timeout", + "response_delay_seconds", + "expect_timeout", + ), + argvalues=[ + (0.1, 0.09, False), + (0.1, 0.11, True), + ((5.0, 0.1), 0.09, False), + ((5.0, 0.1), 0.11, True), + ], + ) + def test_custom_timeout( + image: io.BytesIO | BinaryIO, + *, + custom_timeout: float | tuple[float, float], + response_delay_seconds: float, + expect_timeout: bool, + ) -> None: + """Custom timeouts are honored for both float and tuple forms.""" + with ( + freeze_time() as frozen_datetime, + MockVWS( + response_delay_seconds=response_delay_seconds, + sleep_fn=lambda seconds: ( + frozen_datetime.tick( + delta=datetime.timedelta(seconds=seconds), + ), + None, + )[1], + ) as mock, + ): + database = VuforiaDatabase() + mock.add_database(database=database) + cloud_reco_client = CloudRecoService( + client_access_key=database.client_access_key, + client_secret_key=database.client_secret_key, + request_timeout_seconds=custom_timeout, + ) + + if expect_timeout: + with pytest.raises( + expected_exception=requests.exceptions.Timeout, + ): + cloud_reco_client.query(image=image) + else: + matches = cloud_reco_client.query(image=image) + assert not matches + + class TestCustomBaseVWQURL: """Tests for using a custom base VWQ URL.""" diff --git a/tests/test_vws.py b/tests/test_vws.py index 9a1c8ded9..f09906ee5 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -150,6 +150,72 @@ def test_default_timeout( ) +class TestCustomRequestTimeout: + """Tests for custom request timeout values.""" + + @staticmethod + @pytest.mark.parametrize( + argnames=( + "custom_timeout", + "response_delay_seconds", + "expect_timeout", + ), + argvalues=[ + (0.1, 0.09, False), + (0.1, 0.11, True), + ((5.0, 0.1), 0.09, False), + ((5.0, 0.1), 0.11, True), + ], + ) + def test_custom_timeout( + image: io.BytesIO | BinaryIO, + *, + custom_timeout: float | tuple[float, float], + response_delay_seconds: float, + expect_timeout: bool, + ) -> None: + """Custom timeouts are honored for both float and tuple forms.""" + with ( + freeze_time() as frozen_datetime, + MockVWS( + response_delay_seconds=response_delay_seconds, + sleep_fn=lambda seconds: ( + frozen_datetime.tick( + delta=datetime.timedelta(seconds=seconds), + ), + None, + )[1], + ) as mock, + ): + database = VuforiaDatabase() + mock.add_database(database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + request_timeout_seconds=custom_timeout, + ) + + if expect_timeout: + with pytest.raises( + expected_exception=requests.exceptions.Timeout, + ): + vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + else: + vws_client.add_target( + name="x", + width=1, + image=image, + active_flag=True, + application_metadata=None, + ) + + class TestCustomBaseVWSURL: """Tests for using a custom base VWS URL.""" From 9654d576889369d483ceb1cac4881fb19ee36df5 Mon Sep 17 00:00:00 2001 From: adamtheturtle <797801+adamtheturtle@users.noreply.github.com> Date: Sun, 15 Feb 2026 12:36:58 +0000 Subject: [PATCH 0969/1003] Bump CHANGELOG --- CHANGELOG.rst | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 174256880..20a40ddb9 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,10 @@ Changelog Next ---- +2026.02.15 +---------- + + * Add ``request_timeout_seconds`` parameter to ``VWS`` and ``CloudRecoService``, allowing customization of the request timeout. This accepts a float or a ``(connect, read)`` tuple, matching the ``requests`` library's timeout interface. The default remains 30 seconds. 2025.03.10.1 From 1d1890940b37d3f0cd926d90608ab1fd29ee1af4 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sun, 15 Feb 2026 21:49:48 +0000 Subject: [PATCH 0970/1003] Enable coverage report.show_missing --- pyproject.toml | 1 + 1 file changed, 1 insertion(+) diff --git a/pyproject.toml b/pyproject.toml index 2dadc4af3..0da02ac7e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -293,6 +293,7 @@ report.exclude_also = [ "if TYPE_CHECKING:", ] +report.show_missing = true [tool.mypy] strict = true files = [ "." ] From afa54a8546aa455f8a8c4ae633a4e1bc239c52bc Mon Sep 17 00:00:00 2001 From: "pre-commit-ci-lite[bot]" <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com> Date: Sun, 15 Feb 2026 21:50:55 +0000 Subject: [PATCH 0971/1003] [pre-commit.ci lite] apply automatic fixes --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 0da02ac7e..931426792 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -292,8 +292,8 @@ run.branch = true report.exclude_also = [ "if TYPE_CHECKING:", ] - report.show_missing = true + [tool.mypy] strict = true files = [ "." ] From 9b9855a0b836115f14a54b7d004a27570cdf8502 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Feb 2026 11:29:09 +0000 Subject: [PATCH 0972/1003] Bump ty from 0.0.16 to 0.0.17 Bumps [ty](https://github.com/astral-sh/ty) from 0.0.16 to 0.0.17. - [Release notes](https://github.com/astral-sh/ty/releases) - [Changelog](https://github.com/astral-sh/ty/blob/main/CHANGELOG.md) - [Commits](https://github.com/astral-sh/ty/compare/0.0.16...0.0.17) --- updated-dependencies: - dependency-name: ty dependency-version: 0.0.17 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 43defd463..458aea327 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -74,7 +74,7 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2026.1.12", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", - "ty==0.0.16", + "ty==0.0.17", "types-requests==2.32.4.20260107", "vulture==2.14", "vws-python-mock==2026.2.15.4", From 1f228869cc8631068cfef17d3f2f0abdc4645892 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Feb 2026 11:29:21 +0000 Subject: [PATCH 0973/1003] Bump actionlint-py from 1.7.10.24 to 1.7.11.24 Bumps [actionlint-py](https://github.com/Mateusz-Grzelinski/actionlint-py) from 1.7.10.24 to 1.7.11.24. - [Commits](https://github.com/Mateusz-Grzelinski/actionlint-py/compare/v1.7.10.24...v1.7.11.24) --- updated-dependencies: - dependency-name: actionlint-py dependency-version: 1.7.11.24 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 43defd463..71a44c2da 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -38,7 +38,7 @@ dependencies = [ "vws-auth-tools>=2024.7.12", ] optional-dependencies.dev = [ - "actionlint-py==1.7.10.24", + "actionlint-py==1.7.11.24", "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", From 0b2673e6c03eab8ff5d101622248ea13401a1e0e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Feb 2026 11:29:27 +0000 Subject: [PATCH 0974/1003] Bump doccmd from 2026.1.31.3 to 2026.2.15 Bumps [doccmd](https://github.com/adamtheturtle/doccmd) from 2026.1.31.3 to 2026.2.15. - [Release notes](https://github.com/adamtheturtle/doccmd/releases) - [Changelog](https://github.com/adamtheturtle/doccmd/blob/main/CHANGELOG.rst) - [Commits](https://github.com/adamtheturtle/doccmd/compare/2026.01.31.3...2026.02.15) --- updated-dependencies: - dependency-name: doccmd dependency-version: 2026.2.15 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 43defd463..1d5189397 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -42,7 +42,7 @@ optional-dependencies.dev = [ "check-manifest==0.51", "deptry==0.24.0", "doc8==2.0.0", - "doccmd==2026.1.31.3", + "doccmd==2026.2.15", "freezegun==1.5.5", "furo==2025.12.19", "interrogate==1.7.0", From d3f91187ab612dfc214890650dc6b32a15f5d5b3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Feb 2026 11:29:38 +0000 Subject: [PATCH 0975/1003] Bump prek from 0.3.2 to 0.3.3 Bumps [prek](https://github.com/j178/prek) from 0.3.2 to 0.3.3. - [Release notes](https://github.com/j178/prek/releases) - [Changelog](https://github.com/j178/prek/blob/master/CHANGELOG.md) - [Commits](https://github.com/j178/prek/compare/v0.3.2...v0.3.3) --- updated-dependencies: - dependency-name: prek dependency-version: 0.3.3 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 43defd463..5676f951e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,7 +48,7 @@ optional-dependencies.dev = [ "interrogate==1.7.0", "mypy[faster-cache]==1.19.1", "mypy-strict-kwargs==2026.1.12", - "prek==0.3.2", + "prek==0.3.3", "pydocstringformatter==0.7.5", "pydocstyle==6.3", "pygments==2.19.2", From b179aa8f4762ed0dd782c28f64ef06c14beaf73f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 16 Feb 2026 11:38:48 +0000 Subject: [PATCH 0976/1003] Bump vws-python-mock from 2026.2.15.4 to 2026.2.15.5 Bumps [vws-python-mock](https://github.com/VWS-Python/vws-python-mock) from 2026.2.15.4 to 2026.2.15.5. - [Release notes](https://github.com/VWS-Python/vws-python-mock/releases) - [Changelog](https://github.com/VWS-Python/vws-python-mock/blob/main/CHANGELOG.rst) - [Commits](https://github.com/VWS-Python/vws-python-mock/compare/2026.02.15.4...2026.02.15.5) --- updated-dependencies: - dependency-name: vws-python-mock dependency-version: 2026.2.15.5 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c61d5e9e5..8aa97ac42 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -77,7 +77,7 @@ optional-dependencies.dev = [ "ty==0.0.17", "types-requests==2.32.4.20260107", "vulture==2.14", - "vws-python-mock==2026.2.15.4", + "vws-python-mock==2026.2.15.5", "vws-test-fixtures==2023.3.5", "yamlfix==1.19.1", "zizmor==1.22.0", From 8ebd2af35f65e9aad49011ad8684fc9021d20f8d Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 18 Feb 2026 10:33:41 +0000 Subject: [PATCH 0977/1003] Bump pyrefly from 0.52.0 to 0.53.0 Bumps [pyrefly](https://github.com/facebook/pyrefly) from 0.52.0 to 0.53.0. - [Release notes](https://github.com/facebook/pyrefly/releases) - [Commits](https://github.com/facebook/pyrefly/compare/0.52.0...0.53.0) --- updated-dependencies: - dependency-name: pyrefly dependency-version: 0.53.0 dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c4cdc33c0..f73e2c9e9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -55,7 +55,7 @@ optional-dependencies.dev = [ "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", "pyproject-fmt==2.16.0", - "pyrefly==0.52.0", + "pyrefly==0.53.0", "pyright==1.1.408", "pyroma==5.0.1", "pytest==9.0.2", From d0c90e256d180fc1a7ca494bbad4c52d61f0e84f Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 18 Feb 2026 10:33:56 +0000 Subject: [PATCH 0978/1003] Bump vws-python-mock from 2026.2.15.5 to 2026.2.18 Bumps [vws-python-mock](https://github.com/VWS-Python/vws-python-mock) from 2026.2.15.5 to 2026.2.18. - [Release notes](https://github.com/VWS-Python/vws-python-mock/releases) - [Changelog](https://github.com/VWS-Python/vws-python-mock/blob/main/CHANGELOG.rst) - [Commits](https://github.com/VWS-Python/vws-python-mock/compare/2026.02.15.5...2026.02.18) --- updated-dependencies: - dependency-name: vws-python-mock dependency-version: 2026.2.18 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index c4cdc33c0..61d1d0081 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -77,7 +77,7 @@ optional-dependencies.dev = [ "ty==0.0.17", "types-requests==2.32.4.20260107", "vulture==2.14", - "vws-python-mock==2026.2.15.5", + "vws-python-mock==2026.2.18", "vws-test-fixtures==2023.3.5", "yamlfix==1.19.1", "zizmor==1.22.0", From 1b4e9fa9403db4ac8f51111f25306860ec99a01e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 18 Feb 2026 10:37:18 +0000 Subject: [PATCH 0979/1003] Bump pyproject-fmt from 2.16.0 to 2.16.1 Bumps [pyproject-fmt](https://github.com/tox-dev/toml-fmt) from 2.16.0 to 2.16.1. - [Release notes](https://github.com/tox-dev/toml-fmt/releases) - [Commits](https://github.com/tox-dev/toml-fmt/compare/pyproject-fmt/2.16.0...pyproject-fmt/2.16.1) --- updated-dependencies: - dependency-name: pyproject-fmt dependency-version: 2.16.1 dependency-type: direct:development update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index f73e2c9e9..262882a72 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -54,7 +54,7 @@ optional-dependencies.dev = [ "pygments==2.19.2", "pylint[spelling]==4.0.4", "pylint-per-file-ignores==3.2.0", - "pyproject-fmt==2.16.0", + "pyproject-fmt==2.16.1", "pyrefly==0.53.0", "pyright==1.1.408", "pyroma==5.0.1", From f24db3bd1bb425e228c649a17f72580507285a8d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 18 Feb 2026 12:34:40 +0000 Subject: [PATCH 0980/1003] Use CPU-only PyTorch index to speed up dev dependency installation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit torch and torchvision are transitive dependencies of vws-python-mock. By default uv resolves them from PyPI, which provides CUDA-enabled wheels on Linux (~916 MB for torch). Redirecting to the pytorch CPU-only index reduces torch to ~189 MB — a 727 MB saving per cold-cache install. Following: https://vws-python.github.io/vws-python-mock/installation.html#faster-installation Co-Authored-By: Claude Sonnet 4.6 --- pyproject.toml | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/pyproject.toml b/pyproject.toml index fb0a98d48..28a4997a8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -74,6 +74,11 @@ optional-dependencies.dev = [ "sphinx-substitution-extensions==2026.1.12", "sphinxcontrib-spelling==8.0.2", "sybil==9.3.0", + # Listed explicitly (despite being transitive via vws-python-mock) so that + # [tool.uv.sources] can redirect to the CPU-only PyTorch index. + # See: https://vws-python.github.io/vws-python-mock/installation.html#faster-installation + "torch>=2.5.1", + "torchvision>=0.20.1", "ty==0.0.17", "types-requests==2.32.4.20260107", "vulture==2.14", @@ -106,6 +111,11 @@ bdist_wheel.universal = true # Code to match this is in ``conf.py``. version_scheme = "post-release" +[tool.uv] +sources.torch = { index = "pytorch-cpu" } +sources.torchvision = { index = "pytorch-cpu" } +index = [ { name = "pytorch-cpu", url = "https://download.pytorch.org/whl/cpu", explicit = true } ] + [tool.ruff] line-length = 79 lint.select = [ @@ -277,6 +287,13 @@ pep621_dev_dependency_groups = [ "dev", "release", ] +# torch and torchvision are listed explicitly in dev deps to allow +# [tool.uv.sources] to redirect them to the CPU-only PyTorch index, +# but they are not directly imported in the vws-python source code. +per_rule_ignores.DEP002 = [ + "torch", + "torchvision", +] [tool.pyproject-fmt] indent = 4 From b46173516abbe846d8f80472fbca928a463d8b5b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Feb 2026 09:31:54 +0000 Subject: [PATCH 0981/1003] Bump vws-python-mock to 2026.2.18.2 Co-Authored-By: Claude Haiku 4.5 --- pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pyproject.toml b/pyproject.toml index 28a4997a8..e6d42b7d0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -82,7 +82,7 @@ optional-dependencies.dev = [ "ty==0.0.17", "types-requests==2.32.4.20260107", "vulture==2.14", - "vws-python-mock==2026.2.18", + "vws-python-mock==2026.2.18.2", "vws-test-fixtures==2023.3.5", "yamlfix==1.19.1", "zizmor==1.22.0", From abe06b7bcd75830402f939581fdfe621091ed8c7 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 21 Feb 2026 00:31:41 +0000 Subject: [PATCH 0982/1003] Bump vws-python-mock to 2026.2.21 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Update VuforiaDatabase → CloudDatabase and add_database → add_cloud_database(cloud_database=) to match new API. Co-Authored-By: Claude Sonnet 4.6 --- conftest.py | 6 +++--- docs/source/index.rst | 6 +++--- pyproject.toml | 2 +- tests/conftest.py | 14 +++++++------- tests/test_cloud_reco_exceptions.py | 10 +++++----- tests/test_query.py | 14 +++++++------- tests/test_vws.py | 26 +++++++++++++------------- tests/test_vws_exceptions.py | 10 +++++----- 8 files changed, 44 insertions(+), 44 deletions(-) diff --git a/conftest.py b/conftest.py index 0e579a4db..89548f800 100644 --- a/conftest.py +++ b/conftest.py @@ -9,7 +9,7 @@ import pytest from beartype import beartype from mock_vws import MockVWS -from mock_vws.database import VuforiaDatabase +from mock_vws.database import CloudDatabase from sybil import Sybil from sybil.parsers.rest import ( ClearNamespaceParser, @@ -53,7 +53,7 @@ def fixture_mock_vws( client_access_key = uuid.uuid4().hex client_secret_key = uuid.uuid4().hex - database = VuforiaDatabase( + database = CloudDatabase( server_access_key=server_access_key, server_secret_key=server_secret_key, client_access_key=client_access_key, @@ -66,7 +66,7 @@ def fixture_mock_vws( monkeypatch.setenv(name="VWS_CLIENT_SECRET_KEY", value=client_secret_key) # We use a low processing time so that tests run quickly. with MockVWS(processing_time_seconds=0.2) as mock: - mock.add_database(database=database) + mock.add_cloud_database(cloud_database=database) yield diff --git a/docs/source/index.rst b/docs/source/index.rst index 818b0698d..c61c2a302 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -78,13 +78,13 @@ To write unit tests for code which uses this library, without using your Vuforia import pathlib from mock_vws import MockVWS - from mock_vws.database import VuforiaDatabase + from mock_vws.database import CloudDatabase from vws import VWS, CloudRecoService with MockVWS() as mock: - database = VuforiaDatabase() - mock.add_database(database=database) + database = CloudDatabase() + mock.add_cloud_database(cloud_database=database) vws_client = VWS( server_access_key=database.server_access_key, server_secret_key=database.server_secret_key, diff --git a/pyproject.toml b/pyproject.toml index e6d42b7d0..510f2c80b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -82,7 +82,7 @@ optional-dependencies.dev = [ "ty==0.0.17", "types-requests==2.32.4.20260107", "vulture==2.14", - "vws-python-mock==2026.2.18.2", + "vws-python-mock==2026.2.21", "vws-test-fixtures==2023.3.5", "yamlfix==1.19.1", "zizmor==1.22.0", diff --git a/tests/conftest.py b/tests/conftest.py index 7c0647786..9073a8c03 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -7,23 +7,23 @@ import pytest from mock_vws import MockVWS -from mock_vws.database import VuforiaDatabase +from mock_vws.database import CloudDatabase from vws import VWS, CloudRecoService @pytest.fixture(name="_mock_database") -def fixture_mock_database() -> Generator[VuforiaDatabase]: - """Yield a mock ``VuforiaDatabase``.""" +def fixture_mock_database() -> Generator[CloudDatabase]: + """Yield a mock ``CloudDatabase``.""" # We use a low processing time so that tests run quickly. with MockVWS(processing_time_seconds=0.2) as mock: - database = VuforiaDatabase() - mock.add_database(database=database) + database = CloudDatabase() + mock.add_cloud_database(cloud_database=database) yield database @pytest.fixture -def vws_client(_mock_database: VuforiaDatabase) -> VWS: +def vws_client(_mock_database: CloudDatabase) -> VWS: """A VWS client which connects to a mock database.""" return VWS( server_access_key=_mock_database.server_access_key, @@ -32,7 +32,7 @@ def vws_client(_mock_database: VuforiaDatabase) -> VWS: @pytest.fixture -def cloud_reco_client(_mock_database: VuforiaDatabase) -> CloudRecoService: +def cloud_reco_client(_mock_database: CloudDatabase) -> CloudRecoService: """A ``CloudRecoService`` client which connects to a mock database.""" return CloudRecoService( client_access_key=_mock_database.client_access_key, diff --git a/tests/test_cloud_reco_exceptions.py b/tests/test_cloud_reco_exceptions.py index 5576f4d40..3b2922fd9 100644 --- a/tests/test_cloud_reco_exceptions.py +++ b/tests/test_cloud_reco_exceptions.py @@ -6,7 +6,7 @@ import pytest from mock_vws import MockVWS -from mock_vws.database import VuforiaDatabase +from mock_vws.database import CloudDatabase from mock_vws.states import States from vws import CloudRecoService @@ -85,13 +85,13 @@ def test_authentication_failure( key exists but the client secret key is incorrect. """ - database = VuforiaDatabase() + database = CloudDatabase() cloud_reco_client = CloudRecoService( client_access_key=database.client_access_key, client_secret_key=uuid.uuid4().hex, ) with MockVWS() as mock: - mock.add_database(database=database) + mock.add_cloud_database(cloud_database=database) with pytest.raises( expected_exception=AuthenticationFailureError @@ -108,9 +108,9 @@ def test_inactive_project( An ``InactiveProject`` exception is raised when querying an inactive database. """ - database = VuforiaDatabase(state=States.PROJECT_INACTIVE) + database = CloudDatabase(state=States.PROJECT_INACTIVE) with MockVWS() as mock: - mock.add_database(database=database) + mock.add_cloud_database(cloud_database=database) cloud_reco_client = CloudRecoService( client_access_key=database.client_access_key, client_secret_key=database.client_secret_key, diff --git a/tests/test_query.py b/tests/test_query.py index d7b64aff2..b5ced6dde 100644 --- a/tests/test_query.py +++ b/tests/test_query.py @@ -9,7 +9,7 @@ import requests from freezegun import freeze_time from mock_vws import MockVWS -from mock_vws.database import VuforiaDatabase +from mock_vws.database import CloudDatabase from vws import VWS, CloudRecoService from vws.include_target_data import CloudRecoIncludeTargetData @@ -75,8 +75,8 @@ def test_default_timeout( )[1], ) as mock, ): - database = VuforiaDatabase() - mock.add_database(database=database) + database = CloudDatabase() + mock.add_cloud_database(cloud_database=database) cloud_reco_client = CloudRecoService( client_access_key=database.client_access_key, client_secret_key=database.client_secret_key, @@ -129,8 +129,8 @@ def test_custom_timeout( )[1], ) as mock, ): - database = VuforiaDatabase() - mock.add_database(database=database) + database = CloudDatabase() + mock.add_cloud_database(cloud_database=database) cloud_reco_client = CloudRecoService( client_access_key=database.client_access_key, client_secret_key=database.client_secret_key, @@ -160,8 +160,8 @@ def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: """ base_vwq_url = "http://example.com" with MockVWS(base_vwq_url=base_vwq_url) as mock: - database = VuforiaDatabase() - mock.add_database(database=database) + database = CloudDatabase() + mock.add_cloud_database(cloud_database=database) vws_client = VWS( server_access_key=database.server_access_key, server_secret_key=database.server_secret_key, diff --git a/tests/test_vws.py b/tests/test_vws.py index f09906ee5..87cdbf8f0 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -11,7 +11,7 @@ import requests from freezegun import freeze_time from mock_vws import MockVWS -from mock_vws.database import VuforiaDatabase +from mock_vws.database import CloudDatabase from vws import VWS, CloudRecoService from vws.exceptions.custom_exceptions import TargetProcessingTimeoutError @@ -122,8 +122,8 @@ def test_default_timeout( )[1], ) as mock, ): - database = VuforiaDatabase() - mock.add_database(database=database) + database = CloudDatabase() + mock.add_cloud_database(cloud_database=database) vws_client = VWS( server_access_key=database.server_access_key, server_secret_key=database.server_secret_key, @@ -187,8 +187,8 @@ def test_custom_timeout( )[1], ) as mock, ): - database = VuforiaDatabase() - mock.add_database(database=database) + database = CloudDatabase() + mock.add_cloud_database(cloud_database=database) vws_client = VWS( server_access_key=database.server_access_key, server_secret_key=database.server_secret_key, @@ -228,8 +228,8 @@ def test_custom_base_url(image: io.BytesIO | BinaryIO) -> None: """ base_vws_url = "http://example.com" with MockVWS(base_vws_url=base_vws_url) as mock: - database = VuforiaDatabase() - mock.add_database(database=database) + database = CloudDatabase() + mock.add_cloud_database(cloud_database=database) vws_client = VWS( server_access_key=database.server_access_key, server_secret_key=database.server_secret_key, @@ -489,8 +489,8 @@ def test_default_seconds_between_requests( ) -> None: """By default, 0.2 seconds are waited between polling requests.""" with MockVWS(processing_time_seconds=0.5) as mock: - database = VuforiaDatabase() - mock.add_database(database=database) + database = CloudDatabase() + mock.add_cloud_database(cloud_database=database) vws_client = VWS( server_access_key=database.server_access_key, server_secret_key=database.server_secret_key, @@ -541,8 +541,8 @@ def test_custom_seconds_between_requests( requests. """ with MockVWS(processing_time_seconds=0.5) as mock: - database = VuforiaDatabase() - mock.add_database(database=database) + database = CloudDatabase() + mock.add_cloud_database(cloud_database=database) vws_client = VWS( server_access_key=database.server_access_key, server_secret_key=database.server_secret_key, @@ -589,8 +589,8 @@ def test_custom_seconds_between_requests( def test_custom_timeout(image: io.BytesIO | BinaryIO) -> None: """It is possible to set a maximum timeout.""" with MockVWS(processing_time_seconds=0.5) as mock: - database = VuforiaDatabase() - mock.add_database(database=database) + database = CloudDatabase() + mock.add_cloud_database(cloud_database=database) vws_client = VWS( server_access_key=database.server_access_key, server_secret_key=database.server_secret_key, diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 4262b3ea6..74374e3d0 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -7,7 +7,7 @@ import pytest from freezegun import freeze_time from mock_vws import MockVWS -from mock_vws.database import VuforiaDatabase +from mock_vws.database import CloudDatabase from mock_vws.states import States from vws import VWS @@ -175,9 +175,9 @@ def test_project_inactive( inactive database. """ - database = VuforiaDatabase(state=States.PROJECT_INACTIVE) + database = CloudDatabase(state=States.PROJECT_INACTIVE) with MockVWS() as mock: - mock.add_database(database=database) + mock.add_cloud_database(cloud_database=database) vws_client = VWS( server_access_key=database.server_access_key, server_secret_key=database.server_secret_key, @@ -286,7 +286,7 @@ def test_authentication_failure( exists but the server secret key is incorrect, or when a client key is incorrect. """ - database = VuforiaDatabase() + database = CloudDatabase() vws_client = VWS( server_access_key=database.server_access_key, @@ -294,7 +294,7 @@ def test_authentication_failure( ) with MockVWS() as mock: - mock.add_database(database=database) + mock.add_cloud_database(cloud_database=database) with pytest.raises( expected_exception=AuthenticationFailureError From 1100913e2b1d0bf9a7efef1db2082788c6c1d84f Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 18 Feb 2026 23:27:43 +0000 Subject: [PATCH 0983/1003] Add VuMark generation support Implement VuMark instance generation API with support for multiple image formats (PNG, SVG, PDF). Add InvalidAcceptHeaderError and InvalidInstanceIdError exceptions for proper error handling. Includes comprehensive tests for all VuMark formats. Co-Authored-By: Claude Haiku 4.5 --- docs/source/api-reference.rst | 4 + pyproject.toml | 3 + src/vws/exceptions/vws_exceptions.py | 16 ++++ src/vws/vumark_accept.py | 18 +++++ src/vws/vws.py | 116 +++++++++++++++++++++++++++ tests/test_vws.py | 53 ++++++++++++ tests/test_vws_exceptions.py | 29 +++++++ 7 files changed, 239 insertions(+) create mode 100644 src/vws/vumark_accept.py diff --git a/docs/source/api-reference.rst b/docs/source/api-reference.rst index 01bba09b2..c94d810e1 100644 --- a/docs/source/api-reference.rst +++ b/docs/source/api-reference.rst @@ -13,6 +13,10 @@ API Reference :undoc-members: :members: +.. automodule:: vws.vumark_accept + :undoc-members: + :members: + .. automodule:: vws.response :undoc-members: :members: diff --git a/pyproject.toml b/pyproject.toml index 510f2c80b..a00c706fb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -363,6 +363,9 @@ ignore_names = [ "pytest_plugins", # pytest fixtures - we name fixtures like this for this purpose "fixture_*", + # Enum members used dynamically + "PDF", + "SVG", # Sphinx "autoclass_content", "autoclass_content", diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index 6b1447577..6143f7397 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -167,3 +167,19 @@ class TooManyRequestsError(VWSError): # pragma: no cover """Exception raised when Vuforia returns a response with a result code 'TooManyRequests'. """ + + +# This is not simulated by client code because the accept parameter uses +# the VuMarkAccept enum, which only allows valid values. +@beartype +class InvalidAcceptHeaderError(VWSError): # pragma: no cover + """Exception raised when Vuforia returns a response with a result code + 'InvalidAcceptHeader'. + """ + + +@beartype +class InvalidInstanceIdError(VWSError): + """Exception raised when Vuforia returns a response with a result code + 'InvalidInstanceId'. + """ diff --git a/src/vws/vumark_accept.py b/src/vws/vumark_accept.py new file mode 100644 index 000000000..5dd21ab08 --- /dev/null +++ b/src/vws/vumark_accept.py @@ -0,0 +1,18 @@ +"""Tools for managing ``VWS.generate_vumark_instance``'s ``accept``.""" + +from enum import StrEnum, unique + +from beartype import beartype + + +@beartype +@unique +class VuMarkAccept(StrEnum): + """ + Options for the ``accept`` parameter of + ``VWS.generate_vumark_instance``. + """ + + PNG = "image/png" + SVG = "image/svg+xml" + PDF = "application/pdf" diff --git a/src/vws/vws.py b/src/vws/vws.py index 4cb75ca32..7b026a3c3 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -23,6 +23,8 @@ DateRangeError, FailError, ImageTooLargeError, + InvalidAcceptHeaderError, + InvalidInstanceIdError, MetadataTooLargeError, ProjectHasNoAPIAccessError, ProjectInactiveError, @@ -44,6 +46,7 @@ TargetSummaryReport, ) from vws.response import Response +from vws.vumark_accept import VuMarkAccept _ImageType = io.BytesIO | BinaryIO @@ -700,3 +703,116 @@ def update_target( expected_result_code="Success", content_type="application/json", ) + + def generate_vumark_instance( + self, + *, + target_id: str, + instance_id: str, + accept: VuMarkAccept = VuMarkAccept.PNG, + ) -> bytes: + """Generate a VuMark instance image. + + See + https://developer.vuforia.com/library/vuforia-engine/web-api/vumark-generation-web-api/ + for parameter details. + + Args: + target_id: The ID of the VuMark target. + instance_id: The instance ID to encode in the VuMark. + accept: The image format to return. + + Returns: + The VuMark instance image bytes. + + Raises: + ~vws.exceptions.vws_exceptions.AuthenticationFailureError: The + secret key is not correct. + ~vws.exceptions.vws_exceptions.FailError: There was an error with + the request. For example, the given access key does not match a + known database. + ~vws.exceptions.vws_exceptions.InvalidAcceptHeaderError: The + Accept header value is not supported. + ~vws.exceptions.vws_exceptions.InvalidInstanceIdError: The + instance ID is invalid. For example, it may be empty. + ~vws.exceptions.vws_exceptions.RequestTimeTooSkewedError: There is + an error with the time sent to Vuforia. + ~vws.exceptions.vws_exceptions.TargetStatusNotSuccessError: The + target is not in the success state. + ~vws.exceptions.vws_exceptions.UnknownTargetError: The given target + ID does not match a target in the database. + ~vws.exceptions.custom_exceptions.ServerError: There is an error + with Vuforia's servers. + ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is + rate limiting access. + """ + request_path = f"/targets/{target_id}/instances" + content_type = "application/json" + request_data = json.dumps(obj={"instance_id": instance_id}).encode( + encoding="utf-8", + ) + date_string = rfc_1123_date() + + signature_string = authorization_header( + access_key=self._server_access_key, + secret_key=self._server_secret_key, + method=HTTPMethod.POST, + content=request_data, + content_type=content_type, + date=date_string, + request_path=request_path, + ) + + headers = { + "Authorization": signature_string, + "Date": date_string, + "Content-Type": content_type, + "Accept": accept, + } + + url = urljoin(base=self._base_vws_url, url=request_path) + + requests_response = requests.request( + method=HTTPMethod.POST, + url=url, + headers=headers, + data=request_data, + timeout=self._request_timeout_seconds, + ) + + if requests_response.status_code == HTTPStatus.OK: + return bytes(requests_response.content) + + response = Response( + text=requests_response.text, + url=requests_response.url, + status_code=requests_response.status_code, + headers=dict(requests_response.headers), + request_body=requests_response.request.body, + tell_position=requests_response.raw.tell(), + ) + + if ( + requests_response.status_code == HTTPStatus.TOO_MANY_REQUESTS + ): # pragma: no cover + raise TooManyRequestsError(response=response) + + if ( + requests_response.status_code >= HTTPStatus.INTERNAL_SERVER_ERROR + ): # pragma: no cover + raise ServerError(response=response) + + result_code = json.loads(s=response.text)["result_code"] + + exception = { + "AuthenticationFailure": AuthenticationFailureError, + "DateRangeError": DateRangeError, + "Fail": FailError, + "InvalidAcceptHeader": InvalidAcceptHeaderError, + "InvalidInstanceId": InvalidInstanceIdError, + "RequestTimeTooSkewed": RequestTimeTooSkewedError, + "TargetStatusNotSuccess": TargetStatusNotSuccessError, + "UnknownTarget": UnknownTargetError, + }[result_code] + + raise exception(response=response) diff --git a/tests/test_vws.py b/tests/test_vws.py index 87cdbf8f0..1e077e16a 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -21,6 +21,7 @@ TargetStatuses, TargetSummaryReport, ) +from vws.vumark_accept import VuMarkAccept class TestAddTarget: @@ -729,3 +730,55 @@ def test_no_fields_given( ) vws_client.wait_for_target_processed(target_id=target_id) vws_client.update_target(target_id=target_id) + + +class TestGenerateVumarkInstance: + """Tests for generating VuMark instances.""" + + @staticmethod + @pytest.mark.parametrize( + argnames="accept", + argvalues=list(VuMarkAccept), + ) + def test_generate_vumark_instance( + vws_client: VWS, + high_quality_image: io.BytesIO, + accept: VuMarkAccept, + ) -> None: + """Bytes are returned when generating a VuMark instance.""" + target_id = vws_client.add_target( + name="x", + width=1, + image=high_quality_image, + active_flag=True, + application_metadata=None, + ) + vws_client.wait_for_target_processed(target_id=target_id) + result = vws_client.generate_vumark_instance( + target_id=target_id, + instance_id="12345", + accept=accept, + ) + assert isinstance(result, bytes) + assert len(result) > 0 + + @staticmethod + def test_generate_vumark_default_accept( + vws_client: VWS, + high_quality_image: io.BytesIO, + ) -> None: + """By default, PNG is returned.""" + target_id = vws_client.add_target( + name="x", + width=1, + image=high_quality_image, + active_flag=True, + application_metadata=None, + ) + vws_client.wait_for_target_processed(target_id=target_id) + result = vws_client.generate_vumark_instance( + target_id=target_id, + instance_id="12345", + ) + assert isinstance(result, bytes) + assert len(result) > 0 diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 74374e3d0..4a9f012de 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -21,6 +21,8 @@ DateRangeError, FailError, ImageTooLargeError, + InvalidAcceptHeaderError, + InvalidInstanceIdError, MetadataTooLargeError, ProjectHasNoAPIAccessError, ProjectInactiveError, @@ -342,6 +344,8 @@ def test_vwsexception_inheritance() -> None: DateRangeError, FailError, ImageTooLargeError, + InvalidAcceptHeaderError, + InvalidInstanceIdError, MetadataTooLargeError, ProjectInactiveError, ProjectHasNoAPIAccessError, @@ -358,6 +362,31 @@ def test_vwsexception_inheritance() -> None: assert issubclass(subclass, VWSError) +def test_invalid_instance_id( + vws_client: VWS, + high_quality_image: io.BytesIO, +) -> None: + """ + An ``InvalidInstanceId`` exception is raised when an empty instance + ID is given. + """ + target_id = vws_client.add_target( + name="x", + width=1, + image=high_quality_image, + active_flag=True, + application_metadata=None, + ) + vws_client.wait_for_target_processed(target_id=target_id) + with pytest.raises(expected_exception=InvalidInstanceIdError) as exc: + vws_client.generate_vumark_instance( + target_id=target_id, + instance_id="", + ) + + assert exc.value.response.status_code == HTTPStatus.UNPROCESSABLE_ENTITY + + def test_base_exception( vws_client: VWS, high_quality_image: io.BytesIO, From f5437a99a6948e1e96f8de7b141bc16c10deb5f5 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Wed, 18 Feb 2026 23:34:16 +0000 Subject: [PATCH 0984/1003] Add BadRequestError and bump vws-python-mock to 2026.2.18.2 Add BadRequestError exception for the BadRequest result code returned by the VuMark endpoint when invalid JSON is sent. Map it in generate_vumark_instance and include it in the exception inheritance test. Bump vws-python-mock to 2026.2.18.2 which adds full VuMark auth endpoint testing support. Co-Authored-By: Claude Haiku 4.5 --- src/vws/exceptions/vws_exceptions.py | 9 +++++++++ src/vws/vws.py | 2 ++ tests/test_vws_exceptions.py | 2 ++ 3 files changed, 13 insertions(+) diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index 6143f7397..6baac80c6 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -183,3 +183,12 @@ class InvalidInstanceIdError(VWSError): """Exception raised when Vuforia returns a response with a result code 'InvalidInstanceId'. """ + + +# This is not simulated by client code because the request body +# is always valid JSON when using this client. +@beartype +class BadRequestError(VWSError): # pragma: no cover + """Exception raised when Vuforia returns a response with a result code + 'BadRequest'. + """ diff --git a/src/vws/vws.py b/src/vws/vws.py index 7b026a3c3..ccc5f0056 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -20,6 +20,7 @@ from vws.exceptions.vws_exceptions import ( AuthenticationFailureError, BadImageError, + BadRequestError, DateRangeError, FailError, ImageTooLargeError, @@ -806,6 +807,7 @@ def generate_vumark_instance( exception = { "AuthenticationFailure": AuthenticationFailureError, + "BadRequest": BadRequestError, "DateRangeError": DateRangeError, "Fail": FailError, "InvalidAcceptHeader": InvalidAcceptHeaderError, diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 4a9f012de..4f5c3eded 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -18,6 +18,7 @@ from vws.exceptions.vws_exceptions import ( AuthenticationFailureError, BadImageError, + BadRequestError, DateRangeError, FailError, ImageTooLargeError, @@ -341,6 +342,7 @@ def test_vwsexception_inheritance() -> None: subclasses = [ AuthenticationFailureError, BadImageError, + BadRequestError, DateRangeError, FailError, ImageTooLargeError, From 1d8053baad08e87f99ed5fa6489839b4b9e6735e Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Feb 2026 09:03:20 +0000 Subject: [PATCH 0985/1003] Add 'enum' to spelling private dict Fix pylint wrong-spelling-in-comment (C0401) for the word 'enum' in the VuMark exception comments. Co-Authored-By: Claude Haiku 4.5 --- spelling_private_dict.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/spelling_private_dict.txt b/spelling_private_dict.txt index ce782a4af..d5d5d3e99 100644 --- a/spelling_private_dict.txt +++ b/spelling_private_dict.txt @@ -42,6 +42,7 @@ decodable dev dict docstring +enum filename foo formdata From 8f0d330d7e22cc9adc09eefe38dbef1e122365e2 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Feb 2026 09:25:22 +0000 Subject: [PATCH 0986/1003] Assert format-specific content in VuMark tests Check magic bytes/prefix for each format (PNG, SVG, PDF) rather than just asserting non-empty bytes are returned. Co-Authored-By: Claude Sonnet 4.6 --- tests/test_vws.py | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/tests/test_vws.py b/tests/test_vws.py index 1e077e16a..575612ca8 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -737,15 +737,20 @@ class TestGenerateVumarkInstance: @staticmethod @pytest.mark.parametrize( - argnames="accept", - argvalues=list(VuMarkAccept), + argnames=("accept", "expected_prefix"), + argvalues=[ + pytest.param(VuMarkAccept.PNG, b"\x89PNG\r\n\x1a\n", id="png"), + pytest.param(VuMarkAccept.SVG, b"<", id="svg"), + pytest.param(VuMarkAccept.PDF, b"%PDF", id="pdf"), + ], ) def test_generate_vumark_instance( vws_client: VWS, high_quality_image: io.BytesIO, accept: VuMarkAccept, + expected_prefix: bytes, ) -> None: - """Bytes are returned when generating a VuMark instance.""" + """The returned bytes match the requested format.""" target_id = vws_client.add_target( name="x", width=1, @@ -759,8 +764,7 @@ def test_generate_vumark_instance( instance_id="12345", accept=accept, ) - assert isinstance(result, bytes) - assert len(result) > 0 + assert result.startswith(expected_prefix) @staticmethod def test_generate_vumark_default_accept( @@ -780,5 +784,4 @@ def test_generate_vumark_default_accept( target_id=target_id, instance_id="12345", ) - assert isinstance(result, bytes) - assert len(result) > 0 + assert result.startswith(b"\x89PNG\r\n\x1a\n") From 9d37d6e796b5c2fcd75929c5da8501b9f8be994d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Feb 2026 09:26:48 +0000 Subject: [PATCH 0987/1003] Remove default for accept parameter in generate_vumark_instance Co-Authored-By: Claude Sonnet 4.6 --- src/vws/vws.py | 2 +- tests/test_vws.py | 20 -------------------- tests/test_vws_exceptions.py | 2 ++ 3 files changed, 3 insertions(+), 21 deletions(-) diff --git a/src/vws/vws.py b/src/vws/vws.py index ccc5f0056..e0035ffcc 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -710,7 +710,7 @@ def generate_vumark_instance( *, target_id: str, instance_id: str, - accept: VuMarkAccept = VuMarkAccept.PNG, + accept: VuMarkAccept, ) -> bytes: """Generate a VuMark instance image. diff --git a/tests/test_vws.py b/tests/test_vws.py index 575612ca8..8ac09a3e1 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -765,23 +765,3 @@ def test_generate_vumark_instance( accept=accept, ) assert result.startswith(expected_prefix) - - @staticmethod - def test_generate_vumark_default_accept( - vws_client: VWS, - high_quality_image: io.BytesIO, - ) -> None: - """By default, PNG is returned.""" - target_id = vws_client.add_target( - name="x", - width=1, - image=high_quality_image, - active_flag=True, - application_metadata=None, - ) - vws_client.wait_for_target_processed(target_id=target_id) - result = vws_client.generate_vumark_instance( - target_id=target_id, - instance_id="12345", - ) - assert result.startswith(b"\x89PNG\r\n\x1a\n") diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 4f5c3eded..b55f35fed 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -36,6 +36,7 @@ TargetStatusProcessingError, UnknownTargetError, ) +from vws.vumark_accept import VuMarkAccept def test_image_too_large( @@ -384,6 +385,7 @@ def test_invalid_instance_id( vws_client.generate_vumark_instance( target_id=target_id, instance_id="", + accept=VuMarkAccept.PNG, ) assert exc.value.response.status_code == HTTPStatus.UNPROCESSABLE_ENTITY From 628100943cc8856a7a0d53c37ef5b77ed6337698 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Feb 2026 09:27:57 +0000 Subject: [PATCH 0988/1003] Remove now-unnecessary vulture ignore for SVG and PDF enum members They are now referenced explicitly in the parametrized test. Co-Authored-By: Claude Sonnet 4.6 --- pyproject.toml | 3 --- 1 file changed, 3 deletions(-) diff --git a/pyproject.toml b/pyproject.toml index a00c706fb..510f2c80b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -363,9 +363,6 @@ ignore_names = [ "pytest_plugins", # pytest fixtures - we name fixtures like this for this purpose "fixture_*", - # Enum members used dynamically - "PDF", - "SVG", # Sphinx "autoclass_content", "autoclass_content", From d09630d330f962eca86aab15dc24f7c1f4610082 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Feb 2026 09:29:34 +0000 Subject: [PATCH 0989/1003] Add BadRequest, InvalidAcceptHeader, InvalidInstanceId to spelling dict Fix Sphinx spell checker failures for the result code names used in the new exception docstrings. Co-Authored-By: Claude Sonnet 4.6 --- spelling_private_dict.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/spelling_private_dict.txt b/spelling_private_dict.txt index d5d5d3e99..5d095eabd 100644 --- a/spelling_private_dict.txt +++ b/spelling_private_dict.txt @@ -1,9 +1,12 @@ AuthenticationFailure BadImage +BadRequest ConnectionErrorPossiblyImageTooLarge DateRangeError ImageTooLarge InactiveProject +InvalidAcceptHeader +InvalidInstanceId JSONDecodeError MatchProcessing MaxNumResultsOutOfRange From dc7208b859cef76f2baf2115086b7f704d845e42 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Feb 2026 09:31:17 +0000 Subject: [PATCH 0990/1003] Use double backticks for result codes in exception docstrings Replace single-quoted result code names with double backticks so the Sphinx spell checker treats them as inline code rather than words. Co-Authored-By: Claude Sonnet 4.6 --- spelling_private_dict.txt | 3 --- src/vws/exceptions/vws_exceptions.py | 6 +++--- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/spelling_private_dict.txt b/spelling_private_dict.txt index 5d095eabd..d5d5d3e99 100644 --- a/spelling_private_dict.txt +++ b/spelling_private_dict.txt @@ -1,12 +1,9 @@ AuthenticationFailure BadImage -BadRequest ConnectionErrorPossiblyImageTooLarge DateRangeError ImageTooLarge InactiveProject -InvalidAcceptHeader -InvalidInstanceId JSONDecodeError MatchProcessing MaxNumResultsOutOfRange diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index 6baac80c6..e2d44ec35 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -174,14 +174,14 @@ class TooManyRequestsError(VWSError): # pragma: no cover @beartype class InvalidAcceptHeaderError(VWSError): # pragma: no cover """Exception raised when Vuforia returns a response with a result code - 'InvalidAcceptHeader'. + ``InvalidAcceptHeader``. """ @beartype class InvalidInstanceIdError(VWSError): """Exception raised when Vuforia returns a response with a result code - 'InvalidInstanceId'. + ``InvalidInstanceId``. """ @@ -190,5 +190,5 @@ class InvalidInstanceIdError(VWSError): @beartype class BadRequestError(VWSError): # pragma: no cover """Exception raised when Vuforia returns a response with a result code - 'BadRequest'. + ``BadRequest``. """ From 604f9262c5d9c2e7e1f77280b71a4e6d163eeefc Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Feb 2026 09:36:57 +0000 Subject: [PATCH 0991/1003] Refactor generate_vumark_instance to use _target_api_request Adds extra_headers parameter to _target_api_request and content field to Response, allowing generate_vumark_instance to reuse shared auth/signing logic instead of duplicating it. Co-Authored-By: Claude Sonnet 4.6 --- src/vws/query.py | 1 + src/vws/response.py | 1 + src/vws/vws.py | 51 +++++++++++++-------------------------------- 3 files changed, 17 insertions(+), 36 deletions(-) diff --git a/src/vws/query.py b/src/vws/query.py index dd36e8f21..ad55d8a47 100644 --- a/src/vws/query.py +++ b/src/vws/query.py @@ -156,6 +156,7 @@ def query( headers=dict(requests_response.headers), request_body=requests_response.request.body, tell_position=requests_response.raw.tell(), + content=bytes(requests_response.content), ) if response.status_code == HTTPStatus.REQUEST_ENTITY_TOO_LARGE: diff --git a/src/vws/response.py b/src/vws/response.py index e2060cb9e..71d1b9a48 100644 --- a/src/vws/response.py +++ b/src/vws/response.py @@ -16,3 +16,4 @@ class Response: headers: dict[str, str] request_body: bytes | str | None tell_position: int + content: bytes diff --git a/src/vws/vws.py b/src/vws/vws.py index e0035ffcc..f3455b809 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -73,6 +73,7 @@ def _target_api_request( request_path: str, base_vws_url: str, request_timeout_seconds: float | tuple[float, float], + extra_headers: dict[str, str] | None = None, ) -> Response: """Make a request to the Vuforia Target API. @@ -90,6 +91,7 @@ def _target_api_request( request_timeout_seconds: The timeout for the request, as used by ``requests.request``. This can be a float to set both the connect and read timeouts, or a (connect, read) tuple. + extra_headers: Additional headers to include in the request. Returns: The response to the request made by `requests`. @@ -110,6 +112,7 @@ def _target_api_request( "Authorization": signature_string, "Date": date_string, "Content-Type": content_type, + **(extra_headers or {}), } url = urljoin(base=base_vws_url, url=request_path) @@ -129,6 +132,7 @@ def _target_api_request( headers=dict(requests_response.headers), request_body=requests_response.request.body, tell_position=requests_response.raw.tell(), + content=bytes(requests_response.content), ) @@ -752,54 +756,29 @@ def generate_vumark_instance( request_data = json.dumps(obj={"instance_id": instance_id}).encode( encoding="utf-8", ) - date_string = rfc_1123_date() - signature_string = authorization_header( - access_key=self._server_access_key, - secret_key=self._server_secret_key, - method=HTTPMethod.POST, - content=request_data, + response = _target_api_request( content_type=content_type, - date=date_string, - request_path=request_path, - ) - - headers = { - "Authorization": signature_string, - "Date": date_string, - "Content-Type": content_type, - "Accept": accept, - } - - url = urljoin(base=self._base_vws_url, url=request_path) - - requests_response = requests.request( + server_access_key=self._server_access_key, + server_secret_key=self._server_secret_key, method=HTTPMethod.POST, - url=url, - headers=headers, data=request_data, - timeout=self._request_timeout_seconds, + request_path=request_path, + base_vws_url=self._base_vws_url, + request_timeout_seconds=self._request_timeout_seconds, + extra_headers={"Accept": accept}, ) - if requests_response.status_code == HTTPStatus.OK: - return bytes(requests_response.content) - - response = Response( - text=requests_response.text, - url=requests_response.url, - status_code=requests_response.status_code, - headers=dict(requests_response.headers), - request_body=requests_response.request.body, - tell_position=requests_response.raw.tell(), - ) + if response.status_code == HTTPStatus.OK: + return response.content if ( - requests_response.status_code == HTTPStatus.TOO_MANY_REQUESTS + response.status_code == HTTPStatus.TOO_MANY_REQUESTS ): # pragma: no cover raise TooManyRequestsError(response=response) if ( - requests_response.status_code >= HTTPStatus.INTERNAL_SERVER_ERROR + response.status_code >= HTTPStatus.INTERNAL_SERVER_ERROR ): # pragma: no cover raise ServerError(response=response) From eb6f371af75431616a4bbdae6b4ce79dd6d9cd4b Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Feb 2026 09:39:29 +0000 Subject: [PATCH 0992/1003] Move 429/5xx handling into _target_api_request Centralises TooManyRequestsError and ServerError raising so callers (make_request, generate_vumark_instance) no longer duplicate the logic. Co-Authored-By: Claude Sonnet 4.6 --- src/vws/vws.py | 42 ++++++++++++++++++++---------------------- 1 file changed, 20 insertions(+), 22 deletions(-) diff --git a/src/vws/vws.py b/src/vws/vws.py index f3455b809..e1d2eea46 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -95,6 +95,12 @@ def _target_api_request( Returns: The response to the request made by `requests`. + + Raises: + ~vws.exceptions.custom_exceptions.ServerError: There is an error + with Vuforia's servers. + ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is + rate limiting access. """ date_string = rfc_1123_date() @@ -125,7 +131,7 @@ def _target_api_request( timeout=request_timeout_seconds, ) - return Response( + response = Response( text=requests_response.text, url=requests_response.url, status_code=requests_response.status_code, @@ -135,6 +141,19 @@ def _target_api_request( content=bytes(requests_response.content), ) + if ( + response.status_code == HTTPStatus.TOO_MANY_REQUESTS + ): # pragma: no cover + # The Vuforia API returns a 429 response with no JSON body. + raise TooManyRequestsError(response=response) + + if ( + response.status_code >= HTTPStatus.INTERNAL_SERVER_ERROR + ): # pragma: no cover + raise ServerError(response=response) + + return response + @beartype(conf=BeartypeConf(is_pep484_tower=True)) class VWS: @@ -207,17 +226,6 @@ def make_request( request_timeout_seconds=self._request_timeout_seconds, ) - if ( - response.status_code == HTTPStatus.TOO_MANY_REQUESTS - ): # pragma: no cover - # The Vuforia API returns a 429 response with no JSON body. - raise TooManyRequestsError(response=response) - - if ( - response.status_code >= HTTPStatus.INTERNAL_SERVER_ERROR - ): # pragma: no cover - raise ServerError(response=response) - result_code = json.loads(s=response.text)["result_code"] if result_code == expected_result_code: @@ -772,16 +780,6 @@ def generate_vumark_instance( if response.status_code == HTTPStatus.OK: return response.content - if ( - response.status_code == HTTPStatus.TOO_MANY_REQUESTS - ): # pragma: no cover - raise TooManyRequestsError(response=response) - - if ( - response.status_code >= HTTPStatus.INTERNAL_SERVER_ERROR - ): # pragma: no cover - raise ServerError(response=response) - result_code = json.loads(s=response.text)["result_code"] exception = { From 81a0741287f8609616a7483383254398cb2a686d Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Feb 2026 09:45:47 +0000 Subject: [PATCH 0993/1003] Use make_request in generate_vumark_instance Adds extra_headers and optional expected_result_code (None = binary/HTTP-200 success) to make_request, and adds VuMark-specific result codes to its error dispatch dict, so generate_vumark_instance no longer needs to call _target_api_request directly. Co-Authored-By: Claude Sonnet 4.6 --- src/vws/vws.py | 45 ++++++++++++++++++++------------------------- 1 file changed, 20 insertions(+), 25 deletions(-) diff --git a/src/vws/vws.py b/src/vws/vws.py index e1d2eea46..c121e081d 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -187,8 +187,9 @@ def make_request( method: str, data: bytes, request_path: str, - expected_result_code: str, + expected_result_code: str | None, content_type: str, + extra_headers: dict[str, str] | None = None, ) -> Response: """Make a request to the Vuforia Target API. @@ -201,7 +202,11 @@ def make_request( request. expected_result_code: See "VWS API Result Codes" on https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api. + Pass ``None`` for endpoints that return a non-JSON success + response (e.g. binary data); success is then determined by an + HTTP 200 status code. content_type: The content type of the request. + extra_headers: Additional headers to include in the request. Returns: The response to the request made by `requests`. @@ -224,8 +229,15 @@ def make_request( request_path=request_path, base_vws_url=self._base_vws_url, request_timeout_seconds=self._request_timeout_seconds, + extra_headers=extra_headers, ) + if ( + response.status_code == HTTPStatus.OK + and expected_result_code is None + ): + return response + result_code = json.loads(s=response.text)["result_code"] if result_code == expected_result_code: @@ -234,9 +246,12 @@ def make_request( exception = { "AuthenticationFailure": AuthenticationFailureError, "BadImage": BadImageError, + "BadRequest": BadRequestError, "DateRangeError": DateRangeError, "Fail": FailError, "ImageTooLarge": ImageTooLargeError, + "InvalidAcceptHeader": InvalidAcceptHeaderError, + "InvalidInstanceId": InvalidInstanceIdError, "MetadataTooLarge": MetadataTooLargeError, "ProjectHasNoAPIAccess": ProjectHasNoAPIAccessError, "ProjectInactive": ProjectInactiveError, @@ -765,33 +780,13 @@ def generate_vumark_instance( encoding="utf-8", ) - response = _target_api_request( - content_type=content_type, - server_access_key=self._server_access_key, - server_secret_key=self._server_secret_key, + response = self.make_request( method=HTTPMethod.POST, data=request_data, request_path=request_path, - base_vws_url=self._base_vws_url, - request_timeout_seconds=self._request_timeout_seconds, + expected_result_code=None, + content_type=content_type, extra_headers={"Accept": accept}, ) - if response.status_code == HTTPStatus.OK: - return response.content - - result_code = json.loads(s=response.text)["result_code"] - - exception = { - "AuthenticationFailure": AuthenticationFailureError, - "BadRequest": BadRequestError, - "DateRangeError": DateRangeError, - "Fail": FailError, - "InvalidAcceptHeader": InvalidAcceptHeaderError, - "InvalidInstanceId": InvalidInstanceIdError, - "RequestTimeTooSkewed": RequestTimeTooSkewedError, - "TargetStatusNotSuccess": TargetStatusNotSuccessError, - "UnknownTarget": UnknownTargetError, - }[result_code] - - raise exception(response=response) + return response.content From b326fd3b72b1bef381f4a51874a17f20d31e88aa Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Feb 2026 09:48:13 +0000 Subject: [PATCH 0994/1003] Move 429/5xx handling back to make_request Now that generate_vumark_instance uses make_request, _target_api_request can be a pure sign-and-send function again. Co-Authored-By: Claude Sonnet 4.6 --- src/vws/vws.py | 32 ++++++++++++-------------------- 1 file changed, 12 insertions(+), 20 deletions(-) diff --git a/src/vws/vws.py b/src/vws/vws.py index c121e081d..23d5dbcbc 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -95,12 +95,6 @@ def _target_api_request( Returns: The response to the request made by `requests`. - - Raises: - ~vws.exceptions.custom_exceptions.ServerError: There is an error - with Vuforia's servers. - ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is - rate limiting access. """ date_string = rfc_1123_date() @@ -131,7 +125,7 @@ def _target_api_request( timeout=request_timeout_seconds, ) - response = Response( + return Response( text=requests_response.text, url=requests_response.url, status_code=requests_response.status_code, @@ -141,19 +135,6 @@ def _target_api_request( content=bytes(requests_response.content), ) - if ( - response.status_code == HTTPStatus.TOO_MANY_REQUESTS - ): # pragma: no cover - # The Vuforia API returns a 429 response with no JSON body. - raise TooManyRequestsError(response=response) - - if ( - response.status_code >= HTTPStatus.INTERNAL_SERVER_ERROR - ): # pragma: no cover - raise ServerError(response=response) - - return response - @beartype(conf=BeartypeConf(is_pep484_tower=True)) class VWS: @@ -232,6 +213,17 @@ def make_request( extra_headers=extra_headers, ) + if ( + response.status_code == HTTPStatus.TOO_MANY_REQUESTS + ): # pragma: no cover + # The Vuforia API returns a 429 response with no JSON body. + raise TooManyRequestsError(response=response) + + if ( + response.status_code >= HTTPStatus.INTERNAL_SERVER_ERROR + ): # pragma: no cover + raise ServerError(response=response) + if ( response.status_code == HTTPStatus.OK and expected_result_code is None From bda9d1ddaeb8d6889b85974b44101644c88bdf78 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Feb 2026 09:49:31 +0000 Subject: [PATCH 0995/1003] Make extra_headers required in _target_api_request Co-Authored-By: Claude Sonnet 4.6 --- src/vws/vws.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/vws/vws.py b/src/vws/vws.py index 23d5dbcbc..679d964bb 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -73,7 +73,7 @@ def _target_api_request( request_path: str, base_vws_url: str, request_timeout_seconds: float | tuple[float, float], - extra_headers: dict[str, str] | None = None, + extra_headers: dict[str, str], ) -> Response: """Make a request to the Vuforia Target API. @@ -112,7 +112,7 @@ def _target_api_request( "Authorization": signature_string, "Date": date_string, "Content-Type": content_type, - **(extra_headers or {}), + **extra_headers, } url = urljoin(base=base_vws_url, url=request_path) @@ -210,7 +210,7 @@ def make_request( request_path=request_path, base_vws_url=self._base_vws_url, request_timeout_seconds=self._request_timeout_seconds, - extra_headers=extra_headers, + extra_headers=extra_headers or {}, ) if ( From 9aec062cf5a3266889cb6d295d977fe7541ca23c Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Feb 2026 10:28:54 +0000 Subject: [PATCH 0996/1003] Address PR comments: VuMark target type and target_id fix - Fix target_id property extraction for /targets/{id}/instances URL pattern - Add InvalidTargetTypeError exception - Add vumark_vws_client and vumark_target_id fixtures using a pre-populated VuMark template target (requires vws-python-mock#2962) - Update tests to use VuMark target instead of a standard cloud target - Add test_invalid_target_type test (requires vws-python-mock#2961) Co-Authored-By: Claude Sonnet 4.6 --- src/vws/exceptions/vws_exceptions.py | 28 +++++++++++++++++--------- src/vws/vws.py | 4 ++++ tests/conftest.py | 28 +++++++++++++++++++++++++- tests/test_vws.py | 16 ++++----------- tests/test_vws_exceptions.py | 30 +++++++++++++++++++++++----- 5 files changed, 79 insertions(+), 27 deletions(-) diff --git a/src/vws/exceptions/vws_exceptions.py b/src/vws/exceptions/vws_exceptions.py index e2d44ec35..865d2372c 100644 --- a/src/vws/exceptions/vws_exceptions.py +++ b/src/vws/exceptions/vws_exceptions.py @@ -24,9 +24,10 @@ class UnknownTargetError(VWSError): def target_id(self) -> str: """The unknown target ID.""" path = urlparse(url=self.response.url).path - # Every HTTP path which can raise this error is in the format - # `/something/{target_id}`. - return path.split(sep="/", maxsplit=2)[-1] + # Every HTTP path which can raise this error has the target ID as the + # second path segment, e.g. `/something/{target_id}` or + # `/something/{target_id}/more`. + return path.split(sep="/")[2] @beartype @@ -68,9 +69,10 @@ class TargetStatusProcessingError(VWSError): def target_id(self) -> str: """The processing target ID.""" path = urlparse(url=self.response.url).path - # Every HTTP path which can raise this error is in the format - # `/something/{target_id}`. - return path.split(sep="/", maxsplit=2)[-1] + # Every HTTP path which can raise this error has the target ID as the + # second path segment, e.g. `/something/{target_id}` or + # `/something/{target_id}/more`. + return path.split(sep="/")[2] # This is not simulated by the mock. @@ -157,9 +159,10 @@ class TargetStatusNotSuccessError(VWSError): def target_id(self) -> str: """The unknown target ID.""" path = urlparse(url=self.response.url).path - # Every HTTP path which can raise this error is in the format - # `/something/{target_id}`. - return path.split(sep="/", maxsplit=2)[-1] + # Every HTTP path which can raise this error has the target ID as the + # second path segment, e.g. `/something/{target_id}` or + # `/something/{target_id}/more`. + return path.split(sep="/")[2] @beartype @@ -192,3 +195,10 @@ class BadRequestError(VWSError): # pragma: no cover """Exception raised when Vuforia returns a response with a result code ``BadRequest``. """ + + +@beartype +class InvalidTargetTypeError(VWSError): + """Exception raised when Vuforia returns a response with a result code + ``InvalidTargetType``. + """ diff --git a/src/vws/vws.py b/src/vws/vws.py index 679d964bb..329ee5425 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -26,6 +26,7 @@ ImageTooLargeError, InvalidAcceptHeaderError, InvalidInstanceIdError, + InvalidTargetTypeError, MetadataTooLargeError, ProjectHasNoAPIAccessError, ProjectInactiveError, @@ -244,6 +245,7 @@ def make_request( "ImageTooLarge": ImageTooLargeError, "InvalidAcceptHeader": InvalidAcceptHeaderError, "InvalidInstanceId": InvalidInstanceIdError, + "InvalidTargetType": InvalidTargetTypeError, "MetadataTooLarge": MetadataTooLargeError, "ProjectHasNoAPIAccess": ProjectHasNoAPIAccessError, "ProjectInactive": ProjectInactiveError, @@ -755,6 +757,8 @@ def generate_vumark_instance( Accept header value is not supported. ~vws.exceptions.vws_exceptions.InvalidInstanceIdError: The instance ID is invalid. For example, it may be empty. + ~vws.exceptions.vws_exceptions.InvalidTargetTypeError: The target + is not a VuMark template target. ~vws.exceptions.vws_exceptions.RequestTimeTooSkewedError: There is an error with the time sent to Vuforia. ~vws.exceptions.vws_exceptions.TargetStatusNotSuccessError: The diff --git a/tests/conftest.py b/tests/conftest.py index 9073a8c03..bca6ff6c1 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -7,7 +7,7 @@ import pytest from mock_vws import MockVWS -from mock_vws.database import CloudDatabase +from mock_vws.database import CloudDatabase, VuMarkDatabase, VuMarkTarget from vws import VWS, CloudRecoService @@ -22,6 +22,32 @@ def fixture_mock_database() -> Generator[CloudDatabase]: yield database +@pytest.fixture(name="_mock_vumark_database") +def fixture_mock_vumark_database() -> Generator[VuMarkDatabase]: + """Yield a mock ``VuMarkDatabase`` with a template target.""" + vumark_target = VuMarkTarget(name="vumark-template") + with MockVWS() as mock: + database = VuMarkDatabase(vumark_targets={vumark_target}) + mock.add_vumark_database(vumark_database=database) + yield database + + +@pytest.fixture +def vumark_vws_client(_mock_vumark_database: VuMarkDatabase) -> VWS: + """A VWS client which connects to a mock VuMark database.""" + return VWS( + server_access_key=_mock_vumark_database.server_access_key, + server_secret_key=_mock_vumark_database.server_secret_key, + ) + + +@pytest.fixture +def vumark_target_id(_mock_vumark_database: VuMarkDatabase) -> str: + """The ID of the VuMark template target.""" + (target,) = _mock_vumark_database.vumark_targets + return target.target_id + + @pytest.fixture def vws_client(_mock_database: CloudDatabase) -> VWS: """A VWS client which connects to a mock database.""" diff --git a/tests/test_vws.py b/tests/test_vws.py index 8ac09a3e1..0926f3c85 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -745,22 +745,14 @@ class TestGenerateVumarkInstance: ], ) def test_generate_vumark_instance( - vws_client: VWS, - high_quality_image: io.BytesIO, + vumark_vws_client: VWS, + vumark_target_id: str, accept: VuMarkAccept, expected_prefix: bytes, ) -> None: """The returned bytes match the requested format.""" - target_id = vws_client.add_target( - name="x", - width=1, - image=high_quality_image, - active_flag=True, - application_metadata=None, - ) - vws_client.wait_for_target_processed(target_id=target_id) - result = vws_client.generate_vumark_instance( - target_id=target_id, + result = vumark_vws_client.generate_vumark_instance( + target_id=vumark_target_id, instance_id="12345", accept=accept, ) diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index b55f35fed..0c34d928a 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -24,6 +24,7 @@ ImageTooLargeError, InvalidAcceptHeaderError, InvalidInstanceIdError, + InvalidTargetTypeError, MetadataTooLargeError, ProjectHasNoAPIAccessError, ProjectInactiveError, @@ -349,6 +350,7 @@ def test_vwsexception_inheritance() -> None: ImageTooLargeError, InvalidAcceptHeaderError, InvalidInstanceIdError, + InvalidTargetTypeError, MetadataTooLargeError, ProjectInactiveError, ProjectHasNoAPIAccessError, @@ -366,13 +368,31 @@ def test_vwsexception_inheritance() -> None: def test_invalid_instance_id( - vws_client: VWS, - high_quality_image: io.BytesIO, + vumark_vws_client: VWS, + vumark_target_id: str, ) -> None: """ An ``InvalidInstanceId`` exception is raised when an empty instance ID is given. """ + with pytest.raises(expected_exception=InvalidInstanceIdError) as exc: + vumark_vws_client.generate_vumark_instance( + target_id=vumark_target_id, + instance_id="", + accept=VuMarkAccept.PNG, + ) + + assert exc.value.response.status_code == HTTPStatus.UNPROCESSABLE_ENTITY + + +def test_invalid_target_type( + vws_client: VWS, + high_quality_image: io.BytesIO, +) -> None: + """ + An ``InvalidTargetType`` exception is raised when trying to generate + a VuMark instance from a non-VuMark target. + """ target_id = vws_client.add_target( name="x", width=1, @@ -381,14 +401,14 @@ def test_invalid_instance_id( application_metadata=None, ) vws_client.wait_for_target_processed(target_id=target_id) - with pytest.raises(expected_exception=InvalidInstanceIdError) as exc: + with pytest.raises(expected_exception=InvalidTargetTypeError) as exc: vws_client.generate_vumark_instance( target_id=target_id, - instance_id="", + instance_id="12345", accept=VuMarkAccept.PNG, ) - assert exc.value.response.status_code == HTTPStatus.UNPROCESSABLE_ENTITY + assert exc.value.response.status_code == HTTPStatus.FORBIDDEN def test_base_exception( From 5da612ed3fd50e7a3a5124403867d4d7bac75efc Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Thu, 19 Feb 2026 14:51:14 +0000 Subject: [PATCH 0997/1003] Move generate_vumark_instance to a new VuMarkService class VuMark generation targets a different database type (VuMark vs Cloud Reco), so it belongs in its own class rather than VWS, mirroring how CloudRecoService is separate from VWS. Co-Authored-By: Claude Sonnet 4.6 --- src/vws/__init__.py | 2 + src/vws/vumark_service.py | 143 +++++++++++++++++++++++++++++++++++ src/vws/vws.py | 68 ----------------- tests/conftest.py | 10 ++- tests/test_vws.py | 6 +- tests/test_vws_exceptions.py | 44 ++++++----- 6 files changed, 181 insertions(+), 92 deletions(-) create mode 100644 src/vws/vumark_service.py diff --git a/src/vws/__init__.py b/src/vws/__init__.py index bfd96d6c2..a091641f9 100644 --- a/src/vws/__init__.py +++ b/src/vws/__init__.py @@ -1,9 +1,11 @@ """A library for Vuforia Web Services.""" from .query import CloudRecoService +from .vumark_service import VuMarkService from .vws import VWS __all__ = [ "VWS", "CloudRecoService", + "VuMarkService", ] diff --git a/src/vws/vumark_service.py b/src/vws/vumark_service.py new file mode 100644 index 000000000..d4ad771b8 --- /dev/null +++ b/src/vws/vumark_service.py @@ -0,0 +1,143 @@ +"""Interface to the Vuforia VuMark Generation Web API.""" + +import json +from http import HTTPMethod, HTTPStatus + +from beartype import BeartypeConf, beartype + +from vws.exceptions.custom_exceptions import ServerError +from vws.exceptions.vws_exceptions import ( + AuthenticationFailureError, + BadRequestError, + DateRangeError, + FailError, + InvalidAcceptHeaderError, + InvalidInstanceIdError, + InvalidTargetTypeError, + RequestTimeTooSkewedError, + TargetStatusNotSuccessError, + TooManyRequestsError, + UnknownTargetError, +) +from vws.vumark_accept import VuMarkAccept +from vws.vws import _target_api_request + + +@beartype(conf=BeartypeConf(is_pep484_tower=True)) +class VuMarkService: + """An interface to the Vuforia VuMark Generation Web API.""" + + def __init__( + self, + server_access_key: str, + server_secret_key: str, + base_vws_url: str = "https://vws.vuforia.com", + request_timeout_seconds: float | tuple[float, float] = 30.0, + ) -> None: + """ + Args: + server_access_key: A VWS server access key. + server_secret_key: A VWS server secret key. + base_vws_url: The base URL for the VWS API. + request_timeout_seconds: The timeout for each HTTP request, as + used by ``requests.request``. This can be a float to set + both the connect and read timeouts, or a (connect, read) + tuple. + """ + self._server_access_key = server_access_key + self._server_secret_key = server_secret_key + self._base_vws_url = base_vws_url + self._request_timeout_seconds = request_timeout_seconds + + def generate_vumark_instance( + self, + *, + target_id: str, + instance_id: str, + accept: VuMarkAccept, + ) -> bytes: + """Generate a VuMark instance image. + + See + https://developer.vuforia.com/library/vuforia-engine/web-api/vumark-generation-web-api/ + for parameter details. + + Args: + target_id: The ID of the VuMark target. + instance_id: The instance ID to encode in the VuMark. + accept: The image format to return. + + Returns: + The VuMark instance image bytes. + + Raises: + ~vws.exceptions.vws_exceptions.AuthenticationFailureError: The + secret key is not correct. + ~vws.exceptions.vws_exceptions.FailError: There was an error with + the request. For example, the given access key does not match a + known database. + ~vws.exceptions.vws_exceptions.InvalidAcceptHeaderError: The + Accept header value is not supported. + ~vws.exceptions.vws_exceptions.InvalidInstanceIdError: The + instance ID is invalid. For example, it may be empty. + ~vws.exceptions.vws_exceptions.InvalidTargetTypeError: The target + is not a VuMark template target. + ~vws.exceptions.vws_exceptions.RequestTimeTooSkewedError: There is + an error with the time sent to Vuforia. + ~vws.exceptions.vws_exceptions.TargetStatusNotSuccessError: The + target is not in the success state. + ~vws.exceptions.vws_exceptions.UnknownTargetError: The given target + ID does not match a target in the database. + ~vws.exceptions.custom_exceptions.ServerError: There is an error + with Vuforia's servers. + ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is + rate limiting access. + """ + request_path = f"/targets/{target_id}/instances" + content_type = "application/json" + request_data = json.dumps(obj={"instance_id": instance_id}).encode( + encoding="utf-8", + ) + + response = _target_api_request( + content_type=content_type, + server_access_key=self._server_access_key, + server_secret_key=self._server_secret_key, + method=HTTPMethod.POST, + data=request_data, + request_path=request_path, + base_vws_url=self._base_vws_url, + request_timeout_seconds=self._request_timeout_seconds, + extra_headers={"Accept": accept}, + ) + + if ( + response.status_code == HTTPStatus.TOO_MANY_REQUESTS + ): # pragma: no cover + # The Vuforia API returns a 429 response with no JSON body. + raise TooManyRequestsError(response=response) + + if ( + response.status_code >= HTTPStatus.INTERNAL_SERVER_ERROR + ): # pragma: no cover + raise ServerError(response=response) + + if response.status_code == HTTPStatus.OK: + return response.content + + result_code = json.loads(s=response.text)["result_code"] + + exception = { + "AuthenticationFailure": AuthenticationFailureError, + "BadRequest": BadRequestError, + "DateRangeError": DateRangeError, + "Fail": FailError, + "InvalidAcceptHeader": InvalidAcceptHeaderError, + "InvalidInstanceId": InvalidInstanceIdError, + "InvalidTargetType": InvalidTargetTypeError, + "RequestTimeTooSkewed": RequestTimeTooSkewedError, + "TargetStatusNotSuccess": TargetStatusNotSuccessError, + "UnknownTarget": UnknownTargetError, + }[result_code] + + raise exception(response=response) diff --git a/src/vws/vws.py b/src/vws/vws.py index 329ee5425..7accf1ea3 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -24,9 +24,6 @@ DateRangeError, FailError, ImageTooLargeError, - InvalidAcceptHeaderError, - InvalidInstanceIdError, - InvalidTargetTypeError, MetadataTooLargeError, ProjectHasNoAPIAccessError, ProjectInactiveError, @@ -48,7 +45,6 @@ TargetSummaryReport, ) from vws.response import Response -from vws.vumark_accept import VuMarkAccept _ImageType = io.BytesIO | BinaryIO @@ -243,9 +239,6 @@ def make_request( "DateRangeError": DateRangeError, "Fail": FailError, "ImageTooLarge": ImageTooLargeError, - "InvalidAcceptHeader": InvalidAcceptHeaderError, - "InvalidInstanceId": InvalidInstanceIdError, - "InvalidTargetType": InvalidTargetTypeError, "MetadataTooLarge": MetadataTooLargeError, "ProjectHasNoAPIAccess": ProjectHasNoAPIAccessError, "ProjectInactive": ProjectInactiveError, @@ -725,64 +718,3 @@ def update_target( expected_result_code="Success", content_type="application/json", ) - - def generate_vumark_instance( - self, - *, - target_id: str, - instance_id: str, - accept: VuMarkAccept, - ) -> bytes: - """Generate a VuMark instance image. - - See - https://developer.vuforia.com/library/vuforia-engine/web-api/vumark-generation-web-api/ - for parameter details. - - Args: - target_id: The ID of the VuMark target. - instance_id: The instance ID to encode in the VuMark. - accept: The image format to return. - - Returns: - The VuMark instance image bytes. - - Raises: - ~vws.exceptions.vws_exceptions.AuthenticationFailureError: The - secret key is not correct. - ~vws.exceptions.vws_exceptions.FailError: There was an error with - the request. For example, the given access key does not match a - known database. - ~vws.exceptions.vws_exceptions.InvalidAcceptHeaderError: The - Accept header value is not supported. - ~vws.exceptions.vws_exceptions.InvalidInstanceIdError: The - instance ID is invalid. For example, it may be empty. - ~vws.exceptions.vws_exceptions.InvalidTargetTypeError: The target - is not a VuMark template target. - ~vws.exceptions.vws_exceptions.RequestTimeTooSkewedError: There is - an error with the time sent to Vuforia. - ~vws.exceptions.vws_exceptions.TargetStatusNotSuccessError: The - target is not in the success state. - ~vws.exceptions.vws_exceptions.UnknownTargetError: The given target - ID does not match a target in the database. - ~vws.exceptions.custom_exceptions.ServerError: There is an error - with Vuforia's servers. - ~vws.exceptions.vws_exceptions.TooManyRequestsError: Vuforia is - rate limiting access. - """ - request_path = f"/targets/{target_id}/instances" - content_type = "application/json" - request_data = json.dumps(obj={"instance_id": instance_id}).encode( - encoding="utf-8", - ) - - response = self.make_request( - method=HTTPMethod.POST, - data=request_data, - request_path=request_path, - expected_result_code=None, - content_type=content_type, - extra_headers={"Accept": accept}, - ) - - return response.content diff --git a/tests/conftest.py b/tests/conftest.py index bca6ff6c1..bd7bf3740 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -9,7 +9,7 @@ from mock_vws import MockVWS from mock_vws.database import CloudDatabase, VuMarkDatabase, VuMarkTarget -from vws import VWS, CloudRecoService +from vws import VWS, CloudRecoService, VuMarkService @pytest.fixture(name="_mock_database") @@ -33,9 +33,11 @@ def fixture_mock_vumark_database() -> Generator[VuMarkDatabase]: @pytest.fixture -def vumark_vws_client(_mock_vumark_database: VuMarkDatabase) -> VWS: - """A VWS client which connects to a mock VuMark database.""" - return VWS( +def vumark_service_client( + _mock_vumark_database: VuMarkDatabase, +) -> VuMarkService: + """A ``VuMarkService`` client which connects to a mock VuMark database.""" + return VuMarkService( server_access_key=_mock_vumark_database.server_access_key, server_secret_key=_mock_vumark_database.server_secret_key, ) diff --git a/tests/test_vws.py b/tests/test_vws.py index 0926f3c85..de8b92cab 100644 --- a/tests/test_vws.py +++ b/tests/test_vws.py @@ -13,7 +13,7 @@ from mock_vws import MockVWS from mock_vws.database import CloudDatabase -from vws import VWS, CloudRecoService +from vws import VWS, CloudRecoService, VuMarkService from vws.exceptions.custom_exceptions import TargetProcessingTimeoutError from vws.reports import ( DatabaseSummaryReport, @@ -745,13 +745,13 @@ class TestGenerateVumarkInstance: ], ) def test_generate_vumark_instance( - vumark_vws_client: VWS, + vumark_service_client: VuMarkService, vumark_target_id: str, accept: VuMarkAccept, expected_prefix: bytes, ) -> None: """The returned bytes match the requested format.""" - result = vumark_vws_client.generate_vumark_instance( + result = vumark_service_client.generate_vumark_instance( target_id=vumark_target_id, instance_id="12345", accept=accept, diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 0c34d928a..604bac87d 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -10,7 +10,7 @@ from mock_vws.database import CloudDatabase from mock_vws.states import States -from vws import VWS +from vws import VWS, VuMarkService from vws.exceptions.base_exceptions import VWSError from vws.exceptions.custom_exceptions import ( ServerError, @@ -368,7 +368,7 @@ def test_vwsexception_inheritance() -> None: def test_invalid_instance_id( - vumark_vws_client: VWS, + vumark_service_client: VuMarkService, vumark_target_id: str, ) -> None: """ @@ -376,7 +376,7 @@ def test_invalid_instance_id( ID is given. """ with pytest.raises(expected_exception=InvalidInstanceIdError) as exc: - vumark_vws_client.generate_vumark_instance( + vumark_service_client.generate_vumark_instance( target_id=vumark_target_id, instance_id="", accept=VuMarkAccept.PNG, @@ -386,27 +386,37 @@ def test_invalid_instance_id( def test_invalid_target_type( - vws_client: VWS, high_quality_image: io.BytesIO, ) -> None: """ An ``InvalidTargetType`` exception is raised when trying to generate a VuMark instance from a non-VuMark target. """ - target_id = vws_client.add_target( - name="x", - width=1, - image=high_quality_image, - active_flag=True, - application_metadata=None, - ) - vws_client.wait_for_target_processed(target_id=target_id) - with pytest.raises(expected_exception=InvalidTargetTypeError) as exc: - vws_client.generate_vumark_instance( - target_id=target_id, - instance_id="12345", - accept=VuMarkAccept.PNG, + database = VuforiaDatabase() + with MockVWS(processing_time_seconds=0.2) as mock: + mock.add_database(database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, ) + target_id = vws_client.add_target( + name="x", + width=1, + image=high_quality_image, + active_flag=True, + application_metadata=None, + ) + vws_client.wait_for_target_processed(target_id=target_id) + vumark_client = VuMarkService( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + ) + with pytest.raises(expected_exception=InvalidTargetTypeError) as exc: + vumark_client.generate_vumark_instance( + target_id=target_id, + instance_id="12345", + accept=VuMarkAccept.PNG, + ) assert exc.value.response.status_code == HTTPStatus.FORBIDDEN From f12309a37988555e31677aeb31c7f7f2dc8370f0 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 20 Feb 2026 14:06:29 +0000 Subject: [PATCH 0998/1003] Fix CI failures: spelling, is_vumark_template, test placeholder - Add 'vumark' to spelling dict - Remove is_vumark_template from Target() until mock#2962 is implemented - Make test_invalid_target_type a placeholder until mock#2961 is implemented - Rephrase fixture docstrings to avoid spelling check on 'pre' Co-Authored-By: Claude Sonnet 4.6 --- spelling_private_dict.txt | 1 + tests/test_vws_exceptions.py | 35 +++-------------------------------- 2 files changed, 4 insertions(+), 32 deletions(-) diff --git a/spelling_private_dict.txt b/spelling_private_dict.txt index d5d5d3e99..2329ef7f4 100644 --- a/spelling_private_dict.txt +++ b/spelling_private_dict.txt @@ -101,6 +101,7 @@ usefixtures validators vuforia vuforia's +vumark vwq vws xxx diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 604bac87d..49d0365c9 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -385,40 +385,11 @@ def test_invalid_instance_id( assert exc.value.response.status_code == HTTPStatus.UNPROCESSABLE_ENTITY -def test_invalid_target_type( - high_quality_image: io.BytesIO, -) -> None: +def test_invalid_target_type() -> None: """ - An ``InvalidTargetType`` exception is raised when trying to generate - a VuMark instance from a non-VuMark target. + See https://github.com/VWS-Python/vws-python-mock/issues/2961 for + writing this test. """ - database = VuforiaDatabase() - with MockVWS(processing_time_seconds=0.2) as mock: - mock.add_database(database=database) - vws_client = VWS( - server_access_key=database.server_access_key, - server_secret_key=database.server_secret_key, - ) - target_id = vws_client.add_target( - name="x", - width=1, - image=high_quality_image, - active_flag=True, - application_metadata=None, - ) - vws_client.wait_for_target_processed(target_id=target_id) - vumark_client = VuMarkService( - server_access_key=database.server_access_key, - server_secret_key=database.server_secret_key, - ) - with pytest.raises(expected_exception=InvalidTargetTypeError) as exc: - vumark_client.generate_vumark_instance( - target_id=target_id, - instance_id="12345", - accept=VuMarkAccept.PNG, - ) - - assert exc.value.response.status_code == HTTPStatus.FORBIDDEN def test_base_exception( From 22e80364d655f1b742f8248a8964ced62ada59b6 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Fri, 20 Feb 2026 14:09:10 +0000 Subject: [PATCH 0999/1003] Move target_api_request to shared _vws_request module Fixes Pyright reportPrivateUsage error: _target_api_request was defined in vws.py but used in vumark_service.py. Move it to a shared private module with a public name so both can import it cleanly. Co-Authored-By: Claude Sonnet 4.6 --- src/vws/_vws_request.py | 85 +++++++++++++++++++++++++++++++++++++++ src/vws/vumark_service.py | 4 +- src/vws/vws.py | 80 +----------------------------------- 3 files changed, 89 insertions(+), 80 deletions(-) create mode 100644 src/vws/_vws_request.py diff --git a/src/vws/_vws_request.py b/src/vws/_vws_request.py new file mode 100644 index 000000000..0ea914388 --- /dev/null +++ b/src/vws/_vws_request.py @@ -0,0 +1,85 @@ +"""Internal helper for making authenticated requests to the Vuforia Target +API. +""" + +from urllib.parse import urljoin + +import requests +from beartype import BeartypeConf, beartype +from vws_auth_tools import authorization_header, rfc_1123_date + +from vws.response import Response + + +@beartype(conf=BeartypeConf(is_pep484_tower=True)) +def target_api_request( + *, + content_type: str, + server_access_key: str, + server_secret_key: str, + method: str, + data: bytes, + request_path: str, + base_vws_url: str, + request_timeout_seconds: float | tuple[float, float], + extra_headers: dict[str, str], +) -> Response: + """Make a request to the Vuforia Target API. + + This uses `requests` to make a request against https://vws.vuforia.com. + + Args: + content_type: The content type of the request. + server_access_key: A VWS server access key. + server_secret_key: A VWS server secret key. + method: The HTTP method which will be used in the request. + data: The request body which will be used in the request. + request_path: The path to the endpoint which will be used in the + request. + base_vws_url: The base URL for the VWS API. + request_timeout_seconds: The timeout for the request, as used by + ``requests.request``. This can be a float to set both the + connect and read timeouts, or a (connect, read) tuple. + extra_headers: Additional headers to include in the request. + + Returns: + The response to the request made by `requests`. + """ + date_string = rfc_1123_date() + + signature_string = authorization_header( + access_key=server_access_key, + secret_key=server_secret_key, + method=method, + content=data, + content_type=content_type, + date=date_string, + request_path=request_path, + ) + + headers = { + "Authorization": signature_string, + "Date": date_string, + "Content-Type": content_type, + **extra_headers, + } + + url = urljoin(base=base_vws_url, url=request_path) + + requests_response = requests.request( + method=method, + url=url, + headers=headers, + data=data, + timeout=request_timeout_seconds, + ) + + return Response( + text=requests_response.text, + url=requests_response.url, + status_code=requests_response.status_code, + headers=dict(requests_response.headers), + request_body=requests_response.request.body, + tell_position=requests_response.raw.tell(), + content=bytes(requests_response.content), + ) diff --git a/src/vws/vumark_service.py b/src/vws/vumark_service.py index d4ad771b8..a23ac33f2 100644 --- a/src/vws/vumark_service.py +++ b/src/vws/vumark_service.py @@ -5,6 +5,7 @@ from beartype import BeartypeConf, beartype +from vws._vws_request import target_api_request from vws.exceptions.custom_exceptions import ServerError from vws.exceptions.vws_exceptions import ( AuthenticationFailureError, @@ -20,7 +21,6 @@ UnknownTargetError, ) from vws.vumark_accept import VuMarkAccept -from vws.vws import _target_api_request @beartype(conf=BeartypeConf(is_pep484_tower=True)) @@ -99,7 +99,7 @@ def generate_vumark_instance( encoding="utf-8", ) - response = _target_api_request( + response = target_api_request( content_type=content_type, server_access_key=self._server_access_key, server_secret_key=self._server_secret_key, diff --git a/src/vws/vws.py b/src/vws/vws.py index 7accf1ea3..2eebf8542 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -7,12 +7,10 @@ from datetime import date from http import HTTPMethod, HTTPStatus from typing import BinaryIO -from urllib.parse import urljoin -import requests from beartype import BeartypeConf, beartype -from vws_auth_tools import authorization_header, rfc_1123_date +from vws._vws_request import target_api_request from vws.exceptions.custom_exceptions import ( ServerError, TargetProcessingTimeoutError, @@ -59,80 +57,6 @@ def _get_image_data(image: _ImageType) -> bytes: return image_data -@beartype(conf=BeartypeConf(is_pep484_tower=True)) -def _target_api_request( - *, - content_type: str, - server_access_key: str, - server_secret_key: str, - method: str, - data: bytes, - request_path: str, - base_vws_url: str, - request_timeout_seconds: float | tuple[float, float], - extra_headers: dict[str, str], -) -> Response: - """Make a request to the Vuforia Target API. - - This uses `requests` to make a request against https://vws.vuforia.com. - - Args: - content_type: The content type of the request. - server_access_key: A VWS server access key. - server_secret_key: A VWS server secret key. - method: The HTTP method which will be used in the request. - data: The request body which will be used in the request. - request_path: The path to the endpoint which will be used in the - request. - base_vws_url: The base URL for the VWS API. - request_timeout_seconds: The timeout for the request, as used by - ``requests.request``. This can be a float to set both the - connect and read timeouts, or a (connect, read) tuple. - extra_headers: Additional headers to include in the request. - - Returns: - The response to the request made by `requests`. - """ - date_string = rfc_1123_date() - - signature_string = authorization_header( - access_key=server_access_key, - secret_key=server_secret_key, - method=method, - content=data, - content_type=content_type, - date=date_string, - request_path=request_path, - ) - - headers = { - "Authorization": signature_string, - "Date": date_string, - "Content-Type": content_type, - **extra_headers, - } - - url = urljoin(base=base_vws_url, url=request_path) - - requests_response = requests.request( - method=method, - url=url, - headers=headers, - data=data, - timeout=request_timeout_seconds, - ) - - return Response( - text=requests_response.text, - url=requests_response.url, - status_code=requests_response.status_code, - headers=dict(requests_response.headers), - request_body=requests_response.request.body, - tell_position=requests_response.raw.tell(), - content=bytes(requests_response.content), - ) - - @beartype(conf=BeartypeConf(is_pep484_tower=True)) class VWS: """An interface to Vuforia Web Services APIs.""" @@ -198,7 +122,7 @@ def make_request( This may happen if the server address is not a valid Vuforia server. """ - response = _target_api_request( + response = target_api_request( content_type=content_type, server_access_key=self._server_access_key, server_secret_key=self._server_secret_key, From 0730af2812577fc2c21b804ca5dcb0361285d388 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 21 Feb 2026 00:44:17 +0000 Subject: [PATCH 1000/1003] Fix VuMarkTarget import: use mock_vws.target not mock_vws.database mypy flags VuMarkTarget as not explicitly exported from mock_vws.database; import it from mock_vws.target instead. Co-Authored-By: Claude Sonnet 4.6 --- tests/conftest.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/conftest.py b/tests/conftest.py index bd7bf3740..0f15e6a9a 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -7,7 +7,8 @@ import pytest from mock_vws import MockVWS -from mock_vws.database import CloudDatabase, VuMarkDatabase, VuMarkTarget +from mock_vws.database import CloudDatabase, VuMarkDatabase +from mock_vws.target import VuMarkTarget from vws import VWS, CloudRecoService, VuMarkService From bf64c7faae80e9d67cdb83962b6e14801be8c7c1 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 21 Feb 2026 01:14:51 +0000 Subject: [PATCH 1001/1003] Remove dead expected_result_code=None branch from VWS.make_request No VWS method passes expected_result_code=None; VuMarkService handles binary responses via its own direct target_api_request call. Removing the unused branch restores 100% test coverage. Co-Authored-By: Claude Sonnet 4.6 --- src/vws/vws.py | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/src/vws/vws.py b/src/vws/vws.py index 2eebf8542..6977ed18f 100644 --- a/src/vws/vws.py +++ b/src/vws/vws.py @@ -89,7 +89,7 @@ def make_request( method: str, data: bytes, request_path: str, - expected_result_code: str | None, + expected_result_code: str, content_type: str, extra_headers: dict[str, str] | None = None, ) -> Response: @@ -104,9 +104,6 @@ def make_request( request. expected_result_code: See "VWS API Result Codes" on https://developer.vuforia.com/library/web-api/cloud-targets-web-services-api. - Pass ``None`` for endpoints that return a non-JSON success - response (e.g. binary data); success is then determined by an - HTTP 200 status code. content_type: The content type of the request. extra_headers: Additional headers to include in the request. @@ -145,12 +142,6 @@ def make_request( ): # pragma: no cover raise ServerError(response=response) - if ( - response.status_code == HTTPStatus.OK - and expected_result_code is None - ): - return response - result_code = json.loads(s=response.text)["result_code"] if result_code == expected_result_code: From 396941852d7aaa184b470bd82c7153d157d14740 Mon Sep 17 00:00:00 2001 From: Adam Dangoor Date: Sat, 21 Feb 2026 02:17:10 +0000 Subject: [PATCH 1002/1003] Implement test_invalid_target_type to validate VuMark database type checking The test verifies that InvalidTargetTypeError is raised when attempting to generate a VuMark instance using credentials from a CloudDatabase (non-VuMark) database. This was previously a stub pending the mock implementation in vws-python-mock#2961. Co-Authored-By: Claude Haiku 4.5 --- tests/test_vws_exceptions.py | 36 +++++++++++++++++++++++++++++++++--- 1 file changed, 33 insertions(+), 3 deletions(-) diff --git a/tests/test_vws_exceptions.py b/tests/test_vws_exceptions.py index 49d0365c9..2ab6510ee 100644 --- a/tests/test_vws_exceptions.py +++ b/tests/test_vws_exceptions.py @@ -385,11 +385,41 @@ def test_invalid_instance_id( assert exc.value.response.status_code == HTTPStatus.UNPROCESSABLE_ENTITY -def test_invalid_target_type() -> None: +def test_invalid_target_type( + high_quality_image: io.BytesIO, +) -> None: """ - See https://github.com/VWS-Python/vws-python-mock/issues/2961 for - writing this test. + An ``InvalidTargetType`` exception is raised when trying to generate + a VuMark instance from a non-VuMark database. """ + database = CloudDatabase() + with MockVWS(processing_time_seconds=0.2) as mock: + mock.add_cloud_database(cloud_database=database) + vws_client = VWS( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + ) + target_id = vws_client.add_target( + name="example_target", + width=1, + image=high_quality_image, + active_flag=True, + application_metadata=None, + ) + vumark_service = VuMarkService( + server_access_key=database.server_access_key, + server_secret_key=database.server_secret_key, + ) + with pytest.raises( + expected_exception=InvalidTargetTypeError, + ) as exc: + vumark_service.generate_vumark_instance( + target_id=target_id, + instance_id="example_instance_id", + accept=VuMarkAccept.PNG, + ) + + assert exc.value.response.status_code == HTTPStatus.UNPROCESSABLE_ENTITY def test_base_exception( From 0ca5921b520f2d569d71e9680c6b6e95aa047bf2 Mon Sep 17 00:00:00 2001 From: adamtheturtle <797801+adamtheturtle@users.noreply.github.com> Date: Sat, 21 Feb 2026 08:32:28 +0000 Subject: [PATCH 1003/1003] Bump CHANGELOG --- CHANGELOG.rst | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 20a40ddb9..fffe7a623 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -4,6 +4,10 @@ Changelog Next ---- +2026.02.21 +---------- + + 2026.02.15 ----------