Skip to content

QA: run_qa v1.6 form + ExplicitImports#157

Merged
ChrisRackauckas merged 1 commit into
SciML:masterfrom
ChrisRackauckas-Claude:qa-run_qa-v1.6-explicit-imports
Jun 27, 2026
Merged

QA: run_qa v1.6 form + ExplicitImports#157
ChrisRackauckas merged 1 commit into
SciML:masterfrom
ChrisRackauckas-Claude:qa-run_qa-v1.6-explicit-imports

Conversation

@ChrisRackauckas-Claude

Copy link
Copy Markdown
Contributor

Please ignore until reviewed by @ChrisRackauckas.

Brings this repo's QA onto the SciMLTesting 1.6 run_qa form with ExplicitImports enabled (mode: hand-rolled → run_qa).

test/qa/qa.jl

Before: hand-rolled Aqua.test_all(FEniCS) + JET.test_package(FEniCS; target_defined_modules = true).

After:

using SciMLTesting, FEniCS, Test
using JET

run_qa(
    FEniCS;
    explicit_imports = true,
    ei_kwargs = (; all_qualified_accesses_are_public = (; ignore = (:getdoc,))),
)

Aqua + ExplicitImports come from SciMLTesting's own deps; using JET triggers the JET weakdep extension so the JET check still runs.

ExplicitImports findings (enabled here for the first time at the run_qa level)

Ran all six EI checks against released SciMLTesting 1.6.0:

Check Result
no_implicit_imports pass
no_stale_explicit_imports pass
all_explicit_imports_via_owners pass
all_qualified_accesses_via_owners pass
all_qualified_accesses_are_public fail → ignored (see below)
all_explicit_imports_are_public pass

The single finding is getdoc, which is not public in Base.Docs. FEniCS extends Base.Docs.getdoc(::fenicsobject) (src/FEniCS.jl:85) to surface a wrapped PyObject's docstring. Extending a Base-internal method requires naming it and there is nothing to make public, so it is ignored (not skipped) via ei_kwargs, documented with its source module. No aqua_broken/jet_broken/ei_broken markers are needed — Aqua (test_all, 11/11) and JET (0 reports) are clean.

Other changes

  • The standalone test/explicit_imports.jl (run in the Core group via core.jl) only ran two of the six checks; run_qa runs all six, so that include + the file are removed, and ExplicitImports drops from the root [extras]/[targets].test (now supplied transitively in the QA env via SciMLTesting).
  • test/qa/Project.toml: SciMLTesting compat → "1.6"; drop ExplicitImports (transitive via SciMLTesting); keep Aqua (test_all's ambiguities sub-check), JET, and SafeTestsets (run_tests wraps each group body in @safetestset).

Verification

Run locally against released SciMLTesting 1.6.0 (resolved from the registry, no dev-from-branch) inside the CI cmhyett/julia-fenics container so using FEniCS (PyCall → conda fenics) succeeds, on Julia 1.10.11:

Test Summary: | Pass  Total     Time
QA            |   18     18  1m36.3s

18 = 11 Aqua + 1 JET + 6 ExplicitImports. 0 Fail / 0 Error / 0 Broken. A control run without the getdoc ignore errors on exactly getdoc, confirming the ignore is load-bearing and the check genuinely runs.

🤖 Generated with Claude Code

Convert test/qa/qa.jl from the hand-rolled Aqua.test_all + JET.test_package
body to the SciMLTesting 1.6 `run_qa` form with ExplicitImports enabled.

- qa.jl now calls `run_qa(FEniCS; explicit_imports = true, ei_kwargs = ...)`.
  Aqua and ExplicitImports come from SciMLTesting's own deps; `using JET`
  triggers the JET weakdep extension so the JET check still runs (clean,
  0 reports under run_qa's default target_modules=(FEniCS,) config — and also
  under the old target_defined_modules=true config).
- Fold the six ExplicitImports checks into the QA group. The standalone
  test/explicit_imports.jl (run in Core via core.jl) only ran two of them
  (no_implicit_imports, no_stale_explicit_imports); run_qa runs all six, so the
  Core-group include and the file are removed and ExplicitImports drops from the
  root [extras]/[targets].test (now supplied transitively in the QA env via
  SciMLTesting).
- Only ExplicitImports finding: `all_qualified_accesses_are_public` flags
  `getdoc`, which is not public in `Base.Docs`. FEniCS extends
  `Base.Docs.getdoc(::fenicsobject)` (src/FEniCS.jl) to surface a wrapped
  PyObject's docstring; extending a Base-internal method requires naming it and
  there is nothing to make public, so it is ignored via
  ei_kwargs = (; all_qualified_accesses_are_public = (; ignore = (:getdoc,))).
  All other five EI checks, Aqua (test_all, 11/11) and JET pass with no kwargs.
- test/qa/Project.toml: bump SciMLTesting compat to "1.6"; drop ExplicitImports
  (transitive via SciMLTesting); keep Aqua (test_all's ambiguities sub-check),
  JET, SafeTestsets (run_tests wraps each group body in @safetestset).

Verified locally against released SciMLTesting 1.6.0 (resolved from the registry,
no dev-from-branch) inside the CI fenics container: QA group 18/18 Pass, 0 Fail,
0 Error, 0 Broken (11 Aqua + 1 JET + 6 ExplicitImports). Control run without the
getdoc ignore errors on exactly getdoc, confirming the ignore is load-bearing and
the check genuinely runs.

Co-Authored-By: Chris Rackauckas <accounts@chrisrackauckas.com>
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@ChrisRackauckas ChrisRackauckas marked this pull request as ready for review June 27, 2026 13:08
@ChrisRackauckas ChrisRackauckas merged commit c5634d6 into SciML:master Jun 27, 2026
8 of 9 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