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

gh-134674: fix: ast.MatchStar.name incorrectly having class-level default value#134676

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

Closed
hunterhogan wants to merge2,314 commits intopython:mainfromhunterhogan:ast_MatchStar_name

Conversation

hunterhogan
Copy link
Contributor

@hunterhoganhunterhogan commentedMay 25, 2025
edited by github-actionsbot
Loading

Fixesgh-134674

Problem

ast.MatchStar.name incorrectly appears to have a class-level default value when usingast.dump(). The issue causesast.MatchStar(name=None) to display asMatchStar() instead of the expectedMatchStar(name=None).

Solution

Change the ASDL definition ofMatchStar, and addMatchStar to the special cases list inast.dump() alongsideConstant andMatchSingleton.


📚 Documentation preview 📚:https://cpython-previews--134676.org.readthedocs.build/

miss-islingtonand others added30 commitsApril 12, 2025 10:42
(cherry picked from commitad3bbe8)Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
…unctions (GH-113575) (#132437)gh-58211: Add tests for  the `__self__` attribute of builtins functions (GH-113575)---------(cherry picked from commit891465f)Co-authored-by: Adorilson Bezerra <adorilson@gmail.com>Co-authored-by: Victor Stinner <vstinner@python.org>Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>Co-authored-by: Sergey B Kirpichev <skirpichev@gmail.com>Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
…32441)Docs: Fix specifications of `gcvisitobjects_t` (GH-132433)`gcvisitobjects_t` callbacks should return 1 for the iteration to continue instead of 0.(cherry picked from commit1e5798e)Co-authored-by: da-woods <dw-git@d-woods.co.uk>
…base (GH-132231) (GH-132443)Use only a limited number of randomly selected entries.(cherry picked from commit842ab81)Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
…onFly BSD (GH-132431) (GH-132458)Also fix a compiler warning on FreeBSD.(cherry picked from commitf2f86d3)
Fix a typo in c-api/typeobj.rst (GH-132317)(cherry picked from commitf69b344)Co-authored-by: Yongzi Li <1538321957@qq.com>
…-132374) (#132465)gh-132354: document return value for `asyncio.Task.cancel` (GH-132374)(cherry picked from commit64b066a)Co-authored-by: Felix Scherz <felixwscherz@gmail.com>
gh-132111: Document dataclasses.InitVar (GH-132446)(cherry picked from commit281fc33)Co-authored-by: Tapeline <mail@tapeline.dev>
…32422) (#132485)Co-authored-by: Yuki Kobayashi <drsuaimqjgar@gmail.com>
…d FreeBSD (GH-132476) (GH-132498)On platforms where the file descriptor limit is larger than FD_SETSIZEthat test was always skipped (FreeBSD) or always failing (NetBSD).(cherry picked from commitf7b24ff)Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
…) (#132487)gh-86513: improve docs of loop.call_exception_handler (GH-132466)(cherry picked from commitce75351)Co-authored-by: Kumar Aditya <kumaraditya@python.org>
…lotted_base` (GH-132516) (#132518)gh-132515: de-duplicate `test_dataclass_derived_generic_from_slotted_base` (GH-132516)(cherry picked from commit45c447b)Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
…H-132497)Now all protocols always accept the Bluetooth address as string andgetsockname() always returns the Bluetooth address as string.* BTPROTO_SCO now accepts not only bytes, but str.* BTPROTO_SCO now checks address for embedded null.* On *BSD, BTPROTO_HCI now accepts str instead of bytes.* On FreeBSD, getsockname() for BTPROTO_HCI now returns str instead of bytes.* On NetBSD and DragonFly BSD, BTPROTO_HCI now checks address for embedded null.(cherry picked from commit1fc1df8)
…132521)gh-46236: Add missing PyUnicode_FromOrdinal() doc (#132040)(cherry picked from commit8768df2)Co-authored-by: RUANG (James Roy) <longjinyii@outlook.com>
…set_wakeup_fd (GH-131859) (#132522)gh-131803: Clarify that you must register signal handlers for set_wakeup_fd (GH-131859)(cherry picked from commit939476b)Co-authored-by: Jeremy Fleischman <jeremyfleischman@gmail.com>
…as `bases` (GH-132212) (#132548)gh-132176: Fix crash on `type()` when `tuple` subclass passed as `bases` (GH-132212)(cherry picked from commitb6c552f)Co-authored-by: sobolevn <mail@sobolevn.me>Co-authored-by: Victor Stinner <vstinner@python.org>
…ZoneInfo` (GH-114731) (#132563)gh-114713: Handle case of an empty string passed to `zoneinfo.ZoneInfo` (GH-114731)(cherry picked from commit884df11)Co-authored-by: Bogdan Romanyuk <65823030+wrongnull@users.noreply.github.com>Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>Co-authored-by: Kirill Podoprigora <kirill.bast9@mail.ru>
…GH-132567) (#132573)Docs: Synchronise ``indexsidebar.html`` with docsbuild-scripts (GH-132567)(cherry picked from commit4f10b93)Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
…H-132580)They were emitted if internet connection was not available.(cherry picked from commit82f74eb)Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
… no_proxy) (GH-132584) (GH-132585)(cherry picked from commit8b7cb94)Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
…lue` and `interpolation` set (GH-130949) (#132588)gh-130941: Fix `configparser` parsing values with `allow_no_value` and `interpolation` set (GH-130949)(cherry picked from commitc35c735)Co-authored-by: sobolevn <mail@sobolevn.me>
) (#132598)gh-130052: Fix search_map_for_section() error handling (GH-132594)* Don't call close() if the file descriptor is negative.* If close() fails, chain the existing exception.(cherry picked from commit014c7f9)Co-authored-by: Victor Stinner <vstinner@python.org>
) (#132603)Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

ast.MatchStar.name incorrectly has class-level default value
28 participants
@hunterhogan@ZeroIntensity@miss-islington@kumaraditya303@serhiy-storchaka@tomasr8@vsajip@vstinner@bswck@ambv@gpshead@sobolevn@picnixz@hugovk@nascheme@corona10@markshannon@StanFromIreland@brandtbucher@zooba@TERESH1@colesbury@methane@mkaraev@graingert@gvanrossum@noamcohen97@kattni

[8]ページ先頭

©2009-2025 Movatter.jp