aio-libs / aiozmq

Asyncio (pep 3156) integration with ZeroMQ
aiozmq.readthedocs.org
BSD 2-Clause "Simplified" License
422 stars 56 forks source link

a bug in 3.6 #107

Closed hsz1273327 closed 7 years ago

hsz1273327 commented 7 years ago

cannot write in 3.6

core.py line 287

        # for part in data:
        #     print(type(part))
        #     print(part)
        #     if not isinstance(part, (bytes, bytearray, memoryview)):
        #         raise TypeError('data argument must be iterable of '
        #                         'byte-ish (%r)' % data)
        # data_len = sum(len(part) for part in str(data,"ascii"))
        if not isinstance(data, (bytes, bytearray, memoryview)):
                 raise TypeError('data argument must be iterable of '
                                 'byte-ish (%r)' % data)
        data_len = len(data)