[Tutor] educational

Ben Finney ben+python at benfinney.id.au
Sun Mar 9 23:33:39 CET 2014


Alan Gauld <alan.gauld at btinternet.com> writes:

> On 09/03/14 19:56, Ben Finney wrote:
> > Now all I need is for the Tkinter-using community to change itself
> > to fix this confusing practice [‘from tkinter import *’]. I won't
> > hold my breath.
>
> I don't find everyone in the Tkinter community using from tkinter
> import *, quite a few use normal practice.

Then they are not following the advice of the documentation
<URL:http://docs.python.org/3/library/tkinter.html>, which explicitly
recommends ‘from tkinter import *’.

It's also prevalent in third-party <URL:http://effbot.org/tkinterbook/>
<URL:http://www.tkdocs.com/> documents which are referenced from the
official documentation.

This one <URL:http://infohost.nmt.edu/tcc/help/pubs/tkinter/web/> does
at least get it right. If ‘import tkinter as tk’ were to become the norm
in official and third-party documentation, I'd agree the problem would
be solved at that point.

-- 
 \          “One bad programmer can easily create two new jobs a year. |
  `\      Hiring more bad programmers will just increase our perceived |
_o__)                     need for them.” —David Lorge Parnas, 1999-03 |
Ben Finney



More information about the Tutor mailing list