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

Segmentation fault with Python 3.14.1, 3.13.10: insertdict: Assertion `!_PyDict_HasSplitTable(mp)' failed. #142218

Closed
Labels
3.13bugs and security fixes3.14bugs and security fixes3.15new features, bugs and security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)release-blockertype-crashA hard crash of the interpreter, possibly with a core dump
@emontnemery

Description

@emontnemery

Bug report

Bug description:

There's a segmentation fault in Python 3.14.1 and 3.13.10 which doesn't happen in the previous point releases.

I'm sorry about the messy reproducer, the issue was noticed in a much larger program and this is what I ended up with after removing all the cruft.

seg_fault_issue_import.py:

importasyncioimportatexitclassOtherClass:__slots__='a','b','c','d','e','f','g','h','i'def__init__(self):passdefregister_async_client_cleanup():defcleanup_wrapper():loop=asyncio.new_event_loop()loop.close()atexit.register(cleanup_wrapper)register_async_client_cleanup()

seg_fault_debug.py:

fromenumimportStrEnumfromseg_fault_issue_importimportOtherClassclassMyClass:def__init__(self):self.attr=OtherClass()classMyEnum(StrEnum):ATTR="attr"mydata=MyClass()setattr(mydata,MyEnum.ATTR,None)

Runningseg_fault_debug.py causes a segmentation fault with Python 3.13.10 and 3.14.1:

$ python3 seg_fault_debug.pySegmentation fault (core dumped)
Original reproducer

seg_fault_issue_import.py:

importasyncioimportatexitfromdataclassesimportdataclass@dataclass(slots=True)classCPU:"""CPU."""count:int|None=Nonefrequency:float|None=Noneload_average:float|None=Noneper_cpu:list[float]|None=Nonepower:float|None=Nonestats:float|None=Nonetemperature:float|None=Nonetimes:float|None=Nonetimes_percent:float|None=Nonedefregister_async_client_cleanup():defcleanup_wrapper():loop=asyncio.new_event_loop()loop.close()atexit.register(cleanup_wrapper)register_async_client_cleanup()

seg_fault_debug.py:

fromdataclassesimportdataclass,fieldfromenumimportStrEnumfromseg_fault_issue_importimportCPU@dataclassclassMyDataclass:attr:None=field(default_factory=CPU)classMyEnum(StrEnum):ATTR="attr"mydata=MyDataclass()setattr(mydata,MyEnum.ATTR,None)

CPython versions tested on:

3.14

Operating systems tested on:

Linux

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    3.13bugs and security fixes3.14bugs and security fixes3.15new features, bugs and security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)release-blockertype-crashA hard crash of the interpreter, possibly with a core dump

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp