Skip to content

Commit

Permalink
set Python version for pre-commit and turn versions into strings
Browse files Browse the repository at this point in the history
  • Loading branch information
alexander-held committed Jun 27, 2022
1 parent 3205e6d commit 0df4987
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 10 deletions.
10 changes: 6 additions & 4 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,16 @@ jobs:
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.9'
- uses: pre-commit/action@v3.0.0

test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: [3.7, 3.8, 3.9]
python-version: ['3.7', '3.8', '3.9']

steps:
- uses: actions/checkout@v3
Expand Down Expand Up @@ -51,15 +53,15 @@ jobs:
run: |
python -m pip install .[pyhf_backends] # install pyhf backends
- name: Test with pytest and generate coverage report
if: matrix.python-version == 3.7
if: matrix.python-version == '3.7'
run: |
pytest --runslow --cov-report=xml
- name: Test with pytest
if: matrix.python-version != 3.7
if: matrix.python-version != '3.7'
run: |
pytest --runslow
- name: Upload coverage to codecov
if: matrix.python-version == 3.7
if: matrix.python-version == '3.7'
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/dependencies-head.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
python-version: [3.9]
python-version: ['3.9']

steps:
- uses: actions/checkout@v3
Expand All @@ -38,7 +38,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
python-version: [3.9]
python-version: ['3.9']

steps:
- uses: actions/checkout@v3
Expand All @@ -63,7 +63,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
python-version: [3.9]
python-version: ['3.9']

steps:
- uses: actions/checkout@v3
Expand All @@ -88,7 +88,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
python-version: [3.9]
python-version: ['3.9']

steps:
- uses: actions/checkout@v3
Expand All @@ -114,7 +114,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
python-version: [3.9]
python-version: ['3.9']

steps:
- uses: actions/checkout@v3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
- name: Set up Python 3.9
uses: actions/setup-python@v4
with:
python-version: 3.9
python-version: '3.9'

- name: Install python-build, check-manifest, and twine
run: |
Expand Down

0 comments on commit 0df4987

Please # to comment.