Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restore the codecov comments on PRs #1173

Merged
merged 5 commits into from
Nov 25, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions .github/codecov.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,23 +12,27 @@ coverage:
paths:
- "src/jupytext/"
target: 97%
threshold: 0.002
threshold: 0.2%
tests:
paths:
- "tests/"
target: 100%
unit-tests:
threshold: 0.2%
flags:
- unit
functional-tests:
threshold: 0.2%
flags:
- functional
integration-tests:
threshold: 0.2%
flags:
- integration
external-tests:
threshold: 0.2%
flags:
- external
patch:
default:
target: 80% # new contributions should have a coverage at least equal to target
target: 80%
10 changes: 0 additions & 10 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,13 +58,3 @@ jobs:
uses: ./.github/workflows/step_build.yml
with:
upload: ${{ inputs.upload-build-artifacts || false }}

pass:
needs: [pre-commit, codeql, test-unit-functional-integration, test-pip, test-conda, test-ui, build]
runs-on: ubuntu-latest
steps:
- name: Check jobs
uses: re-actors/alls-green@release/v1
with:
jobs: ${{ toJSON(needs) }}
if: always()
23 changes: 13 additions & 10 deletions .github/workflows/step_tests-conda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ jobs:
os: [ 'ubuntu-latest', 'macos-latest', 'windows-latest' ]
python-version: [ 3.11 ]
runs-on: ${{ matrix.os }}
defaults:
run:
shell: bash -el {0}

steps:
- name: Checkout
Expand All @@ -38,29 +41,29 @@ jobs:
use-only-tar-bz2: true

- name: Install from source
shell: pwsh
run: python -m pip install -e '.[test-external,test-cov]'

- name: Create kernel
shell: pwsh
run: |
python -m ipykernel install --name jupytext-ci --user

- name: Conda list
shell: pwsh
run: conda list

- name: Install a Jupyter Kernel
run: python -m ipykernel install --name jupytext-ci --user

- name: Test lab extension
shell: pwsh
run: |
# Check extension
jupyter labextension list
jupyter labextension list 2>&1 | grep -ie "jupyterlab-jupytext.*OK"
python -m jupyterlab.browser_check

- name: Test with pytest
shell: pwsh
run: pytest --cov
# We use an explicit coverage file otherwise the
# codecov action below does not find it
run: pytest --cov . --cov-report xml:coverage.xml

- name: Upload coverage
uses: codecov/codecov-action@v3
with:
fail_ci_if_error: true
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fail_ci_if_error has no effect here because this step is not triggered if the test step failed. You can add if: always() if you do want it to upload failed code coverage.

verbose: true
files: coverage.xml
20 changes: 7 additions & 13 deletions .github/workflows/step_tests-pip.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,26 +10,17 @@ concurrency:

jobs:
test-pip:
continue-on-error: ${{ matrix.experimental || false }}
runs-on: ubuntu-latest

strategy:
fail-fast: false
matrix:
python-version: [ "3.8", "3.9", "3.10", "3.11" ]
markdown-it-py-version: ["~=2.0"]
python-version: [ "3.8", "3.9", "3.10", "3.11", "3.12-dev"]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Python 3.12 has been officially out. Should be included soon.

markdown-it-py-version: ["~=3.0"]
include:
- python-version: "3.12-dev"
experimental: true
- python-version: "3.13-dev"
experimental: true
- python-version: "3.x"
markdown-it-py-version: ""
- python-version: "3.x"
markdown-it-py-version: "~=3.0"
markdown-it-py-version: "~=2.0"
- python-version: "3.x"
markdown-it-py-version: "~=4.0"
experimental: true
markdown-it-py-version: ""
- python-version: "3.x"
no_kernel: true
- python-version: "3.x"
Expand Down Expand Up @@ -74,3 +65,6 @@ jobs:

- name: Upload coverage
uses: codecov/codecov-action@v3
with:
fail_ci_if_error: true
verbose: true
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ test-functional = [
]
test-integration = [
"jupytext[test-functional]",
"jupyter-server",
"jupyter-server!=2.11", # issue 1165
# jupytext --execute
"nbconvert",
"ipykernel",
Expand Down
Loading