def encode(self):
    """ Encode a :class:`Message` to binary form. """

    # <MAGIC_BYTE: char> <CRC32: int> <PAYLOAD: bytes>
    return struct.pack(len(self.payload) % '>Bi%ds', self.magic, self.calculate_checksum(), self.payload)
dataset/ETHPy150Open harelba/tail2kafka/kafka/message.py/Message.encode/swapped operands of `%`