added a missing comma π§ββοΈ #188
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This workflow will install Python dependencies, run tests and lint with a single version of Python | |
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions | |
name: Python application | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Cache | |
uses: actions/[email protected] | |
with: | |
path: ~/.cache/pip | |
key: ${{ runner.os }}-pip-${{ hashFiles('**/flake8_requirements.txt') }} | |
restore-keys: | | |
${{ runner.os }}-pip- | |
- name: Lines of codes | |
run: | | |
find . -name '*.py' | xargs wc -l | |
- name: Set up Python 3.10 | |
uses: actions/setup-python@v2 | |
with: | |
python-version: "3.10" | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install flake8 | |
if [ -f flake8_requirements.txt ]; then pip install -r flake8_requirements.txt; fi | |
- name: Lint with flake8 | |
run: | | |
# stop the build if there are Python syntax errors or undefined names | |
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide, but we are ok with 150 | |
flake8 . --count --select E9,F63,F7,F82 --ignore E203,F --show-source --exit-zero --max-complexity 35 --max-line-length 150 --statistics |