Re: (More) Re: Is __import__ known to be slow in windows?

2007-12-01 Thread Joshua Kugler
John Machin wrote: On Dec 1, 2:12 pm, Joshua Kugler [EMAIL PROTECTED] wrote: x = __import__(m) Have you ever tried print m, x.__file__ here to check that the modules are being found where you expect them to be found? No, I haven't, but I do know for a fact that the only

(More) Re: Is __import__ known to be slow in windows?

2007-11-30 Thread Joshua Kugler
Ok, so we have this code: t = timeit.Timer(stmt='r()', setup='from __main__ import r') sys.path.insert(0,'/path/to/code') def r(): for m in ['three','module','names']: try: x = __import__(m) except ImportError, e: if not e.message.startswith('No

Re: (More) Re: Is __import__ known to be slow in windows?

2007-11-30 Thread John Machin
On Dec 1, 2:12 pm, Joshua Kugler [EMAIL PROTECTED] wrote: Ok, so we have this code: t = timeit.Timer(stmt='r()', setup='from __main__ import r') sys.path.insert(0,'/path/to/code') def r(): for m in ['three','module','names']: try: x = __import__(m) Have you ever