summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* GH-91173: disable frozen modules in debug builds (#92023)Kumar Aditya2022-05-033-25/+27
|
* gh-91928: Add `datetime.UTC` alias for `datetime.timezone.utc` (GH-91973)Kabir Kwatra2022-05-036-3/+23
| | | | | | | | | ### fixes #91928 `UTC` is now module attribute aliased to `datetime.timezone.utc`. You can now do the following: ```python from datetime import UTC ```
* gh-87304: Improve comments in language reference for imports (#92164)Robert Yang2022-05-031-3/+3
|
* gh-92206: Improve scoping of sqlite3 statement helper (#92260)Erlend Egeberg Aasland2022-05-033-9/+8
|
* Improve the typing docs (#92264)Jelle Zijlstra2022-05-031-34/+33
| | | Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* gh-81057: Fix indent. (gh-92267)Eric Snow2022-05-031-1/+1
|
* bpo-45639: Add webp and avif image formats to mimetypes (#29259)kixorz2022-05-033-0/+6
| | | Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* gh-92062: `inspect.Parameter` checks whether `name` is a keyword (GH-92065)Zac Hatfield-Dodds2022-05-033-3/+12
| | | Fixes #92062.
* gh-91321: Fix PyModuleDef_HEAD_INIT on C++ (#92259)Victor Stinner2022-05-031-5/+5
| | | | The PyModuleDef_HEAD_INIT macro now uses _Py_NULL to fix C++ compiler warnings when using it in C++.
* gh-89289: Fix compiler warning in _sqlite/connection.c (#92258)Erlend Egeberg Aasland2022-05-031-1/+1
|
* gh-92206: Improve scoping of sqlite3 bind param functions (#92250)Erlend Egeberg Aasland2022-05-033-257/+250
|
* gh-91320: Use _PyCFunction_CAST() (#92251)Victor Stinner2022-05-0331-146/+146
| | | | | | | | | | Replace "(PyCFunction)(void(*)(void))func" cast with _PyCFunction_CAST(func). Change generated by the command: sed -i -e \ 's!(PyCFunction)(void(\*)(void)) *\([A-Za-z0-9_]\+\)!_PyCFunction_CAST(\1)!g' \ $(find -name "*.c")
* gh-91321: Add _Py_NULL macro (#92253)Victor Stinner2022-05-036-18/+28
| | | | | | | | Fix C++ compiler warnings: "zero as null pointer constant" (clang -Wzero-as-null-pointer-constant). * Add the _Py_NULL macro used by static inline functions to use nullptr in C++. * Replace NULL with nullptr in _testcppext.cpp.
* gh-81057: Get the c-analyzer tool working again. (gh-92246)Eric Snow2022-05-034-4/+16
|
* gh-90172: add test for functools.singledispatch on Union types with None ↵Thaddeus14992022-05-031-0/+43
| | | | | | | type (#92174) Signed-off-by: prwatson <prwatson@redhat.com> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* gh-91320: Fix more old-style cast warnings in C++ (#92247)Victor Stinner2022-05-033-16/+19
| | | | | | | Use _Py_CAST(), _Py_STATIC_CAST() and _PyASCIIObject_CAST() in static inline functions to fix C++ compiler warnings: "use of old-style cast" (clang -Wold-style-cast). test_cppext now builds the C++ test extension with -Wold-style-cast.
* gh-91320: Argument Clinic uses _PyCFunction_CAST() (#32210)Victor Stinner2022-05-0399-975/+978
| | | | Replace "(PyCFunction)(void(*)(void))func" cast with _PyCFunction_CAST(func).
* gh-89289: Harden sqlite3.Connection init (#92214)Erlend Egeberg Aasland2022-05-031-8/+15
| | | | | - Make sure SQLite resources are freed if database open fails - Remove unneeded branches if init is aborted
* gh-89653: PEP 670: Convert PyBytes macros to functions (#91990)Victor Stinner2022-05-034-14/+47
| | | | | | | | | | | | Convert the following macros to static inline functions: * PyByteArray_AS_STRING() * PyByteArray_GET_SIZE() * PyBytes_AS_STRING() * PyBytes_GET_SIZE() Limited C API version 3.11 no longer casts arguments. Add _PyBytes_CAST() and _PyByteArray_CAST() macros.
* gh-92206: Improve scoping of sqlite3 reset statement helper (#92241)Erlend Egeberg Aasland2022-05-033-30/+28
|
* bpo-46696: Add socket.SO_INCOMING_CPU constant (#31237)David CARLIER2022-05-033-0/+13
| | | Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* bpo-29890: Test IPv*Interface construction with tuple argument (#30862)Humbled Drugman2022-05-032-0/+10
| | | Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* GH-91752: Skip test_freeze_simple_script when zlib is not available (#91758)Abhigyan Bose2022-05-032-1/+2
| | | Fixes GH-91752.
* gh-88753: Make BooleanOptionalAction's addition of default to help more ↵Toshio Kuratomi2022-05-033-16/+32
| | | | | | | | | | | | | | | | similar to other actions (#27808) Help for other actions omit the default value if default is SUPPRESS or already contains the special format string '%(default)'. Add those special cases to BooleanOptionalAction's help formatting too. Fixes https://bugs.python.org/issue44587 so that default=SUPPRESS is not emitted. Fixes https://bugs.python.org/issue38956 as this code will detect whether '%(default)s' has already been specified in the help string. Signed-off-by: Micky Yun Chan (michiboo): <chanmickyyun@gmail.com> Co-authored-by: Micky Yun Chan <michan@redhat.com>
* gh-89452: Prefer gdbm-compat over ndbm (#92208)Łukasz Langa2022-05-035-9/+11
| | | | | This makes macOS gdbm provided by Homebrew not segfault through correct selection of the linked library (-lgdbm_compat) *AND* the correct ndbm-style header (gdbm-ndbm.h instead of the invalid ndbm.h).
* bpo-46604: fix function name in ssl module docstring (#31064)Kossi GLOKPOR2022-05-031-3/+4
| | | | | The function fetch_server_certificate is replaced by get_server_certificate in the module. I reflected the change in the module docstrings. Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* gh-92031: Deoptimize Static Code at Finalization (GH-92039)Dennis Sweeney2022-05-035-10/+225
|
* gh-90887: posix module: Add more flags for fcopy_file (#31300)David CARLIER2022-05-032-0/+4
| | | | | | Closes #90887 Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* GH-91355: micro-optimize Connection.send_bytes() method (gh-32247)Ma Lin2022-05-031-3/+2
|
* Link to GitHub instead of BPO for CPython bug tracker (GH-92221)slateny2022-05-032-9/+3
|
* gh-92135: Rename _Py_reinterpret_cast() to _Py_CAST() (#92230)Victor Stinner2022-05-039-24/+24
| | | Rename also _Py_static_cast() to _Py_STATIC_CAST().
* bpo-44863: Allow generic typing.TypedDict (#27663)Samodya Abey2022-05-036-7/+172
| | | | | | Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com> Co-authored-by: Yurii Karabas <1998uriyyo@gmail.com> Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* gh-92154: Expose PyCode_GetCode in the C API (GH-92168)Ken Jin2022-05-036-0/+53
|
* gh-92206: Improve scoping of sqlite3 register cursor helper (#92212)Erlend Egeberg Aasland2022-05-033-28/+23
|
* Dependabot: only bump actions for major versions (#92186)Hugo van Kemenade2022-05-032-3/+8
|
* gh-70363: Implement `io.IOBase` interface for `SpooledTemporaryFile` (GH-29560)Carey Metcalfe2022-05-035-3/+92
| | | | | | | | | | | | | | | | Since the underlying file-like objects (either `io.BytesIO`, or a true file object) all implement the `io.IOBase` interface, the `SpooledTemporaryFile` should as well. Additionally, since the underlying file object will either be an instance of an `io.BufferedIOBase` (for binary mode) or an `io.TextIOBase` (for text mode), methods for these classes were also implemented. In every case, the required methods and properties are simply delegated to the underlying file object. Co-authored-by: Gary Fernie <Gary.Fernie@skyscanner.net> Co-authored-by: Inada Naoki <songofacandy@gmail.com>
* bpo-46415: Use f-string for ValueError in ↵Thomas Cellerier2022-05-033-9/+24
| | | | | | | | | | | | | | | | | | | | | | ipaddress.ip_{address,network,interface} helper functions (#30642) `IPv*Network` and `IPv*Interface` constructors accept a 2-tuple of (address description, netmask) as the address parameter. When the tuple-based address is used errors are not propagated correctly through the `ipaddress.ip_*` helper because of the %-formatting now expecting several arguments: In [7]: ipaddress.ip_network(("192.168.100.0", "fooo")) ... TypeError: not all arguments converted during string formatting Compared to: In [8]: ipaddress.IPv4Network(("192.168.100.0", "foo")) ... NetmaskValueError: 'foo' is not a valid netmask Use an f-string to make sure the error is always properly formatted. Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* The stdev calculation is more accurate computing its own mean (#92220)Raymond Hettinger2022-05-031-2/+1
|
* gh-92169: Use warnings_helper.import_deprecated() to import deprecated ↵Hugo van Kemenade2022-05-0310-41/+33
| | | | modules uniformly in tests (GH-92170)
* Fix doc warnings in What's New in 3.11 (GH-92215)Ken Jin2022-05-031-1/+1
|
* bpo-46267: Test compresslevel in gzip.compress (#30416)Ruben Vorderman2022-05-031-0/+9
| | | Fixes #90425
* gh-92206: Move pysqlite_step() to Modules/_sqlite/cursor.c (#92207)Erlend Egeberg Aasland2022-05-033-16/+14
|
* bpo-46785: Fix race condition between os.stat() and unlink on Windows (GH-31858)Itai Steinherz2022-05-024-1/+57
|
* gh-91621: Fix typing.get_type_hints for collections.abc.Callable (#91656)Shantanu2022-05-023-3/+35
| | | | | | This mirrors logic in typing.get_args. The trickiness comes from how we flatten args in collections.abc.Callable, see https://bugs.python.org/issue42195
* gh-84461: Add ability for multiprocessed libregrtest to use a different ↵Ethan Smith2022-05-023-2/+12
| | | | Python executable (GH-91930)
* bpo-43923: Add support for generic typing.NamedTuple (#92027)Serhiy Storchaka2022-05-025-4/+66
|
* gh-92106: Add test that subscription works on arbitrary TypedDicts (#92176)Serhiy Storchaka2022-05-021-0/+13
|
* gh-92032: Add soft keywords to rlcompleter (#92029)kbeldan2022-05-023-2/+7
| | | | | | | Let the interpreter autocomplete soft-keywords, ATM the PEP-634 'match' / 'case' / '_' (wildcard pattern). Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* bpo-46586: Fix more erroneous doc links to builtins (#31429)Meer Suri2022-05-023-3/+3
| | | | Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com> Co-authored-by: Éric <merwok@netwok.org>
* Delete outdated comment in logging module (#31117)Thomas Miedema2022-05-021-2/+0
| | | | | | The root logger is now accessible via its name, see https://github.com/python/cpython/pull/15077 Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>