Skip to content

Dill Should Use a Custom dispatch_table vs Modifying pickle._Pickler.dispatch  #456

@elmq0022

Description

@elmq0022

Dill modifies python's pickler._Pickle.dispatch. This means it can clash with similar packages with similar goals, notably cloudpickle.

Dill does provide dill.extend to turn dill on and off, but this is cumbersome and relies on the user to be know when dill is or is not enabled.

Using a custom dispatch_table as specified in the Python's pickle documentation would be a cleaner implementation, in my opinion, as dill's extensions would be scoped only to dill and not clash with other packages polluting the global scope.

I haven't scoped the effort required, but I would be willing to assist if the maintainer(s) are willing to entertain such a change.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions