Revised algorithm for islanding detection. #2039
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: Python application | |
on: [push, pull_request] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v1 | |
- name: Set up Python 3.9 | |
uses: actions/setup-python@v1 | |
with: | |
python-version: 3.9 | |
- name: Install dependencies | |
run: | | |
# work around a pip issue with extras_require: https://github.com/pypa/pip/issues/8323 | |
python -m pip install -U "pip @ git+https://github.com/pypa/pip.git" | |
python -m pip install --upgrade pip | |
python -m pip install .[all] | |
python -m pip install nbmake==0.10 pytest-xdist line_profiler # add'l packages for notebook tests. | |
- name: Lint with flake8 for pull requests | |
if: github.event_name == 'pull_request' | |
run: | | |
# stop the build if there are Python syntax errors or undefined names | |
flake8 . | |
- name: Test with pytest | |
run: | | |
pytest --log-cli-level=10 | |
- name: Test notebooks. | |
run: | | |
pytest --log-cli-level=10 --nbmake examples --ignore=examples/verification | |
- name: Build a distribution if tagged | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') | |
run: | | |
python setup.py sdist | |
- name: Publish a Python distribution to PyPI if tagged | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') | |
uses: pypa/gh-action-pypi-publish@master | |
with: | |
user: __token__ | |
password: ${{ secrets.pypi_password }} |