From bdaef73fb3acbc0a5c60794f0d65e9a61042595d Mon Sep 17 00:00:00 2001 From: Roman Dyakov Date: Sat, 6 Apr 2024 15:31:42 +0300 Subject: [PATCH 1/4] Makefile format --- Makefile | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Makefile b/Makefile index 3d2daa7..6cbaeed 100644 --- a/Makefile +++ b/Makefile @@ -8,3 +8,9 @@ format: source ./venv/bin/activate && autoflake -r --in-place --remove-all-unused-imports ./auth_lib source ./venv/bin/activate && isort ./auth_lib source ./venv/bin/activate && black ./auth_lib + source ./venv/bin/activate && autoflake -r --in-place --remove-all-unused-imports ./tests + source ./venv/bin/activate && isort ./tests + source ./venv/bin/activate && black ./tests + source ./venv/bin/activate && autoflake -r --in-place --remove-all-unused-imports ./migrations + source ./venv/bin/activate && isort ./migrations + source ./venv/bin/activate && black ./migrations From 50412af42fc449a7d6784be78864341dd37e64d6 Mon Sep 17 00:00:00 2001 From: Roman Dyakov Date: Sat, 6 Apr 2024 15:41:18 +0300 Subject: [PATCH 2/4] Style --- Makefile | 6 ------ auth_lib/aiomethods.py | 2 +- auth_lib/methods.py | 2 +- 3 files changed, 2 insertions(+), 8 deletions(-) diff --git a/Makefile b/Makefile index 6cbaeed..3d2daa7 100644 --- a/Makefile +++ b/Makefile @@ -8,9 +8,3 @@ format: source ./venv/bin/activate && autoflake -r --in-place --remove-all-unused-imports ./auth_lib source ./venv/bin/activate && isort ./auth_lib source ./venv/bin/activate && black ./auth_lib - source ./venv/bin/activate && autoflake -r --in-place --remove-all-unused-imports ./tests - source ./venv/bin/activate && isort ./tests - source ./venv/bin/activate && black ./tests - source ./venv/bin/activate && autoflake -r --in-place --remove-all-unused-imports ./migrations - source ./venv/bin/activate && isort ./migrations - source ./venv/bin/activate && black ./migrations diff --git a/auth_lib/aiomethods.py b/auth_lib/aiomethods.py index 25951e0..6b896d5 100644 --- a/auth_lib/aiomethods.py +++ b/auth_lib/aiomethods.py @@ -3,7 +3,7 @@ import aiohttp -from .exceptions import AuthFailed, IncorrectData, NotFound, SessionExpired +from .exceptions import AuthFailed, SessionExpired # See docs on https://api.test.profcomff.com/?urls.primaryName=auth diff --git a/auth_lib/methods.py b/auth_lib/methods.py index 48cbe67..a5d876a 100644 --- a/auth_lib/methods.py +++ b/auth_lib/methods.py @@ -3,7 +3,7 @@ import requests -from .exceptions import AuthFailed, IncorrectData, NotFound, SessionExpired +from .exceptions import AuthFailed, SessionExpired # See docs on https://api.test.profcomff.com/?urls.primaryName=auth From faddf7be02b2aad4fcc74010b686879bb1fb9c8b Mon Sep 17 00:00:00 2001 From: Roman Dyakov Date: Sat, 6 Apr 2024 15:56:50 +0300 Subject: [PATCH 3/4] Better on pr workflow --- .github/workflows/checks.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.github/workflows/checks.yml b/.github/workflows/checks.yml index 02c1cb2..d62c737 100644 --- a/.github/workflows/checks.yml +++ b/.github/workflows/checks.yml @@ -1,9 +1,8 @@ -name: Python package +name: Python tests on: pull_request: - jobs: linting: runs-on: ubuntu-latest @@ -17,9 +16,8 @@ jobs: requirementsFiles: "requirements.txt requirements.dev.txt" - uses: psf/black@stable - name: Comment if linting failed - if: ${{ failure() }} + if: failure() uses: thollander/actions-comment-pull-request@v2 with: message: | :poop: Code linting failed, use `black` and `isort` to fix it. - From 9219ca7bfa6810faaafda839e2bd27e51031b720 Mon Sep 17 00:00:00 2001 From: Roman Dyakov Date: Sat, 6 Apr 2024 16:07:46 +0300 Subject: [PATCH 4/4] Style --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 960c225..82f7f5b 100644 --- a/setup.py +++ b/setup.py @@ -5,7 +5,7 @@ with open("requirements.txt", "r", encoding="utf-8") as req_file: - req = req_file.read().split('\n') + req = req_file.read().split("\n") setup(