changing sys.path

Andrea Crotti andrea.crotti.0 at
Fri Feb 10 14:08:28 CET 2012

I think I finally located the issue with the sys.path extension.

The problem is that I have many namespace directories, for example

  - sub1
  - sub2

   - sub3
   - sub4

But to have everything working I had lib.sub3 in easy-install.pth.
Now if I try to add something else to the path it doesn't take care of 
the namespace
(every in the packages contains: 
and just doesn't find the other submodules..

If I try to add manually lib.sub1, lib.sub2 changing the sys.path the 
imports will only work for the first one.

Strangely if I just create a dev_main.pth in site-packages containing 
the same paths, everything works perfectly.

Any suggestions now that the problem is more clear?

More information about the Python-list mailing list