import/from import question

Peter Hansen peter at engcorp.com
Wed Jul 2 15:04:12 EDT 2003


"Artur M. Piwko" wrote:
> 
> Is there a way to detect if module was imported by 'from <mod> import <sth>'
> or by 'import <mod>'?

Why do you want to do that?  It's likely to be a bad idea...




More information about the Python-list mailing list