Repository navigation
Fix StochasticDiffEqHighOrder SRACache to extend SciMLBase cache hooks - #4718
Merged
ChrisRackauckas merged 2 commits intoOct 4, 2026
Merged
ChrisRackauckas merged 2 commits into
ChrisRackauckas merged 2 commits into
Conversation
SRACache's u_cache/du_cache/user_cache were defining HighOrder-local functions instead of extending DiffEqBase/SciMLBase, so resize! never dispatched to them. Import the owner functions like StochasticDiffEqImplicit. Co-Authored-By: Chris Rackauckas <[email protected]> Co-Authored-By: Cursor Agent <[email protected]> Agent-Harness: Cursor Agent CLI 2026.10.01-14929f9 Agent-Model: auto Agent-Session: local session, transcript at /home/crackauc/sandbox/goals/qa-hygiene/jobs/sde-qa/log.txt on amdci2
This was referenced Oct 2, 2026
Import SciMLBase's u_cache/du_cache/user_cache (owner path), drop the false resize! rationale and non-discriminating resize assertions, and dedupe chi2 in SRACache's du_cache. Co-Authored-By: Chris Rackauckas <[email protected]> Co-Authored-By: Cursor Agent <[email protected]> Agent-Harness: Cursor Agent CLI 2026.10.01-14929f9 Agent-Model: auto Agent-Session: local session, transcript at /home/crackauc/sandbox/goals/qa-hygiene/jobs/sde-qa/log.txt on amdci2
ChrisRackauckas
marked this pull request as ready for review
October 4, 2026 14:22
ChrisRackauckas
referenced
this pull request
Oct 14, 2026
…inaryDiffEqBDF, OrdinaryDiffEqExplicitRK, OrdinaryDiffEqFIRK, OrdinaryDiffEqFeagin, OrdinaryDiffEqHighOrderRK, OrdinaryDiffEqPDIRK, OrdinaryDiffEqRKN, OrdinaryDiffEqSDIRK, StochasticDiffEqHighOrder, StochasticDiffEqLowOrder, and StochasticDiffEqMilstein for release (#4871) Agent-Harness: Devin CLI 3000.11.3 Agent-Model: Fusion (Claude Opus 5.5 Medium + SWE-2 Medium) Agent-Session: local transcript ~/.local/share/devin/cli/transcripts/flash-hour.json Co-authored-by: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.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.
Summary
StochasticDiffEqHighOrder'sSRACachedefined localu_cache/du_cache/user_cacheinstead of extending SciMLBase's exported functions. That shadowed the SciMLBase bindings inside HighOrder and caused an umbrella reexport clash / Aqua undefined-exports whenStochasticDiffEq@reexports HighOrder alongside DiffEqBase.This PR imports
SciMLBase: u_cache, du_cache, user_cache(SciMLBase is a direct dep and the owner; DiffEqBase only forwards them), so the methods extend the shared functions. It also dedupes a duplicatedc.chi2entry indu_cache(::SRACache).Not a resize! fix. Nothing in the SDE path calls the cache-level
u_cache/du_cache/user_cachehooks;resize!walksfull_cachethenresize_non_user_cache!. This change does not makeresize!reach previously skipped SRACache buffers.Pre-existing:
SRA+resize!is separately broken (H0stage buffers not resized) — tracked in #4720. Not fixed here.Verification
cd lib/StochasticDiffEqHighOrder && GROUP=Core julia --project -e 'using Pkg; Pkg.test()'Before (master src + this test):
After (this branch):
The test keeps only discriminating checks:
=== SciMLBaseand methods exist forSRACache(plus non-emptydu_cache/user_cachecontents). Noresize!assertions.Not verified
H0/H1stage-buffer resize for SRA/SRI/weak families).Please ignore this draft until reviewed by @ChrisRackauckas.
Risk assessment
resize!code path.lib/StochasticDiffEqHighOrdernamespace binding for the three cache accessors; umbrella reexport consistency.Harness: Cursor Agent CLI 2026.10.01-14929f9; model: auto; transcript: /home/crackauc/sandbox/goals/qa-hygiene/jobs/sde-qa/log.txt
Risk assessment
Risk: low
Blast radius: Limited to
lib/StochasticDiffEqHighOrder. Three methods onSRACache(u_cache,du_cache,user_cache) now extend SciMLBase's exported functions. Before this PR they were HighOrder-local functions that hid the SciMLBase names. Anyone callingSciMLBase.du_cache(::SRACache)(and the other two) used to get aMethodErrorand now gets the buffer tuples. No code in the SDE path calls these on a cache: StochasticDiffEqCore's integrator interface only usesfull_cacheandresize_non_user_cache!, so solver andresize!behavior don't change. Removing the duplicatec.chi2fromdu_cacheonly changes a tuple that nothing reads.Evidence: Four checks fail on head
ff56dcb. All four fail with the same error on master4a5c0e71b3ande70688847a, so they are pre-existing, not regressions:SciMLSensitivity.jl/Core1fails with MooncakeMethodError: no constructors have been defined for Anyatconcrete_solve_derivatives.jl:451.tests / GPU (julia 1)fails with 3 QNDFmass=diag_cufailures atdae_tests.jl:481(170 passed, 3 failed).downgrade-sublibraries / test (lib/DiffEqBase)fails athigh_level_solve.jl:94/98.downgrade-sublibraries / test (lib/OrdinaryDiffEqDifferentiation)errors in "ScalarOperator mass matrix".Everything that covers this change passes: StochasticDiffEqHighOrder Core on Julia 1, lts and pre; StochasticDiffEqHighOrder QA; every StochasticDiffEq group including QA and StaticAnalysis; downgrade for StochasticDiffEqHighOrder; Runic, Typos and Docs.
Other checks:
u_cache,du_cacheanduser_cacheare exported by SciMLBase, a direct dependency. HighOrder never exported these names, so there's no SemVer impact and no version bump is needed.SRACachedocstrings now attach to SciMLBase's functions, so they will show up in?SciMLBase.du_cache. The description also says the change fixes an "Aqua undefined-exports" problem, but QA passes on master and the PR shows no failing QA run from before the change. That part of the motivation is unverified, though it doesn't affect the code.Independent review: Devin CLI (Mac) / fusion-claude-opus-5-5-high-sidekick-swe-2-medium rated it low, high confidence: it's an import-only fix that makes the three methods extend the right exported SciMLBase functions, nothing in the solver path calls them on a cache, and every failing CI check fails the same way on master.
Merge: auto-merge candidate. The content is fine, but the PR is still a draft whose body says "Please ignore this draft until reviewed by @ChrisRackauckas", so it has to be marked ready first. Its attribution line says
model: autorather than an exact model ID.🤖 Risk assessment posted by an AI agent (fleet master) — harness: Devin CLI (Mac) / fusion-claude-opus-5-5-high-sidekick-swe-2-medium; dispatched by Devin CLI 3000.11.3 (Mac) fleet-master caretaker, model Fusion (claude-opus-5-5 medium + swe-2 medium)
Conversation: local transcript ~/.local/share/devin/cli/transcripts/speckle-whale.json (Chris's Mac)