You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Here is a patch that implements PEP-488 **except** for Windows installer stuff. I don't think the Windows changes need to block this patch going in, but I will need someone on Windows to help fix up PC/, PCbuild/, Tools/msi, Lib/distutils/command/bdist_msi.py, and Lib/distutils/command/bdist_wininst.py (if you just search for [pyo] you will find what needs an update).
Otherwise if someone wants to give the patch a review you can feel free, else I will commit it at PyCon (do be aware that if you run tests under -O and -OO there are several failures that have nothing to do with this patch).
I don't actually see any essential changes. The bdist_wininst and bdist_msi changes are just for usage help, and presumably they'll go from "do not compile .py to .pyo (optimized)" to "do not compile .py to optimized .pyc".
I'd prefer to leave the .pyo file association in the installer, since it will affect previous installations.
The only change I see in PC/ is PC/getpathp.c, which is just removing a condition on "o" vs "c", and I don't see anything in PCBuild/ that really needs fixing. (Removing the cleanup code is unnecessary and leaving it in may help make sure the buildbots clean up any old .pyo files after we stop creating them.)
Activity
brettcannon commentedon Mar 21, 2015
https://www.python.org/dev/peps/pep-0488/
brettcannon commentedon Mar 22, 2015
Will probably want to see http://bugs.python.org/issue17232 resolved as part of this as well.
brettcannon commentedon Apr 1, 2015
Here is a patch that implements PEP-488 **except** for Windows installer stuff. I don't think the Windows changes need to block this patch going in, but I will need someone on Windows to help fix up PC/, PCbuild/, Tools/msi, Lib/distutils/command/bdist_msi.py, and Lib/distutils/command/bdist_wininst.py (if you just search for [pyo] you will find what needs an update).
Otherwise if someone wants to give the patch a review you can feel free, else I will commit it at PyCon (do be aware that if you run tests under -O and -OO there are several failures that have nothing to do with this patch).
zooba commentedon Apr 1, 2015
I don't actually see any essential changes. The bdist_wininst and bdist_msi changes are just for usage help, and presumably they'll go from "do not compile .py to .pyo (optimized)" to "do not compile .py to optimized .pyc".
I'd prefer to leave the .pyo file association in the installer, since it will affect previous installations.
The only change I see in PC/ is PC/getpathp.c, which is just removing a condition on "o" vs "c", and I don't see anything in PCBuild/ that really needs fixing. (Removing the cleanup code is unnecessary and leaving it in may help make sure the buildbots clean up any old .pyo files after we stop creating them.)
pfmoore commentedon Apr 1, 2015
A few minor review comments. Nothing substantial, tbh. Looks good.
ericsnowcurrently commentedon Apr 2, 2015
Thanks for doing this, Brett. It's so simple a change yet such a great one. :)
ericsnowcurrently commentedon Apr 9, 2015
LGTM
python-dev commentedon Apr 13, 2015
New changeset a86d630555bd by Brett Cannon in branch 'default':
Issue bpo-23731: Implement PEP-488.
https://hg.python.org/cpython/rev/a86d630555bd
brettcannon commentedon Apr 13, 2015
Thanks to Paul and Eric for the review and everyone who provided input!
python-dev commentedon May 13, 2015
New changeset bbdbc4399b52 by Zachary Ware in branch 'default':
Issue bpo-23731: Fix tracemalloc test on Windows.
https://hg.python.org/cpython/rev/bbdbc4399b52