summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* gh-114685: Fix incorrect use of PyBUF_READ in import.c (GH-114686)Nikita Sobolev2024-01-291-1/+1
|
* gh-109653: Improve import time of importlib.metadata / email.utils (#114664)Shantanu2024-01-293-2/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | My criterion for delayed imports is that they're only worth it if the majority of users of the module would benefit from it, otherwise you're just moving latency around unpredictably. mktime_tz is not used anywhere in the standard library and grep.app indicates it's not got much use in the ecosystem either. Distribution.files is not nearly as widely used as other importlib.metadata APIs, so we defer the csv import. Before: ``` λ hyperfine -w 8 './python -c "import importlib.metadata"' Benchmark 1: ./python -c "import importlib.metadata" Time (mean ± σ): 65.1 ms ± 0.5 ms [User: 55.3 ms, System: 9.8 ms] Range (min … max): 64.4 ms … 66.4 ms 44 runs ``` After: ``` λ hyperfine -w 8 './python -c "import importlib.metadata"' Benchmark 1: ./python -c "import importlib.metadata" Time (mean ± σ): 62.0 ms ± 0.3 ms [User: 52.5 ms, System: 9.6 ms] Range (min … max): 61.3 ms … 62.8 ms 46 runs ``` for about a 3ms saving with warm disk cache, maybe 7-11ms with cold disk cache.
* gh-89159: Add some TarFile attribute types (GH-114520)Stanley2024-01-291-0/+6
| | | | Co-authored-by: Stanley <46876382+slateny@users.noreply.github.com>
* GH-113464: A JIT backend for tier 2 (GH-113465)Brandt Bucher2024-01-290-0/+0
| | | | | | | | Add an option (--enable-experimental-jit for configure-based builds or --experimental-jit for PCbuild-based ones) to build an *experimental* just-in-time compiler, based on copy-and-patch (https://fredrikbk.com/publications/copy-and-patch.pdf). See Tools/jit/README.md for more information, including how to install the required build-time tooling. Merry JIT-mas! ;)
* GH-113464: Add a JIT backend for tier 2 (GH-113465)Brandt Bucher2024-01-2929-5/+1738
| | | | | | | Add an option (--enable-experimental-jit for configure-based builds or --experimental-jit for PCbuild-based ones) to build an *experimental* just-in-time compiler, based on copy-and-patch (https://fredrikbk.com/publications/copy-and-patch.pdf). See Tools/jit/README.md for more information on how to install the required build-time tooling.
* gh-55664: Add warning when creating a type using a namespace dictionary with ↵Furkan Onder2024-01-283-1/+28
| | | | | non-string keys. (GH-105338) Co-authored-by: Daniel Urban <durban@users.noreply.github.com>
* gh-100734: Add 'Notable change in 3.11.x' to `whatsnew/3.11.rst` (#114657)Hugo van Kemenade2024-01-281-0/+26
| | | | Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* Fix indentation in `__post_init__` documentation. (gh-114666)Bhushan Mohanraj2024-01-281-2/+2
|
* Correction Skip Montanaro's email address (#114677)Skip Montanaro2024-01-284-5/+5
|
* Use bool in fileinput.input() docstring and tests for the inplace argument ↵Ville Skyttä2024-01-272-3/+3
| | | | | (GH-111998) The `.rst` docs, most tests, and typeshed already use bool for it.
* GH-79634: Speed up pathlib globbing by removing `joinpath()` call. (#114623)Barney Gale2024-01-273-5/+6
| | | | | Remove `self.joinpath('')` call that should have been removed in 6313cdde. This makes `PathBase.glob('')` yield itself *without* adding a trailing slash. It's hard to say whether this is more or less correct, but at least everything else is faster, and there's no behaviour change in the public classes where empty glob patterns are disallowed.
* gh-114100: Remove superfluous writing to fd 1 in test_pty (GH-114647)Serhiy Storchaka2024-01-271-1/+21
|
* gh-101100: Fix sphinx warnings in `reference/import.rst` (#114646)Nikita Sobolev2024-01-272-4/+4
|
* gh-101100: Fix Sphinx warnings in `whatsnew/3.11.rst` and related (#114531)Hugo van Kemenade2024-01-2715-70/+70
|
* gh-113560: Improve docstrings for set.issubset() and set.issuperset() ↵Charlie Zhao2024-01-271-2/+10
| | | | (GH-113562)
* gh-101100: Fix sphinx warnings in `library/email.mime.rst` (GH-114635)Nikita Sobolev2024-01-272-9/+8
|
* Fix `c-api/file.rst` indexes (GH-114608)Nikita Sobolev2024-01-271-2/+3
|
* Simplify concurrent.futures.process code by using itertools.batched() ↵NewUserHa2024-01-271-11/+1
| | | | (GH-114221)
* gh-113445: Amend PyObject_RichCompareBool() docs (GH-113891)Sergey B Kirpichev2024-01-271-6/+2
|
* gh-113055: Use pointer for interp->obmalloc state (gh-113412)Neil Schemenauer2024-01-279-24/+157
| | | | | | | | | For interpreters that share state with the main interpreter, this points to the same static memory structure. For interpreters with their own obmalloc state, it is heap allocated. Add free_obmalloc_arenas() which will free the obmalloc arenas and radix tree structures for interpreters with their own obmalloc state. Co-authored-by: Eric Snow <ericsnowcurrently@gmail.com>
* Cover OS-specific behaviour in `PurePathBase` and `PathBase` tests. (#114633)Barney Gale2024-01-272-627/+625
| | | | Wherever possible, move tests for OS-specific behaviour from `PurePathTest` and `PathTest` to `DummyPurePathTest` and `DummyPathTest`.
* Cover OS-specific behaviour in `PurePath` and `Path` tests (#114632)Barney Gale2024-01-271-70/+128
| | | Test Posix- and Windows-specific behaviour from `PurePathTest` and `PathTest`.
* pathlib tests: annotate tests needing symlinks with decorator (#114625)Barney Gale2024-01-262-48/+55
| | | | | | | | Add `@needs_symlinks` decorator for tests that require symlink support in the path class. Also add `@needs_windows` and `@needs_posix` decorators for tests that require a specific a specific path flavour. These aren't much used yet, but will be later.
* gh-114490: Add check for Mach-O linkage in Lib/platform.py (#114491)Aiden Fox Ivey2024-01-262-0/+3
| | | | | ``platform.architecture()`` now returns the format of binaries (e.g. Mach-O) instead of the default empty string. Co-authored-by: AN Long <aisk@users.noreply.github.com>
* gh-114494: Change logging docstring to bool for exec_info (GH=114558)Tristan Pank2024-01-261-6/+6
|
* Add More Entries to CODEOWNERS (#114617)Eric Snow2024-01-261-1/+40
|
* gh-88569: add `ntpath.isreserved()` (#95486)Barney Gale2024-01-268-72/+154
| | | | | | | | | | | Add `ntpath.isreserved()`, which identifies reserved pathnames such as "NUL", "AUX" and "CON". Deprecate `pathlib.PurePath.is_reserved()`. --------- Co-authored-by: Eryk Sun <eryksun@gmail.com> Co-authored-by: Brett Cannon <brett@python.org> Co-authored-by: Steve Dower <steve.dower@microsoft.com>
* Docs: rework the dbm.dumb introduction (#114550)Erlend E. Aasland2024-01-261-30/+36
| | | | | | | - consistently use correct parameter markup - consistently use submodule name as database name - improve accuracy of the dbm.dumb.open() spec - remove dumbdbm class refs and replace them with generic "database object" - use parameter list for dbm.dumb.open()
* Document PyOS_strtoul and PyOS_strtol (GH-114048)Sergey B Kirpichev2024-01-261-0/+36
|
* gh-114435: Allow test_stat_inaccessible_file() to have matching ino/dev ↵Steve Dower2024-01-261-4/+3
| | | | | (GH-114571) This may occur if Windows allows reading stat information from a file even if the current user does not have access.
* Use Unicode unconditionally for _winapi.CreateFile (GH-114611)Steve Dower2024-01-262-13/+17
| | | Currently it switches based on build settings, but argument clinic does not handle it correctly.
* gh-112087: Make list_repr and list_length to be thread-safe (gh-114582)Donghee Na2024-01-262-10/+21
|
* gh-111968: Unify freelist naming schema to Eric's suggestion (gh-114581)Donghee Na2024-01-268-25/+25
|
* gh-77749: Fix inconsistent behavior of non-ASCII handling in ↵Rito Takeuchi2024-01-263-1/+27
| | | | | | | EmailPolicy.fold() (GH-6986) It now always encodes non-ASCII characters in headers if utf8 is false. Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
* Docs: mark up dbm.open() with param list (#114601)Erlend E. Aasland2024-01-261-26/+26
| | | Also consolidate following paragraphs regarding database objects.
* gh-114272: Allow _wmi audit test to succeed even if it times out (GH-114602)Steve Dower2024-01-261-1/+7
|
* Docs: 'still' is a better word than 'nonetheless' (#114598)Ned Batchelder2024-01-263-3/+3
|
* Docs: fix versionchanged directives for dbm.open() and dbm.whichdb() (#114594)Erlend E. Aasland2024-01-261-5/+5
|
* Docs: reword dbm.ndbm introduction (#114549)Erlend E. Aasland2024-01-261-21/+26
| | | | | | | - add abbreviation directives for NDBM and GDBM - consistently spell NDBM as NDBM - silence broken ndbm class refs - improve accuracy of dbm.ndbm.open() spec - use replacement text for NDBM/GDBM file format incompatibility note
* Docs: rework dbm introduction (#114551)Erlend E. Aasland2024-01-261-10/+11
| | | | | - add refs to other parts of the docs (dict, bytes, etc.) - clarify whichdb() return value by using list markup - silence refs to example or generic submodule methods (keys, get, etc.)
* gh-114569: Use PyMem_* APIs for most non-PyObject uses (#114574)Erlend E. Aasland2024-01-267-33/+36
| | | Fix usage in Modules, Objects, and Parser subdirectories.
* gh-114312: Fix rare event counter tests on aarch64 (GH-114554)Michael Droettboom2024-01-261-5/+5
|
* Docs: reword dbm.gnu introduction (#114548)Erlend E. Aasland2024-01-261-20/+21
| | | | | | Also... - consistently spell GDBM as GDBM - silence gdbm class refs - improve accuracy of dbm.gdbm.open() spec
* gh-101100: Fix sphinx warnings in `c-api/file.rst` (#114546)Nikita Sobolev2024-01-263-4/+15
| | | | Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
* gh-114250: Fetch metadata for pip and its vendored dependencies from PyPI ↵Seth Michael Larson2024-01-262-50/+837
| | | | (#114450)
* gh-112451: Prohibit subclassing of datetime.timezone. (#114190)Mariusz Felisiak2024-01-263-0/+9
| | | This is consistent with C-extension datetime.timezone.
* GH-73435: Add `pathlib.PurePath.full_match()` (#114350)Barney Gale2024-01-266-72/+155
| | | | | | | | | | | | | | | | In 49f90ba we added support for the recursive wildcard `**` in `pathlib.PurePath.match()`. This should allow arbitrary prefix and suffix matching, like `p.match('foo/**')` or `p.match('**/foo')`, but there's a problem: for relative patterns only, `match()` implicitly inserts a `**` token on the left hand side, causing all patterns to match from the right. As a result, it's impossible to match relative patterns from the left: `PurePath('foo/bar').match('bar/**')` is true! This commit reverts the changes to `match()`, and instead adds a new `full_match()` method that: - Allows empty patterns - Supports the recursive wildcard `**` - Matches the *entire* path when given a relative pattern
* Add CODEOWNERS for dbm (gh-114555)Donghee Na2024-01-251-0/+3
|
* gh-107901: compiler replaces POP_BLOCK instruction by NOPs before ↵Irit Katriel2024-01-251-1/+2
| | | | optimisations (#114530)
* gh-114561: Mark some tests in ``test_wincosoleio`` with ↵Kirill Podoprigora2024-01-251-1/+4
| | | | `requires_resource('console')` decorator (GH-114565)