Skip to content

QA: run_qa v1.6 form + ExplicitImports#467

Merged
ChrisRackauckas merged 4 commits into
SciML:masterfrom
ChrisRackauckas-Claude:qa-run-qa-v16-explicit-imports
Jul 3, 2026
Merged

QA: run_qa v1.6 form + ExplicitImports#467
ChrisRackauckas merged 4 commits into
SciML:masterfrom
ChrisRackauckas-Claude:qa-run-qa-v16-explicit-imports

Conversation

@ChrisRackauckas-Claude

Copy link
Copy Markdown
Contributor

Please ignore until reviewed by @ChrisRackauckas.

Brings DiffEqGPU's QA group onto the SciMLTesting run_qa v1.6 form with ExplicitImports enabled (scratch conversion: there was no run_qa-based QA before — only the bespoke @test_opt type-stability suite, which is kept).

What changed

  • New test/qa/qa.jl calling run_qa(DiffEqGPU; explicit_imports = true, ...). Aqua + ExplicitImports come from SciMLTesting's own deps; using JET turns on the JET check (weakdep extension). So the QA group now runs, on the lts and 1 matrix versions:
    • Aqua.test_all (all sub-checks),
    • JET.test_package (report-clean on both versions: 0 reports — run as a hard check), and
    • ExplicitImports' six standard + public-API checks.
  • test/runtests.jl: the GROUP=="QA" branch now also includes qa/qa.jl and is made terminal (exit()). Previously it fell through into the GPU-backend testsets, which error on the CPU-only QA lane (the QA lane was red on master for this reason).
  • test/qa/Project.toml: add SciMLTesting (compat "1.6") and Aqua (the ambiguities sub-check needs Aqua a direct dep); ExplicitImports stays transitive via SciMLTesting. JET/ForwardDiff/SciMLBase/StaticArrays/Test retained (the bespoke jet_tests.jl uses them).

ExplicitImports findings (6 checks)

  • no_stale_explicit_imports: FIXED — dropped the unused arithmetic_closure import in src/DiffEqGPU.jl (no method/use site, not extended downstream).
  • no_implicit_imports: BROKEN via ei_broken = (:no_implicit_imports,) — ~75 names implicitly imported through heavy using of KernelAbstractions / SciMLBase / DiffEqBase / StaticArrays / ...; making them explicit is a large refactor. Tracked in QA: ExplicitImports no_implicit_imports — make implicit imports explicit #466 (auto-flags an Unexpected Pass once fixed).
  • all_explicit_imports_via_owners, all_qualified_accesses_via_owners, all_qualified_accesses_are_public, all_explicit_imports_are_public: IGNORED per-check, listing upstream packages' non-owner / non-public names (SciMLBase, DiffEqBase, ForwardDiff, LinearSolve, SimpleDiffEq, StaticArrays internals, Adapt, Random, Base/Core), documented by source package in qa.jl. These go public as those base libraries declare public.

Aqua finding (FIXED, not disabled)

deps_compat flagged missing [compat] for the stdlib deps Distributed/LinearAlgebra/Random and the [extras]-only Test/pocl_jll. Added those [compat] entries to the root Project.toml, so no Aqua sub-check is disabled (no aqua_broken).

Local verification (released SciMLTesting 1.6.0, Pkg resolves it; no dev-from-branch)

Pkg.test() with GROUP=QA:

Quality Assurance   | 17 Pass, 1 Broken, 0 Fail, 0 Error   (lts = 1.10.11 and 1 = 1.12.6)
JET static analysis | 75 Pass
Testing DiffEqGPU tests passed

The single Broken is the tracked no_implicit_imports (#466). GPU testsets correctly do not run on the QA lane.

🤖 Generated with Claude Code

ChrisRackauckas and others added 3 commits June 25, 2026 07:46
Add a SciMLTesting `run_qa`-based QA group (test/qa/qa.jl) with ExplicitImports
enabled, replacing the bare hand-rolled QA env that previously only ran the
bespoke `@test_opt` type-stability suite (kept as test/jet_tests.jl).

The QA group now runs, on the `lts` and `1` matrix versions:
  * Aqua.test_all (all sub-checks),
  * JET.test_package (report-clean: 0 reports, run as a hard check), and
  * ExplicitImports' six standard + public-API checks.

ExplicitImports findings:
  * no_stale_explicit_imports: FIXED — dropped the unused `arithmetic_closure`
    import (no method/use site, not extended downstream).
  * no_implicit_imports: BROKEN via `ei_broken = (:no_implicit_imports,)` —
    ~75 names implicitly imported through heavy `using` of KernelAbstractions /
    SciMLBase / DiffEqBase / StaticArrays / ...; making them explicit is a large
    refactor. Tracked in SciML#466 (auto-flags Unexpected Pass once fixed).
  * owners + are-public checks: per-check ignore-lists for upstream packages'
    non-owner / non-public names (SciMLBase, DiffEqBase, ForwardDiff, LinearSolve,
    SimpleDiffEq, StaticArrays internals, ...), documented by source in qa.jl.

Aqua deps_compat finding FIXED in Project.toml: added the missing [compat]
entries for the stdlib deps Distributed/LinearAlgebra/Random and the
[extras]-only Test/pocl_jll (check_extras), so no Aqua sub-check is disabled.

Also make the GROUP=="QA" branch of runtests.jl terminal (`exit()`): it
previously fell through into the GPU-backend testsets, which error on the
CPU-only QA lane.

test/qa/Project.toml: add SciMLTesting (compat "1.6") and Aqua (the ambiguities
sub-check needs Aqua a direct dep); ExplicitImports stays transitive via
SciMLTesting.

Verified locally vs released SciMLTesting 1.6.0 (Pkg resolves it):
  Quality Assurance | 17 Pass, 1 Broken, 0 Fail/Error  (lts = 1.10.11 and 1 = 1.12.6)
  JET static analysis | 75 Pass

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…releases

SciMLTesting 1.7.0 now runs check_all_qualified_accesses_are_public and
check_all_explicit_imports_are_public only on Julia >= 1.11 (skipped on lts),
and several base libs declared more names public (SciMLBase 3.24.0 etc.).

Removed 11 now-redundant entries from all_qualified_accesses_are_public:
AbstractDEAlgorithm, AbstractODEProblem, build_solution, successful_retcode
(now public in SciMLBase 3.24.0); Default, Success, T, Terminated (no longer
accessed); Fix2 (public in Base); adapt_structure (Adapt), seed! (Random)
(no longer flagged against registered releases).

Bumped qa env compat: SciMLTesting "1.6"->"1.7", SciMLBase "3.1"->"3.24".

Verified against registered releases (no dev): Julia 1.12 QA group 17 pass /
1 broken / 0 fail (public-API checks pass with the surviving minimal
ignore-list); Julia 1.10 QA group 15 pass / 1 broken / 0 fail (public-API
checks skipped on lts). The surviving ignores name genuine internals of
SciMLBase/DiffEqBase/ForwardDiff/LinearSolve/SimpleDiffEq/LinearAlgebra/Core
that are still non-public in the registered releases.

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…I ignores

After the base-library make-public releases (SciMLBase 3.27.0, DiffEqBase 7.6.0,
SciMLTesting 1.7.0), finish the public-API ExplicitImports cleanup:

- Caller-migrate `DiffEqBase.X` -> `SciMLBase.X` for the SciMLBase-owned names
  (AbstractODEAlgorithm, AbstractSDEAlgorithm, AbstractODEIntegrator, has_jac,
  has_tgrad) now that SciMLBase is the owner. `using SciMLBase` is already in the
  module and SciMLBase is already a [deps] entry. This makes
  `all_qualified_accesses_via_owners` pass for those names via the owner.
- Bump the QA env SciMLBase compat floor to 3.27 so the released make-public
  versions are admitted.
- Empty and re-derive the two public-API ignore tuples
  (`all_qualified_accesses_are_public`, `all_explicit_imports_are_public`) against
  the registered releases on Julia 1.12 (where these checks run). Names that became
  public are dropped (AbstractEnsembleProblem, AbstractJumpProblem, is_diagonal_noise,
  AbstractODEAlgorithm, AbstractSDEAlgorithm, has_jac, ImmutableODEProblem,
  ODE_DEFAULT_NORM, find_callback_time, find_first_continuous_callback, get_condition);
  names still non-public are kept (SciMLBase internals incl. AbstractODEIntegrator/
  has_tgrad, ForwardDiff, LinearSolve, SimpleDiffEq, LinearAlgebra, Core internals,
  the DiffEqBase RecursiveArrayTools re-export, StaticArrays internals).

Verified the QA group against the registered releases (no dev of base libs):
  Julia 1.12 (public-API checks active): 17 Pass, 1 Broken (the known
    `no_implicit_imports` ei_broken), 0 errored, 0 failed.
  Julia 1.10 (public-API checks skipped per SciMLTesting 1.7): 15 Pass, 1 Broken,
    0 errored, 0 failed.

`no_implicit_imports` (ei_broken, SciML#466) and the `*_via_owners` ignores are left
untouched.

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@ChrisRackauckas-Claude ChrisRackauckas-Claude marked this pull request as ready for review June 29, 2026 09:51
Eliminate the `:no_implicit_imports` ei_broken blanket (which hid 72 names)
by making every implicit import explicit, and trim the qualified-access /
explicit-import ignore lists to the genuinely-irreducible residuals.

Root fixes (drop ignore, no behavior change):
- Make all 72 implicit `using X` names explicit `using X: a, b, ...`; add
  CommonSolve, StaticArraysCore, UnPack as direct deps (true owners of
  `solve`, the Static* aliases, and `@unpack`). Drops `:no_implicit_imports`.
- Migrate `DiffEqBase.RecursiveArrayTools.recursive_bottom_eltype` to the
  public `RecursiveArrayTools.recursive_bottom_eltype` (RAT is a direct dep).
- Define a local `_unwrap_val` (the SciMLBase internal is `_`-prefixed and
  won't be publicized) and drop the SciMLBase qualification + ignore.
- Drop the now-empty `all_qualified_accesses_via_owners` list and the
  now-public SciMLBase names (EnsembleAlgorithm/has_tgrad/AbstractODEIntegrator/
  has_initialization_data) from `all_qualified_accesses_are_public`
  (public in SciMLBase 3.30); bump qa-env SciMLBase compat to 3.30.

Remaining exceptions are genuine non-public upstream APIs (ForwardDiff
differentiation, LinearSolve cache/algorithm extension, SimpleDiffEq tableau
internals, SciMLBase callback/rootfind/ensemble internals, LinearAlgebra
HermOrSym, Core.Compiler.return_type with no cross-version public equivalent
on the 1.10 LTS floor, and StaticArrays/StaticArraysCore/Base internals backing
the vendored GPU LU/linsolve kernels) — each documented inline.

Net qa.jl exception entries 51 -> 42. Verified GROUP=QA on Julia 1.12.6
(18/18 pass, all 6 EI checks green) and package load on Julia 1.10.11 LTS.

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
@ChrisRackauckas ChrisRackauckas merged commit c4cfb25 into SciML:master Jul 3, 2026
20 of 26 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