# \[ANN\] ExplicitImports.jl: tooling to help use and maintain explicit imports in your package

**URL:** <https://discourse.julialang.org/t/ann-explicitimports-jl-tooling-to-help-use-and-maintain-explicit-imports-in-your-package/110973>\
**Category:** Package Announcements\
**Created:** [February 29, 2024, 8:07pm UTC](https://discourse.julialang.org/t/ann-explicitimports-jl-tooling-to-help-use-and-maintain-explicit-imports-in-your-package/110973 "2024-02-29T20:07:24Z")\
**Posts on this page:** 6\
**Page:** 2

<div class="post-metadata">

**Author:** ![ericphanson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ericphanson/32/215186_2.png) [@ericphanson](https://discourse.julialang.org/u/ericphanson)\
**Post date:** [January 12, 2026, 5:01pm UTC](https://discourse.julialang.org/t/ann-explicitimports-jl-tooling-to-help-use-and-maintain-explicit-imports-in-your-package/110973/21 "2026-01-12T17:01:58Z")

</div>

## ExplictImports v1.14.2

Since last time, we’ve had:

- one new feature, released in v1.14.0: `check_all_explicit_imports_are_public` and `check_all_qualified_accesses_are_public` now accept a `from` keyword argument to limit checks to names from particular modules ([#134](https://github.com/JuliaTesting/ExplicitImports.jl/pull/134))
- 8 bugfixes:
  - v0.14.2
    - Fix issue where explicitly imported macros aren’t detected as imported. This may cause previously undetected stale explicit imports of macros to now be detected. ([#159](https://github.com/JuliaTesting/ExplicitImports.jl/pull/159))
    - Fix bug in kwarg default values, e.g. where `f(; convert=convert)` would not detect the usage of `convert` as external. ([#148](https://github.com/JuliaTesting/ExplicitImports.jl/pull/148))
    - Fix scoping issues in default values of positional arguments ([#147](https://github.com/JuliaTesting/ExplicitImports.jl/pull/147)), similar to above for kwargs
    - Fix bug where if a field name in a struct was the same as the usage of a global in a constructor, that usage would be missed. ([#146](https://github.com/JuliaTesting/ExplicitImports.jl/pull/146))
    - Fix bug where names exported by Base and re-exported by other modules are incorrectly suggested to be explicitly imported from those other modules. ([#145](https://github.com/JuliaTesting/ExplicitImports.jl/pull/145))

  - v1.14.1
    - Fix type parameter issue ([#141](https://github.com/JuliaTesting/ExplicitImports.jl/pull/141))

  - v1.13.2
    - Fix ExplicitImports to work with `--depwarn=error` ([#132](https://github.com/JuliaTesting/ExplicitImports.jl/pull/132))

  - v1.13.1
    - improve function argument parsing ([#130](https://github.com/JuliaTesting/ExplicitImports.jl/pull/130))

As a result, ExplicitImports.jl should be more accurate in identifying implicit imports and stale explicit imports, and generally work a bit more the way it should.

We also have added some “integration tests” (or reverse-dependency tests) where we run checks on particular packages to surface unexpected breakage. See [here](https://github.com/JuliaTesting/ExplicitImports.jl/tree/main/integration). We can add more packages as well- file an issue or PR if you are interested in your package being tested this way.

PSA: Some of these bugfixes (especially the one about macros) may result in test failures if you use ExplicitImports.jl during your package’s tests and relied on the previously-inaccurate results.

---

<div class="post-metadata">

**Author:** ![giordano](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/giordano/32/2166_2.png) [@giordano](https://discourse.julialang.org/u/giordano)\
**Post date:** [January 12, 2026, 10:15pm UTC](https://discourse.julialang.org/t/ann-explicitimports-jl-tooling-to-help-use-and-maintain-explicit-imports-in-your-package/110973/22 "2026-01-12T22:15:08Z")

</div>

> [@ericphanson](#):
>
> - one new feature, released in v1.14.0: `check_all_explicit_imports_are_public` and `check_all_qualified_accesses_are_public` now accept a `from` keyword argument to limit checks to names from particular modules ([#134](https://github.com/JuliaTesting/ExplicitImports.jl/pull/134))

Is there a technical limitation for being able to do something similar for `check_no_implicit_imports`? I have an interested in that possibility 😅_ **Edit** _: uhm, maybe I initially misunderstood the application, and this makes sense only for those checks about methods coming _from_ another module

---

<div class="post-metadata">

**Author:** ![ericphanson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ericphanson/32/215186_2.png) [@ericphanson](https://discourse.julialang.org/u/ericphanson)\
**Post date:** [January 12, 2026, 10:22pm UTC](https://discourse.julialang.org/t/ann-explicitimports-jl-tooling-to-help-use-and-maintain-explicit-imports-in-your-package/110973/23 "2026-01-12T22:22:46Z")

</div>

Yeah, the way these work is (from the docs):

> Alternatively, the `from` keyword can be used to apply the public names check to only certain modules (and their submodules).
> 
> For example,
> 
> ```julia
> 
> @test check_all_explicit_imports_are_public(MyPackage; from=(DataFrames,)) === nothing
> 
> ```
> 
> would check only that explicit imports from the `DataFrames` module (or its submodules) are all public.

There’s lots of other configuration the checks have, `ignore`, `skip`, etc. If you have a use that isn’t covered, feel free to open an issue. I’m hoping to make them flexible enough they can be used in partially-migrated codebases and things like that.

---

<div class="post-metadata">

**Author:** ![giordano](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/giordano/32/2166_2.png) [@giordano](https://discourse.julialang.org/u/giordano)\
**Post date:** [January 12, 2026, 10:52pm UTC](https://discourse.julialang.org/t/ann-explicitimports-jl-tooling-to-help-use-and-maintain-explicit-imports-in-your-package/110973/24 "2026-01-12T22:52:48Z")

</div>

I think what I wanted to use is `ignore`, but `ignore=(MyModule,)` doesn’t seem to ignore submodules of `MyModule` (I feel like I tried this before already and may explain why I didn’t use it). I guess I’ll have to list all submodules.

---

<div class="post-metadata">

**Author:** ![ericphanson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ericphanson/32/215186_2.png) [@ericphanson](https://discourse.julialang.org/u/ericphanson)\
**Post date:** [January 12, 2026, 11:42pm UTC](https://discourse.julialang.org/t/ann-explicitimports-jl-tooling-to-help-use-and-maintain-explicit-imports-in-your-package/110973/25 "2026-01-12T23:42:35Z")

</div>

If you’re talking about `check_no_implicit_imports`, then it _should_ handle submodules:

```julia
Additionally, the keyword `ignore` can be passed to represent a tuple of items to ignore. These can be:

* modules. Any submodule of `mod` matching an element of `ignore` is skipped. This can be used to allow the usage of implicit imports in some submodule of your package.
* symbols: any implicit import of a name matching an element of `ignore` is ignored (does not throw)
* `symbol => module` pairs. Any implicit import of a name matching that symbol from a module matching the module is ignored.

```

Could be there’s a bug though

---

<div class="post-metadata">

**Author:** ![ericphanson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ericphanson/32/215186_2.png) [@ericphanson](https://discourse.julialang.org/u/ericphanson)\
**Post date:** [January 14, 2026, 11:16am UTC](https://discourse.julialang.org/t/ann-explicitimports-jl-tooling-to-help-use-and-maintain-explicit-imports-in-your-package/110973/26 "2026-01-14T11:16:33Z")

</div>

Mosè indeed found the `ignore` kwarg was not ignoring submodules as intended; that has been fixed in v1.15.0 of ExplicitImports. Here are the release notes.

## New features

- support `ignore` kwarg for all `check_*` functions ([#165](https://github.com/JuliaTesting/ExplicitImports.jl/pull/165))
- add new `test_*` API functions for better integrations into Test.jl testsuites (and to help with Aqua integration) ([#143](https://github.com/JuliaTesting/ExplicitImports.jl/pull/143))
  - new functions: `test_explicit_imports`, `test_no_implicit_imports, test_no_stale_explicit_imports`,  
`test_all_explicit_imports_via_owners`, `test_all_explicit_imports_are_public`,  
`test_all_qualified_accesses_via_owners`, `test_all_qualified_accesses_are_public`,  
`test_no_self_qualified_accesses`

- add `--test` flag to CLI app ([#166](https://github.com/JuliaTesting/ExplicitImports.jl/pull/166))

## Bug fixes

- fix `ignore` to properly ignore submodules of ignored modules ([#165](https://github.com/JuliaTesting/ExplicitImports.jl/pull/165))

[Previous page](https://discourse.julialang.org/t/ann-explicitimports-jl-tooling-to-help-use-and-maintain-explicit-imports-in-your-package/110973.md?page=1)
