seddonym / import-linter

Import Linter allows you to define and enforce rules for the internal and external imports within your Python project.
https://import-linter.readthedocs.io/
BSD 2-Clause "Simplified" License
664 stars 45 forks source link

Forbidden import checking doesn't work correctly for descendants, when allow_indirect_imports=true #196

Closed seddonym closed 11 months ago

seddonym commented 11 months ago

Noticed by @qasimk. The contract will only check the source/forbidden modules, not their descendants.

This has been a bug since allow_indirect_imports was introduced, apologies for this.

seddonym commented 11 months ago

This fix is now available in version 1.12.0, enjoy!

QasimK commented 11 months ago

Thanks @seddonym :smile: