Victor Stinner
da5727a120
gh-92651: Remove the Include/token.h header file ( #92652 )
...
Remove the token.h header file. There was never any public tokenizer
C API. The token.h header file was only designed to be used by Python
internals.
Move Include/token.h to Include/internal/pycore_token.h. Including
this header file now requires that the Py_BUILD_CORE macro is
defined. It no longer checks for the Py_LIMITED_API macro.
Rename functions:
* PyToken_OneChar() => _PyToken_OneChar()
* PyToken_TwoChars() => _PyToken_TwoChars()
* PyToken_ThreeChars() => _PyToken_ThreeChars()
2022-05-11 23:22:50 +02:00
狂男风
b69297ea23
bpo-42627: Fix incorrect parsing of Windows registry proxy settings (GH-26307)
2022-05-11 19:17:17 +01:00
Victor Stinner
ffcc7cd57f
gh-89653: PEP 670: Convert pycore_gc.h macros to functions ( #92649 )
...
Convert the following macros to static inline functions:
* _Py_AS_GC()
* _PyGCHead_FINALIZED(), _PyGCHead_SET_FINALIZED()
* _PyGCHead_NEXT(), _PyGCHead_SET_NEXT()
* _PyGCHead_PREV(), _PyGCHead_SET_PREV()
* _PyGC_FINALIZED(), _PyGC_SET_FINALIZED()
* _PyObject_GC_IS_TRACKED()
* _PyObject_GC_MAY_BE_TRACKED()
Add a macro wrapping the _PyObject_GC_IS_TRACKED() function to cast
the argument to PyObject*.
2022-05-11 13:37:18 +02:00
Serhiy Storchaka
707839b0fe
gh-91810: ElementTree: Use text file's encoding by default in XML declaration (GH-91903)
...
ElementTree method write() and function tostring() now use the text file's
encoding ("UTF-8" if not available) instead of locale encoding in XML
declaration when encoding="unicode" is specified.
2022-05-11 09:31:07 +03:00
Hugo van Kemenade
75e463430e
gh-89336: Fix configparser.RawConfigParser.readfp typo (GH-92636)
2022-05-11 09:18:45 +03:00
Mikhail Terekhov
38486ca212
Fix typo in unittest.rst: addCleanupModule -> addModuleCleanup (GH-92631)
2022-05-11 09:14:12 +03:00
zikcheng
dc091204f9
gh-92632: Make function starunpack_helper run faster when encounters starred argument. (GH-92655)
2022-05-11 15:09:40 +09:00
Serhiy Storchaka
87f849c775
gh-92550: Fix pathlib.Path.rglob() for empty pattern (GH-92604)
2022-05-11 07:43:04 +03:00
Serhiy Storchaka
b1c4368824
Revert "gh-92550 - Fix regression in `pathlib.Path.rglob()` (GH-92583)" (GH-92598)
...
This reverts commit dcdf250d2d
.
2022-05-11 07:14:25 +03:00
Victor Stinner
dfdebda052
gh-92584: test_decimal uses shutil.which() ( #92640 )
...
test_decimal now uses shutil.which() rather than deprecated
distutils.spawn.find_executable().
2022-05-11 01:42:09 +02:00
Victor Stinner
303e5d57bc
What's New 3.12: PyFrame_BlockSetup() was removed in 3.11 ( #92645 )
...
What's New in Python 3.11: "PyFrame_BlockSetup() and
PyFrame_BlockPop() have been removed. (Contributed by Mark Shannon
in bpo-40222.)"
https://docs.python.org/dev/whatsnew/3.11.html#id8
2022-05-11 01:28:17 +02:00
Raymond Hettinger
63794dbc93
gh-91966 Document where key functions are applied in the bisect module ( #92602 )
2022-05-10 17:18:58 -05:00
Bar Harel
30a43586f0
bpo-39264: Fix UserDict.get() to account for __missing__() (GH-17910)
...
Here's the patch according to the discussion at the [Python-Dev mailing list](https://mail.python.org/archives/list/python-dev@python.org/thread/SDXOEMAEM6KQ3CQCJVBVRT5QNSPAVU6X/ ).
UserDict.get() will match dict's behavior and not call `__missing__`.
Automerge-Triggered-By: GH:rhettinger
2022-05-10 14:23:45 -07:00
Carl Bordum Hansen
f481a02e6c
bpo-39278: add docstrings to functions in pdb module ( #17924 )
2022-05-10 15:59:58 -05:00
Jürgen Gmach
fe1c5ba608
bpo-43689: improve documentation for Differ (GH-25132)
...
Lines beginning with ``?`` try to help understanding the given diff.
The output can be hard to understand when it contains whitespace characters, such as spaces, tabs or line breaks.
While previously only tabs were mentioned, now all are listed.
Automerge-Triggered-By: GH:rhettinger
2022-05-10 13:57:12 -07:00
Gregory P. Smith
07b34926d3
gh-84131: Remove the deprecated pathlib.Path.link_to method. ( #92505 )
...
Co-authored-by: Barney Gale <barney.gale@gmail.com>
2022-05-10 12:31:41 -07:00
Géry Ogam
dde8a1668e
Update numbers.rst ( #31995 )
2022-05-10 13:01:49 -05:00
andrei kulakov
392fd272cd
bpo-42259: clarify pprint saferepr docs ( #30256 )
2022-05-10 12:22:36 -05:00
slateny
549567c6e7
gh-80143: Add clarification for escape characters ( #92292 )
2022-05-10 11:12:29 -05:00
Pablo Galindo Salgado
4e6da502f4
gh-91731: Fix typo in pymacro.h ( #92618 )
...
* Fix typo in pymacro.h
* Update Include/pymacro.h
Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Victor Stinner <vstinner@python.org>
2022-05-10 13:47:22 +01:00
Irit Katriel
7c6b7ade8d
gh-92619: Fix bug where the compiler duplicates exit blocks unnecessarily (GH-92620)
2022-05-10 13:36:08 +01:00
Alex Waygood
eef47d5bc7
Add `__slots__` to `typing._NotIterable` (GH-92570)
2022-05-10 12:17:54 +03:00
Erlend Egeberg Aasland
4bd07d1dbd
gh-92256: Improve Argument Clinic parser error messages ( #92268 )
...
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
2022-05-10 09:23:42 +02:00
CAM Gerlach
f1bbcba74f
gh-76773: Update docs mentioning no-longer-supported Windows versions & features (GH-92529)
2022-05-10 09:30:32 +03:00
Alex Waygood
7c638e6405
gh-92417: `zlib` docs, `binascii` docs: remove Python 2 compatibility notes (GH-92543)
2022-05-10 08:48:18 +03:00
Alex Waygood
6823ba4a9e
gh-92417: `unittest.mock` docs: remove references to Python <2.6 (GH-92539)
2022-05-10 08:47:36 +03:00
Paul Ganssle
a0a825c38a
gh-91928: Add what's new entry for datetime.UTC alias (GH-92567)
...
I merged this without a What's New entry to avoid merge conflicts, so here's the follow-up adding the entry.
@Kab1r do you mind reviewing?
Closes #91928
Automerge-Triggered-By: GH:pganssle
2022-05-09 20:51:28 -07:00
Cheryl Sabella
c56e2bb994
bpo-13553: Document tkinter.Tk args ( #4786 )
2022-05-09 20:49:00 -07:00
Ethan Furman
5be069568d
[Enum] Remove redundant check for existing members. (GH-92590)
2022-05-09 19:40:42 -07:00
Barney Gale
dcdf250d2d
gh-92550 - Fix regression in `pathlib.Path.rglob()` (GH-92583)
...
We could try to remedy this by taking a slice, but we then run into an issue where the empty string will match altsep on POSIX. That rabbit hole could keep getting deeper.
A proper fix for the original issue involves making pathlib's path normalisation more configurable - in this case we want to retain trailing slashes, but in other we might want to preserve `./` prefixes, or elide `../` segments when we're sure we won't encounter symlinks.
This reverts commit ea2f5bcda1
.
2022-05-09 17:12:16 -07:00
Victor Stinner
cb35402c18
gh-88750: On Windows, PyThread_acquire_lock() no longer checks for NULL ( #92586 )
...
On Windows, PyThread_acquire_lock(), PyThread_acquire_lock_timed()
and PyThread_release_lock() no longer check at runtime if the lock is
not NULL.
2022-05-10 02:00:38 +02:00
Gregory P. Smith
6ed7c353b8
gh-88750: Remove the PYTHONTHREADDEBUG env var support. ( #92509 )
...
Remove the `PYTHONTHREADDEBUG` env var support.
Remove no-op dprintf() macro calls.
2022-05-09 16:03:46 -07:00
Mariusz Felisiak
22bddc864d
bpo-46907: Update Windows installer to SQLite 3.38.4. ( #92322 )
2022-05-09 23:37:01 +02:00
Julien Palard
b77a95f44a
Doc: Update py2app link. ( #91585 )
...
See: https://mail.python.org/archives/list/docs@python.org/thread/KDVFGNGGUGGPVRZT7WZYHHWXCRS2GEN7/
2022-05-09 23:10:19 +02:00
Erlend Egeberg Aasland
6ecf594baa
gh-92171: Update Tcl/Tk download links in macOS installer script (GH-92179)
2022-05-09 14:32:21 -04:00
Pablo Galindo Salgado
f0614ca980
gh-91731: Add macro compatibility for static_assert for old libcs (GH-92559)
2022-05-09 18:38:38 +01:00
slateny
e3fa60b937
gh-86019: Add table for Windows installer options (GH-91809)
2022-05-09 17:40:51 +01:00
Ken Jin
be3cdd66c9
gh-91345: Talk about ``sys._getframe`` compatibility in 3.11 whatsnew (GH-92552)
2022-05-09 14:45:13 +01:00
Victor Stinner
11a608d2b1
What's New in Python 3.12: move C API at the end ( #92555 )
...
* Separate Build and C API changes in two sections
* Add sub-sections to the C API changes
2022-05-09 14:26:30 +02:00
Victor Stinner
d8104d13cd
What's New in Python 3.11: move C API changes ( #92390 )
...
Move C API changes to the C API > Porting to Python 3.11 section.
2022-05-09 12:40:56 +02:00
Victor Stinner
7b9803f93f
Enhance PyConfig documentation ( #92394 )
2022-05-09 12:35:59 +02:00
Erlend Egeberg Aasland
269e726723
gh-90005: Cleanup after GH-31698 ( #91642 )
2022-05-09 11:00:20 +02:00
Erlend Egeberg Aasland
3edda031e4
CODEOWNERS: Add Erlend Aasland as sqlite3 code owner ( #92535 )
...
Signed-off-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
2022-05-09 10:06:03 +02:00
Raymond Hettinger
e01eeb7b4b
Fix inconsistent return type for statistics median_grouped() gh-92531 ( #92533 )
2022-05-09 02:08:41 -05:00
Ma Lin
5bc2390229
bpo-38056: overhaul Error Handlers section in codecs documentation ( #15732 )
...
* Some handlers were wrongly described as text-encoding only, but actually they can also be used in text-decoding.
* Add more description to each handler.
* Add two REPL examples.
* Add indexes for Error Handler's name.
Co-authored-by: Kyle Stanley <aeros167@gmail.com>
Co-authored-by: Victor Stinner <vstinner@python.org>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-05-08 19:58:55 -07:00
Rafael Fontenelle
f298ba1f27
bpo-39229: fix formatting in library/functions.rst ( #17857 )
...
Missing reference of auditing event presents error when building translated documentation
2022-05-08 16:21:19 -07:00
Godefroid Chapelle
2888b1107f
pdb docs: workaround for double semicolon in strings ( #17011 )
...
see https://github.com/gotcha/ipdb/issues/172
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-05-08 16:20:42 -07:00
David CARLIER
9d85aba9e2
gh-91968: Add socket constants SO_USER_COOKIE/SO_RTABLE from BSD ( #91967 )
...
Those are somewhat equivalent to Linux' SO_MARK.
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-05-08 16:19:41 -07:00
slateny
859250cc55
gh-77521: Add link to builtin module names in modules tutorial ( #92438 )
...
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
2022-05-08 12:30:38 -07:00
Ken Jin
9304f98558
Use percentage over factor for 3.11 whatsnew performance (GH-92496)
2022-05-09 00:44:55 +08:00