module = __import__('module', globals=globals())
I think that's what you're looking for.
- alex23
hmm, well, maybe yes.. should i ovveride the standard import function
of the module?
say that the module is called "pycatrix", would adding this to the
module solve the problem?
def __import__('pycatrix', globals=globals()):
pardon, this:
def __import__('pycatrix', globals=globals()):
pass
Are you positively sure you need this?
Modifying imported modules is already quite fragile, but this.. it's
basically a reversed(import *)
It's quite messy. Where quite equals to "very"
well, i'm writing a module called pycatrix. within the module i have
compile / exec statements in a functions that work on global
variables. ( exec compiledTemplate in globals() ).
now, i don't want to be forced (or force the end user) to import to
call the module's function with a compulsory "globals()" as argument.
up