Christian Heimes
ee1a8b336d
bpo-40280: Block more syscalls that are causing crashes in tests (GH-30601)
2022-01-14 18:48:44 +01:00
Hugo van Kemenade
73140de97c
bpo-23183: Document the timeit output (GH-30359)
...
Co-authored-by: Robert Collins <robertc@robertcollins.net>
2022-01-14 17:25:36 +00:00
neonene
71c0b859ae
bpo-46362: Ensure abspath() tests pass through environment variables to subprocess (GH-30595)
2022-01-14 15:31:15 +00:00
Christian Heimes
c8319f7921
bpo-40280: Build WASM stdlib bundle and more modules for node (GH-30597)
2022-01-14 12:11:49 +01:00
Victor Stinner
7c770d3350
bpo-46280: Fix tracemalloc_copy_domain() (GH-30591)
...
Test if tracemalloc_copy_traces() failed to allocated memory in
tracemalloc_copy_domain().
2022-01-14 05:11:38 +01:00
Eric Snow
322f962f3e
bpo-45953: Statically initialize all the non-object PyInterpreterState fields we can. (gh-30589)
...
https://bugs.python.org/issue45953
2022-01-13 17:17:28 -07:00
Eric Snow
324908ba93
bpo-45953: Statically initialize all the PyThreadState fields we can. (gh-30590)
...
https://bugs.python.org/issue45953
2022-01-13 17:09:24 -07:00
neonene
d4e64cd4b0
bpo-46362: Ensure ntpath.abspath() uses the Windows API correctly (GH-30571)
...
This makes ntpath.abspath()/getpath_abspath() follow normpath(), since some WinAPIs such as PathCchSkipRoot() require backslashed paths.
2022-01-13 23:35:42 +00:00
Eric Snow
b8ddf7e794
Statically initialize _PyRuntimeState fields. (gh-30588)
...
https://bugs.python.org/issue45953
2022-01-13 16:33:40 -07:00
Eric Snow
bc02eac9d2
bpo-46370: Move the static initializer for _PyRuntime to its own header file. (gh-30587)
...
https://bugs.python.org/issue46370
2022-01-13 15:54:36 -07:00
Christian Heimes
276c234ce0
bpo-40479: Fix typo, flag must be set for OpenSSL < 3.0.0 (GH-30584)
2022-01-13 21:47:42 +01:00
Pablo Galindo
9471106fd5
Python 3.11.0a4
2022-01-13 19:38:15 +00:00
Victor Stinner
1a4d1c1c9b
bpo-46070: _PyGC_Fini() untracks objects (GH-30577)
...
Py_EndInterpreter() now explicitly untracks all objects currently
tracked by the GC. Previously, if an object was used later by another
interpreter, calling PyObject_GC_UnTrack() on the object crashed if
the previous or the next object of the PyGC_Head structure became a
dangling pointer.
2022-01-13 19:28:32 +01:00
Victor Stinner
6be848922b
bpo-44133: Link Python executable with object files (GH-30556)
...
When Python is built without --enable-shared, the "python" program is
now linked to object files, rather than being linked to the Python
library (libpython.a), to make sure that all symbols are exported.
Previously, the linker omitted some symbols like the Py_FrozenMain()
function.
When Python is configured with --without-static-libpython, the Python
static library (libpython.a) is no longer built.
* Check --without-static-libpython earlier in configure.ac
* Add LINK_PYTHON_OBJS and LINK_PYTHON_DEPS variables to Makefile.
* test_capi now ensures that the "Py_FrozenMain" symbol is exported.
2022-01-13 19:24:28 +01:00
Victor Stinner
0885999a8e
bpo-46355: Document PyFrameObject and PyThreadState changes (GH-30558)
...
Document PyFrameObject and PyThreadState changes in What's New in
Python 3.11 and explain how to port code.
2022-01-13 19:21:50 +01:00
Nikita Sobolev
f779faccd3
bpo-46358: modernize `test_asyncio` (GH-30562)
2022-01-13 23:28:02 +09:00
Nikita Sobolev
8c49d057bf
bpo-46359: Modernize `test_typing` by removing checks for EOL Python versions (GH-30563)
...
Also removes unused tests meant for older versions of Python.
2022-01-13 21:09:40 +08:00
Irit Katriel
c590b581bb
bpo-46328: Add sys.exception() (GH-30514)
2022-01-13 12:35:58 +00:00
Irit Katriel
9c2ebb906d
bpo-46344: Fix trace bug in else of try and try-star blocks (GH-30544)
2022-01-13 12:34:38 +00:00
Christian Heimes
443b308fee
bpo-40479: Fix hashlib's usedforsecurity for OpenSSL 3.0.0 (GH-30455)
2022-01-13 09:46:38 +01:00
Christian Heimes
a6ca8eee22
bpo-46315: Add ifdef HAVE_ feature checks for WASI compatibility (GH-30507)
2022-01-13 09:46:04 +01:00
Nikita Sobolev
1de60155d5
bpo-46345: Add a test case for implicit `Optional` class attribute (GH-30535)
2022-01-12 15:35:44 -08:00
Eric Snow
ed57b36c32
bpo-45953: Statically allocate the main interpreter (and initial thread state). (gh-29883)
...
Previously, the main interpreter was allocated on the heap during runtime initialization. Here we instead embed it into _PyRuntimeState, which means it is statically allocated as part of the _PyRuntime global. The same goes for the initial thread state (of each interpreter, including the main one). Consequently there are fewer allocations during runtime/interpreter init, fewer possible failures, and better memory locality.
FYI, this also helps efforts to consolidate globals, which in turns helps work on subinterpreter isolation.
https://bugs.python.org/issue45953
2022-01-12 16:28:46 -07:00
Jelle Zijlstra
0bbf30e2b9
bpo-46342: make @typing.final introspectable (GH-30530)
...
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
2022-01-12 11:38:25 -08:00
Christian Heimes
e34c9367f8
bpo-40280: Allow to compile _testcapi as builtin module (GH-30559)
2022-01-12 20:27:37 +01:00
Tim Peters
fc05e6bfce
bpo-46020: Optimize long_pow for the common case (GH-30555)
...
This cuts a bit of overhead by not initializing the table of small
odd powers unless it's needed for a large exponent.
2022-01-12 12:55:02 -06:00
Nikita Sobolev
e2a9c8ef09
bpo-46348: modernize `test_typing` (GH-30547)
2022-01-12 08:48:10 -08:00
Christian Heimes
43839ba438
bpo-40280: Add --with-emscripten-target to build for browser or node (GH-30552)
...
Co-authored-by: Ethan Smith <ethan@ethanhs.me>
2022-01-12 16:08:19 +01:00
Yury Selivanov
be578e0c06
bpo-46347: Yet another fix in the erorr path of PyEval_EvalCodeEx ( #30554 )
2022-01-11 16:35:19 -08:00
Yury Selivanov
20b5791ce9
bpo-46347: Fix PyEval_EvalCodeEx to correctly cleanup in error paths ( #30551 )
2022-01-11 15:37:09 -08:00
Victor Stinner
08bc1bad11
bpo-46303: Fix fileutils.h compiler warnings (GH-30550)
...
Add missing pycore_fileutils.h include in _tkinter.c and
_testconsole.c.
2022-01-12 00:35:26 +01:00
Yury Selivanov
607d8a838f
bpo-46347: Fix memory leak in PyEval_EvalCodeEx. ( #30546 )
...
First introduced in 0332e569c1
2022-01-11 14:25:28 -08:00
Ben Kehoe
dce642f244
bpo-46307: Add string.Template.get_identifiers() method (GH-30493)
...
Add `string.Template.get_identifiers()` method that returns the identifiers within the template. By default, raises an error if it encounters an invalid identifier (like `substitute()`). The keyword-only argument `raise_on_invalid` can be set to `False` to ignore invalid identifiers (like `safe_substitute()`).
Automerge-Triggered-By: GH:warsaw
2022-01-11 11:15:42 -08:00
Eric Snow
cf496d657a
bpo-45953: Statically allocate and initialize global bytes objects. (gh-30096)
...
The empty bytes object (b'') and the 256 one-character bytes objects were allocated at runtime init. Now we statically allocate and initialize them.
https://bugs.python.org/issue45953
2022-01-11 09:37:24 -07:00
Julien Palard
6f05e1ec19
[doc] Add license_url for python-docs-theme 2022.1. (GH-30527)
2022-01-11 17:32:42 +01:00
Pablo Galindo Salgado
cedec19be8
bpo-46339: Fix crash in the parser when computing error text for multi-line f-strings (GH-30529)
...
Automerge-Triggered-By: GH:pablogsal
2022-01-11 08:30:39 -08:00
Julian Gilbey
43c5c1369c
closes bpo-46253: Change Py_UNICODE to Py_UCS4 in the C API docs to match the current source code (GH-30387)
2022-01-11 08:33:06 -06:00
Michael Oliver
73decdf021
Remove unused `Any` from `Concatenate` example in typing docs (GH-30516)
2022-01-11 21:59:26 +08:00
Mark Shannon
7357ac94f8
News item for issue 46314. (GH-30515)
2022-01-11 11:29:48 +00:00
Mark Shannon
bd04fac7eb
bpo-46331: Do not set line number of instruction storing doc-string. (GH-30518)
2022-01-11 11:28:30 +00:00
Victor Stinner
ea1a54506b
bpo-46303: Move fileutils.h private functions to internal C API (GH-30484)
...
Move almost all private functions of Include/cpython/fileutils.h to
the internal C API Include/internal/pycore_fileutils.h.
Only keep _Py_fopen_obj() in Include/cpython/fileutils.h, since it's
used by _testcapi which must not use the internal C API.
Move EncodeLocaleEx() and DecodeLocaleEx() functions from _testcapi
to _testinternalcapi, since the C API moved to the internal C API.
2022-01-11 11:56:16 +01:00
Nikita Sobolev
fc75bfb8be
bpo-46310: simplify `for` loop in `asyncio/windows_events` (GH-30334)
2022-01-11 12:51:34 +02:00
Sam Gross
e13cdca0f5
bpo-46205: exit if no workers are alive in runtest_mp (GH-30470)
2022-01-11 12:03:09 +09:00
Arie Bovenberg
081a214008
bpo-46244: Remove __slots__ from typing.TypeVar, .ParamSpec ( #30444 )
...
* add missing __slots__ to typing._TypeVarLike
* add news entry
* remove slots from _TypeVarLike base classes
* cleanup diff
* fix broken link in blurb
2022-01-11 07:43:39 +08:00
Nikita Sobolev
6223cbf86a
bpo-45331: [Enum] add rule to docs that mixin type must be subclassable (GH-30521)
2022-01-10 15:42:45 -08:00
Nikita Sobolev
13e4659276
bpo-46327: [Enum] remove skipped tests (GH-30512)
2022-01-10 11:12:34 -08:00
Nikita Sobolev
582286d71c
bpo-46301: [Enum] fix refleak tests (GH30510)
2022-01-10 11:09:00 -08:00
Irit Katriel
0d639678d3
bpo-46332: use raise..from instead of assigning __cause__ and raising (GH-30517)
2022-01-10 18:59:21 +00:00
Mark Shannon
ec0c392f34
bpo-46314: Remove extra RESUME when compiling a lamdba. (GH-30513)
2022-01-10 12:29:02 +00:00
Raymond Hettinger
d24cd49acb
bpo-46270: Describe the `in` and `not in` operators as membership tests. (GH-30504)
2022-01-09 18:02:06 -08:00