Commit graph

115173 commits

Author SHA1 Message Date
Eric Snow d45cc80452
gh-98627: Add the _testsinglephase Module (gh-99039)
This makes it more clear that a given test is definitely testing against a single-phase init (legacy) extension module.  The new module is a companion to _testmultiphase.

https://github.com/python/cpython/issues/98627
2022-11-08 09:58:11 -07:00
Victor Stinner 4d5fcca273
gh-91248: Add PyFrame_GetVar() function (#95712)
Add PyFrame_GetVar() and PyFrame_GetVarString() functions to get a
frame variable by its name.

Move PyFrameObject C API tests from test_capi to test_frame.
2022-11-08 17:40:27 +01:00
Mikael Koli acf4d5d5bd
Fix broken link in asyncio-subprocesses doc (GH-99214)
# Fix broken link in Doc/library/asyncio-subprocess.rst

This is a trivial fix in documentation to fix a broken link.

There is a broken link in [Doc/library/asyncio-subprocess.rst](https://docs.python.org/3/library/asyncio-subprocess.html#asyncio.subprocess.Process) for the function ``wait_for``:

![image](https://user-images.githubusercontent.com/37690409/200388894-fb6b7c42-b2cc-49ec-a239-e3472890db1f.png)

I suppose this refers to the function ``asyncio.wait_for`` which is not clear in the docs.

This PR fixes the link and the result looks like the following:

![image](https://user-images.githubusercontent.com/37690409/200389483-b4a92105-7d2c-4285-b0fc-78a6dc0be39c.png)

Automerge-Triggered-By: GH:AlexWaygood
2022-11-08 08:26:06 -08:00
Guido van Rossum f1a654648b
GH-98831: Simple input-output stack effects for bytecodes.c (#99120) 2022-11-08 08:22:56 -08:00
Brandt Bucher c7065ce019
GH-93143: Don't turn LOAD_FAST into LOAD_FAST_CHECK (GH-99075) 2022-11-08 07:50:46 -08:00
Nikita Sobolev e56e33d271
gh-72719: Remove asyncore and asynchat modules (#96580)
Remove modules asyncore and asynchat, which were deprecated by PEP 594.

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-11-08 16:48:58 +01:00
Irit Katriel c43714fbcd
gh-99181: fix except* on unhashable exceptions (GH-99192) 2022-11-08 09:32:20 +00:00
Kumar Aditya a751bf565c
GH-90699: fix refleak in _testcapimodule.c (gh-99236) 2022-11-08 15:50:07 +09:00
Kamil Turek b9dedfe61d
gh-92119: ctypes: Print exception class name instead of its representation (#98302) 2022-11-07 20:53:59 -08:00
Nikita Sobolev a309ad9f76
gh-98513: Test abstract methods of some collections types (#98516) 2022-11-07 17:48:23 -08:00
Nikita Sobolev c32bc1bffd
gh-99124: use concrete exception types in test_builtin (#99125) 2022-11-07 17:47:32 -08:00
Gregory P. Smith d315722564
gh-98433: Fix quadratic time idna decoding. (#99092)
There was an unnecessary quadratic loop in idna decoding. This restores
the behavior to linear.

This also adds an early length check in IDNA decoding to outright reject
huge inputs early on given the ultimate result is defined to be 63 or fewer
characters.
2022-11-07 16:54:41 -08:00
Hugo van Kemenade 9430d27355
gh-98817: Remove PCbuild/lib.pyproj (GH-98818) 2022-11-07 20:23:35 +00:00
Kumar Aditya be0d5008b3
GH-90699: Remove remaining _Py_IDENTIFIER stdlib usage (GH-99067) 2022-11-07 12:06:23 -08:00
Petr Viktorin 1438b77997
gh-96746: Docs: Clear up Py_TPFLAGS_DISALLOW_INSTANTIATION inheritance (GH-99002)
The flag is not inherited, but its effect -- a NULL tp_new -- is.

Drop hints for people who come here wanting to “disallow instantiation”.
2022-11-07 19:45:50 +01:00
Mark Shannon 4a1c58d504
GH-96793: Specialize FOR_ITER for generators. (GH-98772) 2022-11-07 14:49:51 +00:00
Noam Cohen 80c08d1cd6
gh-95389: expose popular ETHERTYPE_* constants in the socket module (#95390)
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
Co-authored-by: CAM Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-11-07 15:27:37 +01:00
Pablo Galindo Salgado 6168e714be
gh-98254: Add what's new entry for the improvement in commit bb56dead33 (#99197) 2022-11-07 13:37:14 +00:00
Pablo Galindo Salgado be31ecf8b3
gh-91058: Add what's new entry for the improvement in commit 7cfbb49fcd (#99198) 2022-11-07 13:36:48 +00:00
Erlend E. Aasland e02f1e2df9
Docs: add argument spec to sqlite3 CLI docs (#99200) 2022-11-07 14:18:36 +01:00
Zackery Spytz 5ff81da6d3
bpo-38523: ignore_dangling_symlinks does not apply recursively (GH-22937) 2022-11-07 11:45:16 +00:00
Harshil cfec5b18bf
remove new line in pickle exception message (GH-31782) 2022-11-07 07:43:39 +00:00
andrei kulakov c6325b1c9f
gh-91803: Mock - fix error when using autospec methods with seal (#92213)
Fixes https://github.com/python/cpython/issues/91803.

Co-authored-by: Karthikeyan Singaravelan <tir.karthi@gmail.com>
Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com>
2022-11-07 07:24:46 +00:00
jmcb 728e42fcf5
doc: Formatting and typo fixes (#98974) 2022-11-06 20:55:55 -08:00
Nikita Sobolev d7a00f1e8e
GH-99155: Fix NormalDist pickle with 0 and 1 protocols (GH-99156) 2022-11-06 21:02:13 -06:00
Nikita Sobolev bef9efabc3
GH-99155: Fix NormalDist pickle with 0 and 1 protocols (GH99156) 2022-11-06 20:56:41 -06:00
Dong-hee Na f626b7b504
gh-96055: Update faulthandler to emit proper unexpect signal number (gh-99162) 2022-11-07 10:19:25 +09:00
Wenzel Jakob 57a405213c
gh-98586: Add What's New entry and update docs (#99056)
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2022-11-06 23:54:55 +01:00
Anh71me bd221c01dd
gh-98139: enhance namespace package repr 2022-11-06 22:13:40 +00:00
Nouran Ali 2db55e0c00
gh-94286 Fix documentation of print default param (GH-94297) 2022-11-06 20:14:58 +00:00
Terry Jan Reedy 5eff82fdde
bpo-33964: IDLE macosx - removed unused local dict. (GH-7926) 2022-11-06 20:10:22 +00:00
Ethan Furman a71b117c3d
[Enum] add built-in property to test_test_simple_enum (GH-98453) 2022-11-06 12:03:42 -08:00
Nikita Sobolev 8463cb55da
gh-99051: remove duplicated test from test_weakref (GH-99052) 2022-11-06 19:28:44 +00:00
Guido van Rossum 7dcd28eb41
GH-98831: Implement super-instruction generation (#99084)
Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
2022-11-06 09:40:47 -08:00
jonasdlindner ede6cb2615
Correct some typos in comments (GH-98194)
Automerge-Triggered-By: GH:AlexWaygood
2022-11-06 08:54:44 -08:00
Irit Katriel 61b6c40b64
gh-99153: set location on SyntaxError for try with both except and except* (GH-99160) 2022-11-06 15:36:19 +00:00
Shantanu d3b82b4463
gh-83004: Clean up refleak in _pickle initialisation (#98841) 2022-11-06 06:05:13 -08:00
Shantanu 31f2f6568d
gh-83004: Clean up refleak in _zoneinfo initialisation (#98842) 2022-11-06 06:04:36 -08:00
Pablo Galindo Salgado 99e2e60cb2
gh-99139: Improve NameError error suggestion for instances (#99140) 2022-11-06 13:52:06 +00:00
Nikita Sobolev a0bc75e2fd
test_typing: use all pickle protocols (#99154) 2022-11-06 11:53:57 +00:00
Ethan Furman 8feb7ab77c
gh-93464: [Enum] fix auto() failure during multiple assignment (GH-99148)
* fix auto() failure during multiple assignment

i.e. `ONE = auto(), 'text'` will now have `ONE' with the value of `(1,
'text')`.  Before it would have been `(<an auto instance>, 'text')`
2022-11-05 18:01:08 -07:00
Doj 586b07e1f9
[doc] fix typo (GH-99143) 2022-11-05 21:03:29 +00:00
Paul Moore 47ab8480e7
gh-99134: Update bundled pip to 22.3.1 (gh-99135)
Update bundled pip to 22.3.1
2022-11-05 17:50:39 +00:00
Nikita Sobolev 317acb8038
gh-94808: add tests covering PyFunction_GetKwDefaults and PyFunction_SetKwDefaults (GH-98809) 2022-11-05 17:08:47 +00:00
Nikita Sobolev c5c40773cb
gh-94808: add tests covering PySequence_{Set,Del}Slice (GH-99123) 2022-11-05 17:08:00 +00:00
Kaushik Kulkarni 67ade403a2
gh-98284: better error message for undefined abstractmethod (#97971) 2022-11-05 09:31:57 -07:00
Nikita Sobolev b5f711185b
gh-94808: add tests covering PyEval_GetFuncDesc function (GH-98300) 2022-11-05 13:07:59 +00:00
Sam James 12078e78f6
gh-99086: Fix implicit int compiler warning in configure check for PTHREAD_SCOPE_SYSTEM (#99085) 2022-11-05 09:30:31 +01:00
Guido van Rossum d04899abb0
GH-99104: Update headers for bytecodes.c and generate_cases.py (#99112)
Also tweak the labels near the end of bytecodes.c.
2022-11-04 17:40:43 -07:00
Brandt Bucher 6a8d3c57af
GH-98686: Fix compiler warning for HAS_ARG (GH-99106) 2022-11-04 16:54:32 -07:00