(self, serialized: Union[str, dict], *, native_id=None, **extra)
return self.message_class.from_dict(
            metadata=metadata, kwargs=kwargs, native_id=native_id, **extra
        )
Takes a serialised string representation and returns a Message object

        Reverse of BlobMessageSerializer
Takes a serialised string representation and returns a Message object
Takes a serialised string representation and returns a Message object
def __call__(self, serialized: Union[str, dict], *, native_id=None, **extra):
        """ Takes a serialised string representation and returns a Message object

        Reverse of BlobMessageSerializer
        """
        # Allow for receiving dicts on the assumption that this will be
        # json which has already been decoded.
        if isinstance(serialized, dict):
            decoded = serialized
        else:
            serialized = decode_bytes(serialized)
            decoded = self.decoder(serialized)

        metadata = decoded.get("metadata", {})
        kwargs = decoded.get("kwargs", {})

        sanity_check_metadata(self.message_class, metadata)

        return self.message_class.from_dict(
            metadata=metadata, kwargs=kwargs, native_id=native_id, **extra
        )
def __call__ ( self , serialized : Union [ str , dict ] , * , native_id = None , * * extra ) : # Allow for receiving dicts on the assumption that this will be # json which has already been decoded. if isinstance ( serialized , dict ) : decoded = serialized else : serialized = decode_bytes ( serialized ) decoded = self . decoder ( serialized ) metadata = decoded . get ( "metadata" , { } ) kwargs = decoded . get ( "kwargs" , { } ) sanity_check_metadata ( self . message_class , metadata ) return self . message_class . from_dict ( metadata = metadata , kwargs = kwargs , native_id = native_id , * * extra )