Skip to content

Commit e308579

Browse files
committed
Try to remove codecov
1 parent 29aa84e commit e308579

File tree

4 files changed

+47
-124
lines changed

4 files changed

+47
-124
lines changed

.github/workflows/ci.yml

Lines changed: 2 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -167,19 +167,11 @@ jobs:
167167
env:
168168
UV_PYTHON: ${{ matrix.python-version }}
169169

170-
- name: Show coverage file
171-
run: |
172-
# Sometimes we have been sure that we have 100% coverage, but codecov
173-
# says otherwise.
174-
#
175-
# We show the coverage file here to help with debugging.
176-
# https://github.com/VWS-Python/vws-python-mock/issues/708
177-
cat ./coverage.xml
178-
179170
- name: Upload coverage data
180171
uses: actions/upload-artifact@v4
181172
with:
182-
name: coverage-data-${{ matrix.python-version }}-${{ matrix.ci_pattern }}
173+
name: |
174+
coverage-data-ci-${{ matrix.python-version }}-${{ matrix.ci_pattern}}
183175
path: .coverage.*
184176
include-hidden-files: true
185177
if-no-files-found: ignore
@@ -195,41 +187,3 @@ jobs:
195187
echo "One or more matrix jobs failed"
196188
exit 1
197189
fi
198-
199-
coverage:
200-
name: Combine & check coverage
201-
if: always()
202-
needs: build
203-
runs-on: ubuntu-latest
204-
205-
steps:
206-
- uses: actions/checkout@v5
207-
- uses: actions/setup-python@v5
208-
with:
209-
# Use latest Python, so it understands all syntax.
210-
python-version: '3.13'
211-
212-
- uses: actions/download-artifact@v4
213-
with:
214-
pattern: coverage-data-*
215-
merge-multiple: true
216-
217-
- name: Combine coverage & fail if it's <100%
218-
run: |
219-
uv tool install 'coverage[toml]'
220-
221-
coverage combine
222-
coverage html --skip-covered --skip-empty
223-
224-
# Report and write to summary.
225-
coverage report --format=markdown >> "$GITHUB_STEP_SUMMARY"
226-
227-
# Report again and fail if under 100%.
228-
coverage report --fail-under=100
229-
230-
- name: Upload HTML report if check failed
231-
uses: actions/upload-artifact@v4
232-
with:
233-
name: html-report
234-
path: htmlcov
235-
if: ${{ failure() }}

.github/workflows/coverage.yml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
---
2+
name: Coverage
3+
4+
on:
5+
workflow_run:
6+
workflows: [CI, Skip tests, Windows CI]
7+
types: [completed]
8+
9+
jobs:
10+
coverage:
11+
name: Combine & check coverage
12+
if: ${{ github.event.workflow_run.conclusion == 'success' }}
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- uses: actions/checkout@v5
17+
- uses: actions/setup-python@v5
18+
with:
19+
# Use latest Python, so it understands all syntax.
20+
python-version: '3.13'
21+
22+
- uses: actions/download-artifact@v4
23+
with:
24+
pattern: coverage-data-*
25+
merge-multiple: true
26+
27+
- name: Combine coverage & fail if it's <100%
28+
run: |
29+
uv tool install 'coverage[toml]'
30+
31+
coverage combine
32+
coverage html --skip-covered --skip-empty
33+
34+
# Report and write to summary.
35+
coverage report --format=markdown >> "$GITHUB_STEP_SUMMARY"
36+
37+
# Report again and fail if under 100%.
38+
coverage report --fail-under=100
39+
40+
- name: Upload HTML report if check failed
41+
uses: actions/upload-artifact@v4
42+
with:
43+
name: html-report
44+
path: htmlcov
45+
if: ${{ failure() }}

.github/workflows/skip-tests.yml

Lines changed: 0 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -74,41 +74,3 @@ jobs:
7474
echo "One or more matrix jobs failed"
7575
exit 1
7676
fi
77-
78-
coverage-skip-tests:
79-
name: Combine & check coverage (skip-tests)
80-
if: always()
81-
needs: build
82-
runs-on: ubuntu-latest
83-
84-
steps:
85-
- uses: actions/checkout@v5
86-
- uses: actions/setup-python@v5
87-
with:
88-
# Use latest Python, so it understands all syntax.
89-
python-version: '3.13'
90-
91-
- uses: actions/download-artifact@v4
92-
with:
93-
pattern: coverage-data-skip-tests-*
94-
merge-multiple: true
95-
96-
- name: Combine coverage & fail if it's <100%
97-
run: |
98-
uv tool install 'coverage[toml]'
99-
100-
coverage combine
101-
coverage html --skip-covered --skip-empty
102-
103-
# Report and write to summary.
104-
coverage report --format=markdown >> "$GITHUB_STEP_SUMMARY"
105-
106-
# Report again and fail if under 100%.
107-
coverage report --fail-under=100
108-
109-
- name: Upload HTML report if check failed
110-
uses: actions/upload-artifact@v4
111-
with:
112-
name: html-report-skip-tests
113-
path: htmlcov
114-
if: ${{ failure() }}

.github/workflows/windows-ci.yml

Lines changed: 0 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -63,41 +63,3 @@ jobs:
6363
echo "One or more matrix jobs failed"
6464
exit 1
6565
fi
66-
67-
coverage-windows:
68-
name: Combine & check coverage (Windows)
69-
if: always()
70-
needs: build
71-
runs-on: ubuntu-latest
72-
73-
steps:
74-
- uses: actions/checkout@v5
75-
- uses: actions/setup-python@v5
76-
with:
77-
# Use latest Python, so it understands all syntax.
78-
python-version: '3.13'
79-
80-
- uses: actions/download-artifact@v4
81-
with:
82-
pattern: coverage-data-windows-*
83-
merge-multiple: true
84-
85-
- name: Combine coverage & fail if it's <100%
86-
run: |
87-
uv tool install 'coverage[toml]'
88-
89-
coverage combine
90-
coverage html --skip-covered --skip-empty
91-
92-
# Report and write to summary.
93-
coverage report --format=markdown >> "$GITHUB_STEP_SUMMARY"
94-
95-
# Report again and fail if under 100%.
96-
coverage report --fail-under=100
97-
98-
- name: Upload HTML report if check failed
99-
uses: actions/upload-artifact@v4
100-
with:
101-
name: html-report-windows
102-
path: htmlcov
103-
if: ${{ failure() }}

0 commit comments

Comments
 (0)