Message144049
| Author |
lebigot |
| Recipients |
lebigot |
| Date |
2011年09月14日.20:32:42 |
| SpamBayes Score |
7.2096645e-07 |
| Marked as misclassified |
No |
| Message-id |
<1316032363.3.0.192750692303.issue12982@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
When creating a .pyo file (either with -O or -OO) and removing any .pyc or .py original file, import <module_name> complains with "No module called <module_name>". The import does work with .pyc files.
I'm not sure that this is the correct behavior, as the documentation does not seem to make any difference between .pyc and .pyo files on this point:
"It is possible to have a file called spam.pyc (or spam.pyo when -O is used) without a file spam.py for the same module. This can be used to distribute a library of Python code in a form that is moderately hard to reverse engineer." |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2011年09月14日 20:32:43 | lebigot | set | recipients:
+ lebigot |
| 2011年09月14日 20:32:43 | lebigot | set | messageid: <1316032363.3.0.192750692303.issue12982@psf.upfronthosting.co.za> |
| 2011年09月14日 20:32:42 | lebigot | link | issue12982 messages |
| 2011年09月14日 20:32:42 | lebigot | create |
|