A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2017-January/147139.html below:

[Python-Dev] Imports with underscores

[Python-Dev] Imports with underscores [Python-Dev] Imports with underscoresTerry Reedy tjreedy at udel.edu
Mon Jan 9 15:29:38 EST 2017
On 1/9/2017 11:48 AM, Guido van Rossum wrote:
> I would focus on changing habits to discourage "import *" rather than

The tkinter doc still has

...to use Tkinter all you need is a simple import statement:
   import tkinter
Or, more often:
   from tkinter import *

Should this be changed?

> uglifying all new code with this "os as _os" pattern. Very occasionally
> one designs a module to explicitly support "import *", and that usually
> entails using __all__ (like it or not), making the problem go away
> without uglifying the code.

tkinter does not have have __all__.  It would have 160 (in 3.6) minus at 
least 3 (for enum, re, and sys) entries.

-- 
Terry Jan Reedy

More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4