Fix docs Euler import and Downgrade (DiffEqBase rrule(numargs) floor); Windows fixed via SciML/.github#100#318
Draft
ChrisRackauckas-Claude wants to merge 2 commits into
Conversation
…fEqBDF downgrade floor Two master-CI failures, two independent fixes: Documentation build (UndefVarError: `Euler` not defined): OrdinaryDiffEq v7 split out the low-order RK solvers and no longer re-exports `Euler` from the umbrella (verified: with OrdinaryDiffEq v7.0.1, isdefined(OrdinaryDiffEq, :Euler) == false; `Euler` now lives in OrdinaryDiffEqLowOrderRK). The docs examples in integrating.md and uncertainty_quantification.md call `Euler()` with only `using OrdinaryDiffEq`, so the @example blocks errored. Add OrdinaryDiffEqLowOrderRK to docs/Project.toml and `using` it in both pages. Higher-order solvers (Tsit5, Rodas5P, Rosenbrock23, Vern7) are still re-exported by the umbrella and need no change. Downgrade (Core) (MethodError: no method matching _initialize_dae! for the NonlinearSolve-backed BrownFullBasicInit in saving_tests.jl's "fail gracefully" DAE test): the `_initialize_dae!(..., BrownFullBasicInit{..., GeneralizedFirstOrderAlgorithm})` dispatch is implemented in OrdinaryDiffEqBDF and first appears in v1.7.0. The previous compat floor "1.3.0" let the downgrade resolve OrdinaryDiffEqBDF v1.3.0, which lacks the method, so the test errored instead of returning ReturnCode.InitialFailure. Bisected locally on Julia 1.10: BDF 1.6.0 errors, BDF 1.7.0 passes; raise the floor to 1.7.0 (a lower-bound raise is downgrade-safe and the repo already allows BDF v2). Verified locally on Julia 1.10 that the fail-gracefully test returns InitialFailure with the bumped floor, and on Julia 1.12 that the integrating.md example runs with the docs env. Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com> Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The strict Downgrade (Core) job still failed after the OrdinaryDiffEqBDF
floor bump: the "fail gracefully" DAE test in saving_tests.jl errored with a
MethodError for _initialize_dae!(..., BrownFullBasicInit{..., GeneralizedFirstOrderAlgorithm}, ::Val{false}) even with OrdinaryDiffEqBDF
v1.8.0 resolved -- so the BDF floor was not the real cause.
Root cause (reproduced locally on Julia 1.10 with the CI-resolved downgrade
stack): DiffEqBase v6.190.2's DiffEqBaseChainRulesCoreExt defines
ChainRulesCore.rrule(::typeof(numargs), f), and SciMLBase v2.146.0's
SciMLBaseChainRulesCoreExt defines the same rrule for SciMLBase.numargs. With
both floors resolved together the duplicate definition raises "Method
overwriting is not permitted during Module precompilation" while loading
DiffEqBaseChainRulesCoreExt, which fails the extension and cascades so the
OrdinaryDiffEqNonlinearSolve _initialize_dae! methods for BrownFullBasicInit
are never available -- hence the MethodError (the listed candidates were only
the OrdinaryDiffEqCore CheckInit/OverrideInit/NoInit methods).
DiffEqBase removed rrule(numargs) from its ext in v6.211.0 (verified: present
in 6.210.0, absent from 6.211.0; SciMLBase owns it now). Raising the floor to
6.211.0 drops the version range that double-defines it; SciMLBase 2.146.0 still
provides the rrule, so nothing is lost. A lower-bound raise is downgrade-safe.
Verified locally on Julia 1.10: with DiffEqBase pinned to 6.211.0 against the
CI downgrade stack (SciMLBase 2.146.0, OrdinaryDiffEqBDF 1.8.0,
OrdinaryDiffEqNonlinearSolve 1.12.0, NonlinearSolveFirstOrder 1.9.0) the stack
precompiles with no method-overwriting error and the "fail gracefully"
testset passes 4/4 (sol.retcode == ReturnCode.InitialFailure).
Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Euler import (OrdinaryDiffEq v7 split) and raise OrdinaryDiffEqBDF downgrade floor
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.
Three master-CI failures addressed.
1. Documentation build (
UndefVarError: Euler not defined)OrdinaryDiffEq v7 split out the low-order RK solvers and no longer re-exports
Eulerfrom the umbrella (verified: with OrdinaryDiffEq v7.0.1,isdefined(OrdinaryDiffEq, :Euler) == false;Eulernow lives in OrdinaryDiffEqLowOrderRK). The docs@exampleblocks inintegrating.mdanduncertainty_quantification.mdcallEuler()with onlyusing OrdinaryDiffEq, so they errored. AddOrdinaryDiffEqLowOrderRKtodocs/Project.tomlandusingit in both pages. Higher-order solvers (Tsit5, Rodas5P, Rosenbrock23, Vern7) are still re-exported by the umbrella and need no change. (Documentation check is green on this branch.)2. Downgrade (Core) —
_initialize_dae!MethodError in the "fail gracefully" DAE testThe first attempt (raise the
OrdinaryDiffEqBDFfloor to 1.7.0) did not fix it — the job still failed withOrdinaryDiffEqBDF v1.8.0resolved, so the BDF floor was not the real cause.Real root cause (reproduced locally on Julia 1.10 against the CI-resolved downgrade stack):
DiffEqBasev6.190.2'sDiffEqBaseChainRulesCoreExtdefinesChainRulesCore.rrule(::typeof(numargs), f), andSciMLBasev2.146.0'sSciMLBaseChainRulesCoreExtdefines the samerruleforSciMLBase.numargs. With both floors resolved together the duplicate raises "Method overwriting is not permitted during Module precompilation" while loadingDiffEqBaseChainRulesCoreExt; that extension fails and cascades soOrdinaryDiffEqNonlinearSolve's_initialize_dae!methods forBrownFullBasicInitare never loaded — hence theMethodError(the listed candidates were only OrdinaryDiffEqCore'sCheckInit/OverrideInit/NoInit).DiffEqBase removed
rrule(numargs)from its ext in v6.211.0 (verified: present in 6.210.0, absent from 6.211.0; SciMLBase owns it now). Raising the floor to6.211.0drops the double-defining range. Verified locally: with DiffEqBase 6.211.0 against the CI downgrade stack the bundle precompiles with no overwriting error and the "fail gracefully" testset passes 4/4. The BDF 1.7.0 floor bump is retained (harmless, downgrade-safe) though the actual fix is the DiffEqBase floor.3. Windows Core tests (
OrdinaryDiffEqCorePolyesterExt: _polyester_batch does not exist) — NOT fixed hereThe
tests / Core (julia 1|lts, windows-latest)reds are not a DiffEqCallbacks bug. They are caused by a bug in the centralizedSciML/.githubtests.yml: the "Set test group env" step writesGROUP=Coreto$GITHUB_ENVwith bash syntax but noshell: bash, so on the PowerShell-default Windows runners$GITHUB_ENVis not expanded andGROUPis never set.runtests.jlthen falls back to the default group ("All"), which on Windows runs theADgroup (SciMLSensitivity) inside the Core test env, upgrading already-loaded packages mid-session and breaking precompilation. Linux/macOS (bash default) are unaffected.Fix: SciML/.github#100 (adds
shell: bash). Once that lands andv1is retagged, the Windows Core jobs here go green with no change to this repo. (Tracked separately because this repo pins the reusable workflow at@v1and does not control its contents.)Please ignore until reviewed by @ChrisRackauckas