Modules are Singletons! (was Re: Catalog of Python Patterns? [LONG!])

Aahz aahz at pythoncraft.com
Fri Apr 5 09:47:10 EST 2002


In article <mailman.1017996733.25069.python-list at python.org>,
Andy Gimblett  <gimbo at ftech.net> wrote:
>
>Really?  I've used Singleton a fair bit (probably too much in fact)
>for stuff like configuration information.  I'm curious as to how else
>I could/should do this.

Use a module.  Don't use a class unless you need a class.
-- 
Aahz (aahz at pythoncraft.com)           <*>         http://www.pythoncraft.com/

"There are times when effort is important and necessary, but this should
not be taken as any kind of moral imperative."  --jdecker



More information about the Python-list mailing list