Skip to content

Fix bigfloat Misc/Wrappers failure and raise DifferentiationInterface floor to 0.7.15 (Downgrade Misc)#514

Merged
ChrisRackauckas merged 2 commits into
SciML:masterfrom
ChrisRackauckas-Claude:fix-bigfloat-test-broken-expression
Jun 23, 2026
Merged

Fix bigfloat Misc/Wrappers failure and raise DifferentiationInterface floor to 0.7.15 (Downgrade Misc)#514
ChrisRackauckas merged 2 commits into
SciML:masterfrom
ChrisRackauckas-Claude:fix-bigfloat-test-broken-expression

Conversation

@ChrisRackauckas-Claude

@ChrisRackauckas-Claude ChrisRackauckas-Claude commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

Summary

Drives the BoundaryValueDiffEq.jl master CI toward green by fixing the failures this repo controls. Two fixes:

1. tests / Misc + tests / Wrappers root-suite bigfloat failure

test/misc/bigfloat_test.jl:68 was @test_broken sol4 = solve(prob, MIRKN4(), dt = 0.01), which failed two ways:

  1. Non-Boolean expression. @test_broken applied to an assignment: when solve() returns, the assignment evaluates to the solution object (non-Boolean) and the testset errors with Expression evaluated to non-Boolean (the error on master).
  2. Unexpected Pass. With current deps the SecondOrderBVProblem + MIRKN4() + BigFloat case now solves with a successful retcode, so even a well-formed @test_broken begin … end errors with Unexpected Pass.

Since the case genuinely passes now, converted it to a real @test SciMLBase.successful_retcode(sol4.retcode).

Verified locally (Julia 1.12 and 1.10): BigFloat compatibility | 7 | 7 PASS.

2. Downgrade Tests - Misc scalar BVP BoundsError

The downgrade-Misc job tests at dependency floors. With DifferentiationInterface = "0.7.13", test/misc/scalar_tests.jl errored:

BoundsError: attempt to access 1-element Vector{ForwardDiff.Dual{…}} at index [2]
@ DifferentiationInterfaceForwardDiffExt/misc.jl:31

This is a bug in DifferentiationInterface 0.7.13/0.7.14: overloaded_input_type for a ForwardDiffOneArgJacobianPrep indexes [2] into the dual vector, so it fails when the prepared input has a single element. Single-shooting on a scalar BVP (u0 isa Number → 1-element vec) hits exactly this via __single_shooting_jacobian_ode_cache. Fixed in DifferentiationInterface 0.7.15, so the floor is raised to 0.7.15 (root + all sublibraries).

Verified locally on Julia 1.10 (lts) by pinning DifferentiationInterface to 0.7.15 and running test/misc/scalar_tests.jl against the developed root + sublibraries:

Scalar BVP tests | Pass Total Time
                 |    4     4  51.2s

(Reproduced the BoundsError on 0.7.13 and 0.7.14; confirmed 0.7.15+ fixes it.)

Remaining red checks — out of this repo's scope (reported, not fixed here)

  • tests / Wrappers (BVPSOL). Cannot find method(s) for bvpsol! — ODEInterface fails to load its Fortran bvpsol solver in the GitHub runner environment. Verified locally on Julia 1.10 that the full wrappers/odeinterface_tests.jl passes (BVPSOL 4/4, COLNEW 1/1, COLNEW-multipoint 1/1) — the test code is correct; this is an ODEInterface/runner environment issue, not a repo bug.
  • Downgrade Sublibraries / test (FIRK/MIRK). --min=@alldeps resolution is Unsatisfiable before any test runs. Root cause traced locally: the package requires SciMLBase = "3", which forces RecursiveArrayTools ≥ 4 and DiffEqBase ≥ 7, but the test-dep floors predate that — and decisively, Enzyme = "0.13.33" admits only Enzyme 0.13.x, every version of which caps DiffEqBase ≤ 6.190.5. So no Enzyme 0.13.x co-installs with the SciMLBase-3 / RAT-4 / DiffEqBase-7 stack at the floor. This is the fleet-wide downgrade-floor wall; resolving it requires a coordinated Enzyme major bump (with likely code adaptation) plus RAT/Rosenbrock/LinearSolve/DiffEqBase floor raises — a separate, larger change, deliberately not attempted here.
  • ModelingToolkit.jl/All / Downstream Tests - All. ModelingToolkit's own InterfaceI testset has 2 internal failures (1388 passed, 2 failed) — a cross-repo failure that resolves when MTK is fixed; not caused by this repo.

Note: This PR should be ignored until reviewed by @ChrisRackauckas.

@github-actions

github-actions Bot commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

Benchmark Results (Julia v1.11)

Time benchmarks
master db60810... master / db60810...
Simple Pendulum/IIP/BoundaryValueDiffEqMIRK.MIRK2() 0.325 ± 0.017 s 0.317 ± 0.0092 s 1.02 ± 0.061
Simple Pendulum/IIP/BoundaryValueDiffEqMIRK.MIRK3() 7.07 ± 0.44 ms 6.69 ± 0.32 ms 1.06 ± 0.083
Simple Pendulum/IIP/BoundaryValueDiffEqMIRK.MIRK4() 1.53 ± 0.1 ms 1.44 ± 0.076 ms 1.06 ± 0.09
Simple Pendulum/IIP/BoundaryValueDiffEqMIRK.MIRK5() 1.85 ± 0.14 ms 1.8 ± 0.13 ms 1.03 ± 0.11
Simple Pendulum/IIP/BoundaryValueDiffEqMIRK.MIRK6() 0.929 ± 0.074 ms 0.901 ± 0.053 ms 1.03 ± 0.1
Simple Pendulum/IIP/MultipleShooting(10, Tsit5; grid_coarsening = false) 0.965 ± 0.12 ms 0.947 ± 0.081 ms 1.02 ± 0.15
Simple Pendulum/IIP/MultipleShooting(10, Tsit5; grid_coarsening = true) 1.95 ± 0.17 ms 1.88 ± 0.11 ms 1.04 ± 0.11
Simple Pendulum/IIP/MultipleShooting(100, Tsit5; grid_coarsening = false) 27.7 ± 3.6 ms 25.1 ± 2.7 ms 1.1 ± 0.19
Simple Pendulum/IIP/MultipleShooting(100, Tsit5; grid_coarsening = true) 0.0443 ± 0.0034 s 0.0394 ± 0.0021 s 1.12 ± 0.11
Simple Pendulum/IIP/Shooting(Tsit5()) 0.109 ± 0.053 ms 0.109 ± 0.053 ms 1 ± 0.69
Simple Pendulum/OOP/BoundaryValueDiffEqMIRK.MIRK2() 0.402 ± 0.011 s 0.386 ± 0.011 s 1.04 ± 0.041
Simple Pendulum/OOP/BoundaryValueDiffEqMIRK.MIRK3() 9.75 ± 6 ms 8.62 ± 3.2 ms 1.13 ± 0.81
Simple Pendulum/OOP/BoundaryValueDiffEqMIRK.MIRK4() 1.91 ± 0.2 ms 1.83 ± 0.11 ms 1.04 ± 0.12
Simple Pendulum/OOP/BoundaryValueDiffEqMIRK.MIRK5() 2.29 ± 0.26 ms 2.17 ± 0.14 ms 1.06 ± 0.14
Simple Pendulum/OOP/BoundaryValueDiffEqMIRK.MIRK6() 1.14 ± 0.15 ms 1.08 ± 0.095 ms 1.06 ± 0.17
Simple Pendulum/OOP/MultipleShooting(10, Tsit5; grid_coarsening = false) 2.45 ± 0.5 ms 2.33 ± 0.37 ms 1.05 ± 0.27
Simple Pendulum/OOP/MultipleShooting(10, Tsit5; grid_coarsening = true) 4.87 ± 4 ms 4.36 ± 5.2 ms 1.12 ± 1.6
Simple Pendulum/OOP/MultipleShooting(100, Tsit5; grid_coarsening = false) 0.0788 ± 0.0083 s 0.0708 ± 0.0091 s 1.11 ± 0.18
Simple Pendulum/OOP/MultipleShooting(100, Tsit5; grid_coarsening = true) 0.121 ± 0.0069 s 0.1 ± 0.003 s 1.2 ± 0.077
Simple Pendulum/OOP/Shooting(Tsit5()) 0.395 ± 0.053 ms 0.382 ± 0.029 ms 1.04 ± 0.16
time_to_load 4.57 ± 0.0071 s 4.36 ± 0.068 s 1.05 ± 0.016
Memory benchmarks
master db60810... master / db60810...
Simple Pendulum/IIP/BoundaryValueDiffEqMIRK.MIRK2() 0.389 M allocs: 0.0442 GB 0.389 M allocs: 0.0442 GB 1
Simple Pendulum/IIP/BoundaryValueDiffEqMIRK.MIRK3() 0.0436 M allocs: 4.87 MB 0.0436 M allocs: 4.87 MB 1
Simple Pendulum/IIP/BoundaryValueDiffEqMIRK.MIRK4() 15.7 k allocs: 1.64 MB 15.7 k allocs: 1.64 MB 1
Simple Pendulum/IIP/BoundaryValueDiffEqMIRK.MIRK5() 22.1 k allocs: 2.03 MB 22.1 k allocs: 2.03 MB 1
Simple Pendulum/IIP/BoundaryValueDiffEqMIRK.MIRK6() 12.8 k allocs: 1.04 MB 12.8 k allocs: 1.04 MB 1
Simple Pendulum/IIP/MultipleShooting(10, Tsit5; grid_coarsening = false) 25.5 k allocs: 1.82 MB 25.5 k allocs: 1.82 MB 1
Simple Pendulum/IIP/MultipleShooting(10, Tsit5; grid_coarsening = true) 0.0491 M allocs: 3.39 MB 0.0491 M allocs: 3.39 MB 1
Simple Pendulum/IIP/MultipleShooting(100, Tsit5; grid_coarsening = false) 0.553 M allocs: 0.0535 GB 0.553 M allocs: 0.0535 GB 1
Simple Pendulum/IIP/MultipleShooting(100, Tsit5; grid_coarsening = true) 0.833 M allocs: 0.0778 GB 0.833 M allocs: 0.0778 GB 1
Simple Pendulum/IIP/Shooting(Tsit5()) 4.63 k allocs: 0.224 MB 4.63 k allocs: 0.224 MB 1
Simple Pendulum/OOP/BoundaryValueDiffEqMIRK.MIRK2() 0.89 M allocs: 0.984 GB 0.89 M allocs: 0.984 GB 1
Simple Pendulum/OOP/BoundaryValueDiffEqMIRK.MIRK3() 0.0932 M allocs: 24.8 MB 0.0932 M allocs: 24.8 MB 1
Simple Pendulum/OOP/BoundaryValueDiffEqMIRK.MIRK4() 0.0324 M allocs: 3.95 MB 0.0324 M allocs: 3.95 MB 1
Simple Pendulum/OOP/BoundaryValueDiffEqMIRK.MIRK5() 0.045 M allocs: 4.98 MB 0.045 M allocs: 4.98 MB 1
Simple Pendulum/OOP/BoundaryValueDiffEqMIRK.MIRK6() 25.3 k allocs: 2.17 MB 25.3 k allocs: 2.17 MB 1
Simple Pendulum/OOP/MultipleShooting(10, Tsit5; grid_coarsening = false) 0.142 M allocs: 10.2 MB 0.142 M allocs: 10.2 MB 1
Simple Pendulum/OOP/MultipleShooting(10, Tsit5; grid_coarsening = true) 0.266 M allocs: 18.7 MB 0.266 M allocs: 18.7 MB 1
Simple Pendulum/OOP/MultipleShooting(100, Tsit5; grid_coarsening = false) 2.52 M allocs: 0.279 GB 2.52 M allocs: 0.279 GB 1
Simple Pendulum/OOP/MultipleShooting(100, Tsit5; grid_coarsening = true) 3.82 M allocs: 0.404 GB 3.82 M allocs: 0.404 GB 1
Simple Pendulum/OOP/Shooting(Tsit5()) 0.0373 M allocs: 1.69 MB 0.0373 M allocs: 1.69 MB 1
time_to_load 0.159 k allocs: 11.2 kB 0.159 k allocs: 11.2 kB 1

The `@test_broken sol4 = solve(...)` at bigfloat_test.jl:68 errored two ways:

1. On master, `@test_broken` was applied to an assignment expression. When
   `solve()` returned (instead of throwing), the assignment evaluated to the
   solution object — a non-Boolean — so the testset errored with "Expression
   evaluated to non-Boolean".

2. The SecondOrderBVProblem with MIRKN4 and BigFloat state now solves correctly
   and returns a successful retcode, so even a well-formed `@test_broken` block
   errors with "Unexpected Pass".

Since the case genuinely passes now, convert it to a real `@test` asserting a
successful retcode.

Verified locally by running test/misc/bigfloat_test.jl on the failing channels:
  - Julia 1.12 ("1"): BigFloat compatibility | 7 | 7 PASS
  - Julia 1.10 (lts):  BigFloat compatibility | 7 | 7 PASS

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@ChrisRackauckas-Claude ChrisRackauckas-Claude force-pushed the fix-bigfloat-test-broken-expression branch from 0d87a97 to 954aa95 Compare June 19, 2026 08:53
@ChrisRackauckas-Claude ChrisRackauckas-Claude changed the title Fix @test_broken on assignment expression in bigfloat_test.jl Fix bigfloat_test.jl MIRKN4 SecondOrderBVProblem test bookkeeping Jun 19, 2026
…alar BVP BoundsError)

The Downgrade Tests - Misc job tests at the dependency floors. The root
Project.toml floor was DifferentiationInterface = "0.7.13", and the
Scalar BVP tests (test/misc/scalar_tests.jl) errored there with

  BoundsError: attempt to access 1-element Vector{ForwardDiff.Dual{...}} at index [2]
  @ DifferentiationInterfaceForwardDiffExt/misc.jl:31

This is a bug in DifferentiationInterface 0.7.13/0.7.14: `overloaded_input_type`
for a `ForwardDiffOneArgJacobianPrep` indexes `[2]` into the dual vector and so
fails when the prepared input has a single element. Single-shooting on a scalar
BVP (u0 isa Number -> 1-element vec) hits exactly this path via
`__single_shooting_jacobian_ode_cache`. The bug is fixed in
DifferentiationInterface 0.7.15.

Verified locally on Julia 1.10 (lts) by pinning DifferentiationInterface to the
new floor 0.7.15 and running test/misc/scalar_tests.jl against the developed
root + sublibraries:

  Scalar BVP tests | Pass Total Time
                   |    4     4  51.2s

(Reproduced the BoundsError on 0.7.13 and 0.7.14; confirmed 0.7.15+ fixes it.)

The sublibrary floors (lib/*/Project.toml) are raised from "0.7" to "0.7.15"
for the same reason and consistency.

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@ChrisRackauckas-Claude ChrisRackauckas-Claude changed the title Fix bigfloat_test.jl MIRKN4 SecondOrderBVProblem test bookkeeping Fix bigfloat Misc/Wrappers failure and raise DifferentiationInterface floor to 0.7.15 (Downgrade Misc) Jun 20, 2026
@ChrisRackauckas ChrisRackauckas marked this pull request as ready for review June 23, 2026 01:18
@ChrisRackauckas ChrisRackauckas merged commit 0c77fed into SciML:master Jun 23, 2026
39 of 52 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants