From 616fbda9cfb91b6ad43650cd24fd31f6502cc571 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Tue, 25 Apr 2023 05:45:08 +0000 Subject: [PATCH 1/2] [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: v4.3.0 → v4.4.0](https://github.com/pre-commit/pre-commit-hooks/compare/v4.3.0...v4.4.0) - [github.com/psf/black: 22.10.0 → 23.3.0](https://github.com/psf/black/compare/22.10.0...23.3.0) - [github.com/pre-commit/mirrors-prettier: v3.0.0-alpha.2 → v3.0.0-alpha.9-for-vscode](https://github.com/pre-commit/mirrors-prettier/compare/v3.0.0-alpha.2...v3.0.0-alpha.9-for-vscode) - [github.com/pycqa/flake8: 5.0.4 → 6.0.0](https://github.com/pycqa/flake8/compare/5.0.4...6.0.0) --- .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 2f36ebd..2b3ff16 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -2,7 +2,7 @@ # See https://pre-commit.com/hooks.html for more hooks repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v4.3.0 + rev: v4.4.0 hooks: - id: trailing-whitespace - id: end-of-file-fixer @@ -10,11 +10,11 @@ repos: # - id: check-added-large-files - repo: https://github.com/psf/black - rev: 22.10.0 + rev: 23.3.0 hooks: - id: black - repo: https://github.com/pre-commit/mirrors-prettier - rev: 'v3.0.0-alpha.2' # Use the sha / tag you want to point at + rev: 'v3.0.0-alpha.9-for-vscode' # Use the sha / tag you want to point at hooks: - id: prettier files: "^frontend/" @@ -23,7 +23,7 @@ repos: - "prettier-plugin-svelte@latest" - "prettier@latest" - repo: https://github.com/pycqa/flake8 - rev: 5.0.4 + rev: 6.0.0 hooks: - id: flake8 # flake8 is passed in all tracked python files From 6ea0d809ad489c3429fccefdb93f7791212bf1fa Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Tue, 25 Apr 2023 05:45:28 +0000 Subject: [PATCH 2/2] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- classquiz/cache.py | 1 - classquiz/tests/test_server.py | 1 - 2 files changed, 2 deletions(-) diff --git a/classquiz/cache.py b/classquiz/cache.py index cc9bec3..14fd059 100644 --- a/classquiz/cache.py +++ b/classquiz/cache.py @@ -33,7 +33,6 @@ async def cache_account(criteria: str, content: str) -> Union[User, None]: await insert_into_redis(res, content) return res elif criteria == "id": - try: res = await User.objects.get(id=uuid.UUID(content), verified=True) except ormar.exceptions.NoMatch: diff --git a/classquiz/tests/test_server.py b/classquiz/tests/test_server.py index 603482a..1d8468e 100644 --- a/classquiz/tests/test_server.py +++ b/classquiz/tests/test_server.py @@ -510,7 +510,6 @@ class TestEditor: class TestExImport: @pytest.mark.asyncio async def test_export_quiz(self, test_client): # noqa : F811 - resp = test_client.get("/api/v1/eximport/jgfgufgfgfzftzi") assert resp.status_code == 422 resp = test_client.get("/api/v1/eximport/8bd77201-65ed-46fe-9160-cfe71dad501f")