Code in __init__.py, is it bad form?

Michael Crute mcrute at gmail.com
Mon Feb 23 20:41:59 EST 2009


Is it bad form (i.e. non-pythonic) to have code in your __init__.py
files? I know this is subjective so I'm just looking for the general
consensus. I've heard both sides of the story and I personally feel
its okay if the code pertains to the whole module but have an open
mind about the matter. If you object to code in __init__.py why, and
what alternatives do you propose?

-- 
________________________________
Michael E. Crute
http://mike.crute.org

God put me on this earth to accomplish a certain number of things.
Right now I am so far behind that I will never die. --Bill Watterson



More information about the Python-list mailing list