def pkt_line(data):
    if data is None:
        return '0000'
    return '%04x%s' % (len(data) + 4, data)
Wrap data in a pkt-line.
dataset/ETHPy150Open natestedman/Observatory/observatory/lib/dulwich/protocol.py/pkt_line