From 8791faa236009baed59f3a40ac9d58111a84c7d3 Mon Sep 17 00:00:00 2001 From: s-weigand Date: Fri, 4 Dec 2020 16:28:46 +0100 Subject: [PATCH] Added flake8 to pre-commit config and set flake8 to ignore E203 E203 needs to be ignore due to a false positive alert for slicing. See. https://github.com/PyCQA/pycodestyle/issues/373#issuecomment-678689283 --- .pre-commit-config.yaml | 5 +++++ setup.cfg | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 65d990e83..ff46eba95 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -12,3 +12,8 @@ repos: hooks: - id: black language_version: python3 + + - repo: https://gitlab.com/pycqa/flake8 + rev: 3.8.4 + hooks: + - id: flake8 diff --git a/setup.cfg b/setup.cfg index 0a195fdb9..82e8014ef 100644 --- a/setup.cfg +++ b/setup.cfg @@ -12,6 +12,6 @@ search = __version__ = '{current_version}' replace = __version__ = '{new_version}' [flake8] -extend-ignore = F401,W504 +extend-ignore = F401,W504,E203 exclude = __init__.py,*.pyc,tests.py paths = ./holidays/ ./tests/