From ca45eaea2e6b2005788dbeb17d04e17caf812acf Mon Sep 17 00:00:00 2001 From: Chavithra Date: Sat, 27 Nov 2021 20:47:25 +0100 Subject: [PATCH] Updating workflows : codespell + mypy (#991) --- .github/workflows/test.yml | 4 ++-- .pre-commit-config.yaml | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 6202d321b85..3afd4dfd123 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -30,7 +30,7 @@ jobs: - run: pip install types-pytz types-requests types-termcolor types-tabulate types-PyYAML types-python-dateutil - run: bandit -x ./tests -r . || true - run: black --check . - - run: codespell --ignore-words-list=pres,hsi,hist,mape,ba,ser,coo --quiet-level=2 --skip=".git" --skip="*.yaml" --skip="*.ipynb" --skip="*.json" --skip="*.js" --skip="*.css" --skip="*.scss" --skip="*.html" --skip="*.ini" --skip="*.lock" --skip="*.csv" + - run: codespell --ignore-words-list=ba,buil,coo,ether,hist,hsi,mape,navagation,operatio,pres,ser,yeld --quiet-level=2 --skip="./tests,.git,*.css,*.csv,*.html,*.ini,*.ipynb,*.js,*.json,*.lock,*.scss,*.txt,*.yaml" - run: flake8 . --count --ignore=E203,W503 --max-line-length=122 --show-source --statistics - run: mypy --ignore-missing-imports --exclude '/setup\.py$' . - run: shopt -s globstar && pyupgrade --py36-plus **/*.py @@ -250,7 +250,7 @@ jobs: shell: bash -l {0} run: | pip install pylint==2.11.1 - pylint terminal.py gamestonk_terminal discordbot tests + pylint discordbot gamestonk_terminal terminal.py tests - name: Run MyPy (Bash) if: runner.os != 'Windows' diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 08e09107320..69b509d6da1 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -15,23 +15,23 @@ repos: rev: 3.9.2 hooks: - id: flake8 - entry: flake8 --max-line-length=122 --ignore=E203,W503 + entry: flake8 --ignore=E203,W503 --max-line-length=122 - repo: https://github.com/codespell-project/codespell rev: v2.1.0 hooks: - id: codespell entry: codespell - args: [ '--ignore-words-list=pres,coo,navagation,ser,buil,operatio,mape,ba,hist,yeld,ether,hsi', '--quiet-level=2', '--skip=".git,*.html,*.yaml,*.json,./tests,*.csv"' ] + args: [ '--ignore-words-list=ba,buil,coo,ether,hist,hsi,mape,navagation,operatio,pres,ser,yeld', '--quiet-level=2', '--skip="./tests,.git,*.css,*.csv,*.html,*.ini,*.ipynb,*.js,*.json,*.lock,*.scss,*.txt,*.yaml"' ] - repo: https://github.com/pre-commit/mirrors-mypy rev: 'v0.812' hooks: - id: mypy - args: [ --ignore-missing-imports ] + args: [ '--ignore-missing-imports', '--exclude "/setup\.py$"', '.'] - repo: local hooks: - id: pylint name: pylint - entry: pylint terminal.py gamestonk_terminal tests discordbot + entry: pylint discordbot gamestonk_terminal terminal.py tests language: system types: [python] - repo: https://github.com/Yelp/detect-secrets