File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -245,7 +245,20 @@ $_julia_cmd --project=. -e 'using Pkg; Pkg.precompile(); Pkg.activate("examples"
245245Pkg.activate("examples_cp"); Pkg.precompile(); Pkg.activate("test"); Pkg.precompile();
246246@info "Precompilation complete."'
247247$_julia_cmd --project=examples -e ' using GLMakie, VortexStepMethod; @info "GLMakie extension ready."'
248- $_julia_cmd -t1 --project=examples_cp -e ' using ControlPlots, VortexStepMethod; @info "ControlPlots extension ready."'
248+ # Julia's @load_preference bakes the CondaPkg backend into the precompiled image
249+ # at compile time. If the image was compiled before LocalPreferences.toml was
250+ # written (e.g. by a previous install_controlplots run), the baked-in value may
251+ # be stale. JULIA_CONDAPKG_BACKEND is always read at runtime and reliably
252+ # overrides the cached value, so we read the preference from the file and
253+ # forward it as an env var.
254+ _cp_lp=" examples_cp/LocalPreferences.toml"
255+ if grep -q ' backend = "Null"' " $_cp_lp " 2> /dev/null; then
256+ JULIA_CONDAPKG_BACKEND=Null $_julia_cmd -t1 --project=examples_cp \
257+ -e ' using ControlPlots, VortexStepMethod; @info "ControlPlots extension ready."'
258+ else
259+ $_julia_cmd -t1 --project=examples_cp \
260+ -e ' using ControlPlots, VortexStepMethod; @info "ControlPlots extension ready."'
261+ fi
249262$_julia_cmd --project=. -e ' using Pkg; Pkg.test(test_args=["settings/test_settings.jl"]);
250263@info "Minimal test smoke check complete."'
251264
You can’t perform that action at this time.
0 commit comments