Skip to content

Master CI: MIRK/Shooting ForwardDiff Dual cache failures and sublibrary downgrade blockers #556

Description

@ChrisRackauckas-Claude

Current master at 906ff8948661c8a917111db3e3e5a4e7b1185ae0 still has several failures after the root QA path bug fixed in #555.

Affected current master jobs

  • Documentation run 29139451376, job 86509810722: https://github.com/SciML/BoundaryValueDiffEq.jl/actions/runs/29139451376/job/86509810722
    • Fails in docs/src/tutorials/extremum.md:14-30, sol = solve(prob, MIRK4(), dt=0.05).
    • Error class: MethodError: no method matching Float64(::ForwardDiff.Dual{...}).
    • Relevant frame: BoundaryValueDiffEqMIRK/src/mirk.jl:338 in __perform_mirk_iteration, called from mirk.jl:293.
  • Downgrade Sublibraries run 29139451449, Shooting job 86509838701: https://github.com/SciML/BoundaryValueDiffEq.jl/actions/runs/29139451449/job/86509838701
    • Fails in lib/BoundaryValueDiffEqShooting/test/Core/basic_problems_tests.jl:4, with the failing test call at line 66.
    • Error class: MethodError: no method matching Float64(::ForwardDiff.Dual{...}).
    • Relevant frames include SciMLBase.reinit!, BoundaryValueDiffEqShooting/src/multiple_shooting.jl:403/406, and __multiple_shooting_mpoint_loss! around multiple_shooting.jl:507.
  • Downgrade Sublibraries MIRK/FIRK jobs 86509838685 and 86509838696 currently fail earlier in resolution. CI reports SciMLBase is restricted by BoundaryValueDiffEqCore to 3.30.0-3.33.1 while an explicit downgrade requirement selects SciMLBase 3.0.0. With the current registry locally, the same class of downgrade resolver blocker appears as LinearSolve@4.2.1 incompatible with MIRK/FIRK LinearSolve = "2.36.2, 3". Raising the local MIRK/FIRK SciMLBase/LinearSolve compat floors allowed MIRK to reach tests, but then MIRK failed with the same Float64(::ForwardDiff.Dual) class in Core/mirk_basic_tests.jl:311 and :434, so this is not just a compat-only fix.

Local reproductions

All commands were run from a clean checkout of 906ff8948661c8a917111db3e3e5a4e7b1185ae0 using a local depot.

Docs example target:

JULIA_DEPOT_PATH=/home/crackauc/sandbox/tmp_20260708_121627_10236/julia_depot: \
JULIA_PKG_SERVER_REGISTRY_PREFERENCE=eager \
/home/crackauc/.juliaup/bin/julia +1.12.6 --project=docs -e 'using Pkg; Pkg.develop(PackageSpec(path=pwd())); Pkg.instantiate(); using BoundaryValueDiffEq, Plots; tspan = (0.0, pi / 2); function simplependulum!(du, u, p, t); θ = u[1]; dθ = u[2]; du[1] = dθ; du[2] = -9.81 * sin(θ); end; function bc!(residual, u, p, t); residual[1] = maxsol(u, (0.0, pi / 2)) - 5.0496477654230745; residual[2] = minsol(u, (0.0, pi / 2)) + 4.8161991710010925; end; prob = BVProblem(simplependulum!, bc!, [pi / 2, pi / 2], tspan); sol = solve(prob, MIRK4(), dt = 0.05); show(sol.retcode)'\n```\n\nObserved: `MethodError: no method matching Float64(::ForwardDiff.Dual{...})` at `BoundaryValueDiffEqMIRK/src/mirk.jl:338`.\n\nShooting downgrade:\n\n```bash\ncd lib/BoundaryValueDiffEqShooting\nJULIA_DEPOT_PATH=/home/crackauc/sandbox/tmp_20260708_121627_10236/julia_depot: \\\nJULIA_PKG_SERVER_REGISTRY_PREFERENCE=eager \\\n/home/crackauc/.juliaup/bin/julia +1.10 --project=. -e 'import Pkg; Pkg.test(; coverage=true, julia_args=["--check-bounds=yes", "--compiled-modules=yes", "--depwarn=yes"], force_latest_compatible_version=false, allow_reresolve=false)'\n```\n\nObserved: same `Float64(::ForwardDiff.Dual{...})` error through `SciMLBase.reinit!` and `BoundaryValueDiffEqShooting/src/multiple_shooting.jl:406`; the local run was interrupted after the failure was captured.\n\nMIRK/FIRK downgrade resolution:\n\n```bash\ncd lib/BoundaryValueDiffEqMIRK  # same shape for FIRK\nJULIA_DEPOT_PATH=/home/crackauc/sandbox/tmp_20260708_121627_10236/julia_depot: \\\nJULIA_PKG_SERVER_REGISTRY_PREFERENCE=eager \\\n/home/crackauc/.juliaup/bin/julia +1.10 --project=. -e 'import Pkg; Pkg.test(; coverage=true, julia_args=["--check-bounds=yes", "--compiled-modules=yes", "--depwarn=yes"], force_latest_compatible_version=false, allow_reresolve=false)'\n```\n\nObserved locally with current registry: `ERROR: empty intersection between LinearSolve@4.2.1 and project compatibility 2.36.2-3`. CI observed the analogous stale-floor conflict for `SciMLBase 3.0.0` vs `BoundaryValueDiffEqCore` requiring `3.30.0-3`.\n\n## History notes\n\n- Documentation was green at `2bfe4d81` (job 85130496535) and failing by `955122b3` (job 85197972873). `955122b3` itself only touched Core verbosity/Project compat, so this may be dependency/compat interaction rather than a direct source edit in MIRK.\n- Downgrade Shooting was green at `2bfe4d81` (job 85130512053) and failing by `955122b3` (job 85201045592).\n- Downgrade MIRK/FIRK failures predate the current head and are present at least as far back as `2bfe4d81` (jobs 85130512057 and 85130512055).\n\n## Suspected root\n\nMIRK and Shooting both appear to reuse Float64-typed caches/integrators while `DifferentiationInterface`/`ForwardDiff` evaluates residuals or losses with Dual-valued states. The immediate conversion failure happens when a Dual is written into a Float64 buffer or cache. A proper fix likely needs type-adaptive cache rebuilding or Dual-compatible work buffers rather than changing docs/tests to avoid AD.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions