Difference in Python and Ruby interactive shells
malv
malvert at telenet.be
Tue Apr 4 11:52:55 EDT 2006
I think reload should be preceded by import.
Example:
Online code modification: upon modifying and saving mytest.py issue on
the interactive shell:
>>>import mytest
>>>reload(mytest)
The shell should respond with "<module 'mytest' from
'/root/mytest.py'>" (NOT:mytest.pyc)
Note that modules importing mytest should not use 'import * from
mytest' but 'import mytest';
This requires qualifying all objects as mytest.obj
More information about the Python-list
mailing list