Commit Graph

103126 Commits

Author SHA1 Message Date
Miss Islington (bot) 15b6d0a712
bpo-37681: no_sanitize_thread support from GCC 5.1 (GH-15096)
Fix the following warning with GCC 4.8.5:
Objects/obmalloc.c: warning: ‘no_sanitize_thread’ attribute directive ignored
(cherry picked from commit 7e479c8221)

Co-authored-by: Hai Shi <shihai1992@gmail.com>
2019-08-14 03:16:54 -07:00
Hai Shi fbb0c032e8 bpo-37583: Add err 113 to support.get_socket_conn_refused_errs() (GH-15259)
Add error number 113 EHOSTUNREACH to get_socket_conn_refused_errs()
of test.support.
2019-08-14 11:52:36 +02:00
Josh Holland 37fd9f73e2 [3.7] bpo-37814: Document the empty tuple type annotation syntax (GH-15208) (GH-15262)
https://bugs.python.org/issue37814:

> The empty tuple syntax in type annotations, `Tuple[()]`, is not obvious from the examples given in the documentation (I naively expected `Tuple[]` to work); it has been documented in PEP 484 and in mypy, but not in the documentation for the typing module.

https://bugs.python.org/issue37814
(cherry picked from commit 8a784af750)

Co-authored-by: Josh Holland <anowlcalledjosh@gmail.com>





https://bugs.python.org/issue37814



Automerge-Triggered-By: @gvanrossum
2019-08-13 12:26:12 -07:00
Miss Islington (bot) 9286677538 Fix docs for assert_called and assert_called_once (GH-15218)
(cherry picked from commit f9590edfea)

Co-authored-by: Ismail S <ismail-s@users.noreply.github.com>
2019-08-12 09:18:55 +01:00
Miss Islington (bot) dec231a73c
bpo-32178: Fix IndexError trying to parse 'To' header starting with ':'. (GH-15044)
This should fix the IndexError trying to retrieve `DisplayName.display_name` and `DisplayName.value` when the `value` is basically an empty string.

https://bugs.python.org/issue32178
(cherry picked from commit 09a1872a80)

Co-authored-by: Abhilash Raj <maxking@users.noreply.github.com>
2019-08-11 14:05:37 -07:00
Miss Islington (bot) c48d606adc
bpo-34155: Dont parse domains containing @ (GH-13079)
Before:

        >>> email.message_from_string('From: a@malicious.org@important.com', policy=email.policy.default)['from'].addresses
        (Address(display_name='', username='a', domain='malicious.org'),)

        >>> parseaddr('a@malicious.org@important.com')
        ('', 'a@malicious.org')

    After:

        >>> email.message_from_string('From: a@malicious.org@important.com', policy=email.policy.default)['from'].addresses
        (Address(display_name='', username='', domain=''),)

        >>> parseaddr('a@malicious.org@important.com')
        ('', 'a@')

https://bugs.python.org/issue34155
(cherry picked from commit 8cb65d1381)

Co-authored-by: jpic <jpic@users.noreply.github.com>
2019-08-09 01:30:33 -07:00
Miss Islington (bot) 7dafbe81bd bpo-37004: Documented asymmetry of string arguments in difflib.SequenceMatcher for ratio method (GH-13482) (#15158)
https://bugs.python.org/issue37004
(cherry picked from commit e9cbcd0018)

Co-authored-by: sweeneyde <36520290+sweeneyde@users.noreply.github.com>
2019-08-07 11:39:47 -04:00
Miss Islington (bot) 18343aba78
Improve signal documentation (GH-14274)
* add a missing ``.. availability::`` reST explicit markup;
* more consistent "see man page" sentences.
(cherry picked from commit cfebfef2de)

Co-authored-by: Géry Ogam <gery.ogam@gmail.com>
2019-08-06 14:55:48 -07:00
Miss Islington (bot) 4969192f99
bpo-36419: IDLE - Refactor autocompete and improve testing. (GH-15121)
(cherry picked from commit 1213123005)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-08-04 17:09:36 -07:00
Miss Islington (bot) a96f0367d4
bpo-37748: Re-order the Run menu. (GH-15115)
Put the most common choice, Run Module, at the top.
(cherry picked from commit 14070299cd)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-08-04 14:07:26 -07:00
Tal Einat a2ea9448c6
[3.7] bpo-34621: backwards-compatible pickle UUID with is_safe=unknown (GH-14834)
This is a fix for a bug introduced in the original implementation of this for 3.7.
2019-08-04 22:26:32 +03:00
Miss Islington (bot) 9e0c48a002
bpo-37706: IDLE - fix sidebar code bug and drag tests (GH-15103)
Convert mouse y to line number in the sidebar rather than the text.
(cherry picked from commit 86f1a18abf)

Co-authored-by: Tal Einat <taleinat+github@gmail.com>
2019-08-04 09:47:11 -07:00
Serhiy Storchaka 8cd6305784
[3.7] bpo-37730: Fix usage of NotImplemented instead of NotImplementedError in docs. (GH-15062). (GH-15106)
(cherry picked from commit ed5e8e06cb)

Co-authored-by: David H <dheiberg@mozilla.com>
2019-08-04 17:06:51 +03:00
Serhiy Storchaka 6ed20e54e4
[3.7] bpo-37685: Fixed comparisons of datetime.timedelta and datetime.timezone. (GH-14996) (GH-15104)
There was a discrepancy between the Python and C implementations.

Add singletons ALWAYS_EQ, LARGEST and SMALLEST in test.support
to test mixed type comparison.
(cherry picked from commit 17e52649c0)
2019-08-04 15:28:21 +03:00
Miss Islington (bot) 0bb8f22abd Correct description of HTTP status code 308. (GH-15097)
Permanent redirect was explained as a temporary redirect.
(cherry picked from commit 5c72badd06)

Co-authored-by: Florian Wendelborn <1133858+FlorianWendelborn@users.noreply.github.com>
2019-08-03 11:40:09 -07:00
Miss Islington (bot) a49f203e05
bpo-30974: Change os.path.samefile docstring to match docs (GH-7337)
(cherry picked from commit 8e568ef266)

Co-authored-by: Timo Furrer <tuxtimo@gmail.com>
2019-08-02 16:11:33 -07:00
Miss Islington (bot) 1ff7dd681c
bpo-20523: pdb searches for .pdbrc in ~ instead of $HOME (GH-11847)
Previously pdb checked the $HOME environmental variable
to find the user .pdbrc. If $HOME is not set, the user
.pdbrc would not be found.

Change pdb to use `os.path.expanduser('~')` to determine
the user's home directory. Thus, if $HOME is not set (as
in tox or on Windows), os.path.expanduser('~') falls
back on other techniques for locating the user's home
directory.

This follows pip's implementation for loading .piprc.

Co-authored-by: Dan Lidral-Porter <dlp@aperiodic.org>
(cherry picked from commit 7ea9a85f13)

Co-authored-by: Timothy Hopper <tdhopper@users.noreply.github.com>
2019-08-02 15:40:14 -07:00
Miss Islington (bot) 8990ac0ab0 bpo-37726: Prefer argparse over getopt in stdlib tutorial (GH-15052) (#15069)
(cherry picked from commit 2491134029)

Co-authored-by: mental <m3nta1@yahoo.com>
2019-08-01 07:35:20 -07:00
Miss Islington (bot) 35d9c37e27
bpo-37695: Correct unget_wch error message. (GH-14986)
(cherry picked from commit c9345e382c)

Co-authored-by: Anthony Sottile <asottile@umich.edu>
2019-07-31 13:25:45 -07:00
Miss Islington (bot) 33b700ba8c
bpo-37723: Fix performance regression on regular expression parsing. (GH-15030)
Improve performance of sre_parse._uniq function.
(cherry picked from commit 9f55551f3d)

Co-authored-by: yannvgn <hi@yannvgn.io>
2019-07-31 13:22:19 -07:00
Miss Islington (bot) 3533061371 bpo-34101: Add doc of PyBuffer_GetPointer (GH-14994) (GH-15055)
(cherry picked from commit 1b29af83bc)

Co-authored-by: Hai Shi <shihai1992@gmail.com>
2019-07-31 16:57:09 +02:00
Miss Islington (bot) 8c6e35d2d2
bpo-33821: Update IDLE section of What's New 3.7 (GH-15036)
* bpo-33821: Update IDLE section of What's New 3.7

* Fix roles.
(cherry picked from commit 5982b7201b)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-07-30 22:24:43 -07:00
Miss Islington (bot) ac7cb7b9be
bpo-34162: Add missing items to idlelib/NEWS.txt. (GH-15034)
(cherry picked from commit fff5cb21ae)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-07-30 22:21:14 -07:00
Miss Islington (bot) 362217c7d6
Fix idlelib typos discovered by min ho, pr 15018. (GH-15029)
(cherry picked from commit 0acb646b8e)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-07-30 15:33:30 -07:00
Terry Jan Reedy e941cbcf8c
bpo-34162: Update idlelib/news.txt for 3.7.5 (GH-15016) 2019-07-29 19:21:11 -04:00
Miss Islington (bot) 6c9f46fa3a
bpo-34162: Update idlelib/news.txt. (GH-15011)
(cherry picked from commit f35c51d2ea)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-07-29 15:36:20 -07:00
Miss Islington (bot) ad36d21223
bpo-37706: Disable 3 IDLE scrollbar tests on Mac. (GH-15010)
They pass with tk 8.5.9 (Azure) but fail with the 8.6.x we install.
(cherry picked from commit e8874b85b4)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-07-29 15:22:59 -07:00
Miss Islington (bot) d30626443d
bpo-37692: Improve highlight config sample (GH-14983)
Use an example shell interaction in the sample and better labels for shell elements.
(cherry picked from commit b222955355)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-07-28 09:22:18 -07:00
Miss Islington (bot) 0242eb3fa7
bpo-37628: Fix IDLE config sample sizes (GH-14958)
The boxes for the font and highlight samples are now constrained by the overall config dialog size.  They gain scrollbars when the when a large font size makes the samples too large for the box.
(cherry picked from commit 3221a63c69)

Co-authored-by: Tal Einat <taleinat+github@gmail.com>
2019-07-27 10:14:54 -07:00
Miss Islington (bot) 9e7697b3c5
bpo-17535: Increase line number horizontal padding by 2 pixels (GH-14959)
(cherry picked from commit 46ebd4a6a2)

Co-authored-by: Tal Einat <taleinat@gmail.com>
2019-07-26 20:42:00 -07:00
Miss Islington (bot) 4b6421c61e
bpo-32910: Remove implementation detail in venv documentation. (GH-14968)
(cherry picked from commit 91e4957509)

Co-authored-by: Derek Keeler <d3r3kk@users.noreply.github.com>
2019-07-26 15:03:23 -07:00
Miss Islington (bot) ea0f7aa47c
bpo-37664: Update bundled pip to 19.2.1 and setuptools to 41.0.1 (GH-14934)
(cherry picked from commit 5380def826)

Co-authored-by: Pradyun Gedam <pradyunsg@gmail.com>
2019-07-26 10:19:15 -07:00
Miss Islington (bot) 0225d58cc8
bpo-37664: Update regex for ignoring cache warning on some buildbots (GH-14960)
(cherry picked from commit b1eb20e68e)

Co-authored-by: Steve Dower <steve.dower@python.org>
2019-07-26 10:13:11 -07:00
Miss Islington (bot) 9194a20a5b
closes bpo-37675: Use pkgutil.iter_modules to find fixers in a package rather than listdir. (14942)
(cherry picked from commit 93e8aa62cf)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
2019-07-24 16:57:39 -07:00
Miss Islington (bot) 913210d13b
[3.7] Touch up venv docs (GH-14922) (GH-14924)
(cherry picked from commit 2f224a077a)


Co-authored-by: Brett Cannon <54418+brettcannon@users.noreply.github.com>

Automerge-Triggered-By: @brettcannon
2019-07-24 10:14:35 -07:00
Miss Islington (bot) aee260f1c4 bpo-29446: IDLE -- add explicit imports (GH-14919) (#14921)
Stop depending on tkinter import *.
(cherry picked from commit c6fd6c83b7)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-07-23 16:36:57 -04:00
Tal Einat e9ec1663d8
[3.7] bpo-17535: IDLE editor line numbers (GH-14030)
(cherry picked from commit 7123ea009b)
2019-07-23 16:27:04 +03:00
Miss Islington (bot) 28815e0e2c
bpo-33610: validate non-negative integer inputs in IDLE's config (GH-14822)
(cherry picked from commit 1ebee37dde)

Co-authored-by: Tal Einat <taleinat@gmail.com>
2019-07-23 03:21:52 -07:00
Kyle Stanley 83cec020ba [3.7] Fix typos in docs, comments and test assert messages (GH-14872). (#14901)
(cherry picked from commit 96e12d5f4f)

Co-authored-by: Min ho Kim <minho42@gmail.com>
2019-07-22 14:14:07 -04:00
Miss Islington (bot) 5d3d0f382f Update logging cookbook to show multiple worker processes using the concurrent.futures module. (GH-14905) (GH-14907)
(cherry picked from commit d309352c6f)
2019-07-22 13:25:22 +01:00
Miss Islington (bot) e9b187a2bf bpo-21478: Record calls to parent when autospecced objects are used as child with attach_mock (GH 14688) (GH-14903)
* Clear name and parent of mock in autospecced objects used with attach_mock

* Add NEWS entry

* Fix reversed order of comparison

* Test child and standalone function calls

* Use a helper function extracting mock to avoid code duplication and refactor tests.
(cherry picked from commit 7397cda997)

Co-authored-by: Xtreak <tir.karthi@gmail.com>
2019-07-22 09:04:07 +01:00
Miss Islington (bot) 849a37a2b6
bpo-37627: Add acknowledgment (GH-14883)
(cherry picked from commit 4214f1ec3b)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-07-21 13:38:01 -07:00
Miss Islington (bot) 7649f8c7f8
Fix typo found by Min ho Kim (GH-14879)
(cherry picked from commit 8e3a7380ec)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-07-21 12:54:34 -07:00
Miss Islington (bot) d9086f2324
bpo-37627: Initialize IDLE Custom Run dialog with previous entries (GH-14870)
Repeat the command line arguments most recently entered before so the user can edit them.
(cherry picked from commit 35b87e6001)

Co-authored-by: Ngalim Siregar <ngalim.siregar@gmail.com>
2019-07-21 09:09:17 -07:00
Miss Islington (bot) 843fd85cf7
Adjust builtins.zip() docstring to better communicate its signature (GH-14833)
(cherry picked from commit af2f5b1723)

Co-authored-by: Sergey Fedoseev <fedoseev.sergey@gmail.com>
2019-07-19 11:27:13 -07:00
Miss Islington (bot) 87b6078fb9
bpo-37610: improve Using Python doc wrt Editors & IDE (GH-14850)
Move the Editors and IDE section out of the Unix section, to its own section.

https://bugs.python.org/issue37610
(cherry picked from commit 8f040b7a9f)

Co-authored-by: aldwinaldwin <aldwinaldwin@users.noreply.github.com>
2019-07-18 18:28:49 -07:00
Miss Islington (bot) db2957c8eb
bpo-33610: IDLE's code-context always shows current context immediately (GH-14821)
Eliminate delay of up to 100ms and accompanying visual artifact.
Fix bug of never showing context when hide and show.
(cherry picked from commit e0a1f8fb5c)

Co-authored-by: Tal Einat <taleinat@gmail.com>
2019-07-18 13:46:34 -07:00
Miss Islington (bot) 5eb19fddd2 bpo-36390: Gather IDLE Format menu functions into format.py (GH-14827) (GH-14830)
Add two indent spec methods from editor and Rstrip to existing file.
Tests are not added for indent methods because they need change
in lights of 3.x's prohibition on mixing tabs and spaces.
(cherry picked from commit 1b38922434)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-07-17 21:22:25 -04:00
Miss Islington (bot) 80f74ce83b
Fix IndexError when parsing unexpectedly ending quoted-string. (GH-14813)
This exception was caused because the input ended unexpectedly with only one
single quote instead of a pair with some value inside it.
(cherry picked from commit 719a062bcb)

Co-authored-by: Abhilash Raj <maxking@users.noreply.github.com>
2019-07-17 10:32:31 -07:00
Miss Islington (bot) 391511ccaa
bpo-37461: Fix infinite loop in parsing of specially crafted email headers (GH-14794)
* bpo-37461: Fix infinite loop in parsing of specially crafted email headers.

Some crafted email header would cause the get_parameter method to run in an
infinite loop causing a DoS attack surface when parsing those headers. This
patch fixes that by making sure the DQUOTE character is handled to prevent
going into an infinite loop.
(cherry picked from commit a4a994bd3e)

Co-authored-by: Abhilash Raj <maxking@users.noreply.github.com>
2019-07-17 10:02:05 -07:00