![]() |
Available news archives:
comp.lang.tcl
-
comp.lang.python
-
comp.security.firewalls
-
sci.crypt -
comp.lang.php -
comp.lang.javascript
|
|
comp.lang.python archive"dynamical" importing
From: Joerg Schuster <joerg.schuster@gmail.com>
Date: Wed Oct 19 2005 - 10:36:57 CEST
Hello,
I need to import modules from user defined paths. I.e. I want to do
module_dir = sys.argv[1]
my_path = os.path.join(module_dir, 'bin', 'my_module')
from my_path import my_object
Obviously, it doesn't work this way. How would it work?
Jörg Schuster
|