CI: add artifact upload for pytest JUnit XML reports.
What changed, and why it matters
This commit only changes GitHub Actions CI configuration. It adds steps to upload pytest test result files (report.xml) as build artifacts after tests run, even when tests fail. There is no change to application code, no security fix, and no vulnerability introduced.
No security action needed. This is a routine CI improvement. Reviewers may optionally confirm artifact retention settings and that report.xml does not contain secrets, though JUnit XML reports typically contain only test metadata.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The diff modifies .github/workflows/ci.yaml to add actions/upload-artifact@v4 steps after pytest invocations across multiple jobs (prebuild, check-downgrade, integration, integration-valgrind, integration-sanitizers, update-docs-examples, min-btc-support). Artifacts are named uniquely per job/matrix and use if: always() so uploads occur regardless of test outcome. The uploaded path is report.xml (pytest JUnit XML output). This is purely a CI/debugging convenience change.
Changed components
.github/workflows/ci.yamlInspect captured patch +49 / −0
diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml
index 5f13f7ed..3bd67893 100644
--- a/.github/workflows/ci.yaml
+++ b/.github/workflows/ci.yaml
@@ -93,6 +93,13 @@ jobs:
PYTEST_OPTS: ${{ env.PYTEST_OPTS_BASE }}
run: |
uv run make check-source BASE_REF="origin/${{ github.base_ref }}"
+ - name: Upload test results
+ if: always()
+ uses: actions/upload-artifact@v4
+ with:
+ name: pytest-results-prebuild
+ path: report.xml
+ if-no-files-found: ignore
- name: Check Generated Files have been updated
run: uv run make check-gen-updated
- name: Check docs
@@ -315,6 +322,13 @@ jobs:
env
cat config.vars
uv run eatmydata pytest tests/test_downgrade.py -n ${PYTEST_PAR} ${PYTEST_OPTS}
+ - name: Upload test results
+ if: always()
+ uses: actions/upload-artifact@v4
+ with:
+ name: pytest-results-check-downgrade-${{ matrix.TEST_DB_PROVIDER }}-${{ matrix.TEST_NETWORK }}
+ path: report.xml
+ if-no-files-found: ignore
integration:
name: Test CLN ${{ matrix.name }}
@@ -423,6 +437,13 @@ jobs:
env
cat config.vars
VALGRIND=0 uv run eatmydata pytest tests/ -n ${PYTEST_PAR} ${PYTEST_OPTS}
+ - name: Upload test results
+ if: always()
+ uses: actions/upload-artifact@v4
+ with:
+ name: pytest-results-integration-${{ matrix.name }}
+ path: report.xml
+ if-no-files-found: ignore
integration-valgrind:
name: Valgrind Test CLN ${{ matrix.name }}
@@ -493,6 +514,13 @@ jobs:
TEST_DEBUG: 1
run: |
VALGRIND=1 uv run eatmydata pytest tests/ -n 3 ${PYTEST_OPTS} ${{ matrix.PYTEST_OPTS }}
+ - name: Upload test results
+ if: always()
+ uses: actions/upload-artifact@v4
+ with:
+ name: pytest-results-integration-valgrind-${{ matrix.NAME }}
+ path: report.xml
+ if-no-files-found: ignore
integration-sanitizers:
name: Sanitizers Test CLN
@@ -563,6 +591,13 @@ jobs:
- name: Test
run: |
uv run eatmydata pytest tests/ -n 2 ${PYTEST_OPTS} ${{ matrix.PYTEST_OPTS }}
+ - name: Upload test results
+ if: always()
+ uses: actions/upload-artifact@v4
+ with:
+ name: pytest-results-integration-sanitizers-${{ matrix.NAME }}
+ path: report.xml
+ if-no-files-found: ignore
update-docs-examples:
name: Update examples in doc schemas (disabled temporarily!)
@@ -606,6 +641,13 @@ jobs:
- name: Test
run: |
uv run eatmydata make -j $(nproc) check-doc-examples
+ - name: Upload test results
+ if: always()
+ uses: actions/upload-artifact@v4
+ with:
+ name: pytest-results-update-docs-examples
+ path: report.xml
+ if-no-files-found: ignore
min-btc-support:
name: Test minimum supported BTC v${{ matrix.MIN_BTC_VERSION }} with ${{ matrix.NAME }}
@@ -680,6 +722,13 @@ jobs:
env
cat config.vars
VALGRIND=0 uv run eatmydata pytest tests/ -n ${PYTEST_PAR} ${PYTEST_OPTS}
+ - name: Upload test results
+ if: always()
+ uses: actions/upload-artifact@v4
+ with:
+ name: pytest-results-min-btc-support-${{ matrix.NAME }}
+ path: report.xml
+ if-no-files-found: ignore
gather:
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.