Skip to content

ci: Add Flake8 linting to notebooks #7203

ci: Add Flake8 linting to notebooks

ci: Add Flake8 linting to notebooks #7203

Workflow file for this run

name: Flake8
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
on:
# Trigger the workflow on push or pull request,
# but only for the master branch
push:
branches:
- master
pull_request:
branches:
- master
jobs:
flake8:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.12
uses: actions/setup-python@v5
with:
python-version: 3.12
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install flake8
pip install nbqa
- name: Lint with flake8
run: |
flake8 --builtins=ArgumentError .
- name: Lint notebooks with flake8
run: |
nbqa flake8 examples/