Terry Reedy wrote:
Dr. Phillip M. Feldman wrote:
According to the Python documentation, 'reload' reloads a previously imported module (so that changes made via an external editor will be effective). But, when I try to use this command, I get the following error message:

TypeError: reload() argument must be module

Any suggestions will be appreciated.

Besides the other answers, do not use reload. It is removed in Py3 because it cannot be made to work as people reasonably expect.

tjr

It's typically a user module that needs to be reloaded.

It seems that  del sys.modules['moduleName'] has no effect.

Is there some other way of ensuring that any import goes to moduleName.py, instead of moduleName.pyc?

Colin W.
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to