Message19308
If you call reload() with a module that was imported from
a zip, it fails with a "no such module" error. Although
zips are typically read-only, it is possible that a zip could
be modified during a run, and a reload be necessary. If
this is considered unnecessary, then I think a more
informative "can't reload from zip" error would be better
than a 'no such module" one.
"""
>set PYTHONPATH=path/to/spambayes.zip
>python
>>> from spambayes import Options
>>> Options
<module 'spambayes.Options'
from 'c:\spambayes\windows\py2exe\dist\lib\spambayes
.zip\spambayes\Options.pyc'>
>>> reload(Options)
Traceback (most recent call last):
File "<stdin>", line 1, in ?
ImportError: No module named Options
"""
This is with Python 2.3.2 and WinXP. |
|
Date |
User |
Action |
Args |
2007-08-23 14:18:46 | admin | link | issue856103 messages |
2007-08-23 14:18:46 | admin | create | |
|