2005/12/19, Bo Peng <[EMAIL PROTECTED]>:
Dear list,

Is there a better way than doing

try:
   import aModule
except:
   has_aModule = False
else:
   has_aModule = True

The main concern here is that loading aModule is unnecessary (and may
take time).

If loading aModule is unnecessary, the best way is not loading it atall.
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to