Skip to content

Commit 1066519

Browse files
committed
Use b2lx instead of hexlify in net.py
1 parent a93dad4 commit 1066519

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

bitcoin/net.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,14 @@
1313

1414
import struct
1515
import socket
16-
from binascii import hexlify
1716

1817
from bitcoin.core.serialize import (
1918
Serializable,
2019
VarStringSerializer,
2120
ser_read,
2221
uint256VectorSerializer,
2322
)
23+
from bitcoin.core import b2lx
2424

2525
PROTO_VERSION = 60002
2626
CADDR_TIME_VERSION = 31402
@@ -80,7 +80,7 @@ def stream_serialize(self, f):
8080
f.write(self.hash)
8181

8282
def __repr__(self):
83-
return "CInv(type=%s hash=%s)" % (self.typemap[self.type], hexlify(self.hash))
83+
return "CInv(type=%s hash=%s)" % (self.typemap[self.type], b2lx(self.hash))
8484

8585

8686
class CBlockLocator(Serializable):

0 commit comments

Comments
 (0)