-
Notifications
You must be signed in to change notification settings - Fork 0
39 lines (31 loc) · 1008 Bytes
/
Copy pathpython_checks.yml
File metadata and controls
39 lines (31 loc) · 1008 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: Python Checks
on:
push:
branches: [ "master", "release/**" ]
pull_request:
branches: [ "master" ]
jobs:
python_checks:
name: Run Python Checks
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.x'
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
pip install flake8 pylint mypy black
- name: Check Python syntax with flake8
run: |
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
flake8 . --count --exit-zero --max-complexity=15 --max-line-length=300 --statistics
- name: Check Python types with mypy
run: |
mypy --install-types --non-interactive --ignore-missing-imports .
- name: Check Python formatting with Black
run: |
black --check --diff .