From 038ea02e034e83e4addd21ffe8336b754a77264f Mon Sep 17 00:00:00 2001 From: ChrisRackauckas-Claude Date: Thu, 25 Jun 2026 13:22:01 -0400 Subject: [PATCH 1/2] QA: run_qa v1.6 form + ExplicitImports (root + sublibs) Convert every QA environment (root test/QA and each lib//test/qa) to the SciMLTesting v1.6 `run_qa` form with ExplicitImports enabled. Per env: - root RecursiveArrayTools: aqua_broken=(:ambiguities,) (tracking #326); ei_broken=(:no_implicit_imports,) (tracking #619); EI public-access ignore-list for non-public upstream names. Pkg sentinel guard preserved. - RecursiveArrayToolsArrayPartitionAnyAll: piracies treat_as_own=[ArrayPartition]; JET target_defined_modules. EI clean. - RecursiveArrayToolsShorthandConstructors: piracies treat_as_own=[VA, AP]; JET target_defined_modules. EI clean. - RecursiveArrayToolsRaggedArrays: piracies treat_as_own on the RAT-owned AbstractRagged{VectorOfArray,DiffEqArray} abstract types (fixes the pre-existing Aqua piracy false-positive); ei_broken=(:no_implicit_imports,) (#619); EI ignore-lists for the RAT-owned ragged types and non-public upstream names. Removed the stale `AllObserved` explicit import (EI no_stale fix). The JET similar_type(::Any) report is a pre-existing master finding tracked in #620 and is left as a hard check (not silenced). Add SciMLTesting (compat "1.6") to each QA env; ExplicitImports comes in transitively. [sources]/develop wiring preserved exactly. Co-Authored-By: Chris Rackauckas Co-Authored-By: Claude Opus 4.8 (1M context) --- .../test/qa/Project.toml | 2 + .../test/qa/qa.jl | 20 ++++--- .../src/RecursiveArrayToolsRaggedArrays.jl | 2 +- .../test/qa/Project.toml | 2 + .../test/qa/qa.jl | 52 +++++++++++++++---- .../test/qa/Project.toml | 2 + .../test/qa/qa.jl | 22 ++++---- test/QA/Project.toml | 2 + test/QA/qa.jl | 39 ++++++++++---- 9 files changed, 99 insertions(+), 44 deletions(-) diff --git a/lib/RecursiveArrayToolsArrayPartitionAnyAll/test/qa/Project.toml b/lib/RecursiveArrayToolsArrayPartitionAnyAll/test/qa/Project.toml index 0cee54b8..0bcf1069 100644 --- a/lib/RecursiveArrayToolsArrayPartitionAnyAll/test/qa/Project.toml +++ b/lib/RecursiveArrayToolsArrayPartitionAnyAll/test/qa/Project.toml @@ -2,6 +2,7 @@ Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595" JET = "c3a54625-cd67-489e-a8e7-0a5a0ff4e31b" RecursiveArrayToolsArrayPartitionAnyAll = "172d604e-c495-4f00-97bf-d70957099afa" +SciMLTesting = "09d9d899-5365-40a9-917a-5f67fddea283" Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" [sources] @@ -11,5 +12,6 @@ RecursiveArrayToolsArrayPartitionAnyAll = {path = "../.."} Aqua = "0.8" JET = "0.9, 0.10, 0.11" RecursiveArrayToolsArrayPartitionAnyAll = "1" +SciMLTesting = "1.6" Test = "1" julia = "1.10" diff --git a/lib/RecursiveArrayToolsArrayPartitionAnyAll/test/qa/qa.jl b/lib/RecursiveArrayToolsArrayPartitionAnyAll/test/qa/qa.jl index c2ed190d..330f6943 100644 --- a/lib/RecursiveArrayToolsArrayPartitionAnyAll/test/qa/qa.jl +++ b/lib/RecursiveArrayToolsArrayPartitionAnyAll/test/qa/qa.jl @@ -1,14 +1,12 @@ -using RecursiveArrayToolsArrayPartitionAnyAll, Aqua, JET, Test +using SciMLTesting, RecursiveArrayToolsArrayPartitionAnyAll, JET, Test const RATAPAA = RecursiveArrayToolsArrayPartitionAnyAll -@testset "QA" begin - @testset "Aqua" begin - # `any`/`all` are extended on the RecursiveArrayTools-owned `ArrayPartition` - # type, so they are intentional (owned) methods, not piracy. - Aqua.test_all(RATAPAA; piracies = (; treat_as_own = [RATAPAA.ArrayPartition])) - end - @testset "JET" begin - JET.test_package(RecursiveArrayToolsArrayPartitionAnyAll; target_defined_modules = true) - end -end +run_qa( + RATAPAA; + explicit_imports = true, + # `any`/`all` are extended on the RecursiveArrayTools-owned `ArrayPartition` + # type, so they are intentional (owned) methods, not piracy. + aqua_kwargs = (; piracies = (; treat_as_own = [RATAPAA.ArrayPartition])), + jet_kwargs = (; target_defined_modules = true), +) diff --git a/lib/RecursiveArrayToolsRaggedArrays/src/RecursiveArrayToolsRaggedArrays.jl b/lib/RecursiveArrayToolsRaggedArrays/src/RecursiveArrayToolsRaggedArrays.jl index c5bf97e4..aaca7ef4 100644 --- a/lib/RecursiveArrayToolsRaggedArrays/src/RecursiveArrayToolsRaggedArrays.jl +++ b/lib/RecursiveArrayToolsRaggedArrays/src/RecursiveArrayToolsRaggedArrays.jl @@ -2,7 +2,7 @@ module RecursiveArrayToolsRaggedArrays import RecursiveArrayTools: RecursiveArrayTools, AbstractRaggedVectorOfArray, AbstractRaggedDiffEqArray, VectorOfArray, DiffEqArray, - AbstractVectorOfArray, AbstractDiffEqArray, AllObserved, + AbstractVectorOfArray, AbstractDiffEqArray, recursivefill!, recursivecopy! using SymbolicIndexingInterface using SymbolicIndexingInterface: ParameterTimeseriesCollection, ParameterIndexingProxy, diff --git a/lib/RecursiveArrayToolsRaggedArrays/test/qa/Project.toml b/lib/RecursiveArrayToolsRaggedArrays/test/qa/Project.toml index 397670e2..521d6e44 100644 --- a/lib/RecursiveArrayToolsRaggedArrays/test/qa/Project.toml +++ b/lib/RecursiveArrayToolsRaggedArrays/test/qa/Project.toml @@ -2,6 +2,7 @@ Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595" JET = "c3a54625-cd67-489e-a8e7-0a5a0ff4e31b" RecursiveArrayToolsRaggedArrays = "c384ba91-639a-44ca-823a-e1d3691ab84a" +SciMLTesting = "09d9d899-5365-40a9-917a-5f67fddea283" Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" [sources] @@ -11,5 +12,6 @@ RecursiveArrayToolsRaggedArrays = {path = "../.."} Aqua = "0.8" JET = "0.9, 0.10, 0.11" RecursiveArrayToolsRaggedArrays = "1" +SciMLTesting = "1.6" Test = "1" julia = "1.10" diff --git a/lib/RecursiveArrayToolsRaggedArrays/test/qa/qa.jl b/lib/RecursiveArrayToolsRaggedArrays/test/qa/qa.jl index 6e135977..dd1b45c9 100644 --- a/lib/RecursiveArrayToolsRaggedArrays/test/qa/qa.jl +++ b/lib/RecursiveArrayToolsRaggedArrays/test/qa/qa.jl @@ -1,10 +1,44 @@ -using RecursiveArrayToolsRaggedArrays, Aqua, JET, Test +using SciMLTesting, RecursiveArrayToolsRaggedArrays, JET, Test -@testset "QA" begin - @testset "Aqua" begin - Aqua.test_all(RecursiveArrayToolsRaggedArrays) - end - @testset "JET" begin - JET.test_package(RecursiveArrayToolsRaggedArrays; target_defined_modules = true) - end -end +run_qa( + RecursiveArrayToolsRaggedArrays; + explicit_imports = true, + # The arithmetic/array methods (`*`, `+`, `Array`, `copyto!`, ...) are defined on + # the RecursiveArrayTools-owned `AbstractRaggedVectorOfArray` / + # `AbstractRaggedDiffEqArray` abstract types, so they are intentional (owned) + # methods, not piracy. + aqua_kwargs = (; + piracies = (; + treat_as_own = [ + RecursiveArrayToolsRaggedArrays.AbstractRaggedVectorOfArray, + RecursiveArrayToolsRaggedArrays.AbstractRaggedDiffEqArray, + ], + ), + ), + jet_kwargs = (; target_defined_modules = true), + ei_kwargs = (; + # `AbstractRaggedVectorOfArray`/`AbstractRaggedDiffEqArray` are + # RecursiveArrayTools-owned abstract types this subpackage subtypes; they are + # not (yet) declared public in RecursiveArrayTools. + all_explicit_imports_are_public = (; + ignore = (:AbstractRaggedVectorOfArray, :AbstractRaggedDiffEqArray), + ), + # Non-public names legitimately qualified/imported from upstream packages + # (Base, Base.Broadcast, StaticArraysCore, ArrayInterface, Adapt, + # SymbolicIndexingInterface). Not this subpackage's to make public. + all_qualified_accesses_are_public = (; + ignore = ( + Symbol("@propagate_inbounds"), :AbstractArrayStyle, :AllVariables, + :Broadcasted, :DefaultArrayStyle, :HasLength, :IteratorSize, :OneTo, + :Slice, :SolvedVariables, :StaticVecOrMat, :SymbolicTypeTrait, + :adapt_structure, :add_sum, :broadcastable, :check_parent_index_match, + :ensure_indexable, :flatten, :front, :index_dimsum, :ismutable, + :issingular, :maybeview, :mul_prod, :similar_type, :tail, :typename, + :unalias, :viewindexing, + ), + ), + ), + # Whole-module `using` exposes many names implicitly; explicit-import refactor + # tracked in https://github.com/SciML/RecursiveArrayTools.jl/issues/619 + ei_broken = (:no_implicit_imports,), +) diff --git a/lib/RecursiveArrayToolsShorthandConstructors/test/qa/Project.toml b/lib/RecursiveArrayToolsShorthandConstructors/test/qa/Project.toml index 0e399924..41d10427 100644 --- a/lib/RecursiveArrayToolsShorthandConstructors/test/qa/Project.toml +++ b/lib/RecursiveArrayToolsShorthandConstructors/test/qa/Project.toml @@ -2,6 +2,7 @@ Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595" JET = "c3a54625-cd67-489e-a8e7-0a5a0ff4e31b" RecursiveArrayToolsShorthandConstructors = "39fb7555-b4ad-4efd-8abe-30331df017d3" +SciMLTesting = "09d9d899-5365-40a9-917a-5f67fddea283" Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" [sources] @@ -11,5 +12,6 @@ RecursiveArrayToolsShorthandConstructors = {path = "../.."} Aqua = "0.8" JET = "0.9, 0.10, 0.11" RecursiveArrayToolsShorthandConstructors = "1" +SciMLTesting = "1.6" Test = "1" julia = "1.10" diff --git a/lib/RecursiveArrayToolsShorthandConstructors/test/qa/qa.jl b/lib/RecursiveArrayToolsShorthandConstructors/test/qa/qa.jl index 82a07544..d9e5e6ed 100644 --- a/lib/RecursiveArrayToolsShorthandConstructors/test/qa/qa.jl +++ b/lib/RecursiveArrayToolsShorthandConstructors/test/qa/qa.jl @@ -1,15 +1,13 @@ -using RecursiveArrayToolsShorthandConstructors, Aqua, JET, Test +using SciMLTesting, RecursiveArrayToolsShorthandConstructors, JET, Test const RATSC = RecursiveArrayToolsShorthandConstructors -@testset "QA" begin - @testset "Aqua" begin - # `getindex(::Type{VA}, ...)` / `getindex(::Type{AP}, ...)` extend Base on - # RecursiveArrayTools-owned types, so they are intentional (owned) methods, - # not piracy. - Aqua.test_all(RATSC; piracies = (; treat_as_own = [RATSC.VA, RATSC.AP])) - end - @testset "JET" begin - JET.test_package(RecursiveArrayToolsShorthandConstructors; target_defined_modules = true) - end -end +run_qa( + RATSC; + explicit_imports = true, + # `getindex(::Type{VA}, ...)` / `getindex(::Type{AP}, ...)` extend Base on + # RecursiveArrayTools-owned types, so they are intentional (owned) methods, + # not piracy. + aqua_kwargs = (; piracies = (; treat_as_own = [RATSC.VA, RATSC.AP])), + jet_kwargs = (; target_defined_modules = true), +) diff --git a/test/QA/Project.toml b/test/QA/Project.toml index 4c049614..97a60f38 100644 --- a/test/QA/Project.toml +++ b/test/QA/Project.toml @@ -2,6 +2,7 @@ Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595" Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f" RecursiveArrayTools = "731186ca-8d62-57ce-b412-fbd966d074cd" +SciMLTesting = "09d9d899-5365-40a9-917a-5f67fddea283" Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" [sources] @@ -11,5 +12,6 @@ RecursiveArrayTools = {path = "../.."} Aqua = "0.8" Pkg = "1" RecursiveArrayTools = "4" +SciMLTesting = "1.6" Test = "1" julia = "1.10" diff --git a/test/QA/qa.jl b/test/QA/qa.jl index e061435f..e41650eb 100644 --- a/test/QA/qa.jl +++ b/test/QA/qa.jl @@ -1,4 +1,4 @@ -using RecursiveArrayTools, Aqua, Pkg +using SciMLTesting, RecursiveArrayTools, Test, Pkg # yes this is horrible, we'll fix it when Pkg or Base provides a decent API manifest = Pkg.Types.EnvCache().manifest @@ -7,13 +7,30 @@ if haskey(manifest.deps, "NonlinearSolveBase") || haskey(manifest.deps, "DiffEqB error("Don't put Downstream Packages in non Downstream CI") end -@testset "Aqua" begin - Aqua.find_persistent_tasks_deps(RecursiveArrayTools) - Aqua.test_ambiguities(RecursiveArrayTools; recursive = false, broken = true) - Aqua.test_deps_compat(RecursiveArrayTools) - Aqua.test_piracies(RecursiveArrayTools) - Aqua.test_project_extras(RecursiveArrayTools) - Aqua.test_stale_deps(RecursiveArrayTools) - Aqua.test_unbound_args(RecursiveArrayTools) - Aqua.test_undefined_exports(RecursiveArrayTools) -end +run_qa( + RecursiveArrayTools; + explicit_imports = true, + # Method-table ambiguities tracked in + # https://github.com/SciML/RecursiveArrayTools.jl/issues/326 + aqua_broken = (:ambiguities,), + ei_kwargs = (; + # Non-public names legitimately qualified/imported from upstream packages + # (Base, Base.Broadcast, LinearAlgebra, StaticArraysCore, ArrayInterface, + # Adapt, SymbolicIndexingInterface). Not RecursiveArrayTools' to make public. + all_qualified_accesses_are_public = (; + ignore = ( + Symbol("@propagate_inbounds"), :AbstractArrayStyle, :AllVariables, + :ArrayStyle, :BroadcastStyle, :Broadcasted, :DefaultArrayStyle, :OneTo, + :QRCompactWY, :SolvedVariables, :StaticArray, :StaticVecOrMat, + :SymbolicTypeTrait, :_InitialValue, :_ipiv_rows!, :_maybe_reshape, + :_swap_rows!, :_unsafe_getindex, :_unsafe_getindex!, :adapt_structure, + :add_sum, :flatten, :front, :index_shape, :ismutable, :issingular, + :promote_op, :restructure, :result_style, :similar_type, :tail, + :unalias, :zeromatrix, + ), + ), + ), + # Whole-module `using` exposes many names implicitly; explicit-import refactor + # tracked in https://github.com/SciML/RecursiveArrayTools.jl/issues/619 + ei_broken = (:no_implicit_imports,), +) From 443593c30ac742ca210be8266db1c4c1af52b91c Mon Sep 17 00:00:00 2001 From: ChrisRackauckas-Claude Date: Mon, 29 Jun 2026 06:18:12 -0400 Subject: [PATCH 2/2] RaggedArrays QA: mark pre-existing JET similar_type finding as jet_broken The RecursiveArrayToolsRaggedArrays QA lane fails JET typo-mode with 4 similar_type(::Any) no-matching-method reports from the copyto!/fill!/ broadcast immutable-element branches (dest.u[i] infers as ::Any because the abstract AbstractRaggedVectorOfArray .u field is untyped). Verified byte- identically pre-existing on unmodified master (run JET.report_package on a clean bf98ebd checkout: same 4 reports at src lines 1335/1347/1468/1636; the current master tip 5e20683 Sublibrary CI also fails on exactly this one lane). Not introduced by the run_qa v1.6 conversion. Use jet_broken=true so the lane records the finding as @test_broken (report- only, auto-flags an Unexpected Pass once the real fix lands) instead of a hard red. The underlying inference fix is tracked in https://github.com/SciML/RecursiveArrayTools.jl/issues/620. Verified locally vs released SciMLTesting 1.7.0: QA group green on Julia 1.12.6 (16 pass / 2 broken / 0 fail) and Julia 1.10 LTS (14 pass / 2 broken / 0 fail). Co-Authored-By: Claude Opus 4.8 (1M context) Co-Authored-By: Chris Rackauckas --- lib/RecursiveArrayToolsRaggedArrays/test/qa/qa.jl | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/lib/RecursiveArrayToolsRaggedArrays/test/qa/qa.jl b/lib/RecursiveArrayToolsRaggedArrays/test/qa/qa.jl index dd1b45c9..96e7f46e 100644 --- a/lib/RecursiveArrayToolsRaggedArrays/test/qa/qa.jl +++ b/lib/RecursiveArrayToolsRaggedArrays/test/qa/qa.jl @@ -16,6 +16,15 @@ run_qa( ), ), jet_kwargs = (; target_defined_modules = true), + # Pre-existing JET typo-mode finding (reproduces byte-identically on master): + # the `copyto!`/`fill!`/broadcast immutable-element branches call + # `StaticArraysCore.similar_type(dest.u[i])`, but `dest.u[i]` infers as `::Any` + # because the abstract `AbstractRaggedVectorOfArray` `.u` field is untyped, so + # `similar_type(::Any)` has no matching method. Tracked (with the real fix — + # tightening the `.u` type / guarding the immutable branch) in + # https://github.com/SciML/RecursiveArrayTools.jl/issues/620. `jet_broken` + # auto-flags an Unexpected Pass once that fix lands, prompting removal. + jet_broken = true, ei_kwargs = (; # `AbstractRaggedVectorOfArray`/`AbstractRaggedDiffEqArray` are # RecursiveArrayTools-owned abstract types this subpackage subtypes; they are