Commit Graph

21431 Commits

Author SHA1 Message Date
Miss Islington (bot) ca5e6aaea5
closes bpo-36083: Fix formatting of the manpage Synopsis. (GH-12017)
More specifically, the options of --check-hash-based-pycs.
(cherry picked from commit 16323cb2c3)

Co-authored-by: Miro Hrončok <miro@hroncok.cz>
2019-02-24 16:56:13 -08:00
Miss Islington (bot) 25d20a6503
bpo-27313: Avoid test_ttk_guionly ComboboxTest fail with macOS Cocoa Tk (GH-12011)
(cherry picked from commit aeca373b33)

Co-authored-by: Ned Deily <nad@python.org>
2019-02-23 23:46:20 -08:00
Miss Islington (bot) 38aea4131f
bpo-24310: Document IDLE settings dialog font tab sample (GH-12007)
(cherry picked from commit d610116a2e)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-02-23 20:23:08 -08:00
Miss Islington (bot) 6163210089
bpo-36019: Use pythontest.net instead of example.com in network tests (GH-11941)
(cherry picked from commit a40681dd5d)

Co-authored-by: Stéphane Wirtel <stephane@wirtel.be>
2019-02-22 06:03:26 -08:00
Miss Islington (bot) 0e73ea26a5
bpo-33989: Ensure that ms.key_compare is always initialized in list_sort_impl(). (GH-8710)
(cherry picked from commit ebc793d6ac)

Co-authored-by: Zackery Spytz <zspytz@gmail.com>
2019-02-21 00:05:22 -08:00
Miss Islington (bot) e8bf04de4b
bpo-36037: Fix test_ssl for strict OpenSSL policy (GH-11940)
Fix test_ssl for strict OpenSSL configuration like RHEL8 strict crypto policy.
Use older TLS version for minimum TLS version of the server SSL context if
needed, to test TLS version older than default minimum TLS version.
(cherry picked from commit 3ef6344ee5)

Co-authored-by: Victor Stinner <vstinner@redhat.com>
2019-02-19 09:24:16 -08:00
Miss Islington (bot) 64ca728223
bpo-31506: Clarify error messages for object.__new__ and object.__init__ (GH-11641)
`object.__new__` and `object.__init__` do take one argument each,
they just don't take extra user supplied arguments.

Patch by Sanyam Khurana.
(cherry picked from commit 5105483acb)

Co-authored-by: Sanyam Khurana <8039608+CuriousLearner@users.noreply.github.com>
2019-02-19 05:47:13 -08:00
Miss Islington (bot) 99e9c36b29
bpo-35689: IDLE: Add docstrings and unittests for colorizer.py (GH-11472)
(cherry picked from commit ee0f927bd8)

Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
2019-02-18 21:30:53 -08:00
Miss Islington (bot) 3129432845 bpo-34572: change _pickle unpickling to use import rather than retrieving from sys.modules (GH-9047) (GH-11921)
Fix C implementation of pickle.loads to use importlib's locking mechanisms, and thereby avoid using partially-loaded modules.
(cherry picked from commit 4371c0a9c0)

Co-authored-by: tjb900 <ozburgess@gmail.com>
2019-02-18 15:52:32 +00:00
Miss Islington (bot) 0e379d43ac
bpo-34294: re module, fix wrong capturing groups in rare cases. (GH-11546)
Need to reset capturing groups between two SRE(match) callings in loops, this fixes wrong capturing groups in rare cases.

Also add a missing index in re.rst.
(cherry picked from commit 4a7f44a2ed)

Co-authored-by: animalize <animalize@users.noreply.github.com>
2019-02-18 05:48:23 -08:00
Miss Islington (bot) a01065a358
bpo-35942: Improve the error message if __fspath__ returns invalid types in path_converter (GH-11831)
The error message emitted when returning invalid types from __fspath__ in interfaces that allow passing PathLike objects has been improved and now it does explain the origin of the error.
(cherry picked from commit 09fbcd6085)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
2019-02-18 03:05:52 -08:00
Miss Islington (bot) a7f929db60
bpo-35992: Use PySequence_GetItem only if sq_item is not NULL (GH-11857)
Not using `__class_getitem__()` fallback if there is a non-subcriptable metaclass was caused by a certain asymmetry between how `PySequenceMethods` and `PyMappingMethods` are used in `PyObject_GetItem`. This PR removes this asymmetry. No tests failed, so I assume it was not intentional.
(cherry picked from commit ac28147e78)

Co-authored-by: Ivan Levkivskyi <levkivskyi@gmail.com>
2019-02-17 15:33:04 -08:00
Miss Islington (bot) 6f352199e4
bpo-35931: Gracefully handle SyntaxError in pdb debug command (GH-11782)
Previously, `debug print(` would cause the interpreter to exit on a SyntaxError whereas `print(` would properly display the error and return to the pdb prompt.

This patch fixes this by pre-compiling the code before passing it to `Pdb.run`.

https://bugs.python.org/issue35931
(cherry picked from commit 4327705cfa)

Co-authored-by: Daniel Hahler <github@thequod.de>
2019-02-15 13:19:44 -08:00
Victor Stinner fe42122d41
bpo-35746: Credit Colin Read and Nicolas Edet (GH-11864)
Add credit for the cert parser vulnerability. Mention also Cisco
TALOS-2018-0758 identifier.
2019-02-15 13:19:30 +01:00
Miss Islington (bot) e20893596f
closes bpo-35991: Fix a potential double free in Modules/_randommodule.c. (GH-11849)
(cherry picked from commit bb3c05d7ef)

Co-authored-by: Zackery Spytz <zspytz@gmail.com>
2019-02-14 00:02:12 -08:00
Miss Islington (bot) a78251e2d6
bpo-35961: Fix a crash in slice_richcompare() (GH-11830)
Fix a crash in slice_richcompare(): use strong references rather than
stolen references for the two temporary internal tuples.

The crash (or assertion error) occurred if a garbage collection
occurred during slice_richcompare(), especially while calling
PyObject_RichCompare(t1, t2, op).
(cherry picked from commit dcb68f47f7)

Co-authored-by: Victor Stinner <vstinner@redhat.com>
2019-02-13 03:49:34 -08:00
Miss Islington (bot) 009220eae2
bpo-35505: Skip test_imap4_host_default_value if localhost listens on IMAP port (GH-11823)
Make test_imap4_host_default_value independent on whether the
local IMAP server is running.
(cherry picked from commit 3dc67d0316)

Co-authored-by: Matěj Cepl <mcepl@cepl.eu>
2019-02-12 10:54:31 -08:00
Miss Islington (bot) 0a834c18cd bpo-35960: Fix dataclasses.field throwing away empty metadata. (GH-11815) (GH-11826)
(cherry picked from commit b01786c881)

Co-authored-by: Christopher Hunt <chrahunt@gmail.com>
2019-02-12 07:11:48 -05:00
Miss Islington (bot) 58f05ce059 bpo-35918: Remove broken has_key method and add test (GH-11819) (#11824)
(cherry picked from commit a31f4cc881)

Co-authored-by: Rémi Lapeyre <remi.lapeyre@henki.fr>
2019-02-11 17:09:22 -08:00
Miss Islington (bot) 2259b5af3c
[3.7] bpo-22062: Updated docstring and documentation for pathlib (GH-8519) (GH-11817)
Original patch by Mike Short


https://bugs.python.org/issue22062
(cherry picked from commit 537b6caa56)


Co-authored-by: Eivind Teig <eivind.teig@gmail.com>


https://bugs.python.org/issue22062
2019-02-11 04:02:57 -08:00
Miss Islington (bot) 3fcfef357e
bpo-35833: Revise IDLE doc for control codes sent to Shell. (GH-11799)
Add  a code example block.
(cherry picked from commit 8a03ff2ff4)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-02-08 20:43:20 -08:00
Miss Islington (bot) 48769a28ad bpo-35615: Fix crashes when copying a Weak{Key,Value}Dictionary. (GH-11384) (GH-11785)
Protect dict iterations by wrapping them with _IterationGuard in the
following methods:

- WeakValueDictionary.copy()
- WeakValueDictionary.__deepcopy__()
- WeakKeyDictionary.copy()
- WeakKeyDictionary.__deepcopy__()
(cherry picked from commit 96d37dbcd2)

Co-authored-by: Fish <ltfish@users.noreply.github.com>
2019-02-07 20:09:16 +00:00
Antoine Pitrou 15526f5be7
[3.7] bpo-35917: Test multiprocessing manager classes and shareable types (GH-11772) (GH-11780)
multiprocessing: provide unittests for manager classes and shareable types.
(cherry picked from commit 2848d9d299)

Co-authored-by: Giampaolo Rodola <g.rodola@gmail.com>
2019-02-07 11:34:12 +00:00
Miss Islington (bot) 4f6854a690
bpo-35299: Fixed sysconfig and distutils during PGO profiling (GH-11744)
(cherry picked from commit 85e102a2b0)

Co-authored-by: Steve Dower <steve.dower@microsoft.com>
2019-02-04 17:54:59 -08:00
Steve Dower 44467e8ea4
bpo-35872 and bpo-35873: Clears __PYVENV_LAUNCHER__ variable (GH-11745)
After reading __PYVENV_LAUNCHER__ we now set sys._base_executable value for later use.
Make the same changes for macOS to avoid extra platform checks.
2019-02-04 07:20:19 -08:00
Miss Islington (bot) 69af4395a2
bpo-35692: pathlib no longer raises when checking file and directory existence on drives that are not ready (GH-11746)
(cherry picked from commit 2f6fae6e51)

Co-authored-by: Steve Dower <steve.dower@microsoft.com>
2019-02-03 23:27:37 -08:00
Miss Islington (bot) cba16b748c
bpo-35642: Remove asynciomodule.c from pythoncore.vcxproj (GH-11410)
This module is built by _asyncio.vcxproj and does not need to be included in pythoncore.
(cherry picked from commit fbf50683b3)

Co-authored-by: Gregory Szorc <gregory.szorc@gmail.com>
2019-02-02 16:46:12 -08:00
Miss Islington (bot) 81eda28382
bpo-34691: Compile _contextvars module into main Python library (GH-11741)
(cherry picked from commit 4c70d9f79c)

Co-authored-by: Steve Dower <steve.dower@microsoft.com>
2019-02-02 14:54:42 -08:00
Miss Islington (bot) 63a69ef4a2
bpo-29734: nt._getfinalpathname handle leak (GH-740)
Make sure that failure paths call CloseHandle outside of the function that failed
(cherry picked from commit b82bfac436)

Co-authored-by: Mark Becwar <mark@thebecwar.com>
2019-02-02 13:29:07 -08:00
Miss Islington (bot) 04b2a5eeda
bpo-32560: inherit the py launcher's STARTUPINFO (GH-9000)
https://bugs.python.org/issue32560
(cherry picked from commit cb09047626)

Co-authored-by: Shiva Saxena <shivasaxena911@gmail.com>
2019-02-02 11:38:16 -08:00
Miss Islington (bot) 56f84117a7
bpo-1104: msilib.SummaryInfo.GetProperty() truncates the string by one character (GH-4517)
Add one char to MsiSummaryInfoGetProperty() output
Based on the patch in bpo-1104 by Anthony Tuininga (atuining) and Mark McMahon (markm).
(cherry picked from commit 2de576e16d)

Co-authored-by: Tzu-ping Chung <uranusjr@gmail.com>
2019-02-02 09:36:48 -08:00
Miss Islington (bot) c851dfc99b
bpo-33316: PyThread_release_lock always fails (GH-6541)
Use correct interpretation of return value from APIs.
(cherry picked from commit 05e922136a)

Co-authored-by: native-api <ivan_pozdeev@mail.ru>
2019-02-02 08:45:50 -08:00
Miss Islington (bot) 03082a836b
bpo-35854: Fix EnvBuilder and --symlinks in venv on Windows (GH-11700)
(cherry picked from commit a1f9a3332b)

Co-authored-by: Steve Dower <steve.dower@microsoft.com>
2019-01-30 14:14:35 -08:00
Miss Islington (bot) 1c79891026 bpo-35717: Fix KeyError exception raised when using enums and compile (GH-11523) (GH-11669)
https://bugs.python.org/issue17467
(cherry picked from commit 1fd06f1eca)

Co-authored-by: Rémi Lapeyre <remi.lapeyre@henki.fr>
2019-01-30 18:36:51 +01:00
Miss Islington (bot) 10354cbb50
bpo-35847: RISC-V needs CTYPES_PASS_BY_REF_HACK (GH-11694)
This fixes the ctypes.test.test_structures.StructureTestCase test.

https://bugs.python.org/issue35847
(cherry picked from commit 742d768656)

Co-authored-by: Andreas Schwab <schwab@linux-m68k.org>
2019-01-29 13:11:36 -08:00
Miss Islington (bot) b2b023c657 bpo-35780: Fix errors in lru_cache() C code (GH-11623) (GH-11682) 2019-01-26 03:23:40 -05:00
Miss Islington (bot) a6a8524bb1
bpo-35811: Avoid propagating venv settings when launching via py.exe (GH-11677)
(cherry picked from commit adad9e6801)

Co-authored-by: Steve Dower <steve.dower@microsoft.com>
2019-01-25 15:31:18 -08:00
Miss Islington (bot) 6a9c0fca3f
bpo-35797: Fix default executable used by the multiprocessing module (GH-11676)
(cherry picked from commit 4e02f8f8b4)

Co-authored-by: Steve Dower <steve.dower@microsoft.com>
2019-01-25 15:14:41 -08:00
Steve Dower 128efcade6
bpo-35683: Improve Azure Pipelines steps (GH-11493) 2019-01-22 12:31:30 -08:00
Miss Islington (bot) f71e7433eb
bpo-35720: Fixing a memory leak in pymain_parse_cmdline_impl() (GH-11528)
When the loop in the pymain_read_conf function in this same file
calls pymain_init_cmdline_argv() a 2nd time, the pymain->command
buffer of wchar_t is overriden and the previously allocated memory
is never freed.
(cherry picked from commit 35ca1820e1)

Co-authored-by: Lucas Cimon <lucas.cimon@gmail.com>
2019-01-22 08:42:13 -08:00
Miss Islington (bot) d1dd6be613
bpo-35772: Fix test_tarfile on ppc64 (GH-11606)
Fix sparse file tests of test_tarfile on ppc64le with the tmpfs
filesystem.

Fix the function testing if the filesystem supports sparse files:
create a file which contains data and "holes", instead of creating a
file which contains no data.

tmpfs effective block size is a page size (tmpfs lives in the page
cache). RHEL uses 64 KiB pages on aarch64, ppc64 and ppc64le, only
s390x and x86_64 use 4 KiB pages, whereas the test punch holes of
4 KiB.

test.pythoninfo: Add resource.getpagesize().
(cherry picked from commit b2385458ce)

Co-authored-by: Victor Stinner <vstinner@redhat.com>
2019-01-21 01:44:30 -08:00
Miss Islington (bot) d358a8cda7 bpo-20239: Allow repeated deletion of unittest.mock.Mock attributes (GH-11629)
* Allow repeated deletion of unittest.mock.Mock attributes

* fixup! Allow repeated deletion of unittest.mock.Mock attributes

* fixup! fixup! Allow repeated deletion of unittest.mock.Mock attributes
(cherry picked from commit 222d303ade)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
2019-01-21 09:37:54 +00:00
Miss Islington (bot) 2fa53cfa89
bpo-35699: fix distuils cannot detect Build Tools 2017 anymore (GH-11495)
(cherry picked from commit b2dc4a3313)

Co-authored-by: Marc Schlaich <marc.schlaich@googlemail.com>
2019-01-20 11:06:08 -08:00
Miss Islington (bot) a01e23559f
bpo-35770: IDLE macosx deletes Options => Configure IDLE. (GH-11614)
It previously deleted Window => Zoom Height by mistake.
(Zoom Height is now on the Options menu).  On Mac, the settings
dialog is accessed via Preferences on the IDLE menu.
(cherry picked from commit 39ed289a35)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-01-18 11:16:01 -08:00
Miss Islington (bot) 6ca7183b35
bpo-35045: Accept TLSv1 default in min max test (GH-11510)
Make ssl tests less strict and also accept TLSv1 as system default. The
changes unbreaks test_min_max_version on Fedora 29.

Signed-off-by: Christian Heimes <christian@python.org>
(cherry picked from commit 34de2d312b)

Co-authored-by: Christian Heimes <christian@python.org>
2019-01-18 07:29:08 -08:00
Dong-hee Na c2647f2e45 bpo-35283: Add pending deprecation warning for Thread.isAlive (GH-11604)
Add a pending deprecated warning for the threading.Thread.isAlive() method.
2019-01-18 15:09:43 +01:00
Miss Islington (bot) 5f9a168a31
bpo-35769: Change IDLE's name for new files from 'Untitled' to 'untitled' (GH-11602)
'Untitled' violates the PEP 8 standard for .py files
(cherry picked from commit a902239f22)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
2019-01-17 23:24:09 -08:00
Miss Islington (bot) a261b73761 bpo-33687: Fix call to os.chmod() in uu.decode() (GH-7282)
(cherry picked from commit 17f05bbc78)

Co-authored-by: Timo Furrer <tuxtimo@gmail.com>
2019-01-17 17:32:59 +03:00
Miss Islington (bot) be5de958e9
bpo-35746: Fix segfault in ssl's cert parser (GH-11569)
Fix a NULL pointer deref in ssl module. The cert parser did not handle CRL
distribution points with empty DP or URI correctly. A malicious or buggy
certificate can result into segfault.

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

https://bugs.python.org/issue35746
(cherry picked from commit a37f52436f)

Co-authored-by: Christian Heimes <christian@python.org>
2019-01-15 15:03:36 -08:00
Miss Islington (bot) c9f26714d5
bpo-23846: Fix ProactorEventLoop._write_to_self() (GH-11566)
asyncio.ProactorEventLoop now catchs and logs send errors when the
self-pipe is full: BaseProactorEventLoop._write_to_self() now catchs
and logs OSError exceptions, as done by
BaseSelectorEventLoop._write_to_self().
(cherry picked from commit c9f872b0bd)

Co-authored-by: Victor Stinner <vstinner@redhat.com>
2019-01-15 05:17:05 -08:00