Merge system-optimization IR contracts and retire legacy engine adapter
This commit is contained in:
commit
743663e3a6
14 files changed
+3817
-161
No files matched your search
@@ -1,58 +1,31 @@
|
||||
name: Solver regression
|
||||
name: Native backend regression
|
||||
|
||||
on:
|
||||
push:
|
||||
paths:
|
||||
- "app/simulation/**"
|
||||
- "app/**"
|
||||
- "native/**"
|
||||
- "schemas/**"
|
||||
- "tests/**"
|
||||
- "requirements.txt"
|
||||
- "requirements*.txt"
|
||||
- "constraints/**"
|
||||
- ".python-version"
|
||||
- ".gitattributes"
|
||||
- "README.md"
|
||||
- ".github/workflows/solver-regression.yml"
|
||||
pull_request:
|
||||
paths:
|
||||
- "app/simulation/**"
|
||||
- "app/**"
|
||||
- "native/**"
|
||||
- "schemas/**"
|
||||
- "tests/**"
|
||||
- "requirements.txt"
|
||||
- "requirements*.txt"
|
||||
- "constraints/**"
|
||||
- ".python-version"
|
||||
- ".gitattributes"
|
||||
- "README.md"
|
||||
- ".github/workflows/solver-regression.yml"
|
||||
schedule:
|
||||
- cron: "17 3 * * 1-6"
|
||||
- cron: "17 3 * * 0"
|
||||
- cron: "17 3 * * *"
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
suite:
|
||||
description: Regression tier
|
||||
required: true
|
||||
default: quick
|
||||
type: choice
|
||||
options:
|
||||
- quick
|
||||
- historical
|
||||
- main-long
|
||||
case:
|
||||
description: Longest main-model horizon (predecessors run first)
|
||||
required: true
|
||||
default: 0.2s
|
||||
type: choice
|
||||
options:
|
||||
- 0.2s
|
||||
- 1s
|
||||
- 5s
|
||||
- 10s
|
||||
lane:
|
||||
description: Output sampling lane
|
||||
required: true
|
||||
default: production
|
||||
type: choice
|
||||
options:
|
||||
- solver-only
|
||||
- production
|
||||
|
||||
concurrency:
|
||||
group: solver-regression-${{ github.ref }}-${{ github.event_name }}
|
||||
@@ -62,142 +35,67 @@ permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
fixture-byte-contract:
|
||||
if: >-
|
||||
github.event_name == 'push' ||
|
||||
github.event_name == 'pull_request' ||
|
||||
(github.event_name == 'workflow_dispatch' && inputs.suite == 'quick')
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os:
|
||||
- ubuntu-24.04
|
||||
- windows-2022
|
||||
runs-on: ${{ matrix.os }}
|
||||
timeout-minutes: 5
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version-file: .python-version
|
||||
- name: Verify portable regression fixture bytes
|
||||
run: python -m unittest tests.test_regression_fixture_line_endings
|
||||
|
||||
quick:
|
||||
if: >-
|
||||
github.event_name == 'push' ||
|
||||
github.event_name == 'pull_request' ||
|
||||
(github.event_name == 'workflow_dispatch' && inputs.suite == 'quick')
|
||||
contracts:
|
||||
runs-on: ubuntu-24.04
|
||||
timeout-minutes: 15
|
||||
timeout-minutes: 10
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version-file: .python-version
|
||||
cache: pip
|
||||
cache-dependency-path: |
|
||||
requirements.txt
|
||||
constraints/python312-direct.txt
|
||||
constraints/python312-linux-x86_64.lock
|
||||
- name: Install hashed Linux release lock
|
||||
cache-dependency-path: constraints/python312-linux-x86_64.lock
|
||||
- name: Install backend runtime without numerical Python packages
|
||||
run: |
|
||||
python -m pip install \
|
||||
--force-reinstall \
|
||||
-r constraints/python312-linux-x86_64.lock
|
||||
python -m pip install -r constraints/python312-linux-x86_64.lock
|
||||
python -m pip check
|
||||
- name: Run solver foundation tests
|
||||
- name: Validate portable metadata and IR contracts
|
||||
env:
|
||||
SYSTEM_SIMULATION_VERIFY_LOCKED_ENV: "1"
|
||||
run: |
|
||||
python -W error::ResourceWarning -m unittest \
|
||||
tests.test_dependency_constraints \
|
||||
tests.test_benchmark_regression \
|
||||
tests.test_physical_state_v21 \
|
||||
tests.test_test_mql_ame_contract \
|
||||
tests.test_test_mql_8_regression \
|
||||
tests.test_mql_full_branches_regression \
|
||||
tests.test_pressure_flow_causal_execution \
|
||||
tests.test_stream_pressure_block_solver \
|
||||
tests.test_core_solver \
|
||||
tests.test_supported_piston_tangent \
|
||||
tests.test_three_piston_tangent \
|
||||
tests.test_sparse_secant_jacobian \
|
||||
tests.test_generic_jacobian_sparsity \
|
||||
tests.test_generic_system_xml_simulation
|
||||
tests.test_regression_fixture_line_endings \
|
||||
tests.test_component_catalog \
|
||||
tests.test_component_metadata \
|
||||
tests.test_component_registry \
|
||||
tests.test_medium_reference_contract \
|
||||
tests.test_system_xml_v3 \
|
||||
tests.test_system_numeric_ir_v2 \
|
||||
tests.test_native_only_backend
|
||||
|
||||
historical-nightly:
|
||||
if: >-
|
||||
(github.event_name == 'schedule' && github.event.schedule == '17 3 * * 1-6') ||
|
||||
(github.event_name == 'workflow_dispatch' && inputs.suite == 'historical')
|
||||
runs-on: ubuntu-24.04
|
||||
timeout-minutes: 15
|
||||
native-windows:
|
||||
runs-on: windows-2022
|
||||
timeout-minutes: 30
|
||||
defaults:
|
||||
run:
|
||||
shell: pwsh
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/setup-python@v5
|
||||
- uses: conda-incubator/setup-miniconda@v3
|
||||
with:
|
||||
python-version-file: .python-version
|
||||
cache: pip
|
||||
cache-dependency-path: |
|
||||
requirements.txt
|
||||
constraints/python312-direct.txt
|
||||
constraints/python312-linux-x86_64.lock
|
||||
- name: Install hashed Linux release lock
|
||||
python-version: "3.12"
|
||||
activate-environment: simulation-native
|
||||
auto-activate-base: false
|
||||
- name: Install native compiler and SUNDIALS
|
||||
run: |
|
||||
python -m pip install \
|
||||
--force-reinstall \
|
||||
-r constraints/python312-linux-x86_64.lock
|
||||
conda install --yes -c conda-forge sundials=7.4.0 m2w64-gcc
|
||||
if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }
|
||||
"SUNDIALS_ROOT=$env:CONDA_PREFIX\Library" >> $env:GITHUB_ENV
|
||||
"SIMULATION_NATIVE_CC=$env:CONDA_PREFIX\Library\mingw-w64\bin\gcc.exe" >> $env:GITHUB_ENV
|
||||
python -m pip install -r requirements-test.txt
|
||||
python -m pip check
|
||||
- name: Run 0.81 and 2.10 second historical regression
|
||||
- name: Run catalog, numerical, API and schema regression
|
||||
run: |
|
||||
mkdir -p artifacts
|
||||
python -m app.simulation.benchmark_regression \
|
||||
--manifest tests/baselines/simulation/test_mql_full_branches/manifest.json \
|
||||
--lane production \
|
||||
--output artifacts/test-mql-full-branches.json
|
||||
python -c "from app.simulation.native_codegen.build import toolchain; print(toolchain())"
|
||||
if ($LASTEXITCODE -ne 0) { exit $LASTEXITCODE }
|
||||
python -W error::ResourceWarning -m unittest discover -s tests
|
||||
- name: Complete the 10 second skill fixture in native RK45
|
||||
run: |
|
||||
python -m app.simulation.native_codegen tests/data/native-skill-test.xml --output-dir test/ci-skill --method RK45 --max-step 0.001 --rtol 1e-7 --runs 1 --solve-only
|
||||
- if: always()
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: historical-solver-regression
|
||||
path: artifacts/*.json
|
||||
if-no-files-found: warn
|
||||
|
||||
main-periodic:
|
||||
if: >-
|
||||
(github.event_name == 'schedule' && github.event.schedule == '17 3 * * 0') ||
|
||||
(github.event_name == 'workflow_dispatch' && inputs.suite == 'main-long')
|
||||
runs-on: ubuntu-24.04
|
||||
timeout-minutes: 180
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: actions/setup-python@v5
|
||||
with:
|
||||
python-version-file: .python-version
|
||||
cache: pip
|
||||
cache-dependency-path: |
|
||||
requirements.txt
|
||||
constraints/python312-direct.txt
|
||||
constraints/python312-linux-x86_64.lock
|
||||
- name: Install hashed Linux release lock
|
||||
run: |
|
||||
python -m pip install \
|
||||
--force-reinstall \
|
||||
-r constraints/python312-linux-x86_64.lock
|
||||
python -m pip check
|
||||
- name: Run bounded progressive main-model regression
|
||||
env:
|
||||
REQUESTED_CASE: ${{ github.event_name == 'workflow_dispatch' && inputs.case || '10s' }}
|
||||
REQUESTED_LANE: ${{ github.event_name == 'workflow_dispatch' && inputs.lane || 'production' }}
|
||||
run: |
|
||||
mkdir -p artifacts
|
||||
python -m app.simulation.benchmark_regression \
|
||||
--manifest tests/baselines/simulation/test_mql_8/manifest.json \
|
||||
--lane "$REQUESTED_LANE" \
|
||||
--case "$REQUESTED_CASE" \
|
||||
--output artifacts/test-mql-8-progressive.json
|
||||
- if: always()
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: main-model-progressive-regression
|
||||
path: artifacts/*.json
|
||||
name: native-skill-regression
|
||||
path: test/ci-skill/summary.json
|
||||
if-no-files-found: warn
|
||||
Reference in new issue
Block a user