__file__ in 2.0

Jeff Epler jepler at inetnebr.com
Fri Dec 15 09:03:30 EST 2000

On Wed, 13 Dec 2000 06:46:31 GMT, Bryan Mongeau
 <bryan at eevolved.com> wrote:
>And my final question: How do I call __file__ on static modules in 2.0??

You can't.  But if modulename in sys.builtin_module_names, then you know
that no __file__ attribute will be defined.


More information about the Python-list mailing list