summaryrefslogtreecommitdiffstats
path: root/Doc/whatsnew
Commit message (Collapse)AuthorAgeFilesLines
* [3.12] gh-102304: Fix Py_INCREF() for limited C API 3.9 (#105553)Victor Stinner2023-06-091-9/+0
| | | | | | | | | | | | | | | | | * gh-102304: Fix Py_INCREF() for limited C API 3.9 (#105550) When Python is built in debug mode (Py_REF_DEBUG macro), Py_INCREF() and Py_DECREF() of the limited C API 3.9 (and older) now call Py_IncRef() and Py_DecRef(), since _Py_IncRef() and _Py_DecRef() were added to Python 3.10. (cherry picked from commit 7ba0fd9f87ad75f8eda8e002c2fc71049b815f33) * gh-102304: Remove Py_INCREF() doc change (#105552) Py_INCREF() was made compatible again with Python 3.9 and older in the limited API of Python debug mode. (cherry picked from commit 58e4b69f698e6fd0694a58f18679bbe0e7e50e91)
* [3.12] gh-105390: Correctly raise TokenError instead of SyntaxError for ↵Miss Islington (bot)2023-06-071-5/+6
| | | | tokenize errors (GH-105399) (#105439)
* [3.12] gh-102304: Fix Py_INCREF() stable ABI in debug mode (#104763) (#105352)Victor Stinner2023-06-061-0/+9
| | | | | | | | | | | | | | | gh-102304: Fix Py_INCREF() stable ABI in debug mode (#104763) When Python is built in debug mode (if the Py_REF_DEBUG macro is defined), the Py_INCREF() and Py_DECREF() function are now always implemented as opaque functions to avoid leaking implementation details like the "_Py_RefTotal" variable or the _Py_DecRefTotal_DO_NOT_USE_THIS() function. * Remove _Py_IncRefTotal_DO_NOT_USE_THIS() and _Py_DecRefTotal_DO_NOT_USE_THIS() from the stable ABI. * Remove _Py_NegativeRefcount() from limited C API. (cherry picked from commit 92022d8416d9e175800b65c4d71d4e4fb47adcb0)
* [3.12] gh-102304: doc: Add links to Stable ABI and Limited C API (#105345) ↵Victor Stinner2023-06-062-2/+2
| | | | | | | | | | | | | | | | | | | (#105371) * gh-102304: doc: Add links to Stable ABI and Limited C API (#105345) * Add "limited-c-api" and "stable-api" references. * Rename "stable-abi-list" reference to "limited-api-list". * Makefile: Document files regenerated by "make regen-limited-abi" * Remove first empty line in generated files: - Lib/test/test_stable_abi_ctypes.py - PC/python3dll.c (cherry picked from commit bae415ad02c79cf3a2eec4aa6969221a12e6716f) * gh-102304: Fix up Simple ABI doc (GH-105351) (cherry picked from commit 0202aa002e06acef9aa55ace0d939103df19cadd)
* [3.12] What's New in 3.12: List 'Improved Modules' alphabetically ↵Hugo van Kemenade2023-06-051-107/+107
| | | | (GH-105315) (#105321)
* [3.12] Clarify that error messages are better with PEP 701 (GH-105150) (#105169)Miss Islington (bot)2023-06-051-0/+25
| | | | | Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com> Co-authored-by: Marta Gómez Macías <mgmacias@google.com>
* [3.12] Fix typo in Python 3.12 What's New (GH-105278) (#105282)Miss Islington (bot)2023-06-041-2/+2
| | | | | | Fix typo in Python 3.12 What's New (GH-105278) (cherry picked from commit 9a90c9ace2ed878715107bf4ae39e5967d7c931f) Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
* [3.12] GH-89886: Bump to GNU Autoconf v2.71 (#104925) (#105207)Erlend E. Aasland2023-06-011-0/+4
| | | Co-authored-by: Christian Heimes <christian@python.org>
* [3.12] gh-87729: add LOAD_SUPER_ATTR to 3.12 What's New (GH-105125) (#105143)Miss Islington (bot)2023-05-311-0/+7
|
* [3.12] gh-97933: add LOAD_FAST_AND_CLEAR to 3.12 What's New bytecode section ↵Miss Islington (bot)2023-05-311-0/+3
| | | | (GH-105126) (#105142)
* [3.12] Document PEP 698 and other new typing features in What's New ↵Miss Islington (bot)2023-05-281-6/+37
| | | | | | (GH-104957) (#105045) Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* [3.12] gh-104992: [What's New in 3.12] Document ↵Miss Islington (bot)2023-05-281-1/+2
| | | | | | unittest.TestProgram.usageExit's deprecation (GH-104995) (#105036) Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
* [3.12] gh-104992: [What's New in 3.11] Document ↵Miss Islington (bot)2023-05-271-0/+4
| | | | | | | | | | unittest.TestProgram.usageExit's deprecation (GH-104994) (#105009) gh-104992: [What's New in 3.11] Document unittest.TestProgram.usageExit's deprecation (GH-104994) Document unittest.TestProgram.usageExit's pending removal in 3.13 (cherry picked from commit 7df861c23cd61e7c55943d4036ea5c6b1df5cb49) Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
* [3.12] GH-101588: Deprecate pickle/copy/deepcopy support in itertools ↵Miss Islington (bot)2023-05-261-0/+6
| | | | (GH-104965) (GH-104997)
* [3.12] gh-103921: Document PEP 695 (GH-104642) (#104989)Miss Islington (bot)2023-05-261-2/+73
| | | | | | (cherry picked from commit 060277d96bf4ba86df8e4d65831a8cbdfeb51fc5) Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* [3.12] Misc updates to Whatsnew 3.12 (GH-104912) (GH-104915)Miss Islington (bot)2023-05-251-1/+34
|
* [3.12] gh-102856: Add missing quote to fix doctest (GH-104852) (#104854)Miss Islington (bot)2023-05-241-1/+1
| | | | Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
* [3.12] gh-102856: Add changes related to PEP 701 in 3.12 What's New docs ↵Miss Islington (bot)2023-05-241-16/+135
| | | | | | | | | | (GH-104824) (#104847) gh-102856: Add changes related to PEP 701 in 3.12 What's New docs (GH-104824) (cherry picked from commit c45701e9ef004a523ebb28f3be902b3cf2cf7a9b) Co-authored-by: Marta Gómez Macías <mgmacias@google.com> Co-authored-by: Pablo Galindo Salgado <Pablogsal@gmail.com> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* [3.12] GH-104668: Don't call PyOS_* hooks in subinterpreters (GH-104760)Miss Islington (bot)2023-05-231-0/+9
| | | | | | GH-104668: Don't call PyOS_* hooks in subinterpreters (GH-104674) (cherry picked from commit 357bed0bcd3c5d7c4a8caad451754a9a172aca3e) Co-authored-by: Brandt Bucher <brandtbucher@microsoft.com>
* gh-94473: Flatten arguments in tkinter.Canvas.coords() (GH-98479)Serhiy Storchaka2023-05-221-0/+11
| | | | | It now accepts not only "x1, y1, x2, y2, ..." and "[x1, y1, x2, y2, ...]", but also "(x1, y1), (x2, y2), ..." and "[(x1, y1), (x2, y2), ...]".
* gh-98836: Extend PyUnicode_FromFormat() (GH-98838)Serhiy Storchaka2023-05-211-0/+6
| | | | | | | | | * Support for conversion specifiers o (octal) and X (uppercase hexadecimal). * Support for length modifiers j (intmax_t) and t (ptrdiff_t). * Length modifiers are now applied to all integer conversions. * Support for wchar_t C strings (%ls and %lV). * Support for variable width and precision (*). * Support for flag - (left alignment).
* gh-103857: Document utcnow and utcfromtimestamp deprecations in What's New ↵Hugo van Kemenade2023-05-211-0/+10
| | | | | | (#104542) Co-authored-by: Paul Ganssle <1377457+pganssle@users.noreply.github.com>
* gh-92248: Deprecate `type`, `choices`, `metavar` parameters of ↵Nikita Sobolev2023-05-191-0/+5
| | | | | | | | `argparse.BooleanOptionalAction` (#103678) Co-authored-by: Kirill <80244920+Eclips4@users.noreply.github.com> Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com> Co-authored-by: Oleg Iarygin <oleg@arhadthedev.net>
* GH-104484: Add case_sensitive argument to `pathlib.PurePath.match()` (GH-104565)thirumurugan2023-05-181-0/+3
| | | Co-authored-by: Barney Gale <barney.gale@gmail.com>
* gh-104487: PYTHON_FOR_REGEN must be minimum Python 3.10 (#104488)Erlend E. Aasland2023-05-151-0/+2
| | | Also include Python 3.12 in the list of accepted versions.
* gh-91896: Revert some very noisy DeprecationWarnings for `ByteString` (#104424)Alex Waygood2023-05-131-2/+2
|
* gh-91896: Fixup some docs issues following ByteString deprecation (#104422)Alex Waygood2023-05-121-0/+3
| | | Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* gh-97933: (PEP 709) inline list/dict/set comprehensions (#101441)Carl Meyer2023-05-091-0/+24
| | | | Co-authored-by: Irit Katriel <1055913+iritkatriel@users.noreply.github.com> Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* gh-97696: Move around and update the whatsnew entry for asyncio eager task ↵Itamar Ostricher2023-05-091-5/+5
| | | | factory (#104298)
* gh-90656: Add platform triplets for 64-bit LoongArch (LA64) (#30939)Zhang Na2023-05-091-0/+8
| | | | Signed-off-by: Zhang Na <zhangna@loongson.cn> Co-authored-by: WANG Xuerui <git@xen0n.name>
* gh-103193: cache calls to `inspect._shadowed_dict` in ↵Alex Waygood2023-05-071-3/+4
| | | | | `inspect.getattr_static` (#104267) Co-authored-by: Carl Meyer <carl@oddbird.net>
* gh-90953: Emit deprecation warnings for `ast` features deprecated in Python ↵Alex Waygood2023-05-061-0/+13
| | | | | | | 3.8 (#104199) `ast.Num`, `ast.Str`, `ast.Bytes`, `ast.Ellipsis` and `ast.NameConstant` now all emit deprecation warnings on import, access, instantation or `isinstance()` checks. Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* GH-100479: Add `pathlib.PurePath.with_segments()` (GH-103975)Barney Gale2023-05-051-0/+5
| | | | | Add `pathlib.PurePath.with_segments()`, which creates a path object from arguments. This method is called whenever a derivative path is created, such as from `pathlib.PurePath.parent`. Subclasses may override this method to share information between path objects. Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* gh-102500: Add PEP 688 and 698 to the 3.12 release highlights (#104174)Hugo van Kemenade2023-05-041-2/+6
|
* gh-91896: Deprecate collections.abc.ByteString (#102096)Shantanu2023-05-041-0/+5
| | | | Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com> Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
* gh-102500: Document PEP 688 (#102571)Jelle Zijlstra2023-05-041-1/+13
| | | | Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com> Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
* gh-103509: PEP 697 -- Limited C API for Extending Opaque Types (GH-103511)Petr Viktorin2023-05-041-0/+15
| | | | Co-authored-by: Oleg Iarygin <oleg@arhadthedev.net> Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
* gh-97850: Deprecate `find_loader` and `get_loader` in `pkgutil` (GH-98520)Nikita Sobolev2023-05-031-0/+5
| | | | | Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM> Co-authored-by: Brett Cannon <brett@python.org> Co-authored-by: Oleg Iarygin <oleg@arhadthedev.net>
* gh-103590: mention that the change is included in 3.11.4 and clarify except* ↵Irit Katriel2023-05-031-1/+2
| | | | documentation (#104095)
* gh-103693: Add convenience variable feature to `pdb` (#103694)Tian Gao2023-05-031-0/+8
|
* gh-103968: Deprecate creating heap types whose metaclass has custom tp_new. ↵Petr Viktorin2023-05-031-0/+20
| | | | | | | | (GH-103972) (That's a mouthful of an edge case!) Co-authored-by: Barney Gale <barney.gale@gmail.com>
* GH-97850: Suppress cross-references to removed ``importlib.util`` functions ↵Adam Turner2023-05-033-7/+7
| | | | | | | | | (#104134) `importlib.utils` -> `importlib.util` in a few places --------- Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* GH-97850: Suppress cross-references to the removed ``module_repr`` method ↵Adam Turner2023-05-034-8/+8
| | | | | (#104133) Suppress cross-references to ``module_repr``
* GH-98040: Suppress cross-references to the removed ``imp`` module (#104131)Adam Turner2023-05-038-16/+16
| | | Suppress cross-references to imp
* gh-98040: Remove find_loader, find_module and other deprecated APIs (#98059)Barry Warsaw2023-05-037-45/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Remove deprecated classes from pkgutil * Remove some other PEP 302 obsolescence * Use find_spec instead of load_module * Remove more tests of PEP 302 obsolete APIs * Remove another bunch of tests using obsolete load_modules() * Remove deleted names from __all__ * Remove obsolete footnote * imp is removed * Remove `imp` from generated stdlib names * What's new and blurb * Update zipimport documentation for the removed methods * Fix some Windows tests * Remove any test (or part of a test) that references `find_module()`. * Use assertIsNone() / assertIsNotNone() consistently. * Update Doc/reference/import.rst * We don't need pkgutil._get_spec() any more either * test.test_importlib.fixtures.NullFinder * ...BadLoaderFinder.find_module * ...test_api.InvalidatingNullFinder.find_module * ...test.test_zipimport test of z.find_module * Suppress cross-references to find_loader and find_module * Suppress cross-references to Finder * Suppress cross-references to pkgutil.ImpImporter and pkgutil.ImpLoader --------- Co-authored-by: Oleg Iarygin <oleg@arhadthedev.net> Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com>
* gh-82012: Deprecate bitwise inversion (~) of bool (#103487)Tim Hoffmann2023-05-031-0/+6
| | | | | | | | | | | | | | The bitwise inversion operator on bool returns the bitwise inversion of the underlying int value; i.e. `~True == -2` such that `bool(~True) == True`. It's a common pitfall that users mistake `~` as negation operator and actually want `not`. Supporting `~` is an artifact of bool inheriting from int. Since there is no real use-case for the current behavior, let's deprecate `~` on bool and later raise an error. This removes a potential source errors for users. Full reasoning: https://github.com/python/cpython/issues/82012#issuecomment-1258705971 Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
* GH-103484: Fix redirected permanently URLs (#104001)Rafael Fontenelle2023-05-0213-23/+23
| | | | | Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com> Co-authored-by: Oleg Iarygin <dralife@yandex.ru>
* gh-97696: asyncio eager tasks factory (#102853)Itamar Ostricher2023-05-011-0/+5
| | | | Co-authored-by: Jacob Bower <jbower@meta.com> Co-authored-by: Carol Willing <carolcode@willingconsulting.com>
* gh-100458: Clarify Enum.__format__() change of mixed-in types in the ↵Anže Pečar2023-05-011-13/+5
| | | | | | whatsnew/3.11.rst (GH-100387) Co-authored-by: JosephSBoyle <48555120+JosephSBoyle@users.noreply.github.com> Co-authored-by: Ethan Furman <ethan@stoneleaf.us>
* gh-103793: Defer formatting task name (#103767)Itamar Ostricher2023-04-291-0/+3
| | | | | | | | | | | | | The default task name is "Task-<counter>" (if no name is passed in during Task creation). This is initialized in `Task.__init__` (C impl) using string formatting, which can be quite slow. Actually using the task name in real world code is not very common, so this is wasted init. Let's defer this string formatting to the first time the name is read (in `get_name` impl), so we don't need to pay the string formatting cost if the task name is never read. We don't change the order in which tasks are assigned numbers (if they are) -- the number is set on task creation, as a PyLong instead of a formatted string. Co-authored-by: Łukasz Langa <lukasz@langa.pl>