diff --git a/.flake8 b/.flake8 deleted file mode 100644 index 8cdc2fb..0000000 --- a/.flake8 +++ /dev/null @@ -1,27 +0,0 @@ -[flake8] -per-file-ignores = - */__init__.py: F401 -ignore=C901,E126 -exclude = - /venv, - /.tox, - /**/.data, - /tests/tmp, - /**/*.egg-info, - /dist, - /logs, - **/__pycache__, - /.run, - **/.env*, - /.gitignore, - /.pylintrc, - /.dockerignore, - .idea, - .git, - .vscode, - *.suo, - *.ntvs*, - *.njsproj, - *.sln, - *.sw?, - /temp, diff --git a/.github/workflows/python-tests.yml b/.github/workflows/python-tests.yml index 24373cd..de80fa3 100644 --- a/.github/workflows/python-tests.yml +++ b/.github/workflows/python-tests.yml @@ -33,9 +33,9 @@ jobs: - name: Lint with tests run: | # stop the build if there are Python syntax errors or undefined names - flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics + flake8 ./src --count --select=E9,F63,F7,F82 --show-source --statistics # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide - flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics + flake8 ./src --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics - name: Test run: | python -m unittest discover -s tests -t . -p "test_*.py" diff --git a/setup.cfg b/setup.cfg index 1929e97..76b3303 100644 --- a/setup.cfg +++ b/setup.cfg @@ -65,3 +65,31 @@ remote = motor>=3.3.2 elasticsearch[async]~=8.11.0 cos-python-sdk-v5~=1.9.29 + +[flake8] +per-file-ignores = + */__init__.py: F401 +ignore = C901,E126,E501 +exclude = + /venv, + /.tox, + /**/.data, + /tests, + /**/*.egg-info, + /dist, + /logs, + **/__pycache__, + /.run, + **/.env*, + /.gitignore, + /.pylintrc, + /.dockerignore, + .idea, + .git, + .vscode, + *.suo, + *.ntvs*, + *.njsproj, + *.sln, + *.sw?, + /temp, diff --git a/tox.ini b/tox.ini index 26212cd..de730ef 100644 --- a/tox.ini +++ b/tox.ini @@ -1,7 +1,7 @@ [tox] requires = tox-conda minversion = 3.8.0 -envlist = py{38,39,310,311} +envlist = py{38,39,310,311,312} isolated_build = true skipsdist = true skip_missing_interpreters = true