Re: [Tutor] Problems importing random on linux
Magnus Lycka
magnus at thinkware.se
Tue Apr 27 06:03:50 EDT 2004
adam at monkeez.org wrote:
> Thanks Kalle - that was exactly it - I've also removed the .pyc files and
> it works fine now. That's one mistake I'll try to avoid again.
You're certainly not the first one to import something
else than the file you expected... If an imported module
doesn't behave as expected, it's easy to verify that it's
the module you think it is...
>>> import random
>>> print random
<module 'random' from 'D:\Python23\lib\random.pyc'>
See? It tells you what file you imported.
--
Magnus Lycka, Thinkware AB
Alvans vag 99, SE-907 50 UMEA, SWEDEN
phone: int+46 70 582 80 65, fax: int+46 70 612 80 65
http://www.thinkware.se/ mailto:magnus at thinkware.se
More information about the Tutor
mailing list