On 6 avr, 12:26, Mathew Grabau <grabau....@gmail.com> wrote: > I totally agree with that. Though, I just read up, if pierreth is > trying to borrow code from app1/modules inside app2/controllers, then > injecting app1/modules into the python path should work. Of course, > this would just avoid having to put the module code inside app2/ > modules (and would provide the ability inside the app2 controller to > use "import moudleA"). >
I want to share code in my applications but I want my applications to be self-contain too. So I use "modules" and not "site-packages". The only problem is that absolute import statements will not import modules in "modules". It is not the Python path. If this becomes a real problem. I'll write a custom Python importer. It is not hard to do.