[issue34465] ipaddress should accept bytearray in addition to bytes

Gregory P. Smith report at bugs.python.org
Mon Sep 10 21:01:07 EDT 2018


Gregory P. Smith <greg at krypto.org> added the comment:

This isn't limited to just IPv4Address, the Network classes and the IPv6 classes that accept bytes should also be updated for consistency if we're going to do this.

(bytes, bytearray, memoryview) make sense to support, and explicitly test in unittests.

Until then, the workaround is to call bytes on the relevant slice of those.

----------
nosy: +gregory.p.smith

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue34465>
_______________________________________


More information about the Python-bugs-list mailing list