build(deps-dev): bump flake8-bugbear from 24.10.31 to 24.12.12 #1194
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: Tests | |
on: | |
push: | |
branches: | |
- main | |
tags: | |
- 'v*' | |
pull_request: | |
jobs: | |
style: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- uses: abatilo/[email protected] | |
- run: poetry install | |
- run: poetry run flake8 | |
- run: poetry run black --check . | |
- run: poetry run mypy idasen tests | |
docs: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: "3.12" | |
- uses: abatilo/[email protected] | |
- name: Install bluetooth | |
run: | | |
sudo apt update | |
sudo apt install bluetooth | |
- run: poetry install | |
- name: Run sphinx | |
run: poetry run sphinx-build -W -b html docs public | |
- uses: actions/upload-pages-artifact@v3 | |
with: | |
path: public | |
deploy_docs: | |
runs-on: ubuntu-latest | |
needs: docs | |
if: ${{ github.ref == 'refs/heads/main' }} | |
permissions: | |
pages: write | |
id-token: write | |
environment: | |
name: github-pages | |
url: ${{ steps.deployment.outputs.page_url }} | |
steps: | |
- uses: actions/deploy-pages@v4 | |
id: deployment | |
pytest: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- uses: abatilo/[email protected] | |
- name: Install bluetooth | |
run: | | |
sudo apt update | |
sudo apt install bluetooth | |
- run: poetry install | |
- name: Run pytest | |
run: poetry run pytest -vvv --cov=idasen --doctest-modules | |
- name: Upload coverage data to coveralls.io | |
run: poetry run coveralls --service=github | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
COVERALLS_FLAG_NAME: py${{ matrix.python-version }} | |
COVERALLS_PARALLEL: true | |
coveralls: | |
name: Indicate completion to coveralls.io | |
needs: pytest | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: "3.12" | |
- name: Install Poetry | |
uses: abatilo/[email protected] | |
- run: poetry install | |
- name: Finished | |
run: poetry run coveralls --finish --service=github | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
release: | |
name: PyPi Release | |
runs-on: ubuntu-latest | |
if: startsWith(github.ref, 'refs/tags/v') | |
needs: [pytest, docs, style] | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: "3.12" | |
- name: Install Poetry | |
uses: abatilo/[email protected] | |
- run: poetry install | |
- run: poetry publish --build | |
env: | |
POETRY_PYPI_TOKEN_PYPI: ${{ secrets.PYPI_TOKEN }} |