Message153076
I am not really sure that it is a bug, but for me it's at least not the expected behaviour.
In short supposing I have two namespace packages ab and ac (as seen in the tar file), this works perfectly:
import sys
from os import path
sys.path.append(path.abspath('ab'))
sys.path.append(path.abspath('ac'))
from a.b import api as api_ab
from a.c import api as api_ac
But this doesn't:
import sys
from os import path
sys.path.append(path.abspath('ab'))
from a.b import api as api_ab
sys.path.append(path.abspath('ac'))
from a.c import api as api_ac
And raises an ImportError
from a.c import api as api_ac
ImportError: No module named c
Which means that if you actually append all the paths containing package resources before trying to import something it works, but if you interleave the path mangling, it won't..
Is this a bug or maybe I'm doing something wrong? |
|
Date |
User |
Action |
Args |
2012-02-10 20:53:23 | andrea.crotti | set | recipients:
+ andrea.crotti, tarek, eric.araujo |
2012-02-10 20:53:23 | andrea.crotti | set | messageid: <1328907203.29.0.677752935093.issue13991@psf.upfronthosting.co.za> |
2012-02-10 20:53:22 | andrea.crotti | link | issue13991 messages |
2012-02-10 20:53:22 | andrea.crotti | create | |
|