[issue12982] .pyo file cannot be imported

2011-09-16 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: Eric, you can initially give a doc patch as text in a message, though an actual diff in nicer and may get action sooner. I agree that something could be added. Perhaps the quote It is possible should be followed with something like

[issue12982] .pyo file cannot be imported

2011-09-15 Thread Eric O. LEBIGOT
Eric O. LEBIGOT eric.lebi...@normalesup.org added the comment: Indeed. Thanks. I wish it had been in the documentation. :) This is yet another reason for me to check how I can submit patches to the doc. :) I also found out that renaming the .pyo file as .pyc makes Python happy upon import.

[issue12982] .pyo file cannot be imported

2011-09-15 Thread STINNER Victor
STINNER Victor victor.stin...@haypocalc.com added the comment: Indeed. Thanks. I wish it had been in the documentation. :) This is yet another reason for me to check how I can submit patches to the doc. :) Read http://docs.python.org/devguide/ to learn how to get the source of the

[issue12982] .pyo file cannot be imported

2011-09-14 Thread Eric O. LEBIGOT
New submission from Eric O. LEBIGOT eric.lebi...@normalesup.org: 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

[issue12982] .pyo file cannot be imported

2011-09-14 Thread STINNER Victor
STINNER Victor victor.stin...@haypocalc.com added the comment: You need to run Python with -O command line option to ask Python to search for *.pyo files. -- nosy: +haypo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12982