Raise ModelingToolkitBase floor for array codegen#482
Conversation
|
Investigation checkpoint:
|
|
CI checkpoint (Downgrade job):
Job: https://github.com/SciML/ModelingToolkitStandardLibrary.jl/actions/runs/29243540209/job/86794967078 The motor baseline audit remains separate, so no unrelated fix is being added to this focused draft. |
|
CI documentation checkpoint: the failed docs job is the unmodified clean-main documentation baseline, not a ModelingToolkitBase compat regression. It reports the four independently isolated failures:
The stacked #481 documentation job is now green. #482 remains limited to the MTKBase floor/codegen regression; its Core magnetic and downgrade motor blockers are likewise handled separately by the active magnetic audit and #483. |
|
The delayed ModelingToolkit downstream failure is unrelated to this MTKSL compat-floor change. The outer MTK test process first loads LinearSolve 3.87.0, then the downstream environment resolves 4.3.0; precompiling |
ModelingToolkitBase 1.0 passes symbolic array indices directly to OffsetArrays and errors with the supported SymbolicUtils floor. Version 1.1 uses the stable-index API and is the first compatible release. Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Add a focused regression that compiles a StateSpace block with array states and constructs its ODEProblem under downgraded dependencies. Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
1e6a3d2 to
f106c56
Compare
|
Rebased onto current |
|
The rebased red Downgrade and Core / Julia LTS checks now expose the same exact clean-main piston fixture failure; they are not caused by this PR. Both fail This is the next fixture after the motor test fixed by merged #483: importing DynamicQuantities only inside the motor safe-testset does not load its owner extension for the isolated piston safe-testset. The same cause also appears in ModelingToolkit clean-master downstream CI and #4742. I am assigning one separate cross-repository audit to reproduce/bisect/fix this shared fixture-owner issue; #482 assertions and compat change remain untouched. #482 downgrade: https://github.com/SciML/ModelingToolkitStandardLibrary.jl/actions/runs/29253716628/job/86828223048 |
|
Independent clean-main audit: the piston failure is a latent missing independent variable exposed by the folder-based SciMLTesting isolation. On Julia 1.10, current main (933a983) reproduces the CI exception exactly in an isolated |
Important
Ignore this draft until it has been reviewed by @ChrisRackauckas.
Summary
Root cause
The minimum-dependency job exposed by NeuralPDE.jl #1084 selected ModelingToolkitBase 1.0.0 together with SymbolicUtils 4.38.1 and OffsetArrays 1.17.0. In that combination, StateSpace and TransferFunction construction passed symbolic array indices directly to an OffsetVector and errored.
ModelingToolkit commit 0182154217a064ea2b99bc230b8a58dabb2442be changed ModelingToolkitBase array-variable assignment to linearize stable symbolic indices through the public SymbolicUtils API. The first ModelingToolkitBase release containing that change is 1.1.0. This PR therefore corrects a false lower-bound compatibility claim within the existing 1.x series; it does not change ModelingToolkitStandardLibrary's public API.
The focused test makes this dependency requirement explicit without relying only on the larger continuous-block suite.
Local verification
I ran the repository's native SciMLTesting harness with Julia 1.10 and the same
julia-downgrade-compat@v2dependency-mode resolver used by CI.Resolved versions after this change:
Observed before the floor change, at ModelingToolkitBase 1.0.0:
Core/continuous.jl: 54 passed, 2 errored in StateSpace and TransferFunction construction.Observed after the floor change:
Core/array_state_codegen.jl: 1/1 passed.Core/continuous.jl: 76/76 passed.The full Core run then exposed a distinct pre-existing error in
Core/motor.jl:_check_if_ddereceivesModelingToolkitBase.PleaseImportDynamicQuantities. I separately reproduced that exact error on a clean upstream-main checkout at ModelingToolkitBase 1.0.0, so it is not introduced by this branch. It is being investigated separately under the repository's clean-main failure policy; this PR remains a focused draft and does not claim the complete Core group is green yet.Formatting verification:
git diff --check: passed.Process log
Task prompt: investigate the ModelingToolkitStandardLibrary downgrade failure surfaced while updating the downstream workflow.