Commit Graph

102112 Commits

Author SHA1 Message Date
Miss Islington (bot) b2a6aa32f3
closes bpo-34664: Only check file permission bits of newly created directories. (GH-9273)
(cherry picked from commit 84db4a9978)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
2018-09-13 12:42:26 -07:00
Miss Islington (bot) 305056494d
bpo-34247: add porting note to 3.7 What's New (GH-9223)
(cherry picked from commit 66755cbb1e)

Co-authored-by: Ned Deily <nad@python.org>
2018-09-13 12:14:46 -07:00
Miss Islington (bot) 218b4bf474
bpo-34661: Fix test skipping call. (GH-9266)
(cherry picked from commit e78734d579)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
2018-09-13 11:35:18 -07:00
Miss Islington (bot) 1550b73112
closes bpo-34661: Fix test_shutil if unzip doesn't support -t. (GH-9262)
(cherry picked from commit a710ebd21b)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
2018-09-13 10:27:52 -07:00
Miss Islington (bot) b2ff9a9f92
bpo-34658: Fix rare subprocess prexec_fn fork error. (GH-9255)
[bpo-34658](https://www.bugs.python.org/issue34658): Fix a rare interpreter unhandled exception state SystemError only
seen when using subprocess with a preexec_fn while an after_parent handler has
been registered with os.register_at_fork and the fork system call fails.

https://bugs.python.org/issue34658
(cherry picked from commit a20b6adb5a)

Co-authored-by: Gregory P. Smith <greg@krypto.org>
2018-09-13 10:11:00 -07:00
Miss Islington (bot) 35c94c765b
bpo-34652: Remove lchmod from the big func checking block. (GH-9247)
A fix for 883702ebb8.
(cherry picked from commit ed709d5699)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
2018-09-12 22:33:02 -07:00
Miss Islington (bot) 90f7d455b7
bpo-34200: Fix non-determinism of test_pkg (GH-9248)
This causes the tearDown code to only unimport the test modules specifically created as part of each test via the self.mkhier method rather than abusing test.support.modules_setup() and the scary test.support.modules_cleanup() code.

https://bugs.python.org/issue34200
(cherry picked from commit 4ae8ece5cd)

Co-authored-by: Gregory P. Smith <greg@krypto.org>
2018-09-12 18:29:08 -07:00
Miss Islington (bot) ea2fcd3db6
closes bpo-34654: Tolerate + at the beginning of large years. (GH-9238)
(cherry picked from commit e1a34ceb54)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
2018-09-12 16:54:10 -07:00
Miss Islington (bot) 98344a4f2f
closes bpo-34652: Always disable lchmod on Linux. (GH-9234)
(cherry picked from commit 40caa05fa4)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
2018-09-12 16:36:05 -07:00
Benjamin Peterson 0aef909d63
[3.7] closes bpo-34650: Check if sched_getscheduler returns ENOSYS before declaring it supported. (GH-9236)
musl doesn't support the scheduler API, but declares stubs that alway return ENOSYS..
(cherry picked from commit c7042224b8)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
2018-09-12 16:00:06 -07:00
Miss Islington (bot) ec4d099b9f bpo-34649: Add missing NULL checks to _encoded_const() (GH-9225)
Reported by Svace static analyzer.
(cherry picked from commit 6f82bffd2d)

Co-authored-by: Alexey Izbyshev <izbyshev@ispras.ru>
2018-09-13 00:46:40 +03:00
Miss Islington (bot) b608fcd444
closes bpo-34004: Skip lock interruption tests on musl. (GH-9224)
Returning EINTR from pthread semaphore or lock acquisition is an optional POSIX
feature. musl does not provide this feature, so some threadsignal tests fail
when Python is built against it.

There's no good way to test for musl, so we skip if we're on Linux and not using
glibc pthreads.

Also, hedge in the threading documentation about when we can provide interrupts
from lock acquisition.
(cherry picked from commit 5b10d5111d)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
2018-09-12 14:10:56 -07:00
Miss Islington (bot) 329ea4ef7c
bpo-31577: Fix a crash in os.utime() in case of a bad ns argument. (GH-3752)
(cherry picked from commit 0bd1a2dcfd)

Co-authored-by: Oren Milman <orenmn@gmail.com>
2018-09-12 12:46:30 -07:00
Miss Islington (bot) 72c34cf6dd
closes bpo-31903: Release the GIL when calling into SystemConfiguration (GH-4178)
(cherry picked from commit 4859ba0d2c)

Co-authored-by: Max Bélanger <aeromax@gmail.com>
2018-09-12 08:37:30 -07:00
Benjamin Peterson cadb66e173
[3.7] closes bpo-25041: Document AF_PACKET socket address format. (GH-9207)
(cherry picked from commit 731ff68eee)

Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
2018-09-11 18:46:36 -07:00
Miss Islington (bot) 01ce535ba9
Delete old expat comment. (GH-9197)
(cherry picked from commit b9bf9d025e)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
2018-09-11 18:04:33 -07:00
Miss Islington (bot) 4007e4e207
Make sure the line comes from the same node as the col offset. (GH-9189)
Followup to 90fc8980bb.

<!--
Thanks for your contribution!
Please read this comment in its entirety. It's quite important.

GH- Pull Request title

It should be in the following format:

```
bpo-NNNN: Summary of the changes made
```

Where: bpo-NNNN refers to the issue number in the https://bugs.python.org.

Most PRs will require an issue number. Trivial changes, like fixing a typo, do not need an issue.

GH- Backport Pull Request title

If this is a backport PR (PR made against branches other than `master`),
please ensure that the PR title is in the following format:

```
[X.Y] <title from the original PR> (GH-NNNN)
```

Where: [X.Y] is the branch name, e.g. [3.6].

GH-NNNN refers to the PR number from `master`.

-->
(cherry picked from commit d13e59c1b5)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
2018-09-11 16:32:52 -07:00
Miss Islington (bot) d8bc7a666b
closes bpo-31902: Fix the col_offset attribute for ast.Async* nodes to point to the "async" keyword. (GH-4175)
Previously, col_offset points to the keyword after "async".
(cherry picked from commit 90fc8980bb)

Co-authored-by: guoci <zguoci@gmail.com>
2018-09-11 15:21:11 -07:00
Miss Islington (bot) e2b40f4ce9
bpo-34365: Update date object documentation (GH-8814)
Python 3.x does not fall back to comparing object addresses when comparing two `dt` objects.

<!-- issue-number: [bpo-34365](https://www.bugs.python.org/issue34365) -->
https://bugs.python.org/issue34365
<!-- /issue-number -->
(cherry picked from commit 9c223794c7)

Co-authored-by: Danish Prakash <grafitykoncept@gmail.com>
2018-09-11 14:24:53 -07:00
Steve Dower d289df13d3
Update VSTS to Azure DevOps and simplify dependencies (GH-9168) 2018-09-11 14:01:13 -07:00
Miss Islington (bot) 536e45accf
closes bpo-31608: Fix a crash in methods of a subclass of _collections.deque with a bad __new__(). (GH-3788)
(cherry picked from commit 24bd50bdcc)

Co-authored-by: Oren Milman <orenmn@gmail.com>
2018-09-11 12:08:10 -07:00
Miss Islington (bot) e02ca4270e
bpo-34613: document the correct value of limit argument of asyncio.StreamReader (GH-9121)
The default value of asyncio.StreamReader *limit* is `_DEFAULT_LIMIT` instead of `None`.

<!-- issue-number: [bpo-34613](https://www.bugs.python.org/issue34613) -->
https://bugs.python.org/issue34613
<!-- /issue-number -->
(cherry picked from commit b4ec36200a)

Co-authored-by: Bram <cortex@worlddomination.be>
2018-09-11 11:59:29 -07:00
Miss Islington (bot) 3e648f8371
bpo-28617 Fixed docs inaccuracies about the types that support membership tests (GH-9086)
<!-- issue-number: [bpo-28617](https://www.bugs.python.org/issue28617) -->
https://bugs.python.org/issue28617
<!-- /issue-number -->
(cherry picked from commit 08bcf647d8)

Co-authored-by: wim glenn <wim.glenn@gmail.com>
2018-09-11 11:13:33 -07:00
Miss Islington (bot) 3235fac0d7 bpo-34405: Update to OpenSSL 1.1.0i for macOS installer builds (GH-9166) (GH-9167)
(cherry picked from commit 3102e24d83)

Co-authored-by: Ned Deily <nad@python.org>
2018-09-11 09:07:11 -07:00
Miss Islington (bot) c9ece5f4a9
closes bpo-33883: Mention type checkers in the FAQ. (GH-7760)
(cherry picked from commit a378254186)

Co-authored-by: Andrés Delfino <adelfino@gmail.com>
2018-09-10 22:27:00 -07:00
Miss Islington (bot) 2bc4eea8f6
bpo-34625: Update vendorized expat version to 2.2.6. (GH-9150)
(cherry picked from commit 5033aa77aa)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
2018-09-10 21:55:27 -07:00
Miss Islington (bot) 2110f78d92
bpo-33032: Mention the implicit cache in struct.Struct() docs (GH-7700)
Mention the implicit cache in struct.Struct() docs.

Consistent with the re.compile documentation note.
(cherry picked from commit 3666b3c1f6)

Co-authored-by: Zackery Spytz <zspytz@gmail.com>
2018-09-10 21:50:41 -07:00
Miss Islington (bot) 9c4a63fc17 bpo-32270: Don't close stdin/out/err in pass_fds (GH-6242) (GH-9148)
When subprocess.Popen() stdin= stdout= or stderr= handles are specified
and appear in pass_fds=, don't close the original fds after dup'ing them.

This implementation and unittest primarily came from @izbyshev (see the PR)

See also b89b52f284

This also removes the old manual p2cread, c2pwrite, and errwrite closing logic
as inheritable flags and _close_open_fds takes care of that properly today without special treatment.

This code is within child_exec() where it is the only thread so there is no
race condition between the dup and _Py_set_inheritable_async_safe call.
(cherry picked from commit ce34410b8b)

Co-authored-by: Gregory P. Smith <greg@krypto.org> [Google]
2018-09-10 21:36:20 -07:00
Miss Islington (bot) 6df2005b39 Fix missing line from example shell session (GH-9143) (GH-9155)
(cherry picked from commit 2064bb6d57)

Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
2018-09-10 19:13:02 -07:00
Miss Islington (bot) 037582eb7f
bpo-33460: remove ellipsis that look like continuation prompts (GH-7851)
Remove ellipsis that look like continuation prompts,
has a side benefit of putting rest of error message in proper text color.
(cherry picked from commit f019579828)

Co-authored-by: Lew Kurtz <37632626+lew18@users.noreply.github.com>
2018-09-10 18:49:39 -07:00
Miss Islington (bot) f3d00ae3be
switch descriptor howto to return value annotation (GH-7796)
(cherry picked from commit 28ea4c2847)

Co-authored-by: NotAFile <notafile@gmail.com>
2018-09-10 17:44:58 -07:00
Miss Islington (bot) 011141f312
closes bpo-34525: Fix smtplib's authobject() documentation (GH-8965)
(cherry picked from commit 78deb7f332)

Co-authored-by: Sebastian Rittau <srittau@rittau.org>
2018-09-10 11:13:13 -07:00
Benjamin Peterson 4d5d219a7a
[3.7] Fix misleading mentions of tp_size in comments. (GH-9136)
Many type object initializations labeled a field "tp_size" in the
comment, but the name of that field is tp_basicsize..
(cherry picked from commit 0e0bc4e221)

Co-authored-by: Peter Eisentraut <peter@eisentraut.org>
2018-09-10 10:22:55 -07:00
orlnub123 c0d63bf73b [3.7] bpo-34282: Fix Enum._convert method shadowing members named _convert (GH-9034)
* Fix Enum._convert shadowing members named _convert
2018-09-10 09:39:48 -07:00
Miss Islington (bot) 4902017430
bpo-34588: Fix an off-by-one error in traceback formatting. (GH-9077)
The recursive frame pruning code always undercounted the number of elided frames
by one. That is, in the "[Previous line repeated N more times]" message, N would
always be one too few. Near the recursive pruning cutoff, one frame could be
silently dropped. That situation is demonstrated in the OP of the bug report.

The fix is to start the identical frame counter at 1.
(cherry picked from commit d545869d08)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
2018-09-10 09:00:08 -07:00
Tal Einat d53f1cabe8
[3.7] bpo-34621: fix uuid.UUID (un)pickling compatbility with older Python versions (<3.7) (GH-9133) 2018-09-10 18:47:29 +03:00
Miss Islington (bot) e9119a5de6
Test dict values iterator pickling with pickle.HIGHEST_PROTOCOL. (GH-9052)
(cherry picked from commit 1f36bf6077)

Co-authored-by: Sergey Fedoseev <fedoseev.sergey@gmail.com>
2018-09-10 03:45:54 -07:00
Miss Islington (bot) 9c9ac9e697
Revert "Fix misindented yaml in logging how to example (GH-8604)" (GH-9081)
This reverts commit 10b59f1b01.
(cherry picked from commit 290a60bd8a)

Co-authored-by: Rémy HUBSCHER <hubscher.remy@gmail.com>
2018-09-10 02:13:18 -07:00
William Grzybowski 7a633ed79c [3.7] bpo-34604: Fix possible mojibake in pwd.getpwnam() and grp.getgrnam() (GH-9098) (GH-9104)
Pass the user/group name as Unicode to the formatting function,
instead of always decoding a bytes string from UTF-8..
(cherry picked from commit 28658485a5)

Co-authored-by: William Grzybowski <wg@FreeBSD.org>
2018-09-09 13:27:31 +02:00
Miss Islington (bot) 77b92b15a5
bpo-34421 avoid unicode error in distutils logging (GH-8799)
This caused installation errors in some cases on Windows.
Patch by Julien Malard.
(cherry picked from commit 0afada163c)

Co-authored-by: Julien Malard <julien.malard@mail.mcgill.ca>
2018-09-08 13:52:59 -07:00
Miss Islington (bot) 9835696ec4
bpo-34246: Use no mutable default args in smtplib (GH-8554)
Some methods of the SMTP class use mutable default arguments. Specially
`send_message` is affected as it mutates one of the args by appending items
to it, which has side effects on further calls.
(cherry picked from commit d5fbe9b1a3)

Co-authored-by: Pablo Aguiar <scorphus@gmail.com>
2018-09-07 15:29:27 -07:00
Miss Islington (bot) 7399407725
bpo-23855: Add missing NULL checks for malloc() in _msi.c (GH-9038)
(cherry picked from commit 4e519377b1)

Co-authored-by: Zackery Spytz <zspytz@gmail.com>
2018-09-07 15:15:30 -07:00
Zackery Spytz 18d7dff1bb [3.7] bpo-34594: Don't hardcode errno values in the tests. (GH-9094)
(cherry picked from commit b03c2c5190)
2018-09-07 09:17:32 -07:00
Miss Islington (bot) 854b740910 Doc: Missing 'f' in an f-string. (GH-9074) (GH-9095)
(cherry picked from commit 25fa141487)

Co-authored-by: Julien Palard <julien@palard.fr>
2018-09-07 11:59:00 +02:00
Miss Islington (bot) f862f3abae
bpo-25750: fix refcounts in type_getattro() (GH-6118)
When calling tp_descr_get(self, obj, type), make sure that
we own a strong reference to "self".
(cherry picked from commit 8f735485ac)

Co-authored-by: jdemeyer <jdemeyer@cage.ugent.be>
2018-09-07 00:50:35 -07:00
Miss Islington (bot) 2d3f2dc9f8 bpo-34542: Update test certs and keys (GH-8997) (GH-9007)
Update all test certs and keys to use future proof crypto settings:

* 3072 bit RSA keys
* SHA-256 signature

Signed-off-by: Christian Heimes <christian@python.org>
(cherry picked from commit e6dac00779)
2018-09-06 15:13:24 +02:00
Miss Islington (bot) 5b17d7fccd
closes bpo-34581 : Conditionalize use of __pragma in Modules/socketmodule.c. (GH-9067)
(cherry picked from commit 874809ea38)

Co-authored-by: Erik Janssens <erik.janssens@conceptive.be>
2018-09-04 23:45:03 -07:00
Miss Islington (bot) e8ca8806a9 bpo-34563: Fix for invalid assert on big output of multiprocessing.Process (GH-9027) (GH-9064)
Fix for invalid assert on big output of multiprocessing.Process.
(cherry picked from commit 266f4904a2)

Co-authored-by: Alexander Buchkovsky <olex.buchkovsky@gmail.com>
2018-09-04 21:39:54 +02:00
Serhiy Storchaka 20a8392cec
[3.7] bpo-26544: Get rid of dependence from distutils in platform. (GH-8356). (GH-8970)
(cherry picked from commit 7d81e8f599)
2018-09-04 17:31:18 +03:00
Miss Islington (bot) 7aa3eadca2
bpo-34530: Fix distutils find_executable() (GH-9049)
distutils.spawn.find_executable() now falls back on os.defpath if the
PATH environment variable is not set.
(cherry picked from commit 39487196c8)

Co-authored-by: Victor Stinner <vstinner@redhat.com>
2018-09-04 05:19:13 -04:00