Automatic of ignoring type checking imports
Closed this issue · 0 comments
seddonym commented
This feature would be about allowing Import Linter to automatically ignore imports within a type checking guard.
Grimp 3.1 now allows the graph to be built using an exclude_type_checking_imports=True
parameter (although note the documentation build is currently broken) so it's not documented on Read the docs yet.
The way this should is as an optional entry in the top level configuration like so:
[importlinter]
root_package = mypackage
exclude_type_checking_imports = true
That can get passed directly through to grimp.build_graph
.