help on "from deen import *" vs. "import deen"
jfong at ms4.hinet.net
jfong at ms4.hinet.net
Thu Nov 17 20:56:29 EST 2016
Steven D'Aprano at 2016/11/17 4:04:04PM wrote:
> The most important thing you should learn from this thread is:
>
> - avoid using "from module import *" as it is usually more trouble
> than it is worth.
>
>
> It is confusing and leads to more problems than it solves. If Python was being
> invented now, rather than 20 years ago, I would expect that there would be no
> "import *" in the language.
It's the greatest advice I ever had in Python:-)
--Jach
More information about the Python-list
mailing list