Skip to content

partial __getstate__ wrong (?) #125094

@albertz

Description

@albertz

Bug report

Bug description:

The native _functools.partial type __getstate__ will return its __dict__. That will not include func, args or keywords.

This is different from the pure Python implementation of functools.partial (link), where it will return the slots, i.e. the state includes func, args or keywords.

CPython versions tested on:

CPython main branch

Operating systems tested on:

Linux

Metadata

Metadata

Assignees

No one assigned

    Labels

    extension-modulesC modules in the Modules dirtype-bugAn unexpected behavior, bug, or error

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions