4

I'm following the guide for creating a user service as described here. When I place the urlfetcher.py file in ~/.config/pyethapp/contrib directory and restart pyethapp:

$ pyethapp run

I get the following (looping) network errors:

Starting URL translator service
INFO:p2p.peermgr    starting peermanager 
INFO:p2p.peermgr    starting listener addr=('0.0.0.0', 30303)
INFO:p2p.discovery  starting discovery 
INFO:p2p.discovery  starting listener host=0.0.0.0 port=30303
INFO:jsonrpc    starting IPCRPCServer ipcpath=/tmp/pyethapp.ipc
INFO:jsonrpc    starting JSONRPCServer port=4000
INFO:p2p.peermgr    waiting for bootstrap 
INFO:p2p.peer   received hello client_version=Geth/v1.4.4-stable-94ad694a/linux/go1.6.2 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61))
INFO:eth.sync.task  spawning new synctask 
INFO:p2p.peer   received hello client_version=pyethapp/v1.1.1/linux2/py2.7.10 version=55 capabilities=(('eth', 61), ('p2p', 4))
INFO:p2p.peer   received hello client_version=Geth/eth-peer-dal09-4/v1.3.5-34b622a2/linux/go1.6 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61), ('shh', 2))
WARNING:eth.chainservice    invalid network id remote_network_id=996787477 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Gshift/Explorer/v2.5.0-1d1c88f2/linux/go1.6.1 version=4 capabilities=(('shift', 63), ('shift', 62), ('shift', 61))
WARNING:eth.sync.task   syncing hashchain timed out 
WARNING:eth.sync.task   syncing failed with all peers num_protos=1
WARNING:eth.sync.task   syncing failed 
INFO:eth.sync.task  spawning new synctask 
INFO:p2p.peer   received hello client_version=Gexp/v1.3.5-fa6fc40f/linux/go1.5 version=4 capabilities=(('exp', 63), ('exp', 62), ('exp', 61))
INFO:p2p.peer   received hello client_version=Geth/v1.4.0-unstable/linux/go1.5.1 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61), ('shh', 2))
WARNING:eth.chainservice    invalid network id remote_network_id=161 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Geth/v1.4.4-stable-94ad694a/linux/go1.6.2 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61))
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/gevent-1.1.0-py2.7-linux-x86_64.egg/gevent/greenlet.py", line 534, in run
    result = self._run(*self.args, **self.kwargs)
  File "/usr/local/lib/python2.7/dist-packages/devp2p-0.7.2-py2.7.egg/devp2p/peer.py", line 230, in _run_decoded_packets
    self._handle_packet(self.mux.packet_queue.get())  # get_packet blocks
  File "/usr/local/lib/python2.7/dist-packages/devp2p-0.7.2-py2.7.egg/devp2p/peer.py", line 202, in _handle_packet
    cmd_id], protocol=protocol.name, orig_cmd_id=packet.cmd_id)
KeyError: 6
<Greenlet at 0x7f5b56bb0d70: <bound method Peer._run_decoded_packets of <Peer('120.25.154.157', 19999) >>> failed with KeyError

INFO:p2p.peer   received hello client_version=Geth/v1.4.4-stable-8f5a9d44/linux/go1.6.2 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61))
WARNING:eth.chainservice    invalid network id remote_network_id=9895666 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Geth/eth-peer-tok02-1/v1.3.5-34b622a2/linux/go1.6 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61), ('shh', 2))
WARNING:eth.chainservice    invalid network id remote_network_id=996787477 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Gexp/v1.3.5-12b0652e/linux/go1.5.1 version=4 capabilities=(('exp', 63), ('exp', 62), ('exp', 61))
INFO:p2p.peer   received hello client_version=Geth/v1.4.3-stable-dd083aa3/linux/go1.5 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61))
WARNING:eth.chainservice    invalid network id remote_network_id=1123 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Geth/eth-peer-lon02-3/v1.3.5-34b622a2/linux/go1.6 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61), ('shh', 2))
WARNING:eth.chainservice    invalid network id remote_network_id=996787477 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Geth/eth-peer-dal09-7/v1.3.5-34b622a2/linux/go1.6 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61), ('shh', 2))
WARNING:eth.chainservice    invalid network id remote_network_id=996787477 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Gshift/Explorer/v2.5.0-1d1c88f2/linux/go1.6.1 version=4 capabilities=(('shift', 63), ('shift', 62), ('shift', 61))
INFO:p2p.peer   received hello client_version=Gexp/v1.3.5-12b0652e/linux/go1.5.1 version=4 capabilities=(('exp', 63), ('exp', 62), ('exp', 61))
INFO:p2p.peer   received hello client_version=Geth/v1.3.6-8723cd74/linux/go1.5.1 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61))
WARNING:eth.chainservice    invalid genesis hash remote_id=<ETHProtocol <Peer('37.59.24.15', 41303) Geth/v1.3.6-8723cd74>> genesis=5157cbd8975669bdb52c8ba7073bf08fd868946a9f70db197e74097b4342050e
WARNING:protocol    protocol exception, stopping error=wrong genesis block
INFO:p2p.peer   received hello client_version=Gexp/v1.4.4-stable-b118fdab/linux/go1.5 version=4 capabilities=(('exp', 63), ('exp', 62), ('exp', 61))
INFO:p2p.peer   received hello client_version=Geth/v1.5.0-unstable/linux/go1.5.1 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61))
WARNING:eth.chainservice    invalid network id remote_network_id=100558 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Geth/v1.3.6-9e323d65/linux/go1.5 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61))
WARNING:eth.chainservice    invalid network id remote_network_id=1123 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Geth/eth-peer-lon02-6/v1.3.5-34b622a2/linux/go1.6 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61), ('shh', 2))
WARNING:eth.chainservice    invalid network id remote_network_id=996787477 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Geth/eth-peer-dal09-5/v1.3.5-34b622a2/linux/go1.6 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61), ('shh', 2))
WARNING:eth.chainservice    invalid network id remote_network_id=996787477 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Gexp/v1.4.4-stable-b118fdab/linux/go1.5 version=4 capabilities=(('exp', 63), ('exp', 62), ('exp', 61))
INFO:p2p.peer   received hello client_version=Ged/v1.3.6-f653a5ce/linux/go1.6.2 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61))
WARNING:eth.chainservice    invalid network id remote_network_id=88 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Geth/v1.3.5/linux/go1.5.1 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61))
WARNING:eth.chainservice    invalid network id remote_network_id=100558 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Geth/v1.4.0-unstable/linux/go1.5.1 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61))
INFO:p2p.peer   received hello client_version=Geth/v1.5.0-unstable/linux/go1.5.1 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61))
INFO:p2p.peer   received hello client_version=Geth/eth-peer-dal09-1/v1.3.5-34b622a2/linux/go1.6 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61), ('shh', 2))
WARNING:eth.chainservice    invalid network id remote_network_id=996787477 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Geth/eth-atm-lon02-1/v1.3.5-34b622a2/linux/go1.6 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61), ('shh', 2))
WARNING:eth.chainservice    invalid network id remote_network_id=996787477 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Geth/v1.4.4-stable-8f5a9d44/linux/go1.6.2 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61))
WARNING:eth.chainservice    invalid network id remote_network_id=9895888 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id
INFO:p2p.peer   received hello client_version=Gexp/v1.4.4-stable-b118fdab/linux/go1.5 version=4 capabilities=(('exp', 63), ('exp', 62), ('exp', 61))
INFO:p2p.peer   received hello client_version=Geth/eth-atm-lon02-1/v1.3.5-34b622a2/linux/go1.6 version=4 capabilities=(('eth', 63), ('eth', 62), ('eth', 61), ('shh', 2))
WARNING:eth.chainservice    invalid network id remote_network_id=996787477 expected_network_id=1
WARNING:protocol    protocol exception, stopping error=wrong network_id

Is this issue related to running pyethapp behind a NAT without port forwarding? I am running the example on main net (no testnet argument specified).

3

As stated here https://github.com/ethereum/pyethapp/issues/113 this seems to be due to higher level protocols not known by pyethapp. If you wait it will work eventually.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.