what is __init__.py used for?

Simon Brunning simon.brunning at gmail.com
Tue Jul 5 04:49:45 EDT 2005

On 5 Jul 2005 01:31:09 -0700, zelzel.zsu at gmail.com <zelzel.zsu at gmail.com> wrote:
> I am a new learner of Python Programming Language.


>    I was wonderring ... what is the __init__.py used for ?
>    This question may seems to be stupid for an expert.
>    But, if you can give the answer, it will be helpful for me.

The __init__.py files make Python treat the directories as packages -
see http://docs.python.org/tut/node8.html#SECTION008400000000000000000.

We have to do something about those URLs!

Simon B,
simon at brunningonline.net,

More information about the Python-list mailing list