Commit graph

108631 commits

Author SHA1 Message Date
Miss Islington (bot)
9ee12cf325
bpo-27513: email.utils.getaddresses() now handles Header objects (GH-13797) (#27245)
getaddresses() should be able to handle a Header object if passed
one.

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit 89f4c34797)

Co-authored-by: Zackery Spytz <zspytz@gmail.com>
2021-07-19 19:28:56 +02:00
Miss Islington (bot)
2f643b1a8c
[3.9] bpo-44561: Update hyperlinks in Doc/distributing/index.rst (GH-27032) (GH-27233)
* Update hyperlinks in Doc/distributing/index.rst

Update three expired hyperlinks.

Closes [bpo-44561]().
(cherry picked from commit b494685b25)


Co-authored-by: Steven Hsu <hsuhaochun@gmail.com>

Automerge-Triggered-By: GH:ncoghlan
2021-07-18 17:39:03 -07:00
Pablo Galindo Salgado
e05afef3c6
Correct the order of check-abidump (GH-27230)
The check was backwards so we were not correctly detecting removals.
2021-07-18 16:53:14 +01:00
Miss Islington (bot)
049e98b2b7
[3.9] bpo-43958: Document importlib.metadata.PackagePath.locate method (GH-25669) (GH-27221)
(cherry picked from commit b38b2fa021)


Co-authored-by: Paul Moore <p.f.moore@gmail.com>

Automerge-Triggered-By: GH:jaraco
2021-07-17 19:53:00 -07:00
Miss Islington (bot)
8187033de1
Replace @ilevkivskyi with @Fidget-Spinner as typing code owner (GH-27210) (#27213)
(cherry picked from commit 311ee83adb)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
2021-07-17 11:46:11 +02:00
Ken Jin
fa674bdea3
[3.9] bpo-41249: Fix postponed annotations for TypedDict (GH-27017) (GH-27205)
This fixes TypedDict to work with get_type_hints and postponed evaluation of annotations across modules.

This is done by adding the module name to ForwardRef at the time the object is created and using that to resolve the globals during the evaluation.

Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
Co-authored-by: Germán Méndez Bravo <german.mb@gmail.com>
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
2021-07-17 11:36:38 +02:00
Miss Islington (bot)
df7c62980d
bpo-40897:Give priority to using the current class constructor in inspect.signature (GH-27177) (GH-27209)
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit 6aab5f9bf3)

Co-authored-by: Weipeng Hong <hongweichen8888@sina.com>
2021-07-17 10:36:31 +02:00
Łukasz Langa
ed2db9b594
bpo-40897: Partially backport GH-22583's refactor of inspect.py to allow bugfix backports (#27193) 2021-07-17 10:04:01 +02:00
Miss Islington (bot)
298ee657ab
bpo-44184: Fix subtype_dealloc() for freed type (GH-26274)
Fix a crash at Python exit when a deallocator function removes the
last strong reference to a heap type.

Don't read type memory after calling basedealloc() since
basedealloc() can deallocate the type and free its memory.

_PyMem_IsPtrFreed() argument is now constant.
(cherry picked from commit 615069eb08)

Co-authored-by: Victor Stinner <vstinner@python.org>
2021-07-15 16:36:51 -07:00
Miss Islington (bot)
0b4704973d
bpo-44184: Apply GH-26274 to the non-GC-type branch of subtype_dealloc (GH-27165) (GH-27175)
The non-GC-type branch of subtype_dealloc is using the type of an object after freeing in the same unsafe way as GH-26274 fixes. (I believe the old news entry covers this change well enough.)

https://bugs.python.org/issue44184
(cherry picked from commit 074e7659f2)

Co-authored-by: T. Wouters <thomas@python.org>
2021-07-16 01:35:25 +02:00
Miss Islington (bot)
95596d5921
bpo-44647: Fix test_httpservers failing on Unicode characters in os.environ on Windows (GH-27161) (#27170)
GH-23638 introduced a new test for Accept: headers in CGI HTTP servers. This test serializes all of os.environ on the server side. For non-UTF8 locales this can fail for some Unicode characters found in environment variables. This change fixes the HTTP_ACCEPT test.
(cherry picked from commit 82b218f36c)

Co-authored-by: Łukasz Langa <lukasz@langa.pl>
2021-07-15 22:09:55 +02:00
Miss Islington (bot)
421b543311
bpo-44639: fix typo in sqlite.rst (transation => transaction) (GH-27145) (GH-27149)
To my understanding, this is supposed to say "transaction".

See the relevant source:

a158b20019/Modules/_sqlite/connection.cGH-L1434-L1467
(cherry picked from commit 1ca27f2647)

Co-authored-by: Jack DeVries <58614260+jdevries3133@users.noreply.github.com>

Co-authored-by: Jack DeVries <58614260+jdevries3133@users.noreply.github.com>
2021-07-14 23:49:33 +01:00
Miss Islington (bot)
5fc784e28a
bpo-44572: On Windows, disconnect STDIN in platform._syscmd_ver() to prevent erroneous STDIN consumption (GH-27092)
(cherry picked from commit 0ee0a740e1)

Co-authored-by: Konstantin-Glukhov <glukhov.k@gmail.com>
2021-07-14 17:17:18 +01:00
Miss Islington (bot)
94adfe6e2c
bpo-44608: Fix memory leak in _tkinter._flatten() (GH-27107)
if it is called with a sequence or set, but not list or tuple.
(cherry picked from commit f572cbf1fa)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2021-07-13 22:44:08 -07:00
Miss Islington (bot)
fe73509c5b
bpo-44630: Fix assertion errors in csv module (GH-27127)
Fix incorrect handling of exceptions when interpreting dialect objects in
the csv module. Not clearing exceptions between calls to
PyObject_GetAttrString() causes assertion failures in pydebug mode (or with
assertions enabled).

Add a minimal test that would've caught this (passing None as dialect, or
any object that isn't a csv.Dialect subclass, which the csv module allows
and caters to, even though it is not documented.) In pydebug mode, the test
triggers the assertion failure in the old code.

Contributed-By: T. Wouters [Google]
(cherry picked from commit 0093876328)

Co-authored-by: T. Wouters <thomas@python.org>
2021-07-13 16:20:28 -07:00
Miss Islington (bot)
a3d20bfee3
bpo-43126: Expand docs on io.IOBase.readlines() method (GH-27061) (#27114)
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
(cherry picked from commit 3b5b99da4b)

Co-authored-by: andrei kulakov <andrei.avk@gmail.com>
2021-07-13 16:41:31 +02:00
Miss Islington (bot)
105e6cd67c
bpo-44514: Add doctest testcleanup for configparser and bz2 (GH-26909) (#27111)
Add testcleanup section to configparser and bz2 documentation which
removes temporary files created in the filesystem when 'make doctest'
is run.
(cherry picked from commit 48a5aa7f12)

Co-authored-by: Kevin Follstad <kfollstad@gmail.com>
2021-07-13 16:33:50 +02:00
Miss Islington (bot)
c786988b19
bpo-42194: Add "New in version: 3.9" to argparse.BooleanOptionalAction (GH-23026) (#27098)
(cherry picked from commit da2e673c53)

Co-authored-by: David Sanders <shang.xiao.sanders@gmail.com>
2021-07-12 18:23:25 +02:00
Vladimir Feinberg
489c273583
[3.9] bpo-43048: RecursionError traceback RecursionError bugfix for cpy3.9 (GH-24460) (#24460)
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
2021-07-12 17:58:47 +02:00
Miss Islington (bot)
47abf24036
bpo-26329: update os.path.normpath documentation (GH-20138) (#27095)
(cherry picked from commit 66c5853406)

Co-authored-by: Furkan Onder <furkanonder@protonmail.com>
2021-07-12 17:22:33 +02:00
Christian Heimes
c92b391dce
[3.9] bpo-38820: Test with OpenSSL 3.0.0-alpha16 (GH-25942) (#25944)
Also use new make target to install FIPS provider..
(cherry picked from commit e8525567dd)

Co-authored-by: Christian Heimes <christian@python.org>
2021-07-12 17:12:38 +02:00
Miss Islington (bot)
779983ed7f
bpo-43207: InspectLoader.is_package is not an abstract method (GH-24517) (#26322)
Making the description of `InspectLoader.is_package` aligned with the current implementation.

Automerge-Triggered-By: GH:jaraco
(cherry picked from commit 8b9310d902)

Co-authored-by: Junnosuke Kuroda <Isa-rentacs@users.noreply.github.com>
2021-07-12 17:11:59 +02:00
Miss Islington (bot)
e7009f4f9a
bpo-43298: Improved error message when building without the Windows SDK installed (GH-26800) (#26803)
(cherry picked from commit 80190b3e53)

Co-authored-by: Steve Dower <steve.dower@python.org>
2021-07-12 17:11:33 +02:00
Miss Islington (bot)
6fb4248cd9
bpo-44472: Fix ltrace functionality when exceptions are raised (GH-26822) (#26831)
(cherry picked from commit 06cda808f1)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
2021-07-12 17:11:10 +02:00
Miss Islington (bot)
c89f0b2587
[3.9] bpo-43219: shutil.copyfile, raise a less confusing exception instead of IsADirectoryError (GH-27049) (GH-27082)
Fixes the misleading IsADirectoryError to be FileNotFoundError.
(cherry picked from commit 248173cc04)


Co-authored-by: andrei kulakov <andrei.avk@gmail.com>

Automerge-Triggered-By: GH:gpshead
2021-07-09 21:13:59 -07:00
Miss Islington (bot)
302df02789
docs: add the word 'official' (GH-26849)
(cherry picked from commit af4a2dcc40)

Co-authored-by: Ned Batchelder <ned@nedbatchelder.com>
2021-07-08 08:21:55 -07:00
Dong-hee Na
9761abf306
[3.9] bpo-44558: Match countOf is/== treatment to c (GH-27007). (GH-27055) 2021-07-07 23:55:22 +09:00
Miss Islington (bot)
324b93295f
bpo-44563: Fix error handling in tee.fromiterable() (GH-27020) (GH-27042)
In debug build failed tee.fromiterable() corrupted the linked list of all GC objects.
(cherry picked from commit f64de53ff0)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
2021-07-05 23:34:01 +01:00
Ken Jin
51a29c42f1
[3.9] bpo-44562: Remove invalid PyObject_GC_Del from error path of types.GenericAlias … (GH-27016) (GH-27028) 2021-07-05 17:22:43 +01:00
Miss Islington (bot)
9f47d872db
bpo-44558: Make the implementation consistency of operator.indexOf (GH-27012)
(cherry picked from commit 09302405d2)

Co-authored-by: Dong-hee Na <donghee.na@python.org>
2021-07-05 02:52:04 -07:00
Pablo Galindo
fe847a6285
Revert "bpo-44562: Remove invalid PyObject_GC_Del from error path of types.GenericAlias … (GH-27016) (GH-27018)" (GH-27022)
This reverts commit 4684a34c8d.
2021-07-04 20:26:34 +01:00
Miss Islington (bot)
4684a34c8d
bpo-44562: Remove invalid PyObject_GC_Del from error path of types.GenericAlias … (GH-27016) (GH-27018)
(cherry picked from commit d33943a6c3)

Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>

Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
2021-07-04 18:55:43 +01:00
Miss Islington (bot)
21be6cb030
bpo-34266: [pdb] handle ValueError from shlex.split() (GH-26656) (GH-27005)
(cherry picked from commit d968a638fc)

Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
2021-07-03 17:05:33 +01:00
Miss Islington (bot)
91db097358
bpo-30256: [doc] Fix formatting error in news (GH-26994) (GH-26996)
(cherry picked from commit 2560c612c8)

Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
2021-07-02 18:38:04 +01:00
Miss Islington (bot)
8aa45de6c6
bpo-30256: Add manager_owned keyword arg to AutoProxy (GH-16341) (GH-26989)
Co-authored-by: Jordan Speicher <jordan@jspeicher.com>
(cherry picked from commit 85b920498b)

Co-authored-by: finefoot <33361833+finefoot@users.noreply.github.com>
2021-07-01 21:35:31 -07:00
Miss Islington (bot)
67e394562d
bpo-44535: Enable building with Visual Studio 2022 on Windows (GH-26962)
(cherry picked from commit d3a95c1b6e)

Co-authored-by: Steve Dower <steve.dower@python.org>
2021-06-30 12:31:04 -07:00
Steve Dower
863e3d5c7e
bpo-41180: Replace marshal code.__new__ audit event with marshal.load[s] and marshal.dumps (GH-26971) 2021-06-30 18:52:39 +01:00
Miss Islington (bot)
f790bc8084
bpo-44523: Remove the pass-through for hash() in weakref proxy objects (GH-26950) (GH-26960)
(cherry picked from commit e2fea101fd)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
2021-06-30 00:19:32 +01:00
Miss Islington (bot)
02859df105
bpo-38062: [doc] clarify that atexit uses equality comparisons internally. (GH-26935) (GH-26957)
(cherry picked from commit 12803c59d5)

Co-authored-by: Jack DeVries <58614260+jdevries3133@users.noreply.github.com>
2021-06-29 18:53:07 +01:00
Miss Islington (bot)
3ba65cdcef
bpo-42588: Update the docs for the TopologicalSorter.static_order() method (GH-26834) (GH-26952)
(cherry picked from commit 0d7f7975d5)

Co-authored-by: andrei kulakov <andrei.avk@gmail.com>

Co-authored-by: andrei kulakov <andrei.avk@gmail.com>
2021-06-29 15:19:05 +01:00
Łukasz Langa
0787a1b9d0
Post 3.9.6 2021-06-28 11:48:44 +02:00
Łukasz Langa
db3ff76da1
Python 3.9.6 2021-06-28 10:26:18 +02:00
Jason R. Coombs
17b916737b
[3.9] bpo-37741: make importlib.metadata docs discoverable through a module directive. (GH-25415) (GH-26500)
Automerge-Triggered-By: GH:jaraco.
(cherry picked from commit 23acadcc1c)

Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
2021-06-27 18:05:27 -04:00
Miss Islington (bot)
1acd1e6385
bpo-40620: Clarify tutorial controlflow.rst `range` examples (GH-26919) (GH-26928)
(cherry picked from commit 2f49c9debc)

Co-authored-by: jdevries3133 <58614260+jdevries3133@users.noreply.github.com>
2021-06-27 20:52:32 +01:00
Miss Islington (bot)
b2a5dcd8a0
Clarify the order of a stacked abstractmethod (GH-26892)
Co-authored-by: Tal Einat <532281+taleinat@users.noreply.github.com>
(cherry picked from commit 74d60eab55)

Co-authored-by: Ram Rachum <ram@rachum.com>
2021-06-27 11:50:45 -07:00
Serhiy Storchaka
4861fdaf25
[3.9] bpo-44482: Fix very unlikely resource leak in glob in non-CPython implementations (GH-26843). (GH-26916)
(cherry picked from commit 5c7940257e)
2021-06-27 14:28:24 +03:00
Stéphane Bidoul
fe272b7a3a
[3.9] Update vendored pip to 21.1.3 (GH-26912). (GH-26915) 2021-06-26 18:59:57 +01:00
Miss Islington (bot)
0796e21fea
bpo-44229: Ignore spurious EPROTOTYPE on macOS in test_ssl (GH-26893)
(cherry picked from commit b5a52eef67)

Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
2021-06-24 05:25:41 -07:00
Victor Stinner
5ed7827b16
bpo-44441: _PyImport_Fini2() resets PyImport_Inittab (GH-26874) (GH-26878)
Py_RunMain() now resets PyImport_Inittab to its initial value at
exit. It must be possible to call PyImport_AppendInittab() or
PyImport_ExtendInittab() at each Python initialization.

(cherry picked from commit 489699ca05)
2021-06-23 17:47:33 +02:00
Miss Islington (bot)
fcde2c6a8c
bpo-28395: Remove unnecessary semicolons in tests (GH-26868)
(cherry picked from commit 5a3108044d)

Co-authored-by: Dong-hee Na <donghee.na@python.org>
2021-06-23 03:03:00 -07:00