keyword in package name.

Abhishek Mishra abhishekmishra3 at
Sun Oct 19 10:29:37 CEST 2008

On Oct 19, 12:11 pm, Tino Wildenhain <t... at> wrote:
> Abhishek Mishra wrote:
> > Hello Everyone,
> > I have the habit of using domain names (of either the application or
> > company) in reverse in package names.
> > for e.g. com.spam.app1
> While this seemed a good idea for java, I don't think it makes
> sense for python - the reason: in python you have an import
> mechanism, where in java you just have namespaces.
> Therefore you can always avoid namespace clashes at import time.

Thanks for your reply on a Sunday!

Here's my 2 cents on why I prefer this mechanism -

I would like not to worry about namespace clashes at import time.
Using a toplevel package which isolates your namespace from all
others, is a good idea in my opinion.
This could be a product name (like MoinMoin in MoinMoin), company name
(like google in google app engine - which is just one short of btw), or your DNS.
Therefore I use a domain name lots of times. (I admit that I picked up
this habit from programming a lot in java).

Although it looks like in this case I would have to use just the
project name.

Thanks & Regards,
Abhishek Mishra

More information about the Python-list mailing list