Skip to content

Commit

Permalink
replace black/isort/flake8 with ruff
Browse files Browse the repository at this point in the history
  • Loading branch information
ceholden committed Oct 24, 2024
1 parent aa5fe6c commit 3fa51a8
Show file tree
Hide file tree
Showing 39 changed files with 389 additions and 957 deletions.
5 changes: 2 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,8 @@ install:
$(MAKE) -C layers/db install

lint:
pipenv run flake8 cdk/ integration_tests/
pipenv run isort --check-only --profile black cdk/ integration_tests/
pipenv run black --check --diff cdk/ integration_tests/
pipenv run ruff format --diff cdk/ integration_tests/
pipenv run ruff check cdk/ integration_tests/
$(MAKE) -C lambdas/link_fetcher lint
$(MAKE) -C lambdas/date_generator lint
$(MAKE) -C lambdas/downloader lint
Expand Down
4 changes: 1 addition & 3 deletions Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,7 @@ name = "pypi"
[packages]

[dev-packages]
flake8 = "==7.1.1"
isort = "==5.13.2"
black = "==23.11.0"
ruff = "==0.7.1"

[requires]
python_version = "3.11"
27 changes: 26 additions & 1 deletion Pipfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions alembic_migration/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ install:
pipenv install --dev

lint:
pipenv run flake8 .
pipenv run isort --check-only --profile black .
pipenv run black --check --diff .
pipenv run ruff format --diff
pipenv run ruff check

format:
pipenv run isort --profile black .
pipenv run black .
pipenv run ruff check --fix
pipenv run ruff check --select I --fix
pipenv run ruff format

test:
pipenv run pytest -s --cov=. --cov-report term-missing tests/
4 changes: 1 addition & 3 deletions alembic_migration/Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,13 @@ sqlalchemy = "==1.4.0"

[dev-packages]
db = {editable = true, path = "./../layers/db"}
flake8 = "==7.1.1"
isort = "==5.13.2"
black = "==23.11.0"
pytest = "==7.4.3"
moto = "==5.0.17"
psycopg2 = "==2.9.10"
pytest-docker = "==2.0.1"
assertpy = "==1.1"
pytest-cov = "==4.1.0"
ruff = "==0.7.1"

[requires]
python_version = "3.11"
Expand Down
144 changes: 35 additions & 109 deletions alembic_migration/Pipfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions alembic_migration/versions/1c8c38951d47_initiation.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
Create Date: 2021-01-14 12:30:09.347153
"""

from alembic import op
from sqlalchemy import BigInteger, Boolean, Column, Date, DateTime, SmallInteger, String

Expand Down
10 changes: 5 additions & 5 deletions lambdas/date_generator/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ install:
pipenv install --dev

lint:
pipenv run flake8 .
pipenv run isort --check-only --profile black .
pipenv run black --check --diff .
pipenv run ruff format --diff
pipenv run ruff check

format:
pipenv run isort --profile black .
pipenv run black .
pipenv run ruff check --fix
pipenv run ruff check --select I --fix
pipenv run ruff format

test:
pipenv run pytest -s --cov=handler --cov-report term-missing tests/
4 changes: 1 addition & 3 deletions lambdas/date_generator/Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,11 @@ name = "pypi"
[packages]

[dev-packages]
flake8 = "==7.1.1"
isort = "==5.13.2"
black = "==23.11.0"
pytest = "==7.4.3"
assertpy = "==1.1"
freezegun = "==1.0.0"
pytest-cov = "==4.1.0"
ruff = "==0.7.1"

[requires]
python_version = "3.11"
Expand Down
Loading

0 comments on commit 3fa51a8

Please sign in to comment.