Skip to content

QA: make implicit imports explicit (ExplicitImports no_implicit_imports) #139

Description

@ChrisRackauckas-Claude

The QA group now runs ExplicitImports.jl's six checks via SciMLTesting run_qa(...; explicit_imports = true). Five pass. check_no_implicit_imports is currently tracked as ei_broken = (:no_implicit_imports,) because the module pulls many names implicitly from heavy using of ModelingToolkit / ParserCombinator / PythonCall / MLStyle / CondaPkg, and making them explicit is a larger refactor.

check_no_implicit_imports(BaseModelica) reports these implicit imports to convert to explicit using X: name (or qualified access):

From MLStyle: MLStyle, @data (MLStyle.DataType), @match (MLStyle.MatchImpl)
From CondaPkg: CondaPkg
From ModelingToolkit: ModelingToolkit, SymbolicUtils
From ModelingToolkitBase: ModelingToolkitBase, @discretes, @named, @parameters, System, equations, mtkcompile
From Symbolics: Symbolics, @variables, Equation, Num
From SciMLBase: ODEProblem
From SymbolicUtils: substitute
From ParserCombinator: ParserCombinator, @E_str, @e_str, @p_str, @with_names, Debug, Delayed, Drop, Lookahead, NoCache, Not, Plus, Space, Star, make, once
From PythonCall: PythonCall, Py, pybuiltins, pyconvert, pyimport

Once these are made explicit, drop :no_implicit_imports from ei_broken in test/qa/qa.jl (the @test_broken will Unexpected-Pass to prompt it).

Tracked as part of the SciMLTesting run_qa v1.6 / ExplicitImports rollout.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions