summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* [3.6] bpo-33001: Prevent buffer overrun in os.symlink (GH-5989) (GH-5990)Steve Dower2018-03-053-28/+74
|
* bpo-32984: IDLE - set __file__ for startup files (GH-5981)Miss Islington (bot)2018-03-052-0/+10
| | | | | | | | | | | | Like Python, IDLE optionally runs one startup file in the Shell window before presenting the first interactive input prompt. For IDLE, option -s runs a file named in environmental variable IDLESTARTUP or PYTHONSTARTUP; -r file runs file. Python sets __file__ to the startup file name before running the file and unsets it before the first prompt. IDLE now does the same when run normally, without the -n option. (cherry picked from commit 22c82be5df70c3d51e3f89b54fe1d4fb84728c1e) Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* bpo-32857: Raise error when tkinter after_cancel() is called with None. ↵Miss Islington (bot)2018-03-043-3/+115
| | | | | | | (GH-5701) (cherry picked from commit 74382a3f175ac285cc924a73fd758e8dc3cc41bb) Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
* [3.6] bpo-32981: Fix catastrophic backtracking vulns (GH-5955)Benjamin Peterson2018-03-046-4/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Prevent low-grade poplib REDOS (CVE-2018-1060) The regex to test a mail server's timestamp is susceptible to catastrophic backtracking on long evil responses from the server. Happily, the maximum length of malicious inputs is 2K thanks to a limit introduced in the fix for CVE-2013-1752. A 2KB evil response from the mail server would result in small slowdowns (milliseconds vs. microseconds) accumulated over many apop calls. This is a potential DOS vector via accumulated slowdowns. Replace it with a similar non-vulnerable regex. The new regex is RFC compliant. The old regex was non-compliant in edge cases. * Prevent difflib REDOS (CVE-2018-1061) The default regex for IS_LINE_JUNK is susceptible to catastrophic backtracking. This is a potential DOS vector. Replace it with an equivalent non-vulnerable regex. Also introduce unit and REDOS tests for difflib. Co-authored-by: Tim Peters <tim.peters@gmail.com> Co-authored-by: Christian Heimes <christian@python.org>. (cherry picked from commit 0e6c8ee2358a2e23117501826c008842acb835ac)
* Fix missing coroutine declaration in the asyncio documentation. (GH-5964)Miss Islington (bot)2018-03-031-1/+1
| | | | | (cherry picked from commit 13cfd57dcf58485d6242fd8118c6ea4b10e29aab) Co-authored-by: Joongi Kim <me@daybreaker.info>
* [3.6] bpo-32964: Reuse a testing implementation of the path protocol in ↵Serhiy Storchaka2018-03-0311-95/+76
| | | | | | | tests. (GH-5930). (GH-5958) (cherry picked from commit b21d155f57d284aecf9092a9bd24258293965c2f) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* bpo-32903: Fix a memory leak in os.chdir() on Windows (GH-5801) (#5946)Miss Islington (bot)2018-03-012-7/+9
| | | | | (cherry picked from commit 3e197c7a6740d564ad52fb7901c07d5ff49460f5) Co-authored-by: Alexey Izbyshev <izbyshev@users.noreply.github.com>
* bpo-32940: IDLE: Simplify StringTranslatePseudoMapping in pyparse (GH-5862)Miss Islington (bot)2018-02-283-89/+32
| | | | | | The new code also runs faster. (cherry picked from commit f0daa880a405c8de6743e44fa46006754aa145c9) Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
* bpo-30928: Update idlelib/NEWS.txt, possibly for 3.7.0b2 (GH-5932)Miss Islington (bot)2018-02-281-0/+16
| | | | | (cherry picked from commit 0954c9e9c8fbea452f56120df592f2061d3209c7) Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* [3.6] bpo-32922: dbm.open() now encodes filename with the filesystem ↵Serhiy Storchaka2018-02-278-19/+134
| | | | | | | encoding. (GH-5832). (GH-5906) (cherry picked from commit 6f600ff1734ca2fdcdd37a809adf8130f0d8cc4e) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* bpo-32713: Fix tarfile.itn for large/negative float values. (GH-5434)Miss Islington (bot)2018-02-273-1/+11
| | | | | (cherry picked from commit 72d9b2be36f091793ae7ffc5ad751f040c6e6ad3) Co-authored-by: Joffrey F <f.joffrey@gmail.com>
* bpo-32222: Fix pygettext skipping docstrings for funcs with arg typehints ↵Miss Islington (bot)2018-02-263-4/+102
| | | | | | | (GH-4745) (cherry picked from commit eee72d4778a5513038edd5236cdd87ccce2bc60a) Co-authored-by: Tobotimus <Tobotimus@users.noreply.github.com>
* Fix _socket module compilation on Cygwin. (GH-4137) (GH-4145)Miss Islington (bot)2018-02-261-1/+1
| | | (cherry picked from commit 63ae04461fb0cc93ca57cd151103a8dd295581d6)
* Revert "[3.6] bpo-32303 - Consistency fixes for namespace loaders (GH-5481) ↵Barry Warsaw2018-02-269-1473/+1439
| | | | | (#5504)" (#5911) This reverts commit a71397fb6603d0fe673acd7765c74699cd28fe7b.
* [3.6] bpo-32394: Remove some TCP options on older version Windows. (GH-5585)animalize2018-02-264-0/+92
|
* bpo-18533: Avoid RecursionError from repr() of recursive dictview (GH-4823)Miss Islington (bot)2018-02-264-4/+44
| | | | | | | | | | | | | | | | | | dictview_repr(): Use a Py_ReprEnter() / Py_ReprLeave() pair to check for recursion, and produce "..." if so. test_recursive_repr(): Check for the string rather than a RecursionError. (Test cannot be any tighter as contents are implementation-dependent.) test_deeply_nested_repr(): Add new test, replacing the original test_recursive_repr(). It checks that a RecursionError is raised in the case of a non-recursive but deeply nested structure. (Very similar to what test_repr_deep() in test/test_dict.py does for a normal dict.) OrderedDictTests: Add new test case, to test behavior on OrderedDict instances containing their own values() or items(). (cherry picked from commit d7773d92bd11640a8c950d6c36a9cef1cee36f96)
* bpo-31454: Include information about "import X as Y" in Modules tutorial ↵Miss Islington (bot)2018-02-251-0/+19
| | | | | | | (GH-4041) (cherry picked from commit fbee88244e8921afdb29fde51a9a010a8ae18277) Co-authored-by: Mario Corchero <mariocj89@gmail.com>
* bpo-25059: Clarify the print separator usage in tutorial (GH-5879)Miss Islington (bot)2018-02-251-1/+1
| | | | | | By default `print` adds spaces between its arguments. (cherry picked from commit 84c4b0cc67ceb4b70842b78c718b6e8214874d6a) Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
* Delete a broken threading.local example (GH-5870)Miss Islington (bot)2018-02-251-5/+1
| | | | | | This code never did anything correct or useful. The class attribute will never be affected, and the condition will never be true. (cherry picked from commit 5fb632e83136399bad9427ee23ec8b771695290a) Co-authored-by: Aaron Gallagher <habnabit@users.noreply.github.com>
* [3.6] bpo-30622: Fix NPN for OpenSSL 1.1.1-pre1 (GH-5876) (#5881)Christian Heimes2018-02-252-24/+29
| | | | | | Signed-off-by: Christian Heimes <christian@python.org>. (cherry picked from commit 29eab55309b9f78b79074d26db16a44e7841c639) Co-authored-by: Christian Heimes <christian@python.org>
* [3.6] bpo-32647: Link ctypes extension with libdl. (GH-5550) (#5875)Miss Islington (bot)2018-02-252-0/+6
| | | | | | | | | The ctypes module used to depend on indirect linking for dlopen. The shared extension is now explicitly linked against libdl on platforms with dl. Signed-off-by: Christian Heimes <christian@python.org> (cherry picked from commit 5bb9692575f10f4a7c7f1c2c0c70956baf6d5c23) Co-authored-by: Christian Heimes <christian@python.org>
* [3.6] bpo-30622: Improve NPN support detection (GH-5859) (#5861)Christian Heimes2018-02-254-11/+42
| | | | | | | | | The ssl module now detects missing NPN support in LibreSSL. Co-Authored-By: Bernard Spil <brnrd@FreeBSD.org> Signed-off-by: Christian Heimes <christian@python.org>. (cherry picked from commit 6cdb7954b0a578d899e4b78b868ea59eef08480a) Co-authored-by: Christian Heimes <christian@python.org>
* bpo-32185: Don't send IP in SNI TLS extension (#5865)Christian Heimes2018-02-252-2/+42
| | | | | | The SSL module no longer sends IP addresses in SNI TLS extension on platforms with OpenSSL 1.0.2+ or inet_pton. Signed-off-by: Christian Heimes <christian@python.org>
* bpo-17232: Clarify docs for -O and -OO command line options (GH-5839)Miss Islington (bot)2018-02-254-6/+23
| | | | | | The 'optimization' is for space in the executable file, not for run time. (cherry picked from commit 186b606d8a2ea4fd51b7286813302c8e8c7006cc) Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
* bpo-31518: Change TLS protocol for Debian (#3660)Christian Heimes2018-02-246-12/+15
| | | | | | | Debian Unstable has disabled TLS 1.0 and 1.1 for SSLv23_METHOD(). Change TLS/SSL protocol of some tests to PROTOCOL_TLS or PROTOCOL_TLSv1_2 to make them pass on Debian. Signed-off-by: Christian Heimes <christian@python.org>
* bpo-31966: Fixed WindowsConsoleIO.write() for writing empty data. (GH-5754)Miss Islington (bot)2018-02-243-0/+8
| | | | | (cherry picked from commit 42c35d9c0c8175332f50fbe034a001fe52f057b9) Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* bpo-32916: IDLE: Change `str` to `code` in pyparse (GH-5830)Miss Islington (bot)2018-02-245-102/+103
| | | | | | Adjust tests and user modules to match. (cherry picked from commit c29c03a34a9f3c82704b66f323ce5ea9dc89c8af) Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
* bpo-32923: Unittest doc: replace `whilst` with `while` (GH-5833)Miss Islington (bot)2018-02-231-1/+1
| | | | | | | `whilst` and `while` are both english words, `whilst` is not as commonly used. This can be confusing to readers whose primary language is not english. (cherry picked from commit 98f42aac23f3863973cb6e9964c5212cfd3a1d98) Co-authored-by: Mariatta <Mariatta@users.noreply.github.com>
* [3.6] bpo-30028: make test.support.temp_cwd() fork-safe (GH-1066) (GH-5826)Anselm Kruis2018-02-233-1/+35
| | | | | | | Make test.support.temp_cwd() fork-safe. The context manager test.support.temp_cwd() no longer removes the temporary directory when executing in a process other than the parent it entered from. If a forked child exits the context manager it won't do the cleanup.. (cherry picked from commit 33dddac00ba8d9b72cf21b8698504077eb3c23ad) Co-authored-by: Anselm Kruis <a.kruis@science-computing.de>
* bpo-32087: Doc: Make "deprecated-removed" directive translatable (GH-4473)Miss Islington (bot)2018-02-232-5/+8
| | | | | (cherry picked from commit 0febc053736112d7bb9081742b3ac0ece7b973e7) Co-authored-by: cocoatomo <cocoatomo77@gmail.com>
* bpo-32457: Improves handling of denormalized executable path when launching ↵Steve Dower2018-02-223-1/+47
| | | | Python (GH-5756) (#5818)
* bpo-30449: Improve __slots__ documentation (GH-1819)Miss Islington (bot)2018-02-221-14/+15
| | | | | | (cherry picked from commit 2b44e302ec3079363c4d5c875677945953705c58) Co-authored-by: Aaron Hall, MBA <aaronchall@yahoo.com>
* bpo-32905: IDLE - remove unused code in pyparse module (GH-5807)Miss Islington (bot)2018-02-223-50/+8
| | | | | | dump is similar to print but less flexible. lastopenbracketpos is now always initialized in _study2, as was stmt_bracketing, so the class settings are not needed. get_last_open_bracket_pos is never called. (cherry picked from commit 451d1edaf4d27c4e632d81246d308e8dd6ea945f) Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* bpo-32874: IDLE: add tests for pyparse (GH-5755)Miss Islington (bot)2018-02-223-66/+619
| | | | | | There are no code changes other than comments and docstrings. (cherry picked from commit c84cf6c03fce1fb73bfaf91d7909f1c2708f14a2) Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
* bpo-32889: update valgrind suppressions (GH-5779)Miss Islington (bot)2018-02-212-5/+7
| | | | | | | Py_ADDRESS_IN_RANGE was renamed address_in_range in 3.6 (commit 3924f93794fd740c547b44884f73303196475cd5). (cherry picked from commit ba518804bf4c1ea01df5e622b333d3116cbaa3bd) Co-authored-by: Paul Price <price@astro.princeton.edu>
* bpo-32008: don't use PROTOCOL_TLSv1 in example (GH-5789)Miss Islington (bot)2018-02-211-2/+2
| | | | | | | It's bad form to pin to an old version of TLS. ssl.SSLContext has the right protocol default, so let's not pass anyway. (cherry picked from commit e9edee0b65650c4f9db90cefc2e9a8125bad762c) Co-authored-by: Benjamin Peterson <benjamin@python.org>
* bpo-28886: doc: Move deprecated abc decorators to separate section (GH-176)Miss Islington (bot)2018-02-211-22/+17
| | | | | (cherry picked from commit 52c6b89796a7ec391db20281e05b256f57e97b35) Co-authored-by: Harshul jain <harshulrobo@gmail.com>
* closes bpo-32859: Don't retry dup3() if it is not available at runtime (GH-5708)Miss Islington (bot)2018-02-212-1/+3
| | | | | | | | | | | os.dup2() tests for dup3() system call availability at runtime, but doesn't remember the result across calls, repeating the test on each call with inheritable=False. Since the caller of os.dup2() is expected to hold the GIL, fix this by making the variable holding the test result static. (cherry picked from commit b3caf388a0418f6c031e4dbdcc0c1ce7e5cc36bd) Co-authored-by: Alexey Izbyshev <izbyshev@users.noreply.github.com>
* bpo-32540: Update venv documentation (GH-5736)Miss Islington (bot)2018-02-211-4/+3
| | | | | | | If the directory already exists, it will be re-used. (cherry picked from commit e8eb972514cad6086b752754c1d34d703c04dd82) Co-authored-by: TROUVERIE Joachim <joachim.trouverie@linoame.fr>
* bpo-31848: Fix broken error handling in Aifc_read.initfp() when the SSND ↵Miss Islington (bot)2018-02-204-0/+12
| | | | | | | | | chunk is not found (GH-5240) Initialize self._ssnd_chunk so that aifc.Error is raised as intended, not AttributeError. (cherry picked from commit 80d20b918bd8a882043c493a7f958333ecb41727) Co-authored-by: Zackery Spytz <zspytz@gmail.com>
* bpo-32500: Correct the documentation for PySequence_Size() and ↵Miss Islington (bot)2018-02-201-3/+2
| | | | | | | | PySequence_Length() (GH-5767) Dropped the part that says: "For objects that do not provide sequence protocol". (cherry picked from commit 7a1e1786f98ad49caa157dcdf14ada9d0b07d0fd) Co-authored-by: Zackery Spytz <zspytz@gmail.com>
* bpo-32409: Ensures activate.bat can handle Unicode contents (GH-5766)Miss Islington (bot)2018-02-203-0/+32
| | | | | (cherry picked from commit 6240917b773b52f8883387b9e3a5f327a4372068) Co-authored-by: Steve Dower <steve.dower@microsoft.com>
* bpo-30121: Fix test_subprocess for Windows Debug builds (GH-5758)Miss Islington (bot)2018-02-191-1/+1
| | | | | (cherry picked from commit 5537646bfacec463b450871dde31cb06c44a0556) Co-authored-by: Zachary Ware <zachary.ware@gmail.com>
* bpo-32682: Improve libz version parsing in test_zilb (GH-5347)Miss Islington (bot)2018-02-191-4/+9
| | | | | (cherry picked from commit 4c7108a77144493d0aa6fc0105b67d3797e143f5) Co-authored-by: pmp-p <pmp-p@users.noreply.github.com>
* Improve error message for "setup.py upload" without dist files (GH-21060)Miss Islington (bot)2018-02-192-1/+5
| | | | | (cherry picked from commit 08a6926b2584040fe3c3f06263b0b5f1fbbdc24c) Co-authored-by: Éric Araujo <merwok@netwok.org>
* bpo-31972: Improve docstrings for pathlib classes (GH-5310)Miss Islington (bot)2018-02-192-1/+30
| | | | | (cherry picked from commit dfa015cf77a148d229ddc0a5b063562c9f9664f2) Co-authored-by: chason <chason@gmail.com>
* [3.6] Clean up Travis config (GH-5727)Zachary Ware2018-02-181-41/+44
| | | (cherry picked from commit 7eb3f8226ea7b79dae4e4e8b05730cfe0d9af7c1)
* bpo-32869: Fix incorrect dst buffer size for MultiByteToWideChar (GH-5739)Miss Islington (bot)2018-02-181-1/+2
| | | | | | | This function expects the destination buffer size to be given in wide characters, not bytes. (cherry picked from commit b3b4a9d3001f1fc7df8efcccdce081de54fa5eab) Co-authored-by: Alexey Izbyshev <izbyshev@users.noreply.github.com>
* [3.6] Improves the ability to build in CI (GH-5730)Steve Dower2018-02-185-13/+21
|
* [3.6] bpo-30638: Add clinic to `make regen-all` (GH-5671)Zachary Ware2018-02-182-9/+9
| | | | Also, use PYTHON_FOR_REGEN for clinic and blake2s_impl.c rather than PYTHON_FOR_BUILD, and update .travis.yml to make use of the change. (cherry picked from commit d6ff8a7037903497eff95fa32bdac2b6adf71505)