gridoxide 0.0.2__tar.gz → 0.2.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- gridoxide-0.2.0/.cargo/config.toml +25 -0
- gridoxide-0.2.0/.github/workflows/build.yml +117 -0
- gridoxide-0.2.0/.github/workflows/publish.yml +111 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/.github/workflows/pypi.yml +40 -1
- {gridoxide-0.0.2 → gridoxide-0.2.0}/.github/workflows/python.yml +4 -0
- gridoxide-0.2.0/.github/workflows/release.yml +104 -0
- gridoxide-0.2.0/.github/workflows/vscode.yml +127 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/Cargo.lock +368 -15
- gridoxide-0.2.0/Cargo.toml +408 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/PKG-INFO +83 -7
- gridoxide-0.2.0/README.md +131 -0
- gridoxide-0.2.0/build.rs +423 -0
- gridoxide-0.2.0/capi/CMakeLists.txt +163 -0
- gridoxide-0.2.0/capi/examples/powerflow.c +87 -0
- gridoxide-0.2.0/capi/examples/powerflow.cpp +66 -0
- gridoxide-0.2.0/capi/gridoxideConfig.cmake.in +51 -0
- gridoxide-0.2.0/cbindgen.toml +73 -0
- gridoxide-0.2.0/crates/gridoxide-core/Cargo.toml +32 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/ac_sensitivity.rs +644 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/batch.rs +670 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-core}/src/bde.rs +15 -10
- gridoxide-0.2.0/crates/gridoxide-core/src/branch_flow.rs +404 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/constrained.rs +469 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/continuation/augmented.rs +321 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/continuation/corrector.rs +315 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/continuation/direction.rs +202 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/continuation/events.rs +84 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/continuation/mod.rs +1229 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-core}/src/dc.rs +164 -62
- gridoxide-0.2.0/crates/gridoxide-core/src/dispatch.rs +449 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/injection_hessian.rs +246 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/jacobian.rs +898 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/lib.rs +684 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/linear/batch.rs +315 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/linear/btheta.rs +1136 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/linear/impedance.rs +291 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/linear/mod.rs +92 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/linear/sensitivity.rs +830 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/measurement.rs +144 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/network.rs +1547 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/outerloop/area.rs +401 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/outerloop/mod.rs +456 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/outerloop/qlimits.rs +91 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/outerloop/remote.rs +360 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/outerloop/slack.rs +244 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/outerloop/taps.rs +677 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/qv.rs +393 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/ratings.rs +204 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/roots.rs +48 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/scenario.rs +169 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/se/bad_data.rs +522 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/se/batch.rs +437 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/se/case.rs +88 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/se/constraints.rs +195 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/se/functional.rs +627 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/se/iterative.rs +626 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/se/jacobian.rs +676 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/se/mod.rs +755 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/se/nr.rs +822 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/se/observability.rs +712 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/shortcircuit/fortescue.rs +139 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/shortcircuit/mod.rs +289 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/shortcircuit/network.rs +63 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/shortcircuit/solver.rs +787 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-core}/src/solver.rs +235 -456
- gridoxide-0.2.0/crates/gridoxide-core/src/switches.rs +774 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/topology/bus_view.rs +437 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/topology/mod.rs +46 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/topology/model.rs +202 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/topology/reduction.rs +311 -0
- gridoxide-0.2.0/crates/gridoxide-core/src/types.rs +338 -0
- gridoxide-0.2.0/crates/gridoxide-sparse/Cargo.toml +47 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/build.rs +63 -15
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/block_sparse.rs +149 -37
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/PROVENANCE.md +1 -1
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/amd/aat.rs +4 -1
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/amd/core.rs +10 -3
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/amd/mod.rs +19 -4
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/amd/postorder.rs +11 -2
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/analyze.rs +12 -3
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/btf/maxtrans.rs +11 -1
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/btf/mod.rs +52 -15
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/btf/strongcomp.rs +19 -4
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/factor.rs +40 -8
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/ffi_oracle.rs +26 -7
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/kernel.rs +190 -57
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/mod.rs +268 -41
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/refactor.rs +151 -74
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/scale.rs +35 -7
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/solve.rs +81 -28
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/klu_native/types.rs +11 -2
- gridoxide-0.2.0/crates/gridoxide-sparse/src/lib.rs +23 -0
- gridoxide-0.2.0/crates/gridoxide-sparse/src/lu.rs +226 -0
- gridoxide-0.2.0/crates/gridoxide-sparse/src/sparse.rs +696 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/sparse_klu.rs +205 -31
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/src/sparse_pardiso.rs +73 -18
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/PROVENANCE.md +3 -3
- {gridoxide-0.0.2 → gridoxide-0.2.0}/docs/book.toml +1 -0
- gridoxide-0.2.0/docs/examples/README.md +42 -0
- gridoxide-0.2.0/docs/examples/one-node-2ph.json +18 -0
- gridoxide-0.2.0/docs/examples/one-node-slg.json +18 -0
- gridoxide-0.2.0/docs/examples/pst-worked-example.crac.json +34 -0
- gridoxide-0.2.0/docs/examples/two-bus-lmp.json +23 -0
- gridoxide-0.2.0/docs/examples/two-bus-lmp.opf.json +21 -0
- gridoxide-0.2.0/docs/src/SUMMARY.md +95 -0
- gridoxide-0.2.0/docs/src/cgmes/external_network_injection.md +93 -0
- gridoxide-0.2.0/docs/src/cgmes/index.md +224 -0
- gridoxide-0.2.0/docs/src/cgmes/node_breaker.md +236 -0
- gridoxide-0.2.0/docs/src/cgmes/phase_tap_changer_linear.md +118 -0
- gridoxide-0.2.0/docs/src/cgmes/ratio_tap_changer_table.md +102 -0
- gridoxide-0.2.0/docs/src/cgmes/shunt_conductance.md +113 -0
- gridoxide-0.2.0/docs/src/cgmes/static_var_compensator.md +176 -0
- gridoxide-0.2.0/docs/src/dynamics/dae.md +106 -0
- gridoxide-0.2.0/docs/src/dynamics/events.md +123 -0
- gridoxide-0.2.0/docs/src/dynamics/index.md +107 -0
- gridoxide-0.2.0/docs/src/dynamics/initialization.md +84 -0
- gridoxide-0.2.0/docs/src/dynamics/input.md +151 -0
- gridoxide-0.2.0/docs/src/dynamics/models.md +176 -0
- gridoxide-0.2.0/docs/src/dynamics/smallsignal.md +250 -0
- gridoxide-0.2.0/docs/src/dynamics/validation.md +117 -0
- gridoxide-0.2.0/docs/src/getting_started/building.md +92 -0
- gridoxide-0.2.0/docs/src/getting_started/c_api.md +235 -0
- gridoxide-0.2.0/docs/src/getting_started/mcp.md +79 -0
- gridoxide-0.2.0/docs/src/getting_started/python.md +438 -0
- gridoxide-0.2.0/docs/src/import/iidm.md +148 -0
- gridoxide-0.2.0/docs/src/import/matpower.md +80 -0
- gridoxide-0.2.0/docs/src/import/ucte.md +137 -0
- gridoxide-0.2.0/docs/src/introduction.md +55 -0
- gridoxide-0.2.0/docs/src/opf/index.md +606 -0
- gridoxide-0.2.0/docs/src/opf/worked_example.md +196 -0
- gridoxide-0.2.0/docs/src/powerflow/area_interchange.md +176 -0
- gridoxide-0.2.0/docs/src/powerflow/continuation.md +282 -0
- gridoxide-0.2.0/docs/src/powerflow/dc.md +297 -0
- gridoxide-0.2.0/docs/src/powerflow/distributed_slack.md +159 -0
- gridoxide-0.0.2/docs/src/powerflow.md → gridoxide-0.2.0/docs/src/powerflow/index.md +1 -1
- gridoxide-0.2.0/docs/src/powerflow/linear_impedance.md +100 -0
- gridoxide-0.2.0/docs/src/powerflow/multi_island.md +244 -0
- gridoxide-0.2.0/docs/src/powerflow/outer_loops.md +163 -0
- gridoxide-0.2.0/docs/src/powerflow/q_limits.md +185 -0
- gridoxide-0.2.0/docs/src/powerflow/qv.md +161 -0
- gridoxide-0.2.0/docs/src/powerflow/tap_control.md +147 -0
- gridoxide-0.2.0/docs/src/powerflow/zero_impedance_branches.md +181 -0
- gridoxide-0.2.0/docs/src/rao/index.md +296 -0
- gridoxide-0.2.0/docs/src/rao/linear.md +379 -0
- gridoxide-0.2.0/docs/src/rao/margins.md +275 -0
- gridoxide-0.2.0/docs/src/rao/search.md +458 -0
- gridoxide-0.2.0/docs/src/reference/benchmarking.md +87 -0
- gridoxide-0.2.0/docs/src/reference/feature_comparison.md +600 -0
- gridoxide-0.2.0/docs/src/reference/provenance.md +148 -0
- gridoxide-0.2.0/docs/src/reference/resources.md +248 -0
- gridoxide-0.2.0/docs/src/sensitivity/ac.md +292 -0
- gridoxide-0.2.0/docs/src/short_circuit/faults.md +79 -0
- gridoxide-0.2.0/docs/src/short_circuit/index.md +179 -0
- gridoxide-0.2.0/docs/src/short_circuit/sequence.md +200 -0
- gridoxide-0.2.0/docs/src/short_circuit/worked_example.md +226 -0
- gridoxide-0.2.0/docs/src/solvers/backends.md +146 -0
- gridoxide-0.2.0/docs/src/solvers/klu.md +488 -0
- gridoxide-0.2.0/docs/src/state_estimation/diagnostics.md +135 -0
- gridoxide-0.2.0/docs/src/state_estimation/index.md +177 -0
- gridoxide-0.2.0/docs/src/state_estimation/iterative.md +360 -0
- gridoxide-0.2.0/docs/src/state_estimation/measurements.md +121 -0
- gridoxide-0.2.0/docs/src/state_estimation/worked_example.md +285 -0
- gridoxide-0.2.0/docs/theme/custom.css +26 -0
- gridoxide-0.2.0/examples/base_mismatch_probe.rs +92 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/examples/bde_check.rs +24 -8
- gridoxide-0.2.0/examples/bench_contingency.rs +118 -0
- gridoxide-0.2.0/examples/bench_dc.rs +168 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/examples/bench_network.rs +59 -18
- gridoxide-0.2.0/examples/bench_node_breaker.rs +68 -0
- gridoxide-0.2.0/examples/bench_se.rs +315 -0
- gridoxide-0.2.0/examples/cgmes_area_probe.rs +75 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/examples/cgmes_microgrid_be_dump.rs +2 -1
- gridoxide-0.2.0/examples/cpf_probe.rs +133 -0
- gridoxide-0.2.0/examples/dispatch_probe.rs +267 -0
- gridoxide-0.2.0/examples/doc_numbers.rs +81 -0
- gridoxide-0.2.0/examples/dynamics_scale.rs +195 -0
- gridoxide-0.2.0/examples/iidm_area_probe.rs +46 -0
- gridoxide-0.2.0/examples/iidm_regulation_probe.rs +54 -0
- gridoxide-0.2.0/examples/klu_scaling_stress.rs +257 -0
- gridoxide-0.2.0/examples/pf_profile.rs +192 -0
- gridoxide-0.2.0/examples/qv_probe.rs +126 -0
- gridoxide-0.2.0/examples/remote_probe.rs +191 -0
- gridoxide-0.2.0/examples/se_converge.rs +142 -0
- gridoxide-0.2.0/examples/se_profile.rs +133 -0
- gridoxide-0.2.0/examples/smallsignal_scale.rs +111 -0
- gridoxide-0.2.0/examples/switch_ceiling.rs +41 -0
- gridoxide-0.2.0/examples/tap_control_probe.rs +68 -0
- gridoxide-0.2.0/examples/tap_deadband_probe.rs +123 -0
- gridoxide-0.2.0/examples/tap_regulation_probe.rs +69 -0
- gridoxide-0.2.0/examples/ucte_area_probe.rs +47 -0
- gridoxide-0.2.0/examples/voltage_control_probe.rs +74 -0
- gridoxide-0.2.0/include/gridoxide.h +616 -0
- gridoxide-0.2.0/include/gridoxide.hpp +277 -0
- gridoxide-0.2.0/plans/DYNAMICS_LIBRARY_TODO.md +39 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/pyproject.toml +1 -1
- {gridoxide-0.0.2 → gridoxide-0.2.0}/python/README.md +82 -6
- gridoxide-0.2.0/python/gridoxide/__init__.py +76 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/python/gridoxide/matpower.py +173 -13
- gridoxide-0.2.0/python/tests/_pglib.py +30 -0
- gridoxide-0.2.0/python/tests/test_ac_opf.py +179 -0
- gridoxide-0.2.0/python/tests/test_ac_sensitivity.py +131 -0
- gridoxide-0.2.0/python/tests/test_continuation.py +98 -0
- gridoxide-0.2.0/python/tests/test_dc.py +300 -0
- gridoxide-0.2.0/python/tests/test_dc_opf.py +162 -0
- gridoxide-0.2.0/python/tests/test_dispatch.py +115 -0
- gridoxide-0.2.0/python/tests/test_dynamics.py +337 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/python/tests/test_gridoxide.py +56 -3
- gridoxide-0.2.0/python/tests/test_matpower.py +258 -0
- gridoxide-0.2.0/python/tests/test_matpower_opf.py +174 -0
- gridoxide-0.2.0/python/tests/test_node_breaker.py +159 -0
- gridoxide-0.2.0/python/tests/test_qv.py +84 -0
- gridoxide-0.2.0/python/tests/test_short_circuit.py +143 -0
- gridoxide-0.2.0/python/tests/test_state_estimation.py +336 -0
- gridoxide-0.2.0/python/tests/test_tap_control.py +124 -0
- gridoxide-0.2.0/scripts/bench/README.md +999 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/accuracy_case_suite.py +1 -1
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/bench_batch.py +2 -2
- gridoxide-0.2.0/scripts/bench/bench_se_pgm.py +176 -0
- gridoxide-0.2.0/scripts/bench/check_dc_matpower.py +224 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/convert_pandapower_case.py +2 -2
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/cross_validate_cgmes_microgrid_be.py +2 -2
- gridoxide-0.2.0/scripts/bench/iidm_reference.py +113 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/jax_oracle.py +9 -10
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/run_case_suite.py +3 -3
- gridoxide-0.2.0/scripts/bench/se_iterations.py +184 -0
- gridoxide-0.2.0/scripts/bench/ucte_reference.py +159 -0
- gridoxide-0.2.0/src/capi/mod.rs +248 -0
- gridoxide-0.2.0/src/capi/powerflow.rs +1009 -0
- gridoxide-0.2.0/src/capi/types.rs +256 -0
- gridoxide-0.2.0/src/cgmes.rs +5102 -0
- gridoxide-0.2.0/src/dynamics/arnoldi.rs +448 -0
- gridoxide-0.2.0/src/dynamics/arpack.rs +312 -0
- gridoxide-0.2.0/src/dynamics/dae.rs +437 -0
- gridoxide-0.2.0/src/dynamics/dyd.rs +700 -0
- gridoxide-0.2.0/src/dynamics/dyr.rs +565 -0
- gridoxide-0.2.0/src/dynamics/events.rs +346 -0
- gridoxide-0.2.0/src/dynamics/init.rs +367 -0
- gridoxide-0.2.0/src/dynamics/integrator.rs +727 -0
- gridoxide-0.2.0/src/dynamics/json.rs +614 -0
- gridoxide-0.2.0/src/dynamics/mod.rs +480 -0
- gridoxide-0.2.0/src/dynamics/models/avr.rs +309 -0
- gridoxide-0.2.0/src/dynamics/models/gov.rs +323 -0
- gridoxide-0.2.0/src/dynamics/models/load.rs +180 -0
- gridoxide-0.2.0/src/dynamics/models/machine.rs +1792 -0
- gridoxide-0.2.0/src/dynamics/models/mod.rs +533 -0
- gridoxide-0.2.0/src/dynamics/models/pss.rs +197 -0
- gridoxide-0.2.0/src/dynamics/models/unit.rs +472 -0
- gridoxide-0.2.0/src/dynamics/shift.rs +203 -0
- gridoxide-0.2.0/src/dynamics/smallsignal.rs +1149 -0
- gridoxide-0.2.0/src/iidm/dynamics.rs +59 -0
- gridoxide-0.2.0/src/iidm/mod.rs +1611 -0
- gridoxide-0.2.0/src/lib.rs +48 -0
- gridoxide-0.2.0/src/load.rs +462 -0
- gridoxide-0.2.0/src/main.rs +3473 -0
- gridoxide-0.2.0/src/matpower.rs +1198 -0
- gridoxide-0.2.0/src/opf/ac.rs +837 -0
- gridoxide-0.2.0/src/opf/bnb.rs +284 -0
- gridoxide-0.2.0/src/opf/dc.rs +705 -0
- gridoxide-0.2.0/src/opf/highs.rs +406 -0
- gridoxide-0.2.0/src/opf/ipm.rs +735 -0
- gridoxide-0.2.0/src/opf/ipopt.rs +557 -0
- gridoxide-0.2.0/src/opf/mod.rs +487 -0
- gridoxide-0.2.0/src/opf/model.rs +448 -0
- gridoxide-0.2.0/src/opf/nlp.rs +757 -0
- gridoxide-0.2.0/src/pgm/measurement.rs +1983 -0
- gridoxide-0.2.0/src/pgm/mod.rs +2236 -0
- gridoxide-0.2.0/src/pgm/opf.rs +273 -0
- gridoxide-0.2.0/src/pgm/se.rs +163 -0
- gridoxide-0.2.0/src/pgm/shortcircuit.rs +196 -0
- gridoxide-0.2.0/src/python.rs +4200 -0
- gridoxide-0.2.0/src/rao/automaton.rs +1001 -0
- gridoxide-0.2.0/src/rao/castor.rs +1449 -0
- gridoxide-0.2.0/src/rao/costly.rs +207 -0
- gridoxide-0.2.0/src/rao/crac.rs +627 -0
- gridoxide-0.2.0/src/rao/crac_json.rs +839 -0
- gridoxide-0.2.0/src/rao/evaluate.rs +1489 -0
- gridoxide-0.2.0/src/rao/limits.rs +409 -0
- gridoxide-0.2.0/src/rao/linear.rs +3032 -0
- gridoxide-0.2.0/src/rao/mnec.rs +370 -0
- gridoxide-0.2.0/src/rao/mod.rs +53 -0
- gridoxide-0.2.0/src/rao/parameters.rs +302 -0
- gridoxide-0.2.0/src/rao/search.rs +1304 -0
- gridoxide-0.2.0/src/rao/usage.rs +403 -0
- gridoxide-0.2.0/src/rao/validate.rs +221 -0
- gridoxide-0.2.0/src/ucte.rs +1246 -0
- gridoxide-0.2.0/tests/ac_contingency_test.rs +584 -0
- gridoxide-0.2.0/tests/ac_sensitivity_test.rs +668 -0
- gridoxide-0.2.0/tests/all.rs +315 -0
- gridoxide-0.2.0/tests/area_interchange_test.rs +482 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/batch_solver_test.rs +153 -20
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/bde_test.rs +32 -14
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/block_jacobian_test.rs +35 -12
- gridoxide-0.2.0/tests/branch_flow_test.rs +136 -0
- gridoxide-0.2.0/tests/capi_test.rs +614 -0
- gridoxide-0.2.0/tests/cgmes_area_test.rs +259 -0
- gridoxide-0.2.0/tests/cgmes_common/mod.rs +213 -0
- gridoxide-0.2.0/tests/cgmes_dispatch_test.rs +332 -0
- gridoxide-0.2.0/tests/cgmes_fullgrid_test.rs +184 -0
- gridoxide-0.2.0/tests/cgmes_identity_test.rs +668 -0
- gridoxide-0.2.0/tests/cgmes_limits_test.rs +214 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/cgmes_microgrid_be_test.rs +10 -3
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/cgmes_microgrid_hvdc_test.rs +44 -10
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/cgmes_microgrid_nl_test.rs +13 -5
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/cgmes_microgrid_type1_test.rs +29 -5
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/cgmes_microgrid_type2_test.rs +36 -10
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/cgmes_microgrid_type3_test.rs +27 -7
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/cgmes_minigrid_test.rs +11 -3
- gridoxide-0.2.0/tests/cgmes_node_breaker_se_test.rs +384 -0
- gridoxide-0.2.0/tests/cgmes_node_breaker_solve_test.rs +712 -0
- gridoxide-0.2.0/tests/cgmes_node_breaker_test.rs +492 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/cgmes_powerflow_test.rs +8 -2
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/cgmes_pst_phase_tap_changer_linear_test.rs +3 -1
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/cgmes_pst_phase_tap_changer_table_test.rs +8 -2
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/cgmes_realgrid_test.rs +75 -14
- gridoxide-0.2.0/tests/cgmes_remote_test.rs +313 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/cgmes_smallgrid_test.rs +33 -8
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/cgmes_smoke_test.rs +12 -16
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/cgmes_svedala_test.rs +33 -8
- gridoxide-0.2.0/tests/cgmes_tap_regulation_test.rs +261 -0
- gridoxide-0.2.0/tests/cgmes_tap_table_test.rs +218 -0
- gridoxide-0.2.0/tests/cgmes_voltage_base_test.rs +220 -0
- gridoxide-0.2.0/tests/cgmes_voltage_control_test.rs +162 -0
- gridoxide-0.2.0/tests/cli_continuation_test.rs +110 -0
- gridoxide-0.2.0/tests/cli_dynamics_test.rs +308 -0
- gridoxide-0.2.0/tests/cli_estimate_test.rs +166 -0
- gridoxide-0.2.0/tests/cli_opf_test.rs +127 -0
- gridoxide-0.2.0/tests/cli_qv_test.rs +116 -0
- gridoxide-0.2.0/tests/cli_rao_test.rs +106 -0
- gridoxide-0.2.0/tests/cli_security_test.rs +417 -0
- gridoxide-0.2.0/tests/cli_sensitivity_test.rs +146 -0
- gridoxide-0.2.0/tests/cli_short_circuit_test.rs +168 -0
- gridoxide-0.2.0/tests/cli_solve_test.rs +356 -0
- gridoxide-0.2.0/tests/cli_switches_test.rs +180 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/common/mod.rs +14 -4
- gridoxide-0.2.0/tests/constrained_switch_test.rs +475 -0
- gridoxide-0.2.0/tests/continuation_events_test.rs +432 -0
- gridoxide-0.2.0/tests/continuation_test.rs +811 -0
- gridoxide-0.2.0/tests/dc_batch_test.rs +630 -0
- gridoxide-0.2.0/tests/dc_powerflow_test.rs +614 -0
- gridoxide-0.2.0/tests/dc_sensitivity_test.rs +288 -0
- gridoxide-0.2.0/tests/distributed_slack_test.rs +499 -0
- gridoxide-0.2.0/tests/dynamics_dyd_test.rs +439 -0
- gridoxide-0.2.0/tests/dynamics_dyr_test.rs +355 -0
- gridoxide-0.2.0/tests/dynamics_events_test.rs +577 -0
- gridoxide-0.2.0/tests/dynamics_json_test.rs +245 -0
- gridoxide-0.2.0/tests/dynamics_models_test.rs +1855 -0
- gridoxide-0.2.0/tests/dynamics_reference_test.rs +738 -0
- gridoxide-0.2.0/tests/dynamics_relay_test.rs +368 -0
- gridoxide-0.2.0/tests/dynamics_ring/mod.rs +161 -0
- gridoxide-0.2.0/tests/dynamics_smallsignal_arpack_test.rs +166 -0
- gridoxide-0.2.0/tests/dynamics_smallsignal_test.rs +1463 -0
- gridoxide-0.2.0/tests/dynamics_test.rs +495 -0
- gridoxide-0.2.0/tests/iidm_test.rs +1173 -0
- gridoxide-0.2.0/tests/injection_hessian_test.rs +533 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/klu_jacobian_test.rs +18 -6
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/klu_native_jacobian_test.rs +18 -6
- gridoxide-0.2.0/tests/link_test.rs +140 -0
- gridoxide-0.2.0/tests/matpower_opf_test.rs +151 -0
- gridoxide-0.2.0/tests/matpower_se_test.rs +192 -0
- gridoxide-0.2.0/tests/matpower_test.rs +191 -0
- gridoxide-0.2.0/tests/measurement_residual_test.rs +324 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/multi_island_test.rs +136 -24
- gridoxide-0.2.0/tests/openrao/mod.rs +58 -0
- gridoxide-0.2.0/tests/opf_ac_test.rs +467 -0
- gridoxide-0.2.0/tests/opf_cross_test.rs +377 -0
- gridoxide-0.2.0/tests/opf_data_test.rs +262 -0
- gridoxide-0.2.0/tests/opf_dc_test.rs +447 -0
- gridoxide-0.2.0/tests/opf_highs_test.rs +365 -0
- gridoxide-0.2.0/tests/opf_ipm_test.rs +462 -0
- gridoxide-0.2.0/tests/opf_ipopt_test.rs +280 -0
- gridoxide-0.2.0/tests/opf_milp_test.rs +492 -0
- gridoxide-0.2.0/tests/opf_nlp_test.rs +419 -0
- gridoxide-0.2.0/tests/opf_pwl_test.rs +371 -0
- gridoxide-0.2.0/tests/outer_loop_test.rs +458 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/pardiso_jacobian_test.rs +18 -6
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/persistent_solver_test.rs +84 -8
- gridoxide-0.2.0/tests/pglib/mod.rs +46 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/pgm_asym_line_test.rs +4 -4
- gridoxide-0.2.0/tests/pgm_asym_three_winding_test.rs +142 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/pgm_asym_transformer_test.rs +10 -4
- gridoxide-0.2.0/tests/pgm_component_coverage_test.rs +143 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/pgm_gen_test.rs +5 -3
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/pgm_line_test.rs +4 -3
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/pgm_load_test.rs +5 -3
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/pgm_network_test.rs +23 -8
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/pgm_node_test.rs +5 -3
- gridoxide-0.2.0/tests/pgm_short_circuit_test.rs +479 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/pgm_shunt_test.rs +7 -3
- gridoxide-0.2.0/tests/pgm_source_test.rs +90 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/pgm_three_winding_transformer_test.rs +8 -3
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/pgm_transformer_test.rs +11 -4
- gridoxide-0.2.0/tests/power_flow_methods_test.rs +502 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/tests/powerflow_test.rs +5 -8
- gridoxide-0.2.0/tests/q_limits_test.rs +267 -0
- gridoxide-0.2.0/tests/qv_test.rs +402 -0
- gridoxide-0.2.0/tests/rao_castor_test.rs +1847 -0
- gridoxide-0.2.0/tests/rao_crac_test.rs +482 -0
- gridoxide-0.2.0/tests/rao_cucumber_test.rs +2374 -0
- gridoxide-0.2.0/tests/rao_evaluate_test.rs +1029 -0
- gridoxide-0.2.0/tests/rao_linear_test.rs +884 -0
- gridoxide-0.2.0/tests/rao_search_test.rs +819 -0
- gridoxide-0.2.0/tests/rao_validate_test.rs +211 -0
- gridoxide-0.2.0/tests/remote_voltage_test.rs +348 -0
- gridoxide-0.2.0/tests/se_batch_test.rs +454 -0
- gridoxide-0.2.0/tests/se_three_phase_test.rs +1266 -0
- gridoxide-0.2.0/tests/state_estimation_test.rs +894 -0
- gridoxide-0.2.0/tests/tap_control_test.rs +604 -0
- gridoxide-0.2.0/tests/ucte_test.rs +771 -0
- gridoxide-0.0.2/.github/workflows/build.yml +0 -36
- gridoxide-0.0.2/CIMOXIDE_PROVENANCE.md +0 -48
- gridoxide-0.0.2/Cargo.toml +0 -177
- gridoxide-0.0.2/FEATURE_COMPARISON.md +0 -176
- gridoxide-0.0.2/README.md +0 -322
- gridoxide-0.0.2/docs/src/SUMMARY.md +0 -4
- gridoxide-0.0.2/docs/src/q_limits.md +0 -110
- gridoxide-0.0.2/python/gridoxide/__init__.py +0 -15
- gridoxide-0.0.2/python/tests/test_matpower.py +0 -81
- gridoxide-0.0.2/scripts/bench/README.md +0 -991
- gridoxide-0.0.2/src/batch.rs +0 -290
- gridoxide-0.0.2/src/cgmes.rs +0 -1913
- gridoxide-0.0.2/src/jacobian.rs +0 -413
- gridoxide-0.0.2/src/lib.rs +0 -71
- gridoxide-0.0.2/src/main.rs +0 -43
- gridoxide-0.0.2/src/network.rs +0 -817
- gridoxide-0.0.2/src/pgm.rs +0 -772
- gridoxide-0.0.2/src/python.rs +0 -486
- gridoxide-0.0.2/src/sparse.rs +0 -204
- gridoxide-0.0.2/src/types.rs +0 -99
- gridoxide-0.0.2/tests/cgmes_common/mod.rs +0 -109
- gridoxide-0.0.2/tests/data/cgmes/README.md +0 -22
- gridoxide-0.0.2/tests/data/network.json +0 -57
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/asym_gen/README.md +0 -23
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/asym_gen/asym_output.json +0 -109
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/asym_gen/input.json +0 -81
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/asym_load/README.md +0 -23
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/asym_load/asym_output.json +0 -109
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/asym_load/input.json +0 -81
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/distribution-case/README.md +0 -27
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/distribution-case/asym_output_batch.json +0 -772
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/distribution-case/input.json +0 -473
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/distribution-case/update_batch.json +0 -328
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/line/README.md +0 -21
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/line/asym_output.json +0 -196
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/line/input.json +0 -133
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/node/README.md +0 -22
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/node/asym_output.json +0 -99
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/node/input.json +0 -51
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/shunt/README.md +0 -23
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/shunt/asym_output.json +0 -81
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/shunt/input.json +0 -67
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/source/README.md +0 -20
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/source/asym_output.json +0 -132
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/source/input.json +0 -76
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/sym_gen/README.md +0 -25
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/sym_gen/asym_output.json +0 -109
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/sym_gen/input.json +0 -65
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/sym_load/README.md +0 -25
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/sym_load/asym_output.json +0 -109
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/sym_load/input.json +0 -65
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/transformer/README.md +0 -28
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/transformer/asym_output_batch.json +0 -888
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/transformer/input.json +0 -64
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/transformer/update_batch.json +0 -96
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/transmission-case/README.md +0 -25
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/transmission-case/asym_output.json +0 -557
- gridoxide-0.0.2/tests/data/pgm/powerflow/asymmetric/transmission-case/input.json +0 -353
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/basic-node/README.md +0 -18
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/basic-node/input.json +0 -29
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/basic-node/sym_output.json +0 -31
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/distribution-case/README.md +0 -29
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/distribution-case/input.json +0 -473
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/distribution-case/sym_output_batch.json +0 -362
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/distribution-case/update_batch.json +0 -328
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/line/README.md +0 -21
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/line/input.json +0 -125
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/line/sym_output.json +0 -106
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/node/README.md +0 -18
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/node/input.json +0 -51
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/node/sym_output.json +0 -51
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/shunt/README.md +0 -19
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/shunt/input.json +0 -67
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/shunt/sym_output.json +0 -57
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/source/README.md +0 -18
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/source/input.json +0 -76
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/source/sym_output.json +0 -70
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/sym_gen/README.md +0 -22
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/sym_gen/input.json +0 -81
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/sym_gen/sym_output.json +0 -67
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/sym_load/README.md +0 -22
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/sym_load/input.json +0 -81
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/sym_load/sym_output.json +0 -67
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/three_winding_transformer/README.md +0 -24
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/three_winding_transformer/input.json +0 -69
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/three_winding_transformer/sym_output_batch.json +0 -378
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/three_winding_transformer/update_batch.json +0 -118
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/transformer/input.json +0 -133
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/transformer/sym_output_batch.json +0 -723
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/transformer/update_batch.json +0 -228
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/transmission-case/README.md +0 -25
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/transmission-case/input.json +0 -353
- gridoxide-0.0.2/tests/data/pgm/powerflow/symmetric/transmission-case/sym_output.json +0 -241
- gridoxide-0.0.2/tests/pgm_source_test.rs +0 -45
- gridoxide-0.0.2/tests/q_limits_test.rs +0 -116
- {gridoxide-0.0.2 → gridoxide-0.2.0}/.github/workflows/book.yml +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/.gitignore +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/.gitmodules +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/LICENSE +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-core}/src/json.rs +1 -1
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Doc/License.txt +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Include/amd.h +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Include/amd_internal.h +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/README.txt +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd.f +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_1.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_2.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_aat.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_control.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_defaults.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_dump.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_info.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_l1.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_l2.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_l_aat.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_l_control.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_l_defaults.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_l_dump.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_l_info.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_l_order.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_l_post_tree.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_l_postorder.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_l_preprocess.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_l_valid.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_order.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_post_tree.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_postorder.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_preprocess.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_valid.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amd_version.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/AMD/Source/amdbar.f +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/BTF/Doc/License.txt +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/BTF/Include/btf.h +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/BTF/Include/btf_internal.h +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/BTF/README.txt +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/BTF/Source/btf_l_maxtrans.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/BTF/Source/btf_l_order.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/BTF/Source/btf_l_strongcomp.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/BTF/Source/btf_maxtrans.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/BTF/Source/btf_order.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/BTF/Source/btf_strongcomp.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/BTF/Source/btf_version.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/COLAMD/Doc/License.txt +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/COLAMD/Include/colamd.h +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/COLAMD/README.txt +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/COLAMD/Source/colamd.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/COLAMD/Source/colamd_l.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/COLAMD/Source/colamd_version.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Doc/License.txt +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Include/klu.h +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Include/klu_internal.h +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Include/klu_version.h +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/README.txt +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_analyze.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_analyze_given.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_defaults.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_diagnostics.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_dump.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_extract.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_factor.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_free_numeric.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_free_symbolic.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_kernel.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_analyze.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_analyze_given.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_defaults.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_diagnostics.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_dump.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_extract.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_factor.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_free_numeric.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_free_symbolic.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_kernel.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_memory.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_refactor.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_scale.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_solve.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_sort.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_l_tsolve.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_memory.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_refactor.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_scale.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_solve.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_sort.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_tsolve.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_version.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_z.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_z_diagnostics.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_z_dump.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_z_extract.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_z_factor.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_z_free_numeric.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_z_kernel.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_z_refactor.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_z_scale.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_z_solve.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_z_sort.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_z_tsolve.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_zl.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_zl_diagnostics.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_zl_dump.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_zl_extract.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_zl_factor.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_zl_free_numeric.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_zl_kernel.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_zl_refactor.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_zl_scale.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_zl_solve.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_zl_sort.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/KLU/Source/klu_zl_tsolve.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/SuiteSparse_config/README.txt +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/SuiteSparse_config/SuiteSparse_config.c +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0/crates/gridoxide-sparse}/vendor/suitesparse/SuiteSparse_config/SuiteSparse_config.h +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/docs/.gitignore +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/python/gridoxide/generate_grid.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/python/tests/test_generate_grid.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/bench_gridoxide_cgmes.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/bench_gridoxide_native.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/bench_lightsim2grid.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/bench_pandapower.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/bench_pgm.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/bench_pypowsybl.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/bench_pypowsybl_cgmes.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/bench_veragrid.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/cases.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/cgmes_sv.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/check_cgmes_sv_consistency.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/check_matpower_residual.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/generate_grid.py +0 -0
- {gridoxide-0.0.2 → gridoxide-0.2.0}/scripts/bench/matpower_to_pgm.py +0 -0
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# Environment for `cargo build`/`run`/`test` in this workspace.
|
|
2
|
+
|
|
3
|
+
[env]
|
|
4
|
+
# **Only needed by the `opf-ipopt` feature, and only because of how Debian and
|
|
5
|
+
# Ubuntu package IPOPT.** Harmless otherwise — nothing else in this crate loads
|
|
6
|
+
# OpenMPI.
|
|
7
|
+
#
|
|
8
|
+
# `libipopt.so` there is built against MUMPS, which is built against OpenMPI,
|
|
9
|
+
# so `libmpi.so.40` and `libscalapack-openmpi` come along. OpenMPI runs its
|
|
10
|
+
# transport discovery in a **load-time initializer**, and in an environment
|
|
11
|
+
# without the network and shared-memory facilities it probes for, that
|
|
12
|
+
# discovery hangs. The result is a process that hangs before `main` — before
|
|
13
|
+
# any Rust code runs at all, so no amount of care inside the binding can catch
|
|
14
|
+
# it or work around it. A plain C program that merely links `-lipopt` and calls
|
|
15
|
+
# nothing hangs identically, which is how this was pinned on the package rather
|
|
16
|
+
# than on the binding.
|
|
17
|
+
#
|
|
18
|
+
# Restricting the byte transport layer to loopback skips the probe. `self` is
|
|
19
|
+
# sufficient: MUMPS is used single-process here, so there is no inter-rank
|
|
20
|
+
# communication to carry. (`^tcp` and `^openib,tcp` — excluding transports
|
|
21
|
+
# rather than restricting to one — do *not* help; the discovery still runs.)
|
|
22
|
+
#
|
|
23
|
+
# Not forced, so anyone who has a working OpenMPI setup and sets their own
|
|
24
|
+
# value keeps it.
|
|
25
|
+
OMPI_MCA_btl = "self"
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
name: Rust build and test
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [ "main" ]
|
|
6
|
+
pull_request:
|
|
7
|
+
branches: [ "main" ]
|
|
8
|
+
|
|
9
|
+
env:
|
|
10
|
+
CARGO_TERM_COLOR: always
|
|
11
|
+
|
|
12
|
+
jobs:
|
|
13
|
+
build:
|
|
14
|
+
|
|
15
|
+
runs-on: ubuntu-latest
|
|
16
|
+
|
|
17
|
+
steps:
|
|
18
|
+
- uses: actions/checkout@v4
|
|
19
|
+
# The OPF tests and tests/injection_hessian_test.rs read the pglib-opf
|
|
20
|
+
# cases from benchmark-grids and convert them with numpy
|
|
21
|
+
# (tests/data/pglib_opf.py). CGMES-Test-Configurations stays unfetched.
|
|
22
|
+
- name: Fetch benchmark-grids
|
|
23
|
+
run: git submodule update --init --depth 1 tests/data/benchmark-grids
|
|
24
|
+
- uses: actions/setup-python@v5
|
|
25
|
+
with:
|
|
26
|
+
python-version: "3.12"
|
|
27
|
+
- name: Install numpy
|
|
28
|
+
run: pip install numpy
|
|
29
|
+
# Dependencies and the previous run's build, keyed on Cargo.lock. Without
|
|
30
|
+
# it every run compiles every crate from scratch, once per profile.
|
|
31
|
+
- uses: Swatinem/rust-cache@v2
|
|
32
|
+
|
|
33
|
+
# **Each feature set CI covers is compiled on its own, and tested once,
|
|
34
|
+
# together.** Testing them one at a time ran the default suite eight times
|
|
35
|
+
# over and relinked every test binary for each feature set; what the
|
|
36
|
+
# separate builds actually guard is a missing or wrong `#[cfg]`, which a
|
|
37
|
+
# compile check — `--all-targets`, so tests and examples included — finds
|
|
38
|
+
# just as well, with no codegen and no link.
|
|
39
|
+
#
|
|
40
|
+
# Not here at all: `klu` (a C compiler and libclang), `pardiso` (a
|
|
41
|
+
# separately-licensed Intel oneMKL, `MKLROOT` set — not on hosted runners;
|
|
42
|
+
# see docs/src/solvers/backends.md), `opf-highs` and `opf-ipopt` (system
|
|
43
|
+
# libraries no runner has, so `tests/opf_cross_test.rs`, which holds HiGHS
|
|
44
|
+
# against the in-house solver, runs where HiGHS is installed), and
|
|
45
|
+
# `smallsignal-arpack`. Everything below is pure Rust or fetched by cargo:
|
|
46
|
+
#
|
|
47
|
+
# - `opf`: the interior-point QP solver in `src/opf/ipm.rs`, and `opf::bnb`
|
|
48
|
+
# branching over it for the mixed-integer path.
|
|
49
|
+
# - `ucte`: fixed-column text, no dependency. Its suite checks that each
|
|
50
|
+
# network solves to pypowsybl's answer, committed as JSON under
|
|
51
|
+
# `tests/data/ucte/`, so the runner needs no pypowsybl.
|
|
52
|
+
# - `iidm`: one crate (quick-xml). Checked with `ucte` too, because its
|
|
53
|
+
# strongest test reads the same network through both parsers.
|
|
54
|
+
# - `dynamics`: pure Rust on this crate's sparse backends; small-signal
|
|
55
|
+
# analysis rides along on it.
|
|
56
|
+
# - `rao`: serde, which the crate already has. Its external gate,
|
|
57
|
+
# `tests/rao_cucumber_test.rs`, reads powsybl-open-rao's own Cucumber
|
|
58
|
+
# suite from benchmark-grids and needs no Java.
|
|
59
|
+
# - `capi`: pure Rust plus cbindgen.
|
|
60
|
+
# - `matpower`: plain text, no dependency. Its suite reads the cases in
|
|
61
|
+
# benchmark-grids and checks each solution against the case's own
|
|
62
|
+
# equations.
|
|
63
|
+
- name: Check each feature set on its own
|
|
64
|
+
run: |
|
|
65
|
+
for features in "" opf ucte iidm iidm,ucte dynamics dynamics,iidm \
|
|
66
|
+
rao rao,ucte,iidm capi matpower; do
|
|
67
|
+
echo "::group::cargo check --features '$features'"
|
|
68
|
+
cargo check --all-targets --features "$features"
|
|
69
|
+
echo "::endgroup::"
|
|
70
|
+
done
|
|
71
|
+
# Feature *unification* is its own failure mode, which the checks above
|
|
72
|
+
# cannot see: `iidm` and `cgmes` share quick-xml, and cimmodel enables its
|
|
73
|
+
# `encoding` feature — which changes the shape of a public type. That
|
|
74
|
+
# combination compiled in no single-feature step and broke in the one
|
|
75
|
+
# nobody ran. This is that step.
|
|
76
|
+
- name: Check every CI-covered feature together
|
|
77
|
+
run: cargo check --all-targets --features cgmes,ucte,iidm,opf,rao,dynamics,capi,matpower
|
|
78
|
+
# Tested on the union, *less `cgmes`*: its tests read
|
|
79
|
+
# CGMES-Test-Configurations (158 MB), which CI does not fetch, and nine of
|
|
80
|
+
# them fail rather than skip without it. CI has never run them; fetching
|
|
81
|
+
# the submodule and adding `cgmes` here is what would change that.
|
|
82
|
+
#
|
|
83
|
+
# The integration tests are one binary (`tests/all.rs`), so this links once.
|
|
84
|
+
- name: Test every CI-covered feature together
|
|
85
|
+
run: cargo test --features ucte,iidm,opf,rao,dynamics,capi,matpower
|
|
86
|
+
# The library is split into crates (see crates/), and a plain `cargo test`
|
|
87
|
+
# at the root tests only the root package. The others' own unit tests —
|
|
88
|
+
# the KLU port's among them — run here.
|
|
89
|
+
- name: Test the workspace's other crates
|
|
90
|
+
run: cargo test --workspace --exclude gridoxide
|
|
91
|
+
- name: Build the dynamics scaling examples
|
|
92
|
+
run: |
|
|
93
|
+
cargo build --release --features dynamics --example dynamics_scale
|
|
94
|
+
cargo build --release --features dynamics --example smallsignal_scale
|
|
95
|
+
# The two example programs are the part `cargo test` cannot cover. They are
|
|
96
|
+
# what proves the generated header actually parses as C11 and C++17, that
|
|
97
|
+
# the `#[repr(C)]` layouts agree with what a real compiler computes, and
|
|
98
|
+
# that the exported symbols link — none of which a Rust test can check,
|
|
99
|
+
# since it never sees the header at all.
|
|
100
|
+
- name: Compile and run the C and C++ examples
|
|
101
|
+
run: |
|
|
102
|
+
cargo build --release --features capi
|
|
103
|
+
cc -std=c11 -Wall -Wextra -Werror -Iinclude \
|
|
104
|
+
capi/examples/powerflow.c target/release/libgridoxide.a \
|
|
105
|
+
-o /tmp/powerflow_c -lpthread -ldl -lm
|
|
106
|
+
c++ -std=c++17 -Wall -Wextra -Werror -Iinclude \
|
|
107
|
+
capi/examples/powerflow.cpp target/release/libgridoxide.a \
|
|
108
|
+
-o /tmp/powerflow_cpp -lpthread -ldl -lm
|
|
109
|
+
python tests/data/pglib_opf.py /tmp/pglib-opf
|
|
110
|
+
/tmp/powerflow_c /tmp/pglib-opf/pglib_opf_case14_ieee.json
|
|
111
|
+
/tmp/powerflow_cpp /tmp/pglib-opf/pglib_opf_case14_ieee.json
|
|
112
|
+
# The header is committed so a prebuilt-artifact consumer needs no Rust
|
|
113
|
+
# toolchain. Nothing keeps it in step with the code unless something checks,
|
|
114
|
+
# and building with `capi` regenerates it — so a diff here means a
|
|
115
|
+
# contributor changed the ABI without committing the regenerated header.
|
|
116
|
+
- name: Check the committed header is not stale
|
|
117
|
+
run: git diff --exit-code -- include/gridoxide.h
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
name: Publish to crates.io
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags:
|
|
6
|
+
- 'v*'
|
|
7
|
+
workflow_dispatch:
|
|
8
|
+
inputs:
|
|
9
|
+
dry_run:
|
|
10
|
+
description: 'Package and verify everything without uploading'
|
|
11
|
+
type: boolean
|
|
12
|
+
default: true
|
|
13
|
+
|
|
14
|
+
env:
|
|
15
|
+
CARGO_TERM_COLOR: always
|
|
16
|
+
|
|
17
|
+
jobs:
|
|
18
|
+
publish:
|
|
19
|
+
name: Publish to crates.io
|
|
20
|
+
runs-on: ubuntu-latest
|
|
21
|
+
# Same tag trigger as pypi.yml, so one `v*` tag cuts both the wheels and
|
|
22
|
+
# the crate. Nothing here depends on that workflow, though: a PyPI failure
|
|
23
|
+
# shouldn't hold back the crate or vice versa.
|
|
24
|
+
#
|
|
25
|
+
# Holds the CARGO_REGISTRY_TOKEN secret, which is the point of the
|
|
26
|
+
# environment — scoping the token to this one job, and letting a required
|
|
27
|
+
# reviewer be added later without touching this file.
|
|
28
|
+
environment: crate-release
|
|
29
|
+
steps:
|
|
30
|
+
# No `submodules:` — the two git submodules under tests/data/ hold only
|
|
31
|
+
# test fixtures, and Cargo.toml's `exclude` keeps that whole directory
|
|
32
|
+
# out of the packaged .crate anyway.
|
|
33
|
+
- uses: actions/checkout@v4
|
|
34
|
+
|
|
35
|
+
- uses: dtolnay/rust-toolchain@stable
|
|
36
|
+
|
|
37
|
+
- uses: actions/cache@v4
|
|
38
|
+
with:
|
|
39
|
+
path: |
|
|
40
|
+
~/.cargo/registry
|
|
41
|
+
~/.cargo/git
|
|
42
|
+
target
|
|
43
|
+
key: ${{ runner.os }}-cargo-publish-${{ hashFiles('**/Cargo.lock') }}
|
|
44
|
+
restore-keys: ${{ runner.os }}-cargo-publish-
|
|
45
|
+
|
|
46
|
+
# A version published to crates.io can never be replaced, so catch a
|
|
47
|
+
# mistyped tag here rather than by burning the wrong version number.
|
|
48
|
+
# Skipped on workflow_dispatch, which has no tag to compare against.
|
|
49
|
+
- name: Check tag matches crate version
|
|
50
|
+
if: startsWith(github.ref, 'refs/tags/')
|
|
51
|
+
run: |
|
|
52
|
+
set -euo pipefail
|
|
53
|
+
version=$(cargo metadata --no-deps --format-version 1 | jq -r '.packages[] | select(.name == "gridoxide") | .version')
|
|
54
|
+
tag="${GITHUB_REF_NAME#v}"
|
|
55
|
+
if [ "$tag" != "$version" ]; then
|
|
56
|
+
echo "::error::Tag $GITHUB_REF_NAME does not match Cargo.toml version $version"
|
|
57
|
+
exit 1
|
|
58
|
+
fi
|
|
59
|
+
echo "Tag $GITHUB_REF_NAME matches Cargo.toml version $version"
|
|
60
|
+
|
|
61
|
+
# Catches the two ways a .crate can be broken without any local build
|
|
62
|
+
# noticing: a file the package needs that `exclude` dropped, and a
|
|
63
|
+
# dependency that resolves locally but not from the registry.
|
|
64
|
+
#
|
|
65
|
+
# `--workspace` packages the other workspace crates too, and
|
|
66
|
+
# verifies each crate against the others it just packaged rather than
|
|
67
|
+
# against crates.io, where this version does not exist yet. Verifies on
|
|
68
|
+
# default features only, matching build.yml — `klu`/`pardiso` need a C
|
|
69
|
+
# toolchain, libclang, or a local oneMKL install. That's a limit on what
|
|
70
|
+
# this job *compiles*, not on what ships: the crate is source-only, so
|
|
71
|
+
# every feature's source is published either way.
|
|
72
|
+
- name: Package
|
|
73
|
+
run: cargo package --workspace
|
|
74
|
+
|
|
75
|
+
# The `cgmes` feature is the one whose dependencies come from outside
|
|
76
|
+
# this repo (cimoxide's `cimoxide-model`), so build it from the packaged
|
|
77
|
+
# .crate rather than the working tree — that is what a crates.io
|
|
78
|
+
# consumer actually gets. Pure Rust, so unlike `klu` it needs
|
|
79
|
+
# nothing extra on the runner.
|
|
80
|
+
- name: Check the packaged crate builds with --features cgmes
|
|
81
|
+
run: |
|
|
82
|
+
set -euo pipefail
|
|
83
|
+
version=$(cargo metadata --no-deps --format-version 1 | jq -r '.packages[] | select(.name == "gridoxide") | .version')
|
|
84
|
+
# Every workspace crate's .crate, unpacked side by side.
|
|
85
|
+
for crate in target/package/*-$version.crate; do
|
|
86
|
+
tar xzf "$crate" -C target/package
|
|
87
|
+
done
|
|
88
|
+
# This version of the workspace's other crates is not on crates.io
|
|
89
|
+
# until the step below, so point the extracted gridoxide at the
|
|
90
|
+
# extracted crates — again, exactly what a consumer gets.
|
|
91
|
+
patches=()
|
|
92
|
+
for dir in target/package/gridoxide-*-$version/; do
|
|
93
|
+
name=$(basename "$dir" "-$version")
|
|
94
|
+
patches+=(--config "patch.crates-io.$name.path='$PWD/$dir'")
|
|
95
|
+
done
|
|
96
|
+
cargo build --features cgmes \
|
|
97
|
+
--manifest-path "target/package/gridoxide-$version/Cargo.toml" "${patches[@]}"
|
|
98
|
+
|
|
99
|
+
# Everything above is the dry run: a `workflow_dispatch` with dry_run
|
|
100
|
+
# left on exercises the whole packaging path and stops here, without
|
|
101
|
+
# spending a version number.
|
|
102
|
+
#
|
|
103
|
+
# `--no-verify` because the `cargo package` step above already built the
|
|
104
|
+
# very same .crates; re-verifying would just compile faer twice.
|
|
105
|
+
# `--workspace` publishes in dependency order, gridoxide-sparse first
|
|
106
|
+
# and gridoxide last.
|
|
107
|
+
- name: Publish
|
|
108
|
+
if: ${{ github.event_name != 'workflow_dispatch' || !inputs.dry_run }}
|
|
109
|
+
env:
|
|
110
|
+
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
|
|
111
|
+
run: cargo publish --workspace --no-verify
|
|
@@ -114,10 +114,49 @@ jobs:
|
|
|
114
114
|
name: wheels-sdist
|
|
115
115
|
path: dist
|
|
116
116
|
|
|
117
|
+
# gridoxide-mcp: the `gridmcp` binary as a wheel (maturin `bindings = "bin"`),
|
|
118
|
+
# so MCP clients can start it with `uvx --from gridoxide-mcp gridmcp`. Wheels
|
|
119
|
+
# only, for the platforms the bindings ship. No submodules: the binary is
|
|
120
|
+
# built from source alone.
|
|
121
|
+
mcp:
|
|
122
|
+
name: gridoxide-mcp ${{ matrix.name }}
|
|
123
|
+
runs-on: ${{ matrix.os }}
|
|
124
|
+
strategy:
|
|
125
|
+
matrix:
|
|
126
|
+
include:
|
|
127
|
+
- { name: linux-x86_64, os: ubuntu-latest, target: x86_64 }
|
|
128
|
+
- { name: windows-x64, os: windows-latest, target: x64 }
|
|
129
|
+
- { name: macos-aarch64, os: macos-latest, target: aarch64 }
|
|
130
|
+
steps:
|
|
131
|
+
- uses: actions/checkout@v4
|
|
132
|
+
|
|
133
|
+
- uses: dtolnay/rust-toolchain@stable
|
|
134
|
+
|
|
135
|
+
- uses: actions/cache@v4
|
|
136
|
+
with:
|
|
137
|
+
path: |
|
|
138
|
+
~/.cargo/registry
|
|
139
|
+
~/.cargo/git
|
|
140
|
+
target
|
|
141
|
+
key: ${{ runner.os }}-cargo-mcp-${{ matrix.target }}-${{ hashFiles('**/Cargo.lock') }}
|
|
142
|
+
restore-keys: ${{ runner.os }}-cargo-mcp-${{ matrix.target }}-
|
|
143
|
+
|
|
144
|
+
- uses: PyO3/maturin-action@v1
|
|
145
|
+
with:
|
|
146
|
+
target: ${{ matrix.target }}
|
|
147
|
+
working-directory: crates/gridoxide-mcp
|
|
148
|
+
args: --release --out ../../dist
|
|
149
|
+
manylinux: auto
|
|
150
|
+
|
|
151
|
+
- uses: actions/upload-artifact@v4
|
|
152
|
+
with:
|
|
153
|
+
name: wheels-mcp-${{ matrix.name }}
|
|
154
|
+
path: dist
|
|
155
|
+
|
|
117
156
|
publish:
|
|
118
157
|
name: Publish to PyPI
|
|
119
158
|
if: startsWith(github.ref, 'refs/tags/')
|
|
120
|
-
needs: [linux, windows, macos, sdist]
|
|
159
|
+
needs: [linux, windows, macos, sdist, mcp]
|
|
121
160
|
runs-on: ubuntu-latest
|
|
122
161
|
environment: pypi
|
|
123
162
|
permissions:
|
|
@@ -13,6 +13,10 @@ jobs:
|
|
|
13
13
|
steps:
|
|
14
14
|
- uses: actions/checkout@v4
|
|
15
15
|
|
|
16
|
+
# test_matpower_opf.py converts the pglib-opf cases in benchmark-grids.
|
|
17
|
+
- name: Fetch benchmark-grids
|
|
18
|
+
run: git submodule update --init --depth 1 tests/data/benchmark-grids
|
|
19
|
+
|
|
16
20
|
- name: Install Rust (stable)
|
|
17
21
|
uses: dtolnay/rust-toolchain@stable
|
|
18
22
|
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
name: Release
|
|
2
|
+
|
|
3
|
+
# A GitHub release per `v*` tag with the `gridoxide` CLI for each platform
|
|
4
|
+
# attached. The MCP server is not attached: it ships on PyPI and inside the
|
|
5
|
+
# VS Code extension (vscode.yml).
|
|
6
|
+
|
|
7
|
+
on:
|
|
8
|
+
push:
|
|
9
|
+
tags:
|
|
10
|
+
- 'v*'
|
|
11
|
+
# Attaches binaries to a tag pushed before this workflow existed, or re-runs
|
|
12
|
+
# a release that failed half-way. Without `tag` it only builds.
|
|
13
|
+
workflow_dispatch:
|
|
14
|
+
inputs:
|
|
15
|
+
tag:
|
|
16
|
+
description: 'Tag to build and release, e.g. v0.1.0'
|
|
17
|
+
type: string
|
|
18
|
+
default: ''
|
|
19
|
+
|
|
20
|
+
env:
|
|
21
|
+
TAG: ${{ inputs.tag || github.ref_name }}
|
|
22
|
+
|
|
23
|
+
jobs:
|
|
24
|
+
build:
|
|
25
|
+
name: Build ${{ matrix.artifact }}
|
|
26
|
+
runs-on: ${{ matrix.os }}
|
|
27
|
+
strategy:
|
|
28
|
+
matrix:
|
|
29
|
+
include:
|
|
30
|
+
# musl: a static binary runs on any Linux distribution.
|
|
31
|
+
- os: ubuntu-latest
|
|
32
|
+
rust_target: x86_64-unknown-linux-musl
|
|
33
|
+
exe: gridoxide
|
|
34
|
+
artifact: gridoxide-linux-x64
|
|
35
|
+
- os: windows-latest
|
|
36
|
+
rust_target: x86_64-pc-windows-msvc
|
|
37
|
+
exe: gridoxide.exe
|
|
38
|
+
artifact: gridoxide-windows-x64.exe
|
|
39
|
+
- os: macos-latest
|
|
40
|
+
rust_target: aarch64-apple-darwin
|
|
41
|
+
exe: gridoxide
|
|
42
|
+
artifact: gridoxide-macos-arm64
|
|
43
|
+
|
|
44
|
+
steps:
|
|
45
|
+
- uses: actions/checkout@v4
|
|
46
|
+
with:
|
|
47
|
+
ref: ${{ inputs.tag || github.ref }}
|
|
48
|
+
|
|
49
|
+
- uses: dtolnay/rust-toolchain@stable
|
|
50
|
+
with:
|
|
51
|
+
targets: ${{ matrix.rust_target }}
|
|
52
|
+
|
|
53
|
+
- name: Install musl tools
|
|
54
|
+
if: contains(matrix.rust_target, 'musl')
|
|
55
|
+
run: sudo apt-get update && sudo apt-get install -y musl-tools
|
|
56
|
+
|
|
57
|
+
- uses: actions/cache@v4
|
|
58
|
+
with:
|
|
59
|
+
path: |
|
|
60
|
+
~/.cargo/registry
|
|
61
|
+
~/.cargo/git
|
|
62
|
+
target
|
|
63
|
+
key: ${{ runner.os }}-${{ matrix.rust_target }}-cargo-release-${{ hashFiles('**/Cargo.lock') }}
|
|
64
|
+
restore-keys: ${{ runner.os }}-${{ matrix.rust_target }}-cargo-release-
|
|
65
|
+
|
|
66
|
+
# Every feature that needs no system library; klu, pardiso, opf-highs,
|
|
67
|
+
# opf-ipopt and smallsignal-arpack each link one, so they stay off.
|
|
68
|
+
- name: Build gridoxide
|
|
69
|
+
run: >
|
|
70
|
+
cargo build --release --bin gridoxide --target ${{ matrix.rust_target }}
|
|
71
|
+
--features cgmes,ucte,iidm,matpower,opf,rao,dynamics
|
|
72
|
+
|
|
73
|
+
- name: Stage artifact
|
|
74
|
+
shell: bash
|
|
75
|
+
run: cp target/${{ matrix.rust_target }}/release/${{ matrix.exe }} ${{ matrix.artifact }}
|
|
76
|
+
|
|
77
|
+
- uses: actions/upload-artifact@v4
|
|
78
|
+
with:
|
|
79
|
+
name: ${{ matrix.artifact }}
|
|
80
|
+
path: ${{ matrix.artifact }}
|
|
81
|
+
|
|
82
|
+
release:
|
|
83
|
+
name: Create GitHub release
|
|
84
|
+
if: startsWith(github.ref, 'refs/tags/') || inputs.tag != ''
|
|
85
|
+
needs: build
|
|
86
|
+
runs-on: ubuntu-latest
|
|
87
|
+
permissions:
|
|
88
|
+
contents: write
|
|
89
|
+
steps:
|
|
90
|
+
- uses: actions/download-artifact@v4
|
|
91
|
+
with:
|
|
92
|
+
merge-multiple: true
|
|
93
|
+
|
|
94
|
+
# A release made by hand before the run finished only gets the binaries.
|
|
95
|
+
- name: Create release
|
|
96
|
+
env:
|
|
97
|
+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
98
|
+
run: |
|
|
99
|
+
if gh release view "$TAG" --repo ${{ github.repository }} >/dev/null 2>&1; then
|
|
100
|
+
gh release upload "$TAG" --clobber --repo ${{ github.repository }} gridoxide-*
|
|
101
|
+
else
|
|
102
|
+
gh release create "$TAG" --generate-notes \
|
|
103
|
+
--repo ${{ github.repository }} gridoxide-*
|
|
104
|
+
fi
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
name: VS Code extension
|
|
2
|
+
|
|
3
|
+
# One VSIX per platform, each bundling its own `gridmcp`, published to the
|
|
4
|
+
# Visual Studio Marketplace and Open VSX. Needs VSCE_PAT (Azure DevOps token with
|
|
5
|
+
# Marketplace › Manage) and OVSXAT (open-vsx.org access token) in the `vscode-release`
|
|
6
|
+
# environment. --skip-duplicate lets a run that failed half-way be re-run as-is.
|
|
7
|
+
|
|
8
|
+
on:
|
|
9
|
+
push:
|
|
10
|
+
tags:
|
|
11
|
+
- 'v*'
|
|
12
|
+
workflow_dispatch:
|
|
13
|
+
inputs:
|
|
14
|
+
publish:
|
|
15
|
+
description: 'Publish the packages (otherwise only build them)'
|
|
16
|
+
type: boolean
|
|
17
|
+
default: false
|
|
18
|
+
|
|
19
|
+
jobs:
|
|
20
|
+
package:
|
|
21
|
+
name: Package ${{ matrix.vsce_target }}
|
|
22
|
+
runs-on: ${{ matrix.os }}
|
|
23
|
+
strategy:
|
|
24
|
+
matrix:
|
|
25
|
+
include:
|
|
26
|
+
# musl: a static binary runs on any Linux distribution.
|
|
27
|
+
- os: ubuntu-latest
|
|
28
|
+
rust_target: x86_64-unknown-linux-musl
|
|
29
|
+
vsce_target: linux-x64
|
|
30
|
+
exe: gridmcp
|
|
31
|
+
- os: windows-latest
|
|
32
|
+
rust_target: x86_64-pc-windows-msvc
|
|
33
|
+
vsce_target: win32-x64
|
|
34
|
+
exe: gridmcp.exe
|
|
35
|
+
- os: macos-latest
|
|
36
|
+
rust_target: aarch64-apple-darwin
|
|
37
|
+
vsce_target: darwin-arm64
|
|
38
|
+
exe: gridmcp
|
|
39
|
+
|
|
40
|
+
steps:
|
|
41
|
+
- uses: actions/checkout@v4
|
|
42
|
+
|
|
43
|
+
# The smoke test lists case14 from benchmark-grids.
|
|
44
|
+
- name: Fetch benchmark-grids
|
|
45
|
+
if: runner.os == 'Linux'
|
|
46
|
+
run: git submodule update --init --depth 1 tests/data/benchmark-grids
|
|
47
|
+
|
|
48
|
+
- uses: dtolnay/rust-toolchain@stable
|
|
49
|
+
with:
|
|
50
|
+
targets: ${{ matrix.rust_target }}
|
|
51
|
+
|
|
52
|
+
- name: Install musl tools
|
|
53
|
+
if: contains(matrix.rust_target, 'musl')
|
|
54
|
+
run: sudo apt-get update && sudo apt-get install -y musl-tools
|
|
55
|
+
|
|
56
|
+
- uses: actions/cache@v4
|
|
57
|
+
with:
|
|
58
|
+
path: |
|
|
59
|
+
~/.cargo/registry
|
|
60
|
+
~/.cargo/git
|
|
61
|
+
target
|
|
62
|
+
key: ${{ runner.os }}-${{ matrix.rust_target }}-cargo-vscode-${{ hashFiles('**/Cargo.lock') }}
|
|
63
|
+
restore-keys: ${{ runner.os }}-${{ matrix.rust_target }}-cargo-vscode-
|
|
64
|
+
|
|
65
|
+
- name: Build gridmcp
|
|
66
|
+
run: cargo build --release -p gridoxide-mcp --target ${{ matrix.rust_target }}
|
|
67
|
+
|
|
68
|
+
- uses: actions/setup-node@v4
|
|
69
|
+
with:
|
|
70
|
+
node-version: 20
|
|
71
|
+
|
|
72
|
+
- name: Check extension version matches the workspace
|
|
73
|
+
shell: bash
|
|
74
|
+
run: |
|
|
75
|
+
crate=$(sed -n 's/^version = "\(.*\)"/\1/p' Cargo.toml | head -1)
|
|
76
|
+
ext=$(node -p "require('./editors/vscode/package.json').version")
|
|
77
|
+
if [ "$crate" != "$ext" ]; then
|
|
78
|
+
echo "editors/vscode/package.json is $ext, the workspace is $crate" >&2
|
|
79
|
+
exit 1
|
|
80
|
+
fi
|
|
81
|
+
|
|
82
|
+
- name: Package
|
|
83
|
+
shell: bash
|
|
84
|
+
working-directory: editors/vscode
|
|
85
|
+
run: |
|
|
86
|
+
mkdir -p server
|
|
87
|
+
cp ../../target/${{ matrix.rust_target }}/release/${{ matrix.exe }} server/
|
|
88
|
+
npm ci
|
|
89
|
+
npx vsce package --target ${{ matrix.vsce_target }}
|
|
90
|
+
|
|
91
|
+
# The extension in a running VS Code (test/suite.ts): a failure here
|
|
92
|
+
# fails the job, so nothing is published.
|
|
93
|
+
- name: Smoke test
|
|
94
|
+
if: runner.os == 'Linux'
|
|
95
|
+
working-directory: editors/vscode
|
|
96
|
+
run: xvfb-run -a npm test
|
|
97
|
+
|
|
98
|
+
- uses: actions/upload-artifact@v4
|
|
99
|
+
with:
|
|
100
|
+
name: vsix-${{ matrix.vsce_target }}
|
|
101
|
+
path: editors/vscode/*.vsix
|
|
102
|
+
|
|
103
|
+
publish:
|
|
104
|
+
name: Publish
|
|
105
|
+
needs: package
|
|
106
|
+
if: startsWith(github.ref, 'refs/tags/') || inputs.publish
|
|
107
|
+
runs-on: ubuntu-latest
|
|
108
|
+
environment: vscode-release
|
|
109
|
+
steps:
|
|
110
|
+
- uses: actions/download-artifact@v4
|
|
111
|
+
with:
|
|
112
|
+
pattern: vsix-*
|
|
113
|
+
merge-multiple: true
|
|
114
|
+
|
|
115
|
+
- uses: actions/setup-node@v4
|
|
116
|
+
with:
|
|
117
|
+
node-version: 20
|
|
118
|
+
|
|
119
|
+
- name: Publish to the Visual Studio Marketplace
|
|
120
|
+
env:
|
|
121
|
+
VSCE_PAT: ${{ secrets.VSCE_PAT }}
|
|
122
|
+
run: npx --yes @vscode/vsce@3 publish --skip-duplicate --packagePath *.vsix
|
|
123
|
+
|
|
124
|
+
- name: Publish to Open VSX
|
|
125
|
+
env:
|
|
126
|
+
OVSX_PAT: ${{ secrets.OVSXAT }}
|
|
127
|
+
run: npx --yes ovsx@0 publish --skip-duplicate --packagePath *.vsix
|