Fix deprecated ODEProblem API calls in documentation#4000
Conversation
Updated documentation to use the new ODEProblem API that was introduced to replace the deprecated 4-argument signature. Changes include: - Changed ODEProblem(sys, u0, tspan, p) to ODEProblem(sys, [u0; p], tspan) - Changed ODEProblem(sys, [], tspan, []) to ODEProblem(sys, [], tspan) This fixes the deprecation warnings in the "Copy-Pastable Simplified Example" and other tutorial sections. Files modified: - docs/src/tutorials/ode_modeling.md: Line 39 - docs/src/tutorials/programmatically_generating.md: Line 52 - docs/src/basics/Events.md: Lines 421, 442 - docs/src/basics/Composition.md: Line 60 Fixes SciML#3996 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Implementation ProcessDiscovery Phase
Changes MadeUpdated 4 documentation files with 5 total changes:
Notes
Next Steps
|
|
⎿ Setting 2-hour timer for CI completion as per CLAUDE.md instructions... Based on analysis of recent PRs (e.g., #3997), typical CI runtime is 1-2 hours for full test suite. |
Format Check Status UpdateThe Format Check has failed, but this appears to be expected behavior based on recent PRs:
Pattern observed:
Since only markdown files were modified in this PR (no Julia source code), and recent merged PRs show the same pattern, this format check failure does not appear to be a blocker for merging. The main CI tests (build and test suite) are still running. |
😅 but unrelated. |
Summary
This PR fixes the deprecated
ODEProblemAPI calls in the documentation to use the new API that was introduced in recent versions of ModelingToolkit.jl.Changes
Updated the following documentation files to replace the deprecated 4-argument
ODEProblem(sys, u0, tspan, p)signature with the new 3-argument signature where initial conditions and parameters are merged:docs/src/tutorials/ode_modeling.md (Line 39)
ODEProblem(fol, [], (0.0, 10.0), [])ODEProblem(fol, [], (0.0, 10.0))docs/src/tutorials/programmatically_generating.md (Line 52)
ODEProblem(fol, [], (0.0, 10.0), [])ODEProblem(fol, [], (0.0, 10.0))docs/src/basics/Events.md (Lines 421, 442)
ODEProblem(sys, [x => 0.0], (0.0, 2pi), [c => 1.0])ODEProblem(sys, [x => 0.0, c => 1.0], (0.0, 2pi))docs/src/basics/Composition.md (Line 60)
ODEProblem(simplified_sys, x0, (0.0, 100.0), p)ODEProblem(simplified_sys, [x0; p], (0.0, 100.0))Impact
These changes eliminate deprecation warnings that users encounter when running the "Copy-Pastable Simplified Example" and other tutorial code from the documentation. The updated examples now use the current recommended API.
Test Plan
Fixes #3996
🤖 Generated with Claude Code