Skip to content

Update pip requirement from <24.1,>=21.0 to >=21.0,<24.2 #283

Update pip requirement from <24.1,>=21.0 to >=21.0,<24.2

Update pip requirement from <24.1,>=21.0 to >=21.0,<24.2 #283

Workflow file for this run

name: CI
on:
push:
branches:
- main
pull_request: ~
env:
DEFAULT_PYTHON: "3.12"
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
style:
runs-on: ubuntu-latest
name: Check style formatting
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4
- name: Setup python
uses: actions/setup-python@v5
with:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Check code formatting with black
uses: psf/black@stable
- name: Check code formatting with isort
uses: isort/isort-action@master
with:
requirementsFiles: "requirements.txt requirements_dev.txt"
tests:
runs-on: ubuntu-latest
name: Run tests
steps:
- name: Check out code from GitHub
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: ${{ env.DEFAULT_PYTHON }}
- name: Install requirements
run: |
python3 -m pip install -r requirements_dev.txt
- name: Run tests
run: |
pytest \
-qq \
--timeout=9 \
--durations=10 \
-n auto \
--cov custom_components.knmi \
--cov-report=term \
--cov-report=xml \
-o console_output_style=count \
-p no:sugar \
tests
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: true
- name: SonarCloud Scan
uses: sonarsource/sonarcloud-github-action@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}