bpo-27286 fixed a problem where BUILD_MAP_UNPACK_WITH_CALL could
be emitted with an incorrect oparg value, causing the eval loop
to access the wrong stack entry when attempting to read the
function name.
The associated magic number change caused significant problems when
attempting to upgrade to 3.5.3 for anyone that relies on pre-cached
bytecode remaining valid across maintenance releases.
This patch restores the ability to import legacy bytecode generated
by 3.5.0, 3.5.1 or 3.5.2, and modifies the eval loop to
avoid any harmful consequences from the potentially malformed legacy
bytecode.
Original import patch by Petr Viktorin, eval loop patch by Serhiy Storchaka,
and tests and integration by Nick Coghlan.
Mariatta [Mon, 6 Mar 2017 17:31:00 +0000 (09:31 -0800)]
bpo-29557: Remove ambiguous line in binhex docs (GH-90) (GH-474)
"appears to not work in all cases" does not inspire confidence in this
module. I can find no context for what bug this was referencing so it
should be removed.
(cherry picked from commit 6de2b7817fa9403e81dc38f13f3690f0bbf3d064)
Ned Deily [Sat, 4 Mar 2017 06:34:19 +0000 (01:34 -0500)]
[3.5] bpo-27593: Get SCM build info from git instead of hg. (#446) (#454) (#455)
* bpo-27593: Get SCM build info from git instead of hg. (#446)
sys.version and the platform module python_build(),
python_branch(), and python_revision() functions now use
git information rather than hg when building from a repo.
Berker Peksag [Fri, 3 Mar 2017 15:07:01 +0000 (18:07 +0300)]
Add Python version since deprecation in base64 methods. (#33) (#430)
Allow developers to not have to either test on N Python versions or
looked through multiple versions of the docs to know whether they can
easily update.
> inspect.getargvalues() and inspect.formatargvalues() were deprecated
> in Python 3.5 as part of implementing bpo-20438
> This is incorrect, as these are *frame* introspection related functions,
> not callable introspection ones. The documentation and implementation
> layout is confusing though, as they're interleaved with the callable
> introspection operation
This commit undeprecates these functions and adds a note to ignore
previous deprecation notices.
INADA Naoki [Sun, 19 Feb 2017 05:13:02 +0000 (14:13 +0900)]
[backport to 3.5] bpo-29529: Add .travis.yml to 3.5 branch (#26)
* Add .travis.yml to 3.5 branch
* Only run CI checks when appropriate files have changed (#74)
Closes python/core-workflow#14
* Travis CI: run rstlint.py in the docs job (#68)
Currently, http://buildbot.python.org/all/buildslaves/ware-docs
buildbot is only run as post-commit. For example, bpo-29521 (PR#41)
introduced two warnings, unnotified by the Travis CI docs job.
Modify the docs job to run toosl/rstlint.py.
Fix also the two minor warnings which causes the buildbot slave to
fail.
* Use 'make check' instead of 'python3 tools/rstlint.py' (#96)
Nick Coghlan [Sun, 19 Feb 2017 04:33:50 +0000 (10:03 +0530)]
[3.5] bpo-29571: Use correct locale encoding in test_re (#149) (#154)
``local.getlocale(locale.LC_CTYPE)`` and
``locale.getpreferredencoding(False)`` may give different answers
in some cases (such as the ``en_IN`` locale).
``re.LOCALE`` uses the latter, so update the test case to match.
Victor Stinner [Thu, 16 Feb 2017 09:43:16 +0000 (10:43 +0100)]
Backport35 doc fixes: PR#68 and PR#124 (#125) (#126)
* Travis CI: run rstlint.py in the docs job (#68)
Currently, http://buildbot.python.org/all/buildslaves/ware-docs
buildbot is only run as post-commit. For example, bpo-29521 (PR#41)
introduced two warnings, unnotified by the Travis CI docs job.
Mariatta [Tue, 14 Feb 2017 16:54:22 +0000 (08:54 -0800)]
bpo-29521 Fix two minor documentation build warnings (#41) (#84)
Much of bpo-29521 was fixed in parallel with commit e7ffb99 . This cleans up the rest.
Apply parallel change to Doc/make.bat to read
"set SPHINXOPTS=-D latex_elements.papersize="
I don't have a Windows system on which to observe the warning,
but it should be necessary.
In the Windows FAQ, `How do I keep editors from inserting tabs
into my Python source?`, contained a reference to a Python -t
option. In Python 2.x, this caused Python to issue warnings
about lines with mixed spaces and tabs, but as of Python 3.6
it does nothing.
Per discussion at http://bugs.python.org/issue29387, take
their wording. Python [3] raises an IndentationError or
TabError. Tabnanny is now a module.
(cherry picked from commit 3d707be950b387552585451071928e7b39cdfa53)
Berker Peksag [Sun, 12 Feb 2017 16:18:00 +0000 (19:18 +0300)]
bpo-27122: Fix comment to point to correct issue number (#50)
It took me quite a bit to figure out what this was referring to,
since the given issue number is wrong, and the original commit
message I found through git blame lists a different, also wrong
issue number... see https://bugs.python.org/issue27122#msg279449
Serhiy Storchaka [Wed, 25 Jan 2017 11:23:05 +0000 (13:23 +0200)]
Issue #27867: Function PySlice_GetIndicesEx() is replaced with a macro if
Py_LIMITED_API is not set or set to the value between 0x03050400
and 0x03060000 (not including) or 0x03060100 or higher.
Serhiy Storchaka [Tue, 24 Jan 2017 19:27:12 +0000 (21:27 +0200)]
Issue #29083: Fixed the declaration of some public API functions.
PyArg_VaParse() and PyArg_VaParseTupleAndKeywords() were not available in
limited API. PyArg_ValidateKeywordArguments(), PyArg_UnpackTuple() and
Py_BuildValue() were not available in limited API of version < 3.3 when
PY_SSIZE_T_CLEAN is defined.
Martin Panter [Mon, 23 Jan 2017 22:11:09 +0000 (22:11 +0000)]
Issue #29273: Remove unneeded workaround to restore locale
The “readline” module already has a workaround using setlocale(LC_CTYPE,
NULL). The code in test___all__ calls getlocale(), which can subtly alter
the locale string and cause the test framework to complain.