Skip to content

Add discontinuity-controller state to DDE integrators - #4071

Merged
ChrisRackauckas merged 3 commits into
SciML:masterfrom
ChrisRackauckas-Claude:agent/fix-delay-disco-integrator-state
Aug 2, 2026
Merged

ChrisRackauckas merged 3 commits into
SciML:masterfrom
ChrisRackauckas-Claude:agent/fix-delay-disco-integrator-state

Conversation

@ChrisRackauckas-Claude

@ChrisRackauckas-Claude ChrisRackauckas-Claude commented Jul 29, 2026 •

Copy link
Copy Markdown
Member

Ignore this PR until it has been reviewed by @ChrisRackauckas.

Summary

  • add the discontinuity-controller state used by OrdinaryDiffEqCore to DDEIntegrator
  • initialize and reset that state through construction and reinit!
  • cover construction, stepping, and reinitialization in the DelayDiffEq interface tests
  • require OrdinaryDiffEqCore 4.12 and bump DelayDiffEq to 6.1.2

Root cause

OrdinaryDiffEqCore's shared DISCO/controller code assumes that compatible integrators carry is_disco_step and disco_checkpoint. ODEIntegrator gained that state as the DISCO implementation evolved, but DDEIntegrator did not.

A fixed-dependency parent/child check and git bisect identify 408a7a30fe0989a55b446240a18fb2a8c5c30993 (disco optimizations; parent c538565b25ff19e661e5bf788fe1953a154d64e9) as the first incompatible shared-controller change. On current master, the missing state is exposed as:

FieldError: type DDEIntegrator has no field is_disco_step

The new disco_checkpoint is initialized with zero(t0) to preserve the runtime time type, and reinit! clears both fields so reused integrators do not retain transient state.

Version boundary

OrdinaryDiffEqCore 4.12 is the first monorepo release line containing the corresponding controller behavior, so DelayDiffEq now requires 4.12 instead of allowing older Core 4.x releases.

Local verification

On an untouched a7080c6f6d checkout:

  • GROUP=DelayDiffEq_Interface julia +1.12 --project -e 'using Pkg; Pkg.test()' — fails in the mass-matrix tests with the missing-field error above

On this branch at bd63fdaa27:

  • GROUP=DelayDiffEq_Interface julia +1.12 --project -e 'using Pkg; Pkg.test()' — pass, including mass-matrix 7/7 and the new state tests
  • GROUP=DelayDiffEq_Integrators julia +1.12 --project -e 'using Pkg; Pkg.test()' — pass (the existing 36 broken SDIRK tests remain broken)
  • GROUP=DelayDiffEq_QA julia +1.12 --project -e 'using Pkg; Pkg.test()' — 19/19 pass
  • Runic over every changed Julia file — pass
  • git diff --check — pass

@ChrisRackauckas
ChrisRackauckas marked this pull request as ready for review July 29, 2026 21:33
@ChrisRackauckas

Copy link
Copy Markdown
Member

This needs a minimum version on ordinarydiffeqcore for when it was added there

@ChrisRackauckas-Claude

Copy link
Copy Markdown
Member Author

CI audit after completion:

  • All 13 failing DelayDiffEq matrix jobs stopped before test execution: 4 failed while developing in-repo sources and 9 failed in julia-buildpkg. Representative LTS and Julia 1 logs show the same SciMLBase resolver conflict: registered/in-tree packages constrain SciMLBase to 3.39 while OrdinaryDiffEqNonlinearSolve 2.6.0 requests 3.40. Restore SciMLBase 3.39 compatibility for owner imports #4066 is the focused compatibility prerequisite for that conflict.
  • Across the root, sublibrary, downgrade-sublibrary, and downstream workflows, the 125 failing jobs all stopped in setup, resolution, build, downgrade resolution, or downstream loading; none reached a test body. The documentation job stopped on the same SciMLBase resolution conflict.
  • Runic reported only lib/OrdinaryDiffEqCore/src/disco.jl, lib/OrdinaryDiffEqCore/src/integrators/controllers.jl, and test/Integrators_I/disco_tests.jl, which are the pre-existing formatting debt isolated in Run Runic on the disco-optimizations files #4064. All five files changed by this PR were marked formatted by the CI Runic scan.

Local validation on the exact PR commit with a locally resolved SciMLBase 3.40.1 environment did execute the official DelayDiffEq GROUP=Interface suite: discontinuities 48/48, mass matrix 7/7, units 21/21, and multi-algorithm 28/28 passed. No assertions were skipped or changed.

@ChrisRackauckas-Claude
ChrisRackauckas-Claude force-pushed the agent/fix-delay-disco-integrator-state branch from 947469d to e13f39a Compare July 29, 2026 23:28
@ChrisRackauckas-Claude

Copy link
Copy Markdown
Member Author

Addressed in e13f39aa3b: DelayDiffEq now requires OrdinaryDiffEqCore = "4.12", the first release line containing the shared DISCO controller behavior used by these fields. General currently ends at Core 4.11.0.

I rebased the branch onto current master and reran the official DelayDiffEq GROUP=Interface package test with local SciMLBase 3.40.1/Core 4.12.0. It passed, including discontinuities 48/48, mass matrix 7/7, Unitful 21/21, and multi-algorithm 28/28. The PR dependency note and validation section are updated.

The shared autonomous-discontinuity controller reads is_disco_step and disco_checkpoint, but DDEIntegrator did not carry either field. Initialize the state from the runtime time value, reset it during reinit!, and cover discontinuity-enabled and unitful public solver paths.

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
The autonomous-discontinuity controller state used by DDEIntegrator ships with OrdinaryDiffEqCore 4.12. Prevent DelayDiffEq 6.1 from resolving against an older Core release that does not provide the required controller behavior.

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
@ChrisRackauckas-Claude
ChrisRackauckas-Claude force-pushed the agent/fix-delay-disco-integrator-state branch from e13f39a to bd63fda Compare August 2, 2026 14:49
@ChrisRackauckas-Claude
ChrisRackauckas-Claude marked this pull request as draft August 2, 2026 15:02
@ChrisRackauckas
ChrisRackauckas marked this pull request as ready for review August 2, 2026 22:08
@ChrisRackauckas
ChrisRackauckas merged commit b8b4619 into SciML:master Aug 2, 2026
128 of 139 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