Skip to content

Commit

Permalink
Add unused-wildcard-import doc example (#6133)
Browse files Browse the repository at this point in the history
Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
  • Loading branch information
jpy-git and Pierre-Sassoulas authored Apr 3, 2022
1 parent 22f4d52 commit b19ea92
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
4 changes: 4 additions & 0 deletions doc/data/messages/u/unused-wildcard-import/bad.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
from abc import * # [unused-wildcard-import]


class Animal(ABC): ...
1 change: 1 addition & 0 deletions doc/data/messages/u/unused-wildcard-import/detail.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Either remove the wildcard import, make use of every object from the wildcard import, or only import the required objects.
4 changes: 4 additions & 0 deletions doc/data/messages/u/unused-wildcard-import/good.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
from abc import ABC


class Animal(ABC): ...

0 comments on commit b19ea92

Please sign in to comment.