Giampaolo Rodola' added the comment: Note that if we pass bytes to bind(), getsockname() will return str anyway:
>>> s = socket.socket(socket.AF_UNIX) >>> s.bind(b'hello') >>> s.getsockname() 'hello' That said, it seems more consistent to me to return str also in case of abstract namespace. As per: http://blog.eduardofleury.com/archives/2007/09/13 ...one is supposed to set only the first byte to null, and the rest of the path is supposed to be a 'plain' string. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue17683> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com