conflict between my package and os standard module

Ben Wittner benwittner at mediaone.net
Mon Jan 17 07:43:40 EST 2000


Thomas,

Thanks for replying.

> Dont forget that you can replace:
>
> import os # you want the 'enhanced' os, you get the standard one
> os.mygetuser(...)
>
> with:
>
> import myproj_os
> os = myproj_os
>
> To avoid rewriting too much code. (add a 'del myproj_os' if you want to
> avoid pollution.)

Cleaver trick.  I'll try to remember it.
Actually, though, my problem is the reverse; in my_proj/os.py, I don't have
access to the standard os services because when I say
import os
in my_proj/os.py, I get my_proj/os.py instead of the standard os.

> Hi! I'm a .signature virus! copy me into your .signature file to help me
spread!

That's pretty darn funny.  :)

-Ben

benwittner at yahoo.com







More information about the Python-list mailing list