CompatHelper: bump compat for DiffEqBase to 7, (keep existing compat)#407
Closed
github-actions[bot] wants to merge 1 commit into
Closed
CompatHelper: bump compat for DiffEqBase to 7, (keep existing compat)#407github-actions[bot] wants to merge 1 commit into
github-actions[bot] wants to merge 1 commit into
Conversation
b8ed447 to
8608a7d
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #407 +/- ##
=======================================
Coverage 91.70% 91.70%
=======================================
Files 44 44
Lines 2207 2207
=======================================
Hits 2024 2024
Misses 183 183 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
4 tasks
nathanaelbosch
added a commit
that referenced
this pull request
May 13, 2026
…king changes (#410) * Handle OrdinaryDiffEq v7 / DiffEqBase v7 / OrdinaryDiffEqCore v4 breaking changes Bump compats to the new major versions (matching CompatHelper PRs #407, #408, #409) and gate the OrdinaryDiffEqCore internals we extend so the package continues to build against both OrdinaryDiffEqCore v3 and v4. v4 removed a handful of internal hooks that ProbNumDiffEq relied on: - `OrdinaryDiffEqCore._default_dae_init!(integrator, prob, x, alg)` was deleted along with the per-solver DAE-init dispatch; initialization now routes through `_initialize_dae!(integrator, prob, alg::DefaultInit, x)` and the default algorithm switched from `BrownFullBasicInit` to `CheckInit`. Restore the prior behaviour for `AbstractEK` by overriding `_initialize_dae!` for our integrator type on v4. - `OrdinaryDiffEqCore.isstandard` / `ispredictive` traits were removed; PI control is now the default via `default_controller`, so the trait overrides are only needed on v3. - `integrator.EEst` was removed from the `ODEIntegrator` struct and replaced with `OrdinaryDiffEqCore.get_EEst` / `set_EEst!` accessors backed by `integrator.controller_cache`. Wrap both call sites in `perform_step!` with helpers that pick the right API per version. - `OrdinaryDiffEqCore._process_AD_choice` is gone on v4 (the `chunk_size` / `diff_type` / `standardtag` solver kwargs were removed in favour of `AutoForwardDiff(chunksize=…)` / `AutoFiniteDiff(fdtype=…)`). Fall back to an inlined equivalent so `EK1` / `DiagonalEK1` keep accepting the legacy kwargs on both versions. See the OrdinaryDiffEq v7 NEWS.md for the full list of breaking changes. Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com> * JuliaFormatter * Fix v4/v7 stack CI failures: scope reduction, RAT v4, Bool autodiff, DiffEqDevTools v4 Four distinct failures surfaced once CI started resolving the v4/v7 stack (which became possible after the gating deps registered in General). 1. UndefVarError: RadauIIA5. OrdinaryDiffEq v7's package scope reduction means `using OrdinaryDiffEq` no longer re-exports the full solver suite. Add `using OrdinaryDiffEqFIRK: RadauIIA5` in test/stiff_problem.jl and test/mass_matrix.jl, plus the dep UUID in test/Project.toml. 2. length(sol) returned the wrong value at test/solution.jl:29,96. RecursiveArrayTools v4 changed length(sol) from "number of timesteps" to prod(size(sol)) since AbstractVectorOfArray now subtypes AbstractArray. Switch to length(sol.u) per the v7 NEWS migration. 3. MethodError: prepare_ADType(::Bool, ...) when EK1 or DiagonalEK1 was constructed with the legacy autodiff=true or autodiff=false kwarg. The v4 fallback for _process_AD_choice in src/algorithms.jl only handled AutoForwardDiff and AutoFiniteDiff; the v3 OrdinaryDiffEqCore version it replaced also converted Bool to an ADType. Mirror that conversion so the Bool no longer propagates as the AD type parameter on the algorithm. 4. ArgumentError: Passing a Bool for verbose, raised by DiffEqDevTools v3's WorkPrecisionSet on test/diffeqdevtools.jl:79. DiffEqDevTools v4 removed the offending kwarg. Widen Project.toml compat to "2.46, 3, 4" so the resolver picks v4 on the v4/v7 stack. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * Switch default DAE init to CheckInit; drop verbose=false from broken WP test Two changes: 1. src/algorithms.jl: replace the AbstractEK DAE-init override with one that routes through CheckInit on both stacks. Matches the OrdinaryDiffEq v7 / DifferentialEquations v8 default (errors on inconsistent ICs instead of silently correcting them). Users who want the old auto-fix behavior must now pass initializealg=BrownFullBasicInit() explicitly. On v4 the per-alg hook is gone and CheckInit is already the default, so the override is only needed on v3. Verified locally against test/mass_matrix.jl on the v4/v7 stack: both UniformScaling and Robertson mass-matrix tests pass with consistent ICs. 2. test/diffeqdevtools.jl: drop verbose=false from the two WorkPrecisionSet calls in the "is broken" testset. DiffEqDevTools v3 forwards verbose as a Bool which OrdinaryDiffEq v7 rejects (DEVerbosity / SciMLLogging required). DiffEqDevTools v4 removed the kwarg, but v4.0.0 is yanked in General, so we drop the kwarg test-side. On v3/v6 this only removes a deprecation warning the test was already eating. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> * Address code review feedback: fix AutoFiniteDiff regression, trim comments Two functional changes in src/algorithms.jl: - Drop the stray em-dash from the `_process_AD_choice` overview comment to comply with the project's no-em-dashes style. - Guard the `AutoFiniteDiff` branch of the v4 `_process_AD_choice` fallback to only rebuild the ADType when the user passed a non-default legacy `diff_type` kwarg. The previous version unconditionally rebuilt with `fdtype=diff_type`, which silently dropped a user's pre-configured `AutoFiniteDiff(fdtype=Val(:central))` (or similar) when they didn't also set the legacy `diff_type`. Mirrors v3's behavior. Comment trim across src/algorithms.jl and src/alg_utils.jl: the `_alg_autodiff` block, the `_process_AD_choice` overview, the Bool-branch inline comment, and the DAE-init block are all condensed without losing the migration rationale. Saves ~10 lines in the compat-shim region. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> --------- Co-authored-by: ChrisRackauckas-Claude <accounts@chrisrackauckas.com> Co-authored-by: Nathanael Bosch <nathanael.bosch@epfl.ch> Co-authored-by: Claude Opus 4.7 (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.
This pull request changes the compat entry for the
DiffEqBasepackage from6.194to6.194, 7.This keeps the compat entries for earlier versions.
Note: I have not tested your package with this new compat entry.
It is your responsibility to make sure that your package tests pass before you merge this pull request.