Skip to content

Split AD tests into a dedicated off-downgrade group (Mooncake 0.5 needs >= 1.10.8)#617

Merged
ChrisRackauckas merged 3 commits into
SciML:masterfrom
ChrisRackauckas-Claude:fix-downgrade-mooncake-julia-floor
Jun 22, 2026
Merged

Split AD tests into a dedicated off-downgrade group (Mooncake 0.5 needs >= 1.10.8)#617
ChrisRackauckas merged 3 commits into
SciML:masterfrom
ChrisRackauckas-Claude:fix-downgrade-mooncake-julia-floor

Conversation

@ChrisRackauckas-Claude

@ChrisRackauckas-Claude ChrisRackauckas-Claude commented Jun 19, 2026

Copy link
Copy Markdown
Contributor

Problem

The Downgrade (Core) job is red on master with:

[ Info: Running resolver on merged project (extras) for . with --min=@deps
ERROR: LoadError: Unsatisfiable

Root cause

The SciML downgrade workflow (SciML/.github downgrade.yml) builds and tests with project: "@." (the repo root) and runs the resolver with --min=@deps, minimizing every direct dependency and the Julia version to its floor. With the default lts channel the Julia floor is 1.10.0. The GROUP env var only selects which tests run; the resolver still resolves the entire root [targets].test set.

Mooncake 0.5.0 (the floor of Mooncake = "0.5", used by RecursiveArrayToolsMooncakeExt) declares julia = "1.10.8 - 1.10, 1.11.6 - 1". So when Mooncake is in the root test target and the resolver minimizes Julia to 1.10.0, Mooncake is uninstallable -> Unsatisfiable.

Fix: split AD into a dedicated off-downgrade group

Instead of pinning the downgrade Julia version (the prior approach on this branch), this removes the AD backends from the downgrade resolver at the source, following the same pattern as FunctionWrappersWrappers #59:

  • The AD test files (adjoints.jl: Zygote/ForwardDiff/ReverseDiff; mooncake.jl: Mooncake) move from test/Core/ into a new dedicated AD group with its own sub-environment test/AD/Project.toml (with [sources] RecursiveArrayTools = {path = "../.."}, modeled on the existing NoPre group).
  • test/test_groups.toml gains an [AD] group with in_all = false. The Downgrade.yml matrix runs only Core, so AD is never fed to the downgrade resolver.
  • The AD backends (Mooncake/Zygote/ForwardDiff/ReverseDiff) are removed from the root [extras] and [targets].test. They remain [weakdeps] + [compat] for the extensions.
  • Downgrade.yml is reverted to master (the julia-version: "1.11" pin is dropped).
  • The AD tests still run, in their own CI group on a normal Julia (lts/1).
  • The tupe -> type spellcheck fix is kept.

This dodges the Resolver<->Mooncake downgrade wall (StefanKarpinski/Resolver.jl#24 / the Mooncake >= 1.10.8 floor) by keeping Mooncake out of the resolution the downgrade lane performs, rather than working around it with a Julia-version pin.

Local verification

Faithful reproduction on a real Julia 1.10.0 binary (the exact patch the downgrade resolver minimizes to), resolving the merged root-test env with every non-stdlib dep pinned to its [compat] floor (=<floor>, mirroring julia-downgrade-compat, stdlibs skipped):

master  (Mooncake in [targets].test):
  Unsatisfiable requirements detected for package Mooncake [da2b9cff]:
   restricted to versions 0.5.0 by DowngradeProbe ... leaving only versions: 0.5.0
   restricted by julia compatibility requirements to versions: 0.3.0-0.4.137 or uninstalled -- no versions left
  => reproduces the master red

this PR (Mooncake removed from [targets].test):
  RESOLVED CLEANLY

And the AD group still loads and runs Mooncake on a normal Julia (1.10.11, the lts patch >= 1.10.8):

GROUP=AD  Pkg.test("RecursiveArrayTools")  ->  RecursiveArrayTools tests passed
  (RecursiveArrayToolsMooncakeExt precompiled, Mooncake v0.5.32; AD group 26/26 pass)

Please ignore until reviewed by @ChrisRackauckas.

ChrisRackauckas and others added 3 commits June 19, 2026 06:11
The Downgrade (Core) job fails on master with `ERROR: LoadError:
Unsatisfiable`. The downgrade resolver runs `--min=@deps` and minimizes
the Julia version to the floor implied by the workflow's Julia channel.
With the default `lts` channel that floor is 1.10.0, but every Mooncake
0.5.x release (used by RecursiveArrayToolsMooncakeExt) declares
`julia = "1.10.8 - 1.10, 1.11.6 - 1"`, so no Mooncake version is
installable at 1.10.0 and Mooncake gets no candidate version.

Reproduced locally with the actual julia-actions/julia-downgrade-compat
downgrade.jl driver against a checkout of this repo:
  julia_version=1.10 -> ERROR: LoadError: Unsatisfiable
  julia_version=1.11 -> "Successfully resolved minimal versions"

Pin the downgrade job to Julia 1.11 (the same approach OrdinaryDiffEq.jl
uses), where 1.10.8+ is satisfied and every declared floor is jointly
installable. Core support for Julia 1.10 is unchanged and is still
exercised by the normal lts test legs; this only affects which Julia the
downgrade resolver minimizes against.

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Fixes the Spell Check with Typos CI failure flagging `tupe` in
src/named_array_partition.jl.

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Move the Mooncake/Zygote/ForwardDiff/ReverseDiff test files out of the root
Core group and into a dedicated `AD` group with its own sub-environment
(test/AD/Project.toml, [sources] RecursiveArrayTools = path), modeled on the
NoPre group. The AD group is marked in_all = false and is not run in the
Downgrade lane (which runs only Core), so its deps are never fed to the
downgrade resolver.

This removes Mooncake (and the other AD backends) from the root [targets].test
set. The downgrade workflow builds/tests with project: "@." (the repo root) and
minimizes every direct dep plus the Julia version to the 1.10.0 LTS floor;
Mooncake 0.5 requires Julia >= 1.10.8, so at the 1.10.0 floor it was
Unsatisfiable. With Mooncake out of the root test target the resolver no longer
sees it, fixing the wall at the source instead of pinning the downgrade Julia
version.

This reverts the Downgrade.yml julia-version: "1.11" approach from this branch
in favor of the AD split. Mooncake/Zygote/ForwardDiff/ReverseDiff remain as
[weakdeps]+[compat] for the AD extensions; the AD tests still run (in their own
group on a normal Julia). The tupe->type spellcheck fix is kept.

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@ChrisRackauckas-Claude ChrisRackauckas-Claude changed the title Run downgrade CI on Julia 1.11 (Mooncake 0.5 needs >= 1.10.8) Split AD tests into a dedicated off-downgrade group (Mooncake 0.5 needs >= 1.10.8) Jun 21, 2026
@ChrisRackauckas ChrisRackauckas marked this pull request as ready for review June 22, 2026 12:39
@ChrisRackauckas ChrisRackauckas merged commit 003cbd3 into SciML:master Jun 22, 2026
34 of 43 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