From 3b1f0dd4536cc5cef2c4337ae04392e558b5e3fb Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Sun, 17 May 2020 18:24:58 +0200 Subject: [PATCH 1/5] add pre-commit configuration --- .pre-commit-config.yaml | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 .pre-commit-config.yaml diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 00000000..6a3e303e --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,22 @@ +repos: +- repo: https://gitlab.com/pycqa/flake8 + rev: 3.8.1 + hooks: + - id: flake8 + pass_filenames: true + # this seems to need to be here in addition to setup.cfg + exclude: cibuildwheel/resources/ +- repo: https://github.com/pre-commit/pre-commit-hooks + rev: v2.3.0 + hooks: + - id: check-json + - id: check-yaml + - id: check-merge-conflict + - id: end-of-file-fixer +- repo: https://github.com/pre-commit/mirrors-mypy + rev: '' # Use the sha / tag you want to point at + hooks: + - id: mypy + args: [--strict] + files: cibuildwheel/* + exclude: test|cibuildwheel/resources From d43817b49a8bea0b7517b91f77c851432c2a5e72 Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Sun, 17 May 2020 18:26:25 +0200 Subject: [PATCH 2/5] fixed files --- .circleci/config.yml | 2 +- azure-pipelines.yml | 1 - cibuildwheel/resources/pinned_docker_images.cfg | 1 - docs/extra.js | 1 - 4 files changed, 1 insertion(+), 4 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index cf0e47b2..ae7228a8 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -9,7 +9,7 @@ jobs: - run: name: Install flake8 & mypy - command: sudo python -m pip install flake8 mypy + command: sudo python -m pip install flake8==3.8.1 mypy - run: name: flake8 command: flake8 diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 4fb53b11..3eaed5f4 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -42,4 +42,3 @@ jobs: - bash: | python -m pip install -r requirements-dev.txt pytest-azurepipelines python ./bin/run_tests.py - diff --git a/cibuildwheel/resources/pinned_docker_images.cfg b/cibuildwheel/resources/pinned_docker_images.cfg index 534d350b..ea617735 100644 --- a/cibuildwheel/resources/pinned_docker_images.cfg +++ b/cibuildwheel/resources/pinned_docker_images.cfg @@ -19,4 +19,3 @@ manylinux2014 = quay.io/pypa/manylinux2014_ppc64le:2020-05-17-2f8ac3b [s390x] manylinux2014 = quay.io/pypa/manylinux2014_s390x:2020-05-17-2f8ac3b - diff --git a/docs/extra.js b/docs/extra.js index d32c3cc0..1965a84e 100644 --- a/docs/extra.js +++ b/docs/extra.js @@ -2,4 +2,3 @@ $('.rst-content pre') .prev('blockquote') .addClass('code-block-filename'); - From 1a8396726141bdb0a112b9f58f4e3def9d6a9e77 Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Sun, 17 May 2020 22:30:17 +0200 Subject: [PATCH 3/5] remove json check --- .pre-commit-config.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 6a3e303e..90b33545 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -9,7 +9,6 @@ repos: - repo: https://github.com/pre-commit/pre-commit-hooks rev: v2.3.0 hooks: - - id: check-json - id: check-yaml - id: check-merge-conflict - id: end-of-file-fixer From 39101ae8ea053ff6cbdf1dc198f0c2ed39dabfee Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Sun, 14 Jun 2020 21:20:05 +0200 Subject: [PATCH 4/5] update mypy config --- .pre-commit-config.yaml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 90b33545..1112c38c 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -15,7 +15,6 @@ repos: - repo: https://github.com/pre-commit/mirrors-mypy rev: '' # Use the sha / tag you want to point at hooks: - - id: mypy - args: [--strict] - files: cibuildwheel/* - exclude: test|cibuildwheel/resources + - id: mypy + files: cibuildwheel|test + exclude: cibuildwheel/resources From aa99405a9c9826275e2efb74190e85c6332d95e5 Mon Sep 17 00:00:00 2001 From: Grzegorz Bokota Date: Fri, 19 Jun 2020 21:14:07 +0200 Subject: [PATCH 5/5] unpin flake, exclude pinned_docker_images.cfg --- .circleci/config.yml | 2 +- .pre-commit-config.yaml | 1 + cibuildwheel/resources/pinned_docker_images.cfg | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index ae7228a8..cf0e47b2 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -9,7 +9,7 @@ jobs: - run: name: Install flake8 & mypy - command: sudo python -m pip install flake8==3.8.1 mypy + command: sudo python -m pip install flake8 mypy - run: name: flake8 command: flake8 diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 1112c38c..15c843f9 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -12,6 +12,7 @@ repos: - id: check-yaml - id: check-merge-conflict - id: end-of-file-fixer + exclude: cibuildwheel/resources/pinned_docker_images.cfg - repo: https://github.com/pre-commit/mirrors-mypy rev: '' # Use the sha / tag you want to point at hooks: diff --git a/cibuildwheel/resources/pinned_docker_images.cfg b/cibuildwheel/resources/pinned_docker_images.cfg index ea617735..534d350b 100644 --- a/cibuildwheel/resources/pinned_docker_images.cfg +++ b/cibuildwheel/resources/pinned_docker_images.cfg @@ -19,3 +19,4 @@ manylinux2014 = quay.io/pypa/manylinux2014_ppc64le:2020-05-17-2f8ac3b [s390x] manylinux2014 = quay.io/pypa/manylinux2014_s390x:2020-05-17-2f8ac3b +