From 8129a432c760ae5956a0a7e89bf86ef89e7fd0d6 Mon Sep 17 00:00:00 2001 From: Masaya Suzuki <15100604+massongit@users.noreply.github.com> Date: Mon, 2 May 2022 23:28:30 +0900 Subject: [PATCH] Disable flake8 rule E203 (#2821) * Disable flake8 rule E203 * Fix test case * Fix test case * Fix test case * empty commit * Ignore W503 * Change settings --- .automation/test/python_black/python_bad_1.py | 2 ++ .automation/test/python_black/python_good_1.py | 2 ++ .automation/test/python_flake8/python_good_1.py | 2 ++ .github/linters/.flake8 | 1 + TEMPLATES/.flake8 | 1 + 5 files changed, 8 insertions(+) diff --git a/.automation/test/python_black/python_bad_1.py b/.automation/test/python_black/python_bad_1.py index 369a7224..5776c2ae 100644 --- a/.automation/test/python_black/python_bad_1.py +++ b/.automation/test/python_black/python_bad_1.py @@ -11,6 +11,8 @@ env = load_dotenv() api_url = getenv(API_URL, default='https://api.github.com/graphql' ) github_token = getenv("GITHUB_TOKEN", default=None) +m = [1, 2, 3] +print(m[len("t"):]) if github_token is None sys.exit("GitHub Token is not set." + diff --git a/.automation/test/python_black/python_good_1.py b/.automation/test/python_black/python_good_1.py index d41cef25..e5c716e8 100644 --- a/.automation/test/python_black/python_good_1.py +++ b/.automation/test/python_black/python_good_1.py @@ -10,6 +10,8 @@ from dotenv import load_dotenv # pylint: disable=import-error env = load_dotenv() api_url = getenv("API_URL", default="https://api.github.com/graphql") github_token = getenv("GITHUB_TOKEN", default=None) +m = [1, 2, 3] +print(m[len("t") :]) if github_token is None: sys.exit( diff --git a/.automation/test/python_flake8/python_good_1.py b/.automation/test/python_flake8/python_good_1.py index fd2e6a86..e933eddb 100644 --- a/.automation/test/python_flake8/python_good_1.py +++ b/.automation/test/python_flake8/python_good_1.py @@ -10,6 +10,8 @@ from dotenv import load_dotenv # pylint: disable=import-error env = load_dotenv() api_url = getenv("API_URL", default="https://api.github.com/graphql") github_token = getenv("GITHUB_TOKEN", default=None) +m = [1, 2, 3] +print(m[len("t") :]) if github_token is None: sys.exit( diff --git a/.github/linters/.flake8 b/.github/linters/.flake8 index 6deafc26..8332de34 100644 --- a/.github/linters/.flake8 +++ b/.github/linters/.flake8 @@ -1,2 +1,3 @@ [flake8] max-line-length = 120 +extend-ignore = E203 diff --git a/TEMPLATES/.flake8 b/TEMPLATES/.flake8 index 6deafc26..8332de34 100644 --- a/TEMPLATES/.flake8 +++ b/TEMPLATES/.flake8 @@ -1,2 +1,3 @@ [flake8] max-line-length = 120 +extend-ignore = E203