Commit graph

98639 commits

Author SHA1 Message Date
Miss Islington (bot)
ac6245a31f [3.6] bpo-31516: current_thread() should not return a dummy thread at shutdown (GH-3673) (#3856)
bpo-31516: current_thread() should not return a dummy thread at shutdown
(cherry picked from commit 1023dbbcb7)
2017-10-02 17:20:01 +02:00
Miss Islington (bot)
66fb5ef3bb [3.6] bpo-31158: Fix nondeterministic read in test_pty (GH-3808) (GH-3852)
(cherry picked from commit e6f62f69f0)
2017-10-02 02:57:56 -07:00
Terry Jan Reedy
c041816045 [3.6] IDLE: make filetypes a tuple constant. (GH-3847) (#3848)
Save a bit of code, plus non-tuples get converted anyway to tuples by tkinter for the tk call.
(cherry picked from commit 5961e7c156)
2017-10-01 19:37:19 -04:00
Terry Jan Reedy
c8198c9232 [3.6] bpo-31460: Simplify the API of IDLE's Module Browser. (GH-3842) (#3843)
Passing a widget instead of an flist with a root widget opens the option of
creating a browser frame that is only part of a window. Passing a full file
name instead of pieces assumed to come from a .py file opens the possibility
of browsing python files that do not end in .py.
(cherry picked from commit d6bb65f)
2017-09-30 20:32:29 -04:00
Terry Jan Reedy
40c54d5e1a [3.6] bpo-31649: Make IDLE's _htest, _utest parameters keyword-only. (GH-3839) (#3841)
(cherry picked from commit bfebfd8)
2017-09-30 18:45:53 -04:00
Miss Islington (bot)
d9c21a45fd [3.6] bpo-31627: Make test_mailbox be lenient to empty hostname. (GH-3821) (#3837)
(cherry picked from commit f4ea642cb6)
2017-09-30 22:52:00 +03:00
Miss Islington (bot)
a4dfe1c9ea [3.6] bpo-31592: Fix an assertion failure in Python parser in case of a bad unicodedata.normalize(). (GH-3767) (#3836)
(cherry picked from commit 7dc46d8cf5)
2017-09-30 22:51:37 +03:00
Miss Islington (bot)
9ef28b6ad3 [3.6] bpo-31641: Allow arbitrary iterables in concurrent.futures.as_completed() (GH-3830) (#3831)
This was possible before.  GH-1560 introduced a regression after 3.6.2 got
released where only sequences were accepted now.  This commit addresses this
problem.
(cherry picked from commit 574562c5dd)
2017-09-29 15:07:01 -07:00
Miss Islington (bot)
66c2b9f13e [3.6] bpo-31285: Remove splitlines identifier from Python/_warnings.c (GH-3803) (#3829)
(forgot to remove it in GH-3219)
(cherry picked from commit 8b4ff53c44)
2017-09-29 22:26:45 +03:00
Miss Islington (bot)
a5610e0746 [3.6] bpo-25351: avoid activate failure on strict shells (GH-3804) (#3820)
(cherry picked from commit 90f1d98959)
2017-09-29 05:34:43 -07:00
Miss Islington (bot)
641494ec31 bpo-31621: Fix typo in Simple Statements documentation (GH-3809) (GH-3810)
Replace "restriction" with "restrictions".
(cherry picked from commit 8d59aca4a9)
2017-09-28 13:00:17 -07:00
Victor Stinner
7d6ddb96b3 bpo-28129: fix ctypes crashes (#386) (#3799)
* init commit, with initial tests for from_param and fields __set__ and __get__, and some additions to from_buffer and from_buffer_copy

* added the rest of tests and patches. probably only a first draft.

* removed trailing spaces

* replace ctype with ctypes in error messages

* change back from ctypes instance to ctype instance

(cherry picked from commit 1bea762d9e)
2017-09-28 07:32:11 -07:00
Miss Islington (bot)
ec3d34c5b2 [3.6] bpo-31536: Avoid wholesale rebuild after make regen-all (GH-3678) (#3797)
bpo-31536: Avoid wholesale rebuild after `make regen-all`
2017-09-28 13:21:32 +02:00
Serhiy Storchaka
befc956acf [3.6] bpo-31478: Fix an assertion failure in random.seed() in case a seed has a bad __abs__() method. (GH-3596) (#3794)
(cherry picked from commit d780b2d588)
2017-09-28 12:17:51 +03:00
Benjamin Peterson
68b131d5b6 [3.6] closes bpo-22140: Prevent double substitution of prefix in python-config.sh (GH-3769) (#3793)
Fix the logic in python-config.sh to avoid attempting to substitute
prefix in a variable that might have already been subject to
substitution. This e.g. happened if @exec_prefix@ was defined as
"${prefix}" (which is the default of the configure script) -- in which
case the exec_prefix_build variable was initialized with
already-subtituted prefix, and then another round of substitution was
performed which might have resulted in duplicate prefix.

To avoid that, rename the variables so that the variables matching
likely configure names (prefix, exec_prefix) retain their original
values and a '_real' suffix is used for the real values of prefix.

Furthermore, replace the unnecessary prefix and exec_prefix
substitutions with direct prefix_real references since the sed
always replaced the whole string anyway by design.
(cherry picked from commit 14086cfc5e)
2017-09-27 20:27:41 -07:00
Miss Islington (bot)
084f80b82c [3.6] bpo-31588: Validate return value of __prepare__() methods (GH-3790)
Class execution requires that __prepare__() methods return
a proper execution namespace. Check for that immediately
after calling __prepare__(), rather than passing it through
to the code execution machinery and potentially triggering
SystemError (in debug builds) or a cryptic TypeError
(in release builds).

Patch by Oren Milman.
(cherry picked from commit 5837d0418f)
2017-09-28 02:21:33 +10:00
Victor Stinner
fdcf3e9629 bpo-31593: test_socketserver waits child processes (#3766) 2017-09-27 02:21:12 -07:00
Serhiy Storchaka
02c3cdcef8 [3.6] bpo-25532: Protect against infinite loops in inspect.unwrap() (GH-1717) (#3778)
Some objects (like test mocks) auto-generate new objects on
attribute access, which can lead to an infinite loop in
inspect.unwrap().

Ensuring references are retained to otherwise temporary objects
and capping the size of the memo dict turns this case into a
conventional exception instead..
(cherry picked from commit f9169ce6b4)
2017-09-27 09:34:44 +03:00
Miss Islington (bot)
680429b133 [3.6] point to the module-level get_ident function rather than the one in _thread (GH-3782) (#3783)
(cherry picked from commit 236329ed9f)
2017-09-26 23:17:51 -07:00
Miss Islington (bot)
7c24e99c99 [3.6] bpo-31505: Fix an assertion failure in json, in case _json.make_encoder() received a bad encoder() argument. (GH-3643) (#3777)
(cherry picked from commit 2b382dd612)
2017-09-27 08:21:47 +03:00
Serhiy Storchaka
90fe25a051 [3.6] bpo-31285: Fix an assertion failure and a SystemError in warnings.warn_explicit. (GH-3219) (#3775)
(cherry picked from commit 91fb0afe18)
2017-09-27 07:38:03 +03:00
Miss Islington (bot)
bdb215b18a [3.6] bpo-31490: Fix an assertion failure in ctypes in case an _anonymous_ attr is defined only outside _fields_. (GH-3615) (#3774)
(cherry picked from commit 30b61b51e0)
2017-09-27 07:37:37 +03:00
Serhiy Storchaka
f0db2dfda7 [3.6] bpo-31492: Fix assertion failures in case of a module with a bad __name__ attribute. (GH-3620). (#3773)
(cherry picked from commit 6db7033192)
2017-09-27 07:33:00 +03:00
Miss Islington (bot)
a1c49f6f09 [3.6] bpo-31586: Use _count_element fast path for real dicts. (#3776)
(cherry picked from commit 31aca4bf79)
2017-09-26 20:45:57 -07:00
Miss Islington (bot)
69b2dc8637 [3.6] bpo-30347: Stop crashes when concurrently iterate over itertools.groupby() iterators. (GH-1557) (#3770)
(cherry picked from commit c740e4fe8a)
2017-09-26 22:20:22 +03:00
Serhiy Storchaka
d6a356209a [3.6] bpo-31579: Fixed a possible leak in enumerate() with large indices. (GH-3753). (#3760)
(cherry picked from commit 0e950dd22b)
2017-09-26 09:11:34 +03:00
Miss Islington (bot)
26b940f762 bpo-31571: Remove duplicated info in Lexical Analysis documentation (GH-3691) (GH-3754)
- Remove the second mention about the `u` prefix
- Remove the second mention about numeric literals do not include a sign
(cherry picked from commit 4a2d00cb45)
2017-09-25 16:23:33 -07:00
Victor Stinner
ad051cbce1 bpo-31170: Write unit test for Expat 2.2.4 UTF-8 bug (#3570) (#3746)
Non-regression tests for the Expat 2.2.3 UTF-8 decoder bug.

(cherry picked from commit e6d9fcbb8d)
2017-09-25 02:00:04 -07:00
Miss Islington (bot)
a6bddb8e43 [3.6] bpo-31311: Fix a SystemError and a crash in ctypes._CData.__setstate__(), in case of a bad __dict__. (GH-3254) (#3743)
(cherry picked from commit 57c2561c8c)
2017-09-25 11:49:08 +03:00
Miss Islington (bot)
e2a30cd35b [3.6] bpo-27385: Clarify docstring for groupby() (GH-3738) (#3744)
(cherry picked from commit 49392c63a2)
2017-09-25 01:41:49 -07:00
Miss Islington (bot)
73c915a5cd [3.6] bpo-23702: Update Descriptor-HOWTO to reflect the removal of unbound methods (GH-3739) (#3742)
(cherry picked from commit 0d4497b9ca)
2017-09-25 01:11:21 -07:00
Miss Islington (bot)
01438ed4c2 [3.6] bpo-18558: Clarify glossary entry for "Iterable" (GH-3732) (#3741)
(cherry picked from commit 0bf287b6e0)
2017-09-25 00:57:24 -07:00
Miss Islington (bot)
d38caf68bb [3.6] bpo-30085: Improve documentation for operator (GH-1171) (#3736)
The dunderless functions are preferred; dunder are retained for back compatilibity.
Patch by Sanket Dasgupta.
(cherry picked from commit 5b9299d8c7)
2017-09-24 17:13:15 -04:00
Miss Islington (bot)
415cc1fa57 [3.6] bpo-31566: Fix an assertion failure in _warnings.warn() in case of a bad __name__ global. (GH-3717) (#3730)
(cherry picked from commit 5d3e80021a)
2017-09-24 23:14:41 +03:00
Miss Islington (bot)
ce418bf822 bpo-31570: Update Email library documentation example (GH-3720) (GH-3721)
A `"` was missing from an `<a href>` tag.
(cherry picked from commit 8337239d79)
2017-09-24 09:18:50 -07:00
Miss Islington (bot)
e31eca45e5 [3.6] bpo-27319, bpo-31508: Document deprecation in Treeview.selection(). (GH-3667) (#3719)
Defer removing old behavior to 3.8.
Document new feature of selection_set() and friends.
(cherry picked from commit 2fad102354)
2017-09-24 15:03:48 +03:00
Miss Islington (bot)
018e6b9f69 bpo-31564: Update typing documentation (GH-3696) (GH-3715)
Mention that ``NewType`` can derive from another ``NewType``.
(cherry picked from commit 039b25d8fd)
2017-09-23 19:46:24 -07:00
Miss Islington (bot)
7e32cee1a6 [3.6] bpo-25359: Add missed "goto error" after setting an exception. (GH-3712) (#3714)
(cherry picked from commit d6238a76c6)
2017-09-24 03:29:17 +03:00
Miss Islington (bot)
b650194652 [3.6] bpo-31459: Rename IDLE's module browser from Class Browser to Module Browser. (GH-3704) (#3710)
The original module-level class and method browser became a module
browser, with the addition of module-level functions, years ago.
Nested classes and functions were added yesterday.  For back-
compatibility, the virtual event <<open-class-browser>>, which
appears on the Keys tab of the Settings dialog, is not changed.
Patch by Cheryl Sabella.
(cherry picked from commit cd99e79dc7)
2017-09-23 17:16:47 -04:00
Miss Islington (bot)
429b3b1188 [3.6] bpo-31559: Remove test order dependence in idle_test.test_browser. (GH-3708) (#3709)
Order dependence caused leak-test buildbots to fail when running test_idle repeatedly.
(cherry picked from commit 99167f85b7)
2017-09-23 15:24:18 -04:00
Miss Islington (bot)
5614487378 [3.6] Docs: correct hashlib.blake2 keyed hashing example (bpo-31560)
(cherry picked from commit aecc08ac3a)
2017-09-23 10:27:22 -07:00
Terry Jan Reedy
fa1cae5832 [3.6] bpo-1612262: IDLE: Class Browser shows nested functions, classes (GH-2573) (#3702)
Original patches for code and tests by Guilherme Polo and
Cheryl Sabella, respectively.

(cherry picked from commit 058de11360)
2017-09-22 17:28:01 -04:00
Zachary Ware
6de35849cb [3.6] bpo-31423: Fix building the PDF documentation (GH-3693) (GH-3699)
Use prefixed macro names for the `authoraddress` function, add T2A to the font encoding in LaTeX sources to support Cyrillic characters in the PDF documentation, and replace the deprecated `font_size` config option with `pointsize`.
(cherry picked from commit da9b4cfb48)
2017-09-22 13:26:19 -05:00
Miss Islington (bot)
eef49f5dd0 bpo-31351: Set return code in ensurepip when pip fails (GH-3626) (GH-3683)
Previously ensurepip would always report success, even if the
pip installation failed.
(cherry picked from commit 9adda0cdf8)

* Update version changed notice for backport
2017-09-22 06:45:37 -07:00
Terry Jan Reedy
0c4997f191 [3.6] bpo-31500: IDLE: Scale default fonts on HiDPI displays. (GH-3639) (#3686)
(cherry picked from commit a96c96f)
2017-09-21 11:15:45 -04:00
Miss Islington (bot)
88d0663005 [3.6] closes bpo-31532: Fix memory corruption due to allocator mix (GH-3679) (#3681)
Fix a memory corruption in getpath.c due to mixed memory allocators
between Py_GetPath() and Py_SetPath().

The fix use the Raw allocator to mimic the windows version.

This patch should be used from python3.6 to the current version

for more details, see the bug report and
  https://github.com/pyinstaller/pyinstaller/issues/2812
(cherry picked from commit 3d1e2ab584)
2017-09-20 23:47:12 -07:00
Miss Islington (bot)
6b44ad1abd bpo-31533: fix broken link to OpenSSL docs (GH-3674) (GH-3675)
(cherry picked from commit 19e4d9346d)
2017-09-20 13:22:56 -07:00
Miss Islington (bot)
97be14996b [3.6] bpo-31500: Removed fixed size of IDLE config dialog. (GH-3664) (#3665)
This one line of Serhiy Storchacka's bpo-31500 patch for is needed for other issues.
(cherry picked from commit d6e2f26f3f)
2017-09-19 19:45:00 -04:00
Miss Islington (bot)
e2593aa673 bpo-31501: Operator precedence description for arithmetic operators (GH-3633) (GH-3638)
(cherry picked from commit 9b47af6537)
2017-09-19 15:48:29 -07:00
Steve Dower
aa2bda788d Fix build issues in Doc/make.bat (#3663) 2017-09-19 14:40:48 -07:00