This repository was archived by the owner on Oct 13, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +29
-6
lines changed Expand file tree Collapse file tree 2 files changed +29
-6
lines changed Original file line number Diff line number Diff line change 1
1
[flake8]
2
2
filename =
3
- *.py,
4
- *.pys
3
+ *.py
5
4
max-line-length = 120
6
5
extend-exclude =
7
6
venv/
Original file line number Diff line number Diff line change @@ -26,13 +26,37 @@ jobs:
26
26
- name : Set up Python
27
27
uses : actions/setup-python@v5 # https://github.com/actions/setup-python
28
28
with :
29
- python-version : ' 3.10 '
29
+ python-version : ' 3.12 '
30
30
31
31
- name : Install dependencies
32
32
run : |
33
- # pin flake8 before v6.0.0 due to removal of support for type comments (required for Python 2.7 type hints)
34
- python -m pip install --upgrade pip setuptools "flake8<6"
33
+ python -m pip install --upgrade \
34
+ pip \
35
+ setuptools \
36
+ wheel \
37
+ flake8 \
38
+ nb-clean \
39
+ nbqa[toolchain]
35
40
36
41
- name : Test with flake8
37
42
run : |
38
- python -m flake8 --verbose
43
+ python -m flake8 \
44
+ --color=always \
45
+ --verbose
46
+
47
+ - name : Test with nbqa
48
+ run : |
49
+ python -m nbqa flake8 \
50
+ --color=always \
51
+ --verbose \
52
+ .
53
+
54
+ - name : Test with nb-clean
55
+ run : |
56
+ output=$(find . -name '*.ipynb' -exec nb-clean check {} \;)
57
+
58
+ # fail if there are any issues
59
+ if [ -n "$output" ]; then
60
+ echo "$output"
61
+ exit 1
62
+ fi
You can’t perform that action at this time.
0 commit comments