Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
forked frompython/cpython

Merge from cpython#1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
Dev-Mw merged 9,625 commits intoDev-Mw:mainfrompython:main
Jan 21, 2024
Merged

Merge from cpython#1

Dev-Mw merged 9,625 commits intoDev-Mw:mainfrompython:main
Jan 21, 2024

Conversation

@Dev-Mw
Copy link
Owner

No description provided.

corona10and others added30 commitsJanuary 3, 2024 13:25
…h-113621)---------Co-authored-by: Sam Gross <colesbury@gmail.com>
This ensures the source directory is not modified at build time, and different builds (e.g. different versions or GIL vs no-GIL) do not have conflicts.
Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
In `cmd.Cmd.do_help` call `inspect.cleandoc()`,to clean indentation and remove leading/trailing emptylines from a dosctring before printing.
Use `os.DirEntry.path` as the string representation of child paths, unlessthe parent path is empty, in which case we use the entry `name`.
*gh-112532: Isolate abandoned segments by interpreterMimalloc segments are data structures that contain memory allocations alongwith metadata. Each segment is "owned" by a thread. When a thread exits,it abandons its segments to a global pool to be later reclaimed by otherthreads. This changes the pool to be per-interpreter instead of process-wide.This will be important for when we use mimalloc to find GC objects in the`--disable-gil` builds. We want heaps to only store Python objects from asingle interpreter. Absent this change, the abandoning and reclaiming processcould break this isolation.* Add missing '&_mi_abandoned_default' to 'tld_empty'
…tructing protocol classes (#113401)- Only attempt to figure out whether protocol members are "method members" or not if the class is marked as a runtime protocol. This information is irrelevant for non-runtime protocols; we can safely skip the risky introspection for them.- Only do the risky getattr() calls in one place (the runtime_checkable class decorator), rather than in three places (_ProtocolMeta.__init__, _ProtocolMeta.__instancecheck__ and _ProtocolMeta.__subclasscheck__). This reduces the number of locations in typing.py where the risky introspection could go wrong.- For runtime protocols, if determining whether a protocol member is callable or not fails, give a better error message. I think it's reasonable for us to reject runtime protocols that have members which raise strange exceptions when you try to access them.PEP-544 clearly states that all protocol member must be callable for issubclass() calls against the protocol to be valid -- and if a member raises when we try to access it, there's no way for us to figure out whether it's a callable member or not!
…3725)Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>Co-authored-by: Hugo van Kemenade <hugovk@users.noreply.github.com>
Co-authored-by: Xavier de Gaye <xdegaye@gmail.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
*gh-112532: Tag mimalloc heaps and pagesMimalloc pages are data structures that contain contiguous allocationsof the same block size. Note that they are distinct from operatingsystem pages. Mimalloc pages are contained in segments.When a thread exits, it abandons any segments and contained pages thathave live allocations. These segments and pages may be later reclaimedby another thread. To support GC and certain thread-safety guarantees infree-threaded builds, we want pages to only be reclaimed by thecorresponding heap in the claimant thread. For example, we want pagescontaining GC objects to only be claimed by GC heaps.This allows heaps and pages to be tagged with an integer tag that isused to ensure that abandoned pages are only claimed by heaps with thesame tag. Heaps can be initialized with a tag (0-15); any page allocatedby that heap copies the corresponding tag.* Fix conversion warning
This splits part of Modules/gcmodule.c of into Python/gc.c, whichnow contains the core garbage collection implementation. The Pythonmodule remain in the Modules/gcmodule.c file.
Raise auditing events in `pathlib.Path.glob()`, `rglob()` and `walk()`,but not in `pathlib._abc.PathBase` methods. Also move generation of adeprecation warning into `pathlib.Path` so it gets the right stack level.
)Explicitly open and close files instead of using FileType.
gh-113750: Fix object resurrection on free-threaded buildsThis avoids the undesired re-initializing of fields like `ob_gc_bits`,`ob_mutex`, and `ob_tid` when an object is resurrected due to itsfinalizer being called.This change has no effect on the default (with GIL) build.
….7 (#113731)Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Add support for loading XML plists from a string value instead of a only bytes value.
The `DummyPurePath` and `DummyPath` test classes are simple subclasses of`PurePathBase` and `PathBase`. This commit adds `__repr__()` methods to thedummy classes, which makes debugging test failures less painful.
Split test cases for invalid names into dedicated test methods. This willmake it easier to refactor tests for invalid name handling in ABCs later.No change of coverage, just a change of test suite organisation.
keithasaurusand others added29 commitsJanuary 18, 2024 09:03
Use different versions in the examples for when extensions do and do not need to be recompiled to make the examples easier to understand.
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>Co-authored-by: Éric <merwok@netwok.org>
… items (#114259)Use a ring buffer instead of a Python list in order to simplify theprocess of making queue.SimpleQueue thread-safe in free-threadedbuilds. The ring buffer implementation has no places where criticalsections may be released.
Disable toc_object_entries, new in Sphinx 5.2.3
Allow `os.PathLike` objects to be passed as patterns to `pathlib.Path.glob()` and `rglob()`. (It's already possible to use them in `PurePath.match()`)While we're in the area:- Allow empty glob patterns in `PathBase` (but not `Path`)- Speed up globbing in `PathBase` by generating paths with trailing slashes only as a final step, rather than for every intermediate directory.- Simplify and speed up handling of rare patterns involving both `**` and `..` segments.
Use `_make_child_entry()` rather than `_make_child_relpath()` to retrievepath objects for directories to visit. This saves the allocation of onepath object per directory in user subclasses of `PathBase`, and avoids asecond loop.This trick does not apply when walking top-down, because users can affectthe walk by modifying *dirnames* in-place.A side effect of this change is that, in bottom-up mode, subdirectories ofeach directory are visited in reverse order, and that this order doesn'tmatch that of the names in *dirnames*. I suspect this is fine as theorder is arbitrary anyway.
TheGH-93000 change set inadvertently caused a sentence in re.compile()documentation to refer to details that no longer followed. Correct thiswith a link to the Flags sub-subsection.Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com>
Introduce the following headings and subheadings:- Reference  * FTP objects  * FTP_TLS objects  * Module variables
…h-114157)*gh-112529: Use GC heaps for GC allocations in free-threaded buildsThe free-threaded build's garbage collector implementation will need tofind GC objects by traversing mimalloc heaps. This hooks up theallocation calls with the correct heaps by using a thread-local"current_obj_heap" variable.* Refactor out setting heap based on type
)Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
I believe I added this while chasing some performance of hash functionswhen I first created hashlib.  It hasn't been used since, is franklytrivial, and not a test.
…114276)Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
…114057)Some socket tests related to sending file descriptors cause a file descriptor leak on macOS, all of them tests that send one or more descriptors than cannot be received on the read end.  This appears to be a platform bug.This PR skips those tests when doing a refleak test run to avoid hiding other problems.
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
@Dev-MwDev-Mw merged commit8870ee5 intoDev-Mw:mainJan 21, 2024
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

19 participants

@Dev-Mw@corona10@iritkatriel@itamaro@AlexWaygood@fipachu@brandtbucher@ordinary-jamie@wookie184@gvanrossum@barneygale@colesbury@markshannon@pablogsal@hugovk@ZackerySpytz@serhiy-storchaka@ronaldoussoren@aisk

[8]ページ先頭

©2009-2025 Movatter.jp