Skip to content

Commit 4bbcb87

Browse files
ChrisRackauckas-ClaudeChrisRackauckasclaude
authored
docs CI: re-clone StochasticDiffEq fresh in env setup (complete #870 fix) (#872)
* docs: build against released (registry) OrdinaryDiffEq/StochasticDiffEq Drop the `Pkg.develop` of OrdinaryDiffEq and StochasticDiffEq in the docs build (and the env-setup re-clone dance), resolving them — and all the solver subpackages — from the registry at their released versions instead of master. Why: - StochasticDiffEq is a subpackage of the OrdinaryDiffEq.jl monorepo as of v7 (registry `repo = OrdinaryDiffEq.jl`, `subdir = lib/StochasticDiffEq`), so `Pkg.develop("StochasticDiffEq")` re-cloned the same monorepo and the stale leftover checkout of the old `SciML/StochasticDiffEq.jl` repo (6.100.0) broke resolution against the docs `[compat] = "7"`: ERROR: empty intersection between StochasticDiffEq@6.100.0 and compat 7 - `Pkg.develop`ing the monorepo master also risks version skew: the dev'd master meta-package's subpackage [compat] must be satisfiable by the *registered* subpackages (sources don't propagate to the docs project), which breaks whenever master races ahead of the registry. - The released packages already ship their `docs/` (OrdinaryDiffEq 7.0.0's tarball includes `docs/` with pages.jl + src + common_*_steps.jl), so the API docs can be copied from the installed stable packages with no dev checkout. Net effect: the stable docs reflect released versions, the stale-checkout failure mode and the monorepo skew are both gone, and env-setup is just instantiate. (StochasticDiffEq's registered tarball does not yet ship `docs/` — its docs/ needs to be migrated into lib/StochasticDiffEq in the monorepo; until then the "StochasticDiffEq.jl API" section stays dropped, as added in #869.) Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com> Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> * docs: source EnsembleProblem from SciMLBase in the low_dep example Building against the stable release (previous commit) surfaced that OrdinaryDiffEq 7.0.0 does not re-export `EnsembleProblem` (master does), so the low-dependency example's `ODE.EnsembleProblem` was an `UndefVarError`. Source it from SciMLBase, which defines it — consistent with this page's own point that "you will always need SciMLBase.jl, since it defines all of the fundamental types." This is the only docs `@example` affected: across all of docs/src the only OrdinaryDiffEq-exported-on-master-but-not-7.0.0 symbol used via the alias is `EnsembleProblem`, here. Verified locally on the released stack (OrdinaryDiffEq 7.0.0 + OrdinaryDiffEqLowOrderRK + DiffEqCallbacks + SciMLBase): the example's ensemble solve runs successfully. Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com> Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> --------- Co-authored-by: ChrisRackauckas-Claude <accounts@chrisrackauckas.com> Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent 94ae41b commit 4bbcb87

3 files changed

Lines changed: 7 additions & 13 deletions

File tree

.github/workflows/Documentation.yml

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,6 @@ jobs:
3131
using Pkg
3232
Pkg.develop(PackageSpec(path=pwd()))
3333
Pkg.instantiate()
34-
println("--- Adding OrdinaryDiffEq from master")
35-
# Drop any stale dev checkout a previous run left in ~/.julia/dev so the
36-
# current master is cloned fresh; a stale checkout can pin an old version
37-
# that conflicts with the docs [compat] (e.g. OrdinaryDiffEq 6.x vs "7").
38-
let p = joinpath(Pkg.devdir(), "OrdinaryDiffEq")
39-
isdir(p) && rm(p; recursive = true, force = true)
40-
end
41-
Pkg.develop("OrdinaryDiffEq")
4234
env:
4335
DATADEPS_ALWAYS_ACCEPT: true
4436
JULIA_PKG_PRECOMPILE_AUTO: 0

docs/make.jl

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,11 @@ import ODEProblemLibrary,
2525
SDEProblemLibrary, DDEProblemLibrary, DAEProblemLibrary, BVProblemLibrary
2626
using Sundials, DASKR, LSODA, DASSL, SimpleDiffEq, ODEInterfaceDiffEq
2727

28-
# Use development versions for API documentation
29-
import Pkg
30-
Pkg.develop("OrdinaryDiffEq")
31-
Pkg.develop("StochasticDiffEq")
28+
# OrdinaryDiffEq, StochasticDiffEq and the solver subpackages are resolved from the
29+
# registry at their released versions — their docs/ ship in the released packages,
30+
# so the API docs below are copied from the installed (stable) packages with no
31+
# Pkg.develop of master (which would pin the docs to unreleased code and risk
32+
# monorepo version skew against the registered subpackages).
3233

3334
cp("./docs/Manifest.toml", "./docs/src/assets/Manifest.toml", force = true)
3435
cp("./docs/Project.toml", "./docs/src/assets/Project.toml", force = true)

docs/src/features/low_dep.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,7 @@ the old `using DifferentialEquations` shape:
121121
import OrdinaryDiffEq as ODE
122122
import OrdinaryDiffEqLowOrderRK as ODELow # Euler
123123
import DiffEqCallbacks as CB # ProbIntsUncertainty
124+
import SciMLBase # EnsembleProblem
124125
function fitz(du, u, p, t)
125126
V, R = u
126127
a, b, c = p
@@ -132,7 +133,7 @@ tspan = (0.0, 20.0)
132133
p = (0.2, 0.2, 3.0)
133134
prob = ODE.ODEProblem(fitz, u0, tspan, p)
134135
cb = CB.ProbIntsUncertainty(0.2, 1)
135-
ensemble_prob = ODE.EnsembleProblem(prob)
136+
ensemble_prob = SciMLBase.EnsembleProblem(prob)
136137
sim = ODE.solve(ensemble_prob, ODELow.Euler(), trajectories = 100, callback = cb, dt = 1 / 10)
137138
```
138139

0 commit comments

Comments
 (0)