Commit Graph

98290 Commits

Author SHA1 Message Date
Serhiy Storchaka 7972ed2111 [3.6] bpo-31411: Prevent raising a SystemError in case warnings.onceregistry is not a dictionary. (GH-3485). (#3494)
(cherry picked from commit 252033d50e)
2017-09-11 10:01:47 +03:00
Serhiy Storchaka c67838da2c [3.6] bpo-29526: Add reference to help('FORMATTING') in format() builtin (GH-166). (#3491)
(cherry picked from commit 2e6bb4484e)
2017-09-11 09:26:15 +03:00
Miss Islington (bot) 4a8b53a208 [3.6] bpo-30781: IDLE: Fix help button on configdialog (GH-3238) (#3489)
This fixes an omission in the ttk conversion patch for this issue, hence no new news.
Patch by Cheryl Sabella.
(cherry picked from commit 3866d9bbcf)
2017-09-10 23:19:35 -04:00
Henk-Jaap Wagenaar 2a0f7c34c3 Backport docstring improvements to OrderedDict. (GH-3470) 2017-09-10 18:11:18 -07:00
Terry Jan Reedy d6c397bf77 [3.6] bpo-27099: IDLE - Convert built-in extensions to regular features (GH-2494) (#3487)
About 10 IDLE features were implemented as supposedly optional
extensions.  Their different behavior could be confusing or worse for
users and not good for maintenance.  Hence the conversion.

The main difference for users is that user configurable key bindings
for builtin features are now handled uniformly.  Now, editing a binding
in a keyset only affects its value in the keyset.  All bindings are
defined together in the system-specific default keysets in config-
extensions.def.  All custom keysets are saved as a whole in config-
extension.cfg.  All take effect as soon as one clicks Apply or Ok.

The affected events are '<<force-open-completions>>', '<<expand-word>>',
'<<force-open-calltip>>', '<<flash-paren>>', '<<format-paragraph>>',
'<<run-module>>', '<<check-module>>', and '<<zoom-height>>'.  Any
(global) customizations made before 3.6.3 will not affect their keyset-
specific customization after 3.6.3. and vice versa.

Inital patch by Charles Wohlganger, revised by Terry Jan Reedy.
(cherry picked from commit 58fc71c)
2017-09-10 20:30:46 -04:00
Christian Heimes 28580316a5 bpo-29136: Fix versionchange for TLS 1.3 changes (#3483)
Thanks Arfrever!

Signed-off-by: Christian Heimes <christian@python.org>
2017-09-10 21:14:34 +02:00
Miss Islington (bot) f8909d0e4b [3.6] bpo-31406: Fix crash due to lack of type checking in subclassing. (GH-3477) (#3479)
(cherry picked from commit 3cedf46cdb)
2017-09-10 18:46:49 +02:00
Miss Islington (bot) 638601ec52 [3.6] Improve IncrementalEncoder documentation (GH-2746) (GH-3475)
getstate and setstate are instance methods, same as encode and reset.
(cherry picked from commit 30644dee0c)
2017-09-10 06:26:42 -07:00
R. David Murray f8693229f5 [3.6] Clarify nature of parse_args 'args' argument. (GH-3292) (GH-3325)
Patch by Paul.j3.  Includes an unrelated but useful addition to the
optparse porting section.
(cherry picked from commit 0c7983e4ad)
2017-09-09 22:54:05 -07:00
Miss Islington (bot) fe9bebf960 [3.6] Make `json.dumps()` example to be PEP-8 compliant. (GH-3472) (GH-3473)
(cherry picked from commit a7fbad96c8)
2017-09-09 10:26:49 -07:00
Christian Heimes 16f16dbd0e [3.6] bpo-31400: Improve SSL error handling on Windows (GH-3463) (#3466)
* bpo-31392: Improve SSL error handling on Windows

* Remove unnecessary Windows mention in NEWS.
(cherry picked from commit e6eb48c10d)
2017-09-09 08:22:11 -07:00
Miss Islington (bot) a4baf1c543 [3.6] bpo-26669: Fix nan arg value error in pytime.c (GH-3085) (GH-3467)
* Modify NaN check function and error message
* Fix pytime.c when arg is nan
* fix whitespace
(cherry picked from commit 829dacce4f)
2017-09-08 21:53:04 -07:00
Miss Islington (bot) 3892799668 [3.6] bpo-30822: Deduplicate ZoneInfoTest classes in test_datetime. (GH-2534) (#3405)
(cherry picked from commit 34b54873b5)
2017-09-08 15:44:33 -07:00
Miss Islington (bot) ef18b0dab9 [3.6] Fixes reference leak (GH-3457) (#3460)
(cherry picked from commit af8d6b9072)
2017-09-08 14:26:27 -07:00
Serhiy Storchaka ddb536ba7b [3.6] bpo-31393: Fix the use of PyUnicode_READY(). (GH-3451). (#3453)
(cherry picked from commit e3b2b4b8d9)
2017-09-08 10:43:54 +03:00
Christian Heimes 9f2b3d4c28 [3.6] bpo-29136: Add TLS 1.3 cipher suites and OP_NO_TLSv1_3 (GH-1363) (#3444)
* bpo-29136: Add TLS 1.3 support

TLS 1.3 introduces a new, distinct set of cipher suites. The TLS 1.3
cipher suites don't overlap with cipher suites from TLS 1.2 and earlier.
Since Python sets its own set of permitted ciphers, TLS 1.3 handshake
will fail as soon as OpenSSL 1.1.1 is released. Let's enable the common
AES-GCM and ChaCha20 suites.

Additionally the flag OP_NO_TLSv1_3 is added. It defaults to 0 (no op) with
OpenSSL prior to 1.1.1. This allows applications to opt-out from TLS 1.3
now.

Signed-off-by: Christian Heimes <christian@python.org>.
(cherry picked from commit cb5b68abde)
2017-09-07 20:23:52 -07:00
Zackery Spytz f032e9237a [3.6] bpo-30640: Fix undefined behavior in _PyFunction_FastCallDict() and PyEval_EvalCodeEx() (GH-2919) (#2964)
k + 1 was calculated with k = NULL..
(cherry picked from commit c6ea8974e2)
2017-09-08 03:17:38 +02:00
Miss Islington (bot) 645c1e4213 [3.6] bpo-31036: Allow sphinx and blurb to be found automatically (GH-3440) (#3441)
Rather than requiring the path to blurb and/or sphinx-build to be specified to the make rule, enhance the Doc/Makefile to look for each first in a virtual environment created by make venv and, if not found, look on the normal process PATH. This allows the Doc/Makefile to take advantage of an installed spinx-build or blurb and, thus, do the right thing most of the time. Also, make the directory for the venv be configurable and document the `make venv` target.
(cherry picked from commit 590665c399)
2017-09-07 17:38:31 -07:00
Christian Heimes 9423f5d688 [3.6] bpo-27340: Use memoryview in SSLSocket.sendall() (GH-3384) (#3434)
* bpo-27340: Use memoryview in SSLSocket.sendall()

SSLSocket.sendall() now uses memoryview to create slices of data. This fix
support for all bytes-like object. It is also more efficient and avoids
costly copies.

Signed-off-by: Christian Heimes <christian@python.org>

* Cast view to bytes, fix typo

Signed-off-by: Christian Heimes <christian@python.org>.
(cherry picked from commit 888bbdc192)
2017-09-07 16:59:17 -07:00
Christian Heimes 6c99b652f7 [3.6] bpo-28958: Improve SSLContext error reporting. (GH-3414) (#3432)
Signed-off-by: Christian Heimes <christian@python.org>
(cherry picked from commit 17c9ac9)
2017-09-07 16:45:39 -07:00
Miss Islington (bot) fb4c28c032 [3.6] bpo-22635: Update the getstatusoutput docstring. (GH-3435) (#3439)
To match the documentation updates already made.
Also renames the local variable used within to match
what it actually holds.
(cherry picked from commit 2eb0cb4787)
2017-09-07 16:44:58 -07:00
Miss Islington (bot) 27ce5a1b19 [3.6] bpo-31294: Fix ZeroMQSocketListener and ZeroMQSocketHandler examples (GH-3229) (#3430)
* Fix ZeroMQSocketListener and ZeroMQSocketHandler examples

* Use send_json and recv_json to simplify pyzmq interfacing

* Add News entry
(cherry picked from commit 586c0502b5)
2017-09-07 14:27:44 -07:00
Miss Islington (bot) e89b35dd2b [3.6] bpo-31330: Clarify that RawTextHelpFormatter collapses repeated newlines. (GH-3272) (GH-3429)
Also provide a solution if the user wants to keep multiple blank lines.
(cherry picked from commit 397c467c49)
2017-09-07 17:18:45 -04:00
Steve Dower 76006f285a [3.6] bpo-30389 Adds detection of VS 2017 to distutils._msvccompiler GH-1632 (#3425) 2017-09-07 13:58:07 -07:00
Miss Islington (bot) b03623227e [3.6] fixes bpo-31373: fix undefined floating-point demotions (GH-3396) (#3424)
(cherry picked from commit a853a8ba78)
2017-09-07 11:35:03 -07:00
Miss Islington (bot) b0d0217c0e [3.6] bpo-30096: Use ABC in abc reference examples (GH-1220) (GH-3408)
Use base class rather than metaclass in examples.
(cherry picked from commit 122e88a835)
2017-09-07 11:32:07 -07:00
Christian Heimes 2a75012b82 [3.6] Update multissl test helper (GH-3349) (#3415)
Signed-off-by: Christian Heimes <christian@python.org>
(cherry picked from commit d3b9f97)
2017-09-07 10:12:03 -07:00
Steve Dower cb44b626da Add props file for nuget packages (#3410) (#3413) 2017-09-06 20:41:32 -07:00
Ned Deily b368e4e8ce Link to generated changelog, not website. 2017-09-06 20:17:09 -07:00
Miss Islington (bot) dee54f6010 [3.6] bpo-22635: subprocess.getstatusoutput doc update. (GH-3398) (#3411)
The `subprocess.getstatusoutput` API was inadvertently changed
in Python 3.3.4.  Document the change, it is too late to undo the
API change now as it has shipped in many stable releases.
(cherry picked from commit 738b7d9766)
2017-09-06 19:57:52 -07:00
Miss Islington (bot) aa1afc72c1 bpo-30465: Fix lineno and col_offset in fstring AST nodes (GH-1800) (gh-3409)
For f-string ast nodes, fix the line and columns so that tools such as flake8 can identify them correctly.
(cherry picked from commit e7c566caf1)
2017-09-06 19:43:04 -07:00
Miss Islington (bot) e00e1b812c [3.6] Update `make patchcheck` for blurb and NEWS.d (GH-3406)
(cherry picked from commit 1ba9469e9f)
2017-09-07 10:38:51 +10:00
Miss Islington (bot) 1fc47b40af [3.6] bpo-21649: Add RFC 7525 and Mozilla server side TLS (GH-3387) (GH-3399)
Signed-off-by: Christian Heimes <christian@python.org>
(cherry picked from commit ad0ffa033e)
2017-09-06 17:31:30 -07:00
Miss Islington (bot) e29ab7e751 [3.6] bpo-30824: Add mimetype for .json (GH-3048) (#3401)
(cherry picked from commit 8204b90368)
2017-09-06 20:04:14 -04:00
Steve Dower fd645ec6f5 [3.6] bpo-31340: Change to building with MSVC v141 (included with Visual Studio 2017) (GH-3311) (#3386) 2017-09-06 15:55:25 -07:00
Miss Islington (bot) 34c67614c1 [3.6] Fixes Tix build by correcting the directories used by Tcl and Tk. (GH-3391) (#3392) 2017-09-06 15:00:26 -07:00
Miss Islington (bot) 98ceece8f4 [3.6] bpo-30737: Update DevGuide links to new URL (GH-3228) (GH-3390)
Update old devguide links from https://docs.python.org/devguide to https://devguide.python.org
(cherry picked from commit 384899dfae)
2017-09-06 14:29:04 -07:00
Gregory P. Smith 3bad1650a0 [3.6] bpo-31178: Avoid concatenating bytes with str in subprocess error (GH-3066) (#3388)
Avoid concatenating bytes with str in the typically rare subprocess error path (exec failed). Includes a mock based unittest to exercise the codepath.
(cherry picked from commit 3fc499bca1)
2017-09-06 13:34:17 -07:00
Miss Islington (bot) 3aea3c298b [3.6] Stop test_xmlrpc from writing to sys.stderr (GH-3359) (#3380)
One test case of test_xmlrpc uses HTTPServer with a subclass of
BaseHTTPRequestHandler. The BaseRequestHandler class logs to
sys.stderr by default. Override log_message() to not clobber
test output.

Signed-off-by: Christian Heimes <christian@python.org>
(cherry picked from commit 3463ee3972)
2017-09-06 10:22:14 -07:00
Christian Heimes 6da379bde3 [3.6] bpo-29781: Fix SSLObject.version before handshake (GH-3364) (#3381)
SSLObject.version() now correctly returns None when handshake over BIO has
not been performed yet.

Signed-off-by: Christian Heimes <christian@python.org>
(cherry picked from commit 6877111)
2017-09-06 06:42:30 -07:00
Christian Heimes c3c3062169 [3.6] _pickle: Fix whichmodule() (GH-3358) (#3361)
_PyUnicode_FromId() can return NULL: replace Py_INCREF() with
Py_XINCREF().

Fix coverity report: CID 1417269.
(cherry picked from commit af46eb8)
2017-09-05 21:43:19 -07:00
Miss Islington (bot) ff125e1aa9 bpo-31350: Optimize get_event_loop and _get_running_loop (GH-3347) (GH-3373)
* call remove_done_callback in finally section

* Optimize get_event_loop and _get_running_loop

* rename _loop_pid as loop_pid and add blurb news

* rename _loop_pid as loop_pid and add blurb news

* add back _RunningLoop

* Update 2017-09-05-10-30-48.bpo-31350.dXJ-7N.rst

* Update 2017-09-05-10-30-48.bpo-31350.dXJ-7N.rst
(cherry picked from commit 80bbe6a7b6)
2017-09-05 20:05:35 -07:00
Victor Stinner 11453524ed bpo-31355: Travis CI: remove the macOS job (#3367) 2017-09-05 18:41:28 -07:00
Mariatta 3b9d4444fe [3.6] bpo-30662: fixed OrderedDict.__init__ docstring re PEP 468 (GH-2179) (GH-3370)
* fixed OrderedDict.__init__ docstring re PEP 468

* tightened comment and mirrored to C impl

* added space after period per marco-buttu

* preserved substituted for stable

* drop references to Python 3.6 and PEP 468
(cherry picked from commit faa57cbe70)
2017-09-05 18:13:07 -07:00
Miss Islington (bot) c506403faf [3.6] bpo-31320: No traceback to sys.stderr in test_ssl (GH-3360) (GH-3369)
In case PROTOCOL_TLS_SERVER is used for both client context and server
context, the test thread dies with OSError. Catch OSError to avoid
traceback on sys.stderr

Signed-off-by: Christian Heimes <christian@python.org>
(cherry picked from commit 305e56c27a)
2017-09-05 18:11:31 -07:00
Zachary Ware 56b56e3da0 [3.6] Cache externals, depending on changes to PCbuild (GH-3308) (#3366)
(cherry picked from commit f801322e92)
2017-09-05 18:01:33 -07:00
Benjamin Peterson 1b1329debc [3.6] link to legacy doc on the non-legacy website (GH-3362) (#3368)
(cherry picked from commit 60dbed1850)
2017-09-05 17:45:11 -07:00
Victor Stinner 9a3b3852af bpo-30442: Skips refcount test in test_xml_etree under coverage (#1767) (#3363)
(cherry picked from commit 1de4705d00)
2017-09-06 02:10:08 +02:00
Victor Stinner e5f2f80385 bpo-31170: Update libexpat from 2.2.3 to 2.2.4 (#3315) (#3350)
* bpo-31170: Update libexpat from 2.2.3 to 2.2.4

Fix copying of partial characters for UTF-8 input (libexpat bug 115):
https://github.com/libexpat/libexpat/issues/115

* Add NEWS entry.

(cherry picked from commit 759e30ec47)
2017-09-06 01:30:22 +02:00
Victor Stinner 6fce7ea893 bpo-30445: Allow appended output in RecursionError message (#3356)
Running under coverage sometimes causes 'in comparison' to be added to the end of the RecursionError message, which is acceptable.

Patched by Maria Mckinley

(cherry picked from commit 3480ef9dd3)
2017-09-06 01:07:44 +02:00