Bump SCCNonlinearSolve compat floor to 1.13 to fix downgrade precompile#4657
Merged
ChrisRackauckas merged 1 commit intoJun 23, 2026
Merged
Conversation
The downgrade CI lanes ("Downgrade / InterfaceI" and
"downgrade-sublibraries / ModelingToolkitBase") resolved
SCCNonlinearSolve v1.12.1, whose `iteratively_build_sols`
preallocated a `Vector{NonlinearSolution}` and stored a
`LinearSolution` from a linear SCC directly into it, throwing
MethodError: Cannot `convert` an object of type
SciMLBase.LinearSolution to SciMLBase.NonlinearSolution
during the `SCCNonlinearProblem` precompile workload
(src/precompile.jl), failing precompilation of ModelingToolkit and
its extensions.
The fix landed in SCCNonlinearSolve 1.13.0 (commit c5c8120 "fix vector-form
SCCNonlinearProblem with linear SCCs"), which converts a linear SCC's
`LinearSolution` into a stripped `NonlinearSolution` before storing it.
Raising the floor from 1.8.1 to 1.13 prevents the downgrade resolver from
selecting a pre-fix version. SCC 1.13's SciMLBase compat (2.153-3) remains
compatible with ModelingToolkitBase's SciMLBase 3.18 floor.
Verified locally on Julia 1.10: with the old floor (SCC 1.12.1 pinned)
ModelingToolkit precompile fails with the convert MethodError; with the
new floor (SCC 1.13.0) precompile succeeds cleanly.
Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Please ignore until reviewed by @ChrisRackauckas.
Problem
The master downgrade CI lanes —
Downgrade / Downgrade Tests - InterfaceIanddowngrade-sublibraries / test (lib/ModelingToolkitBase)— resolve SCCNonlinearSolve v1.12.1. That version ofiteratively_build_solspreallocates aVector{NonlinearSolution}and stores aLinearSolution(returned for a linear SCC) directly into it, throwing during theSCCNonlinearProblemprecompile workload (src/precompile.jl):This fails precompilation of ModelingToolkit and its OrdinaryDiffEq extensions on the LTS downgrade run (24 such errors in the InterfaceI lane).
Root cause
The fix for this lives in SCCNonlinearSolve 1.13.0 (commit
c5c8120, "fix vector-formSCCNonlinearProblemwith linear SCCs"), which routes a linear SCC through asolve_single_scchelper that converts theLinearSolutioninto a stripped, well-typedNonlinearSolutionbefore storing it. The registered 1.12.1 tree does not contain this helper. The current compat floorSCCNonlinearSolve = "1.8.1"lets the downgrade resolver pick the broken 1.12.1.Fix
Raise the floor to
SCCNonlinearSolve = "1.13"in bothProject.tomlandlib/ModelingToolkitBase/Project.toml. SCC 1.13s SciMLBase compat (2.153.0 - 3) remains compatible with ModelingToolkitBasesSciMLBase = "3.18"floor.Local verification (Julia 1.10)
Reproduced both directions by pinning the downgrade-resolved versions (
SciMLBase 3.18,SimpleNonlinearSolve 2.11.1) and precompilingModelingToolkit:1.12.1, old floor):PRECOMPILE_FAILED, 2×Cannot convert ... LinearSolution ... NonlinearSolution(sameiteratively_build_solsstack as CI).1.13.0, new floor):FIX_PRECOMPILE_OK, 0 convert errors, resolvesSCCNonlinearSolve v1.13.0.Scope note
This addresses the SCC
1.12.1precompile failure that anchors the InterfaceI downgrade lane. Thedowngrade-sublibraries / ModelingToolkitBaselane also resolves SCC 1.12.1 (first failing package isSCCNonlinearSolveChainRulesCoreExt) but surfaces a separateModule IR does not contain specified entry functioncascade that I could not reproduce locally without the full Resolver--min=@alldepsenv; this floor bump applies there too and may help, but that lane should be re-checked in CI. Thebuild(Documentation) andOptimizationtest-group reds are a different root cause — anOptim 2(NLSolversBase 8) vsNLsolve(NLSolversBase ≤ 7.10, pulled by DiffEqDevTools) resolver deadlock — not addressed here.🤖 Generated with Claude Code