-
Notifications
You must be signed in to change notification settings - Fork 37
Labels
type: docsImprovement to the documentation for an API.Improvement to the documentation for an API.
Description
class Composer(proto.Message):
given_name = proto.Field(proto.STRING, number=1)
family_name = proto.Field(proto.STRING, number=2)
composer = Composer(given_name="Johannes", family_name="Bach")
pickled_composer = pickle.dumps(composer)Traceback (most recent call last):
File "<stdin>", line 1, in <module>
_pickle.PicklingError: Can't pickle <class 'Composer'>: it's not the same object as __main__.Composer
The current recommendation is to serialize to bytes. https://proto-plus-python.readthedocs.io/en/latest/reference/message.html
Metadata
Metadata
Assignees
Labels
type: docsImprovement to the documentation for an API.Improvement to the documentation for an API.