Skip to content

Commit 8e3e839

Browse files
MarcoGorellibrandonwillard
authored andcommitted
fix up pre-commit, run in CI
1 parent 3aa092f commit 8e3e839

File tree

3 files changed

+13
-37
lines changed

3 files changed

+13
-37
lines changed

.github/workflows/test.yml

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -40,20 +40,9 @@ jobs:
4040
runs-on: ubuntu-latest
4141
if: ${{ needs.changes.outputs.changes == 'true' }}
4242
steps:
43-
- uses: actions/checkout@v2
44-
- name: Set up Python
45-
uses: actions/setup-python@v1
46-
with:
47-
python-version: 3.7
48-
- name: Install dependencies
49-
run: |
50-
python -m pip install -U pip
51-
python -m pip install -U black flake8 isort
52-
- name: Check the style
53-
run: |
54-
black -t py36 --check theano/ tests/ setup.py conftest.py
55-
isort --check theano/ tests/ setup.py conftest.py
56-
flake8
43+
- uses: actions/checkout@v2
44+
- uses: actions/setup-python@v2
45+
- uses: pre-commit/[email protected]
5746

5847
test:
5948
name: "Test py${{ matrix.python-version }}: ${{ matrix.part }}"
@@ -63,7 +52,7 @@ jobs:
6352
runs-on: ubuntu-latest
6453
if: ${{ needs.changes.outputs.changes == 'true' && needs.style.result == 'success' }}
6554
strategy:
66-
fail-fast: false
55+
fail-fast: true
6756
matrix:
6857
python-version: ["3.6", "3.7"]
6958
fast-compile: [0]

.pre-commit-config.yaml

Lines changed: 8 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,35 +1,21 @@
1+
exclude: |
2+
(?x)^(
3+
versioneer\.py|
4+
theano/_version\.py|
5+
doc/.*|
6+
bin/.*
7+
)$
18
repos:
29
- repo: https://github.com/psf/black
310
rev: 20.8b1
411
hooks:
512
- id: black
613
language_version: python3
7-
exclude: |
8-
(?x)^(
9-
versioneer\.py|
10-
theano/_version\.py|
11-
doc/.*|
12-
bin/.*
13-
)$
1414
- repo: https://gitlab.com/pycqa/flake8
1515
rev: 3.8.4
1616
hooks:
1717
- id: flake8
18-
exclude: |
19-
(?x)^(
20-
versioneer\.py|
21-
theano/_version\.py|
22-
doc/.*|
23-
bin/.*
24-
)$
2518
- repo: https://github.com/pycqa/isort
26-
rev: 5.5.2
19+
rev: 5.6.4
2720
hooks:
2821
- id: isort
29-
exclude: |
30-
(?x)^(
31-
versioneer\.py|
32-
theano/_version\.py|
33-
doc/.*|
34-
bin/.*
35-
)$

setup.cfg

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ per-file-ignores =
1818
tests/gpuarray/test_elemwise.py:E402
1919
tests/gpuarray/test_others.py:E402
2020
tests/gpuarray/test_basic_ops.py:E402
21+
theano/gof/unify.py:F811
2122
exclude =
2223
versioneer.py
2324
doc/

0 commit comments

Comments
 (0)