Skip to content

Commit 7ef60ce

Browse files
committed
Merge #13963: tests: Replace usage of tostring() with tobytes()
8845c8a tests: Replace usage of tostring() with tobytes() (Carl Dong) Pull request description: tostring() is deprecated as of python 3.7 and results in stderr output causing tests to fail Tree-SHA512: 8c5bbd6c6127490922add98543ee7719d19e11200e081784adef2f026ddf90d7735da7d0fb41fa4307d0d3450a27e126752c2b01cbd79b0c8a695855aed080ac
2 parents ddc3ec9 + 8845c8a commit 7ef60ce

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

test/functional/test_framework/netutil.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ def all_interfaces():
107107
max_possible *= 2
108108
else:
109109
break
110-
namestr = names.tostring()
110+
namestr = names.tobytes()
111111
return [(namestr[i:i+16].split(b'\0', 1)[0],
112112
socket.inet_ntoa(namestr[i+20:i+24]))
113113
for i in range(0, outbytes, struct_size)]

0 commit comments

Comments
 (0)