summaryrefslogtreecommitdiffstats
path: root/Doc/whatsnew
Commit message (Collapse)AuthorAgeFilesLines
* gh-82017: Support as_integer_ratio() in the Fraction constructor (GH-120271)Serhiy Storchaka2024-07-191-0/+7
| | | | | Any objects that have the as_integer_ratio() method (e.g. numpy.float128) can now be converted to a fraction.
* Remove duplicate "it" in whatsnew 3.13 (#121580)Rafael Fontenelle2024-07-171-1/+1
|
* GH-105879: Note exec/eval keyword change in What's New (GH-121831)Alyssa Coghlan2024-07-161-0/+4
|
* gh-84978: Add float.from_number() and complex.from_number() (GH-26827)Serhiy Storchaka2024-07-151-0/+4
| | | | | | They are alternate constructors which only accept numbers (including objects with special methods __float__, __complex__ and __index__), but not strings.
* gh-121450: Make inline breakpoints use the most recent pdb instance (#121451)Tian Gao2024-07-111-0/+10
|
* NEWS: Fix Sphinx warnings and increase threshold for new news nits (#121482)Hugo van Kemenade2024-07-083-5/+5
| | | | Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* gh-121141: add support for `copy.replace` to AST nodes (#121162)Bénédikt Tran2024-07-041-2/+6
|
* gh-121027: Make the functools.partial object a method descriptor (GH-121089)Serhiy Storchaka2024-07-031-0/+6
| | | Co-authored-by: d.grigonis <dgrigonis@users.noreply.github.com>
* gh-120743: Soft deprecate os.popen() function (#120744)Victor Stinner2024-07-011-0/+5
| | | Soft deprecate os.popen() and os.spawn*() functions.
* gh-107803: add whatsnew for asyncio double linked list implementation (#120995)Kumar Aditya2024-06-281-0/+8
|
* gh-121027: Add a future warning in functools.partial.__get__ (#121086)Serhiy Storchaka2024-06-271-0/+6
|
* gh-119182: Add PyUnicodeWriter_WriteUCS4() function (#120849)Victor Stinner2024-06-241-0/+1
|
* docs: puremagic.what() as replacement for imghdr.what() (#120871)Christian Clauss2024-06-241-0/+3
|
* GH-73991: Add `pathlib.Path.copytree()` (#120718)Barney Gale2024-06-231-0/+3
| | | | | | | | | | | | | | | | | | | | Add `pathlib.Path.copytree()` method, which recursively copies one directory to another. This differs from `shutil.copytree()` in the following respects: 1. Our method has a *follow_symlinks* argument, whereas shutil's has a *symlinks* argument with an inverted meaning. 2. Our method lacks something like a *copy_function* argument. It always uses `Path.copy()` to copy files. 3. Our method lacks something like a *ignore_dangling_symlinks* argument. Instead, users can filter out danging symlinks with *ignore*, or ignore exceptions with *on_error* 4. Our *ignore* argument is a callable that accepts a single path object, whereas shutil's accepts a path and a list of child filenames. 5. We add an *on_error* argument, which is a callable that accepts an `OSError` instance. (`Path.walk()` also accepts such a callable). Co-authored-by: Nice Zombies <nineteendo19d0@gmail.com>
* GH-120804: add docs for removal for asyncio child watchers (#120895)Kumar Aditya2024-06-233-11/+31
| | | Co-authored-by: Alex Waygood <alex.waygood@gmail.com>
* gh-119182: Add PyUnicodeWriter_DecodeUTF8Stateful() (#120639)Victor Stinner2024-06-211-0/+2
| | | | | | Add PyUnicodeWriter_WriteWideChar() and PyUnicodeWriter_DecodeUTF8Stateful() functions. Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* gh-117511: Make PyMutex public in the non-limited API (#117731)Sam Gross2024-06-201-0/+5
|
* gh-120600: Make Py_TYPE() opaque in limited C API 3.14 (#120601)Victor Stinner2024-06-181-0/+5
| | | | In the limited C API 3.14 and newer, Py_TYPE() is now implemented as an opaque function call to hide implementation details.
* gh-119182: Add PyUnicodeWriter C API (#119184)Victor Stinner2024-06-171-0/+15
|
* gh-112346: Document the OS byte in `gzip.compress` output change in 3.11 ↵Gregory P. Smith2024-06-171-0/+15
| | | | | (#120480) gh-112346: Describe the "os" byte in gzip output change.
* GH-73991: Add `pathlib.Path.copy()` (#119058)Barney Gale2024-06-141-0/+7
| | | | | | | | | | | | | | | Add a `Path.copy()` method that copies the content of one file to another. This method is similar to `shutil.copyfile()` but differs in the following ways: - Uses `fcntl.FICLONE` where available (see GH-81338) - Uses `os.copy_file_range` where available (see GH-81340) - Uses `_winapi.CopyFile2` where available, even though this copies more metadata than the other implementations. This makes `WindowsPath.copy()` more similar to `shutil.copy2()`. The method is presently _less_ specified than the `shutil` functions to allow OS-specific optimizations that might copy more or less metadata. Incorporates code from GH-81338 and GH-93152. Co-authored-by: Eryk Sun <eryksun@gmail.com>
* gh-120345: Fix incorrect use of the :class: role with the "()" suffix ↵Serhiy Storchaka2024-06-122-3/+3
| | | | | | | (GH-120347) * Remove "()" when refer to a class as a type. * Use :func: when refer to a callable. * Fix reference to the datetime.astimezone() method.
* gh-120029: make `symtable.Symbol.__repr__` correctly reflect the compiler's ↵Bénédikt Tran2024-06-121-0/+11
| | | | | | | | | | flags, add methods (#120099) Expose :class:`symtable.Symbol` methods :meth:`~symtable.Symbol.is_free_class`, :meth:`~symtable.Symbol.is_comp_iter` and :meth:`~symtable.Symbol.is_comp_cell`. --------- Co-authored-by: Carl Meyer <carl@oddbird.net>
* gh-120057: Add os.environ.refresh() method (#120059)Victor Stinner2024-06-101-0/+7
|
* gh-119577: Adjust DeprecationWarning when testing element truth values in ↵Jacob Walls2024-06-072-7/+10
| | | | | ElementTree (GH-119762) Adjust DeprecationWarning when testing element truth values in ElementTree, we're planning to go with the more natural True return rather than a disruptive harder to code around exception raise, and are deferring the behavior change for a few more releases.
* gh-114616: Improve docs regarding changes to caches representation in dis ↵Irit Katriel2024-06-041-0/+7
| | | | (#120033)
* Fix incorrect pull GitHub link in What's New (#120045)Trey Hunner2024-06-041-1/+1
| | | Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
* gh-116560: Add PyLong_GetSign() public function (#116561)Sergey B Kirpichev2024-06-031-0/+3
| | | Co-authored-by: Victor Stinner <vstinner@python.org>
* gh-118827: Remove `Quoter` from `urllib.parse` (#118828)Nikita Sobolev2024-06-031-0/+7
| | | | Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com> Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
* gh-109975: What's New in Python 3.13: fix broken link for `telnetlib` ↵Solomon Himelbloom2024-06-031-1/+1
| | | | alternative (#119958)
* gh-119740: Remove deprecated trunc delegation (#119743)Mark Dickinson2024-06-021-0/+5
| | | | | | | | Remove the delegation of `int` to the `__trunc__` special method: `int` will now only delegate to `__int__` and `__index__` (in that order). `__trunc__` continues to exist, but its sole purpose is to support `math.trunc`. --------- Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com> Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* gh-119775: Remove ability to create immutable types with mutable bases (#119776)Nikita Sobolev2024-06-021-0/+2
|
* gh-118934: Fix PyEval_GetLocals docs (PEP 667) (#119932)Alyssa Coghlan2024-06-021-8/+28
| | | | | | | | | | | | | PEP 667's description of the planned changes to PyEval_GetLocals was internally inconsistent when accepted, so the docs added for gh-74929 didn't match either the current behaviour or the intended behaviour once gh-118934 is fixed. This PR updates the documentation and 3.13 What's New to match the intended behaviour (once gh-118934 is fixed). It also tidies up lingering references to `f_locals` always being a dictionary (this hasn't been true since at least when custom namespace support for class statement execution was added)
* gh-118888: Further PEP 667 docs updates (gh-119893)Alyssa Coghlan2024-06-011-1/+25
| | | | | | * Clarify impact on default behaviour of exec, eval, etc * Update documentation for changes to PyEval_GetLocals (gh-74929) Closes gh-11888
* gh-74929: PEP 667 C API documentation (gh-119379)Alyssa Coghlan2024-06-011-1/+15
| | | | | | | | * Add docs for new APIs * Add soft-deprecation notices * Add What's New porting entries * Update comments referencing `PyFrame_LocalsToFast()` to mention the proxy instead * Other related cleanups found when looking for refs to the deprecated APIs
* gh-111201: Support pyrepl on Windows (#119559)Dino Viehland2024-05-311-5/+8
| | | | Co-authored-by: Anthony Shaw <anthony.p.shaw@gmail.com> Co-authored-by: Łukasz Langa <lukasz@langa.pl>
* gh-109218: Deprecate weird cases in the complex() constructor (GH-119620)Serhiy Storchaka2024-05-301-0/+4
| | | | | | | * Passing a string as the "real" keyword argument is now an error; it should only be passed as a single positional argument. * Passing a complex number as the "real" or "imag" argument is now deprecated; it should only be passed as a single positional argument.
* Docs: `shutil.rmtree`'s `onerror` has no pending removal version (#118947)Hugo van Kemenade2024-05-301-3/+3
|
* gh-119729: Use 't' in pkg-config file name for free-threaded build (#119738)Sam Gross2024-05-301-0/+4
| | | | | For example, the free-threaded build now generates `lib/pkgconfig/python-3.13t.pc` and the debug build generates `lib/pkgconfig/python-3.13d.pc`.
* gh-93963: Remove deprecated names from importlib.abc (#119720)Hugo van Kemenade2024-05-291-10/+24
| | | | Co-authored-by: Jason R. Coombs <jaraco@jaraco.com>
* gh-119613: Soft deprecate Py_IS_NAN/INFINITY/FINITE (#119701)Sergey B Kirpichev2024-05-291-0/+6
| | | | | Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com> Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com> Co-authored-by: Victor Stinner <vstinner@python.org>
* gh-97588: Align ctypes struct layout to GCC/MSVC (GH-97702)Matthias Görgens2024-05-291-0/+12
| | | | | | | Structure layout, and especially bitfields, sometimes resulted in clearly wrong behaviour like overlapping fields. This fixes Co-authored-by: Gregory P. Smith <gps@python.org> Co-authored-by: Petr Viktorin <encukou@gmail.com>
* gh-118824: Remove deprecated `master_open` and `slave_open` from `pty` (#118826)Nikita Sobolev2024-05-281-0/+8
| | | Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
* gh-119562: Remove AST nodes deprecated since Python 3.8 (#119563)Alex Waygood2024-05-261-0/+30
|
* docs: fix a few typos identified by codespell (#119516)Ned Batchelder2024-05-266-7/+7
|
* Fix version number in use_load_tests deprecation reference (GH-119151)Jacob Walls2024-05-221-1/+1
| | | Deprecation took place in d78742a260ba09e53c844de7b1fd11a11c674945 (3.5)
* gh-60191: Implement ast.compare (#19211)Batuhan Taskaya2024-05-221-0/+7
| | | | | | | | | | * bpo-15987: Implement ast.compare Add a compare() function that compares two ASTs for structural equality. There are two set of attributes on AST node objects, fields and attributes. The fields are always compared, since they represent the actual structure of the code. The attributes can be optionally be included in the comparison. Attributes capture things like line numbers of column offsets, so comparing them involves test whether the layout of the program text is the same. Since whitespace seems inessential for comparing ASTs, the default is to compare fields but not attributes. ASTs are just Python objects that can be modified in arbitrary ways. The API for ASTs is under-specified in the presence of user modifications to objects. The comparison respects modifications to fields and attributes, and to _fields and _attributes attributes. A user could create obviously malformed objects, and the code will probably fail with an AttributeError when that happens. (For example, adding "spam" to _fields but not adding a "spam" attribute to the object.) Co-authored-by: Jeremy Hylton <jeremy@alum.mit.edu>
* Docs: Add central references to free-threading-related options (#119017)Brett Simmers2024-05-211-1/+2
|
* gh-74929: PEP 667 general docs update (gh-119201)Alyssa Coghlan2024-05-211-4/+51
| | | | | | | | * expand on What's New entry for PEP 667 (including porting notes) * define 'optimized scope' as a glossary term * cover comprehensions and generator expressions in locals() docs * review all mentions of "locals" in documentation (updating if needed) * review all mentions of "f_locals" in documentation (updating if needed)
* gh-118760: Restore the default value of tkinter.wantobjects to 1 (GH-118784)Serhiy Storchaka2024-05-201-10/+0
| | | | It was set to 2 in 65f5e586a1239ed1a66d8284773d7b02ce40e480 (GH-98592).