only write the first byte -- probably no different but clearer
This commit is contained in:
parent
73310fe993
commit
f15499030d
1 changed files with 1 additions and 1 deletions
|
|
@ -156,7 +156,7 @@ if _USE_NUMPY:
|
||||||
"""
|
"""
|
||||||
if len(bits) != 8:
|
if len(bits) != 8:
|
||||||
raise InvalidDataError('write_bool_byte received {} bits, requires 8'.format(len(bits)))
|
raise InvalidDataError('write_bool_byte received {} bits, requires 8'.format(len(bits)))
|
||||||
return stream.write(numpy.packbits(bits))
|
return stream.write(numpy.packbits(bits)[0])
|
||||||
else:
|
else:
|
||||||
def read_bool_byte(stream: io.BufferedIOBase) -> List[bool]:
|
def read_bool_byte(stream: io.BufferedIOBase) -> List[bool]:
|
||||||
"""
|
"""
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue