Skip to content

Improve explicit imports hygiene#39

Merged
ChrisRackauckas merged 1 commit into
SciML:masterfrom
ChrisRackauckas-Claude:explicit-imports-20260107-090546
Jan 8, 2026
Merged

Improve explicit imports hygiene#39
ChrisRackauckas merged 1 commit into
SciML:masterfrom
ChrisRackauckas-Claude:explicit-imports-20260107-090546

Conversation

@ChrisRackauckas-Claude

Copy link
Copy Markdown
Contributor

Summary

  • Fixed implicit imports in src/DimensionalPlotRecipes.jl by making imports explicit
  • Added ExplicitImports.jl tests to ensure import hygiene is maintained
  • All tests pass including new ExplicitImports checks

Changes Made

src/DimensionalPlotRecipes.jl

  • Changed using RecipesBaseusing RecipesBase: RecipesBase, @recipe
  • Changed using LinearAlgebrausing LinearAlgebra: LinearAlgebra, norm

This makes the imports explicit and avoids relying on all exports from these packages.

test/explicit_imports.jl (new file)

Added tests to verify:

  • No implicit imports in the package
  • No stale explicit imports (unused imports)

test/runtests.jl

  • Added include("explicit_imports.jl") to run import hygiene tests

Project.toml

  • Added ExplicitImports to [extras] and [targets] for test dependencies

Test Results

All tests pass:

Test Summary:   | Pass  Total  Time
ExplicitImports |    2      2  1.4s
     Testing DimensionalPlotRecipes tests passed

@ChrisRackauckas - This PR ensures the package follows best practices for explicit imports and prevents future import hygiene issues through automated testing.

🤖 Generated with Claude Code

- Changed imports to explicit form in src/DimensionalPlotRecipes.jl
  - `using RecipesBase` → `using RecipesBase: RecipesBase, @recipe`
  - `using LinearAlgebra` → `using LinearAlgebra: LinearAlgebra, norm`
- Added ExplicitImports.jl tests to test suite
- Added test/explicit_imports.jl with tests for import hygiene
- Added ExplicitImports to [extras] and [targets] in Project.toml
- All tests pass including new ExplicitImports checks

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
@ChrisRackauckas ChrisRackauckas merged commit 772d301 into SciML:master Jan 8, 2026
5 of 6 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.

3 participants