Skip to content

Commit

Permalink
Mention that unused-import skips __init__.py files (#10179)
Browse files Browse the repository at this point in the history
  • Loading branch information
amelenty authored Jan 13, 2025
1 parent d94194b commit 909a883
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions doc/data/messages/u/unused-import/details.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
By default, this check is skipped for ``__init__.py`` files, as they often contain imports from submodules for the convenience of end users. While these imports are not used within ``__init__.py``, they serve the purpose of providing intuitive import paths for the module's important classes and constants.
1 change: 1 addition & 0 deletions doc/data/messages/u/unused-import/related.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- :ref:`--init-import <variables-options>`

0 comments on commit 909a883

Please sign in to comment.