Skip to content
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
11 changes: 6 additions & 5 deletions .github/workflows/python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -109,20 +109,21 @@ jobs:
cache-dependency-path: pyproject.toml
- name: Install the package and test dependencies
run: python -m pip install --upgrade pip ".[dev,fast,contact]"
- name: Run the whole suite with line and branch coverage, kernels traced
# Functions compiled by numba run outside the coverage tracer, so the kernel
# tests run a second time with NUMBA_DISABLE_JIT=1 and are appended.
run: python release/check_coverage.py --fail-under 95
- name: The committed validation report is current
# The script exits non-zero while registered benchmark rows fail; the step
# fails only if the committed report differs from the live calculation.
# fails only if the committed report differs from the live calculation. It runs
# before the coverage run (about 45 min), so a stale report fails within minutes.
shell: bash
run: |
set +e
python validation/scripts/run_validation.py --check 2>&1 | tee validation-check.txt
status=${PIPESTATUS[0]}
if grep -q "validation artefacts are stale" validation-check.txt; then exit 1; fi
echo "run_validation exit status ${status} (registered FAIL rows are expected)"
- name: Run the whole suite with line and branch coverage, kernels traced
# Functions compiled by numba run outside the coverage tracer, so the kernel
# tests run a second time with NUMBA_DISABLE_JIT=1 and are appended.
run: python release/check_coverage.py --fail-under 95
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
if: always()
with:
Expand Down
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,11 @@ All notable changes to CableXSec are recorded in this file. The format follows

### Changed

- The validation report's test-taxonomy lines record the passed count only: the deselected
count is the rest of the suite, so a test added anywhere else marked the committed report
stale without changing a gate. CI checks the committed report before the coverage run, so a
stale report fails within about 15 minutes instead of after the 45-minute coverage run.

- The distributed helix friction model (`friction_model="distributed"`, and `"auto"` on
non-planar paths) runs about three times faster on the 66 kV template. `compute_fatigue` on
one thread, warm, an hour of the 66 kV template at 10 Hz (36 001 samples, both armour
Expand Down
6 changes: 3 additions & 3 deletions validation/scripts/run_validation.py
Original file line number Diff line number Diff line change
Expand Up @@ -1848,10 +1848,10 @@ def _taxonomy_counts() -> dict[str, str]:
if not summaries:
raise RuntimeError(f"pytest taxonomy {marker!r} emitted no pass summary")
stable_summary = summaries[-1].split(" in ", maxsplit=1)[0]
# The passed count only: the deselected count is the rest of the suite, so a test
# added anywhere else would mark the report stale without changing a gate.
stable_parts = [
part.strip()
for part in stable_summary.split(",")
if "passed" in part or "deselected" in part
part.strip() for part in stable_summary.split(",") if "passed" in part
]
out[marker] = ", ".join(stable_parts)
return out
Expand Down
6 changes: 3 additions & 3 deletions validation/validation_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,9 +67,9 @@ Every row is computed from published data or closed-form references in this repo

## Test taxonomy (full gate suite)

- analytical_sanity: `1153 passed, 3250 deselected`
- independent_method: `76 passed, 4327 deselected`
- full_scale: `31 passed, 4372 deselected`
- analytical_sanity: `1153 passed`
- independent_method: `76 passed`
- full_scale: `31 passed`

Run `pytest -m <marker>` to reproduce each group.

Expand Down
Loading