update reinfrocement learning #13
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
name: CI | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
branches: | |
- main | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v2 | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: '3.8' | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt | |
pip install -r dev-requirements.txt | |
pip install "black[jupyter]" # Install Jupyter support for Black | |
- name: Run Black | |
run: | | |
black . --exclude "\.ipynb$" # Skip Jupyter notebook files | |
- name: Run isort | |
run: | | |
isort --check-only . --skip-glob "*.ipynb" # Skip Jupyter notebook files | |
- name: Run Pylint | |
run: | | |
pylint src tests --ignore-patterns=".*\.ipynb$" # Skip Jupyter notebook files | |
- name: Run tests with coverage | |
run: | | |
pytest --cov=src tests/ | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v2 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} |