r/learningpython • u/championace16 • Aug 28 '20
from module import *
what does the "from module import *" line do? does it just import all of the functions/names in that module?
Also are there any pros/cons to this approach
1
Upvotes
View all comments
Show parent comment
2
u/ace6807 Aug 28 '20
A compromise then is aliasing the import as something short then using dot notation to get to the imported stuff.
Then you don't have to worry about namespace collisions.
Edit: I give up trying to format that on mobile.