PEP 394: Change verb tense & cover 2.7 maintenance extension

This commit is contained in:
Nick Coghlan 2014-09-30 21:20:14 +10:00
parent 0f8d772c36
commit 68458f5634
1 changed files with 15 additions and 15 deletions

View File

@ -76,12 +76,12 @@ Rationale
This recommendation is needed as, even though the majority of distributions
still alias the ``python`` command to Python 2, some now alias it to
Python 3 ([5]_). As some of the former distributions do not yet provide a
``python2`` command by default, there is currently no way for Python 2 code
Python 3 ([5]_). As some of the former distributions did not provide a
``python2`` command by default, there was previously no way for Python 2 code
(or any code that invokes the Python 2 interpreter directly rather than via
``sys.executable``) to reliably run on all Unix-like systems without
modification, as the ``python`` command will invoke the wrong interpreter
version on some systems, and the ``python2`` command will fail completely
modification, as the ``python`` command would invoke the wrong interpreter
version on some systems, and the ``python2`` command would fail completely
on others. The recommendations in this PEP provide a very simple mechanism
to restore cross-platform support, with minimal additional work required
on the part of distribution maintainers.
@ -98,7 +98,7 @@ refer to ``python3`` rather than ``python2``.
This recommendation will be periodically reviewed over the next few years,
and updated when the core development team judges it appropriate. As a
point of reference, regular maintenance releases for the Python 2.7 series
will continue until at least 2015.
will continue until at least 2020.
Migration Notes
@ -119,8 +119,9 @@ making such a change.
yet familiar with the backwards incompatible changes in Python 3. For
example, while the change of ``print`` from a statement to a builtin
function is relatively simple for automated converters to handle, the
SyntaxError from attempting to use the Python 2 notation in Python 3 is
thoroughly confusing if you aren't already aware of the change::
SyntaxError from attempting to use the Python 2 notation in versions of
Python 3 prior to 3.4.2 is thoroughly confusing if you aren't already
aware of the change::
$ python3 -c 'print "Hello, world!"'
File "<string>", line 1
@ -128,6 +129,8 @@ making such a change.
^
SyntaxError: invalid syntax
(In Python 3.4.2+, that generic error message has been replaced with the
more explicit "SyntaxError: Missing parentheses in call to 'print'")
* Avoiding breakage of such third party scripts is the key reason this
PEP recommends that ``python`` continue to refer to ``python2`` for the
time being. Until the conventions described in this PEP are more widely
@ -169,9 +172,6 @@ making such a change.
``python`` command is only executed in an interactive manner as a user
convenience, or to run scripts that are source compatible with both Python
2 and Python 3.
* one symbolic date being considered for a possible change to the official
recommendation in this PEP is the planned switch of Python 2.7 from full
maintenance to security update only status in 2015 (see PEP 373).
Backwards Compatibility
@ -190,7 +190,7 @@ Application to the CPython Reference Interpreter
================================================
While technically a new feature, the ``make install`` and ``make bininstall``
command in the 2.7 version of CPython will be adjusted to create the
command in the 2.7 version of CPython were adjusted to create the
following chains of symbolic links in the relevant ``bin`` directory (the
final item listed in the chain is the actual installed binary, preceding
items are relative symbolic links)::
@ -198,9 +198,9 @@ items are relative symbolic links)::
python -> python2 -> python2.7
python-config -> python2-config -> python2.7-config
Similar adjustments will be made to the Mac OS X binary installer.
Similar adjustments were made to the Mac OS X binary installer.
This feature will first appear in the default installation process in
This feature first appeared in the default installation process in
CPython 2.7.3.
The installation commands in the CPython 3.x series already create the
@ -211,7 +211,7 @@ appropriate symlinks. For example, CPython 3.2 creates::
pydoc3 -> pydoc3.2
python3-config -> python3.2-config
And CPython 3.3 will create::
And CPython 3.3 creates::
python3 -> python3.3
idle3 -> idle3.3
@ -219,7 +219,7 @@ And CPython 3.3 will create::
python3-config -> python3.3-config
pysetup3 -> pysetup3.3
The implementation progress of these features in the default installers is
The implementation progress of these features in the default installers was
managed on the tracker as issue #12627 ([3]_).