From 04b6f9f744b0b84cb8140babb60cd35ccea7853f Mon Sep 17 00:00:00 2001 From: Marc de Klerk Date: Thu, 16 Jul 2020 08:11:44 +0200 Subject: [PATCH] add testnet param to socket example --- ch10.asciidoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ch10.asciidoc b/ch10.asciidoc index be789ef8..c0360dcf 100644 --- a/ch10.asciidoc +++ b/ch10.asciidoc @@ -121,10 +121,10 @@ To experiment, we can establish a connection to a node on the network synchronou >>> socket.connect((host, port)) >>> stream = socket.makefile('rb', None) # <2> >>> version = VersionMessage() # <3> ->>> envelope = NetworkEnvelope(version.command, version.serialize()) +>>> envelope = NetworkEnvelope(version.command, version.serialize(), testnet=True) >>> socket.sendall(envelope.serialize()) # <4> >>> while True: -... new_message = NetworkEnvelope.parse(stream) # <5> +... new_message = NetworkEnvelope.parse(stream, testnet=True) # <5> ... print(new_message) ---- <1> This is a server I've set up for testnet.