Giter VIP home page Giter VIP logo

qrl's Introduction

MIT licensed PyPI version CircleCI CircleCI Codacy Badge codebeat badge Snyk Vulnerability Analysis

QRL - Quantum Resistant Ledger

Python-based blockchain ledger utilizing hash-based one-time merkle tree signature scheme (XMSS) instead of ECDSA. Proof-of-work block selection via the cryptonight algorithm. Future transition to POS with signed iterative hash chain reveal scheme which is both probabilistic and random (https://github.com/theQRL/pos).

Hash-based signatures means larger transactions (3kb per tx, binary), longer keypair generation times and the need to record 'state' of transactions as each keypair can only be used once safely. Merkle tree usage enables a single address to be used for signing numerous transactions (up to 2^13 computationally easily enough). Currently XMSS/W-OTS+ are natively supported with extensible support for further cryptographic schemes inbuilt.

Documentation

We recommend exploring our Documentation

For instructions on how to install a node, please refer to Install Node

API documentation can be found at api.theqrl.org

More information


qrl's People

Contributors

ademcan avatar aidanbeale avatar bidulemachin avatar bitcoinssg avatar bmoscon avatar codacy-badger avatar converghub avatar cryptofuture avatar cyyber avatar elliottdehn avatar fr1t2 avatar fullmatches avatar fungibly avatar hadacnot avatar jackalyst avatar jleni avatar jomarip avatar jplomas avatar leagueofdelegates avatar neurone avatar nickycakes avatar r41d avatar randomshinichi avatar randomusergenerator avatar scottdonaldau avatar som-dev avatar surg0r avatar timhovius avatar ubidefeo avatar wyc0 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

qrl's Issues

0.52.2a telnet command send (2nd error)

Send does not work for normal usage
telnet: send 0 430b5ac9c10d194119436d35742cca827b5ef523110766553392973ad18f9c75c4c27cfe 1.1 0

Error:
2017-10-02 16:56:43,508 |synced| CRITICAL : [TWISTED] Unhandled Error
Traceback (most recent call last):
File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 103, in callWithLogger
return callWithContext({"system": lp}, func, *args, **kw)
File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 86, in callWithContext
return context.call({ILogContext: newCtx}, func, *args, **kw)
File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 122, in callWithContext
return self.currentContext().callWithContext(ctx, func, *args, **kw)
File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 85, in callWithContext
return func(*args,**kw)
--- ---
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/posixbase.py", line 597, in _doReadOrWrite
why = selectable.doRead()
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 208, in doRead
return self._dataReceived(data)
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 214, in _dataReceived
rval = self.protocol.dataReceived(data)
File "/home/pi/QRL/qrl/core/walletprotocol.py", line 340, in dataReceived
if not self.parse_cmd(self.parse(data)):
File "/home/pi/QRL/qrl/core/walletprotocol.py", line 231, in parse_cmd
self.send_tx(args)
File "/home/pi/QRL/qrl/core/walletprotocol.py", line 539, in send_tx
fee = decimal.Decimal(decimal.Decimal(args[3]) * 100000000).quantize(decimal.Decimal('1'),
builtins.TypeError: conversion from bytes to Decimal is not supported

telnet: wallet command crashes

Seems to be a new problem, never had this before git pulling today.

2017-10-07 15:34:22,511 |unsynced| CRITICAL : [TWISTED] Unhandled Error
Traceback (most recent call last):
  File "/Users/shinichi/.virtualenvs/qrl/lib/python3.6/site-packages/twisted/python/log.py", line 103, in callWithLogger
    return callWithContext({"system": lp}, func, *args, **kw)
  File "/Users/shinichi/.virtualenvs/qrl/lib/python3.6/site-packages/twisted/python/log.py", line 86, in callWithContext
    return context.call({ILogContext: newCtx}, func, *args, **kw)
  File "/Users/shinichi/.virtualenvs/qrl/lib/python3.6/site-packages/twisted/python/context.py", line 122, in callWithContext
Unhandled Error
    return self.currentContext().callWithContext(ctx, func, *args, **kw)
Traceback (most recent call last):
  File "/Users/shinichi/.virtualenvs/qrl/lib/python3.6/site-packages/twisted/python/context.py", line 85, in callWithContext
  File "/Users/shinichi/.virtualenvs/qrl/lib/python3.6/site-packages/twisted/python/log.py", line 103, in callWithLogger
    return func(*args,**kw)
    return callWithContext({"system": lp}, func, *args, **kw)
--- <exception caught here> ---
  File "/Users/shinichi/.virtualenvs/qrl/lib/python3.6/site-packages/twisted/python/log.py", line 86, in callWithContext
  File "/Users/shinichi/.virtualenvs/qrl/lib/python3.6/site-packages/twisted/internet/selectreactor.py", line 149, in _doReadOrWrite
    return context.call({ILogContext: newCtx}, func, *args, **kw)
    why = getattr(selectable, method)()
  File "/Users/shinichi/.virtualenvs/qrl/lib/python3.6/site-packages/twisted/python/context.py", line 122, in callWithContext
  File "/Users/shinichi/.virtualenvs/qrl/lib/python3.6/site-packages/twisted/internet/tcp.py", line 208, in doRead
    return self.currentContext().callWithContext(ctx, func, *args, **kw)
    return self._dataReceived(data)
  File "/Users/shinichi/.virtualenvs/qrl/lib/python3.6/site-packages/twisted/python/context.py", line 85, in callWithContext
  File "/Users/shinichi/.virtualenvs/qrl/lib/python3.6/site-packages/twisted/internet/tcp.py", line 214, in _dataReceived
    return func(*args,**kw)
    rval = self.protocol.dataReceived(data)
--- <exception caught here> ---
  File "/Users/shinichi/source/QRL/qrl/core/walletprotocol.py", line 97, in dataReceived
  File "/Users/shinichi/.virtualenvs/qrl/lib/python3.6/site-packages/twisted/internet/selectreactor.py", line 149, in _doReadOrWrite
    if not self.parse_cmd(data):
    why = getattr(selectable, method)()
  File "/Users/shinichi/source/QRL/qrl/core/walletprotocol.py", line 78, in parse_cmd
    self.cmd_mapping[command](args)
  File "/Users/shinichi/.virtualenvs/qrl/lib/python3.6/site-packages/twisted/internet/tcp.py", line 208, in doRead
  File "/Users/shinichi/source/QRL/qrl/core/walletprotocol.py", line 344, in _wallet
    return self._dataReceived(data)
    self.factory.state.state_read_chain(self.factory.chain)
  File "/Users/shinichi/.virtualenvs/qrl/lib/python3.6/site-packages/twisted/internet/tcp.py", line 214, in _dataReceived
  File "/Users/shinichi/source/QRL/qrl/core/state.py", line 485, in state_read_chain
    rval = self.protocol.dataReceived(data)
    self.zero_all_addresses()
  File "/Users/shinichi/source/QRL/qrl/core/walletprotocol.py", line 97, in dataReceived
  File "/Users/shinichi/source/QRL/qrl/core/state.py", line 229, in zero_all_addresses
    if not self.parse_cmd(data):
    self.db.put(address, [0, 0, []])
  File "/Users/shinichi/source/QRL/qrl/core/walletprotocol.py", line 78, in parse_cmd
  File "/Users/shinichi/source/QRL/qrl/core/db.py", line 37, in put
    self.cmd_mapping[command](args)
    key_obj = key_obj.encode()
  File "/Users/shinichi/source/QRL/qrl/core/walletprotocol.py", line 344, in _wallet
builtins.AttributeError: 'bytearray' object has no attribute 'encode'
    self.factory.state.state_read_chain(self.factory.chain)

  File "/Users/shinichi/source/QRL/qrl/core/state.py", line 485, in state_read_chain
    self.zero_all_addresses()
  File "/Users/shinichi/source/QRL/qrl/core/state.py", line 229, in zero_all_addresses
    self.db.put(address, [0, 0, []])
  File "/Users/shinichi/source/QRL/qrl/core/db.py", line 37, in put
    key_obj = key_obj.encode()
builtins.AttributeError: 'bytearray' object has no attribute 'encode'

Windows native support

The current release is not supported in Windows.

This is linked to this issue in qrllib: theQRL/qrllib#38

The official Docker container also has problems in Windows.

For the moment, the use of VMs such as virtualbox or VmWare is recommended.

Custom node port as alternative to TCP 9000

Hi guys.
As I've been mentioning in the #suggestions channel, please label this as "feature enhancement" or something appropriate.

I think it would be very beneficial to allow nodes to listen on ports other than TCP 9000.
This would let whomever has the expertise run multiple nodes behind the same public IP.

I personally am accustomed to running my own services for fun as well as for clients' custom applications.

Each node could broadcast IP:PORT as part of the announce information and the protocol could support connecting to different ports.

Hope you'll show some love to this one, to let initial network be backed by the ones who feel like running multiple staking nodes.

thank you for giving me the chance to share this

u.

Dependency problem: pyasn1 is not available

All deps seem to be installed.

:~/QRL# pip3 install -r requirements.txt
Requirement already satisfied: jsonpickle>=0.9.5 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 2))
Requirement already satisfied: leveldb>=0.19 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 3))
Requirement already satisfied: statistics>=1.0.3.5 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 4))
Requirement already satisfied: ntplib>=0.3.3 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 5))
Requirement already satisfied: Twisted==17.5.0 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 6))
Requirement already satisfied: colorlog>=3.0.1 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 7))
Requirement already satisfied: simplejson>=3.11.1 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 8))
Requirement already satisfied: PyYAML==3.12 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 9))
Requirement already satisfied: service_identity in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 10))
Requirement already satisfied: pyopenssl>=17.3.0 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 11))
Requirement already satisfied: pyqrllib>=0.1.20 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 12))
Requirement already satisfied: docutils>=0.3 in /usr/local/lib/python3.5/dist-packages (from statistics>=1.0.3.5->-r requirements.txt (line 4))
Requirement already satisfied: zope.interface>=4.0.2 in /usr/local/lib/python3.5/dist-packages (from Twisted==17.5.0->-r requirements.txt (line 6))
Requirement already satisfied: constantly>=15.1 in /usr/local/lib/python3.5/dist-packages (from Twisted==17.5.0->-r requirements.txt (line 6))
Requirement already satisfied: hyperlink>=17.1.1 in /usr/local/lib/python3.5/dist-packages (from Twisted==17.5.0->-r requirements.txt (line 6))
Requirement already satisfied: Automat>=0.3.0 in /usr/local/lib/python3.5/dist-packages (from Twisted==17.5.0->-r requirements.txt (line 6))
Requirement already satisfied: incremental>=16.10.1 in /usr/local/lib/python3.5/dist-packages (from Twisted==17.5.0->-r requirements.txt (line 6))
Requirement already satisfied: pyasn1-modules in /usr/local/lib/python3.5/dist-packages (from service_identity->-r requirements.txt (line 10))
Requirement already satisfied: attrs in /usr/local/lib/python3.5/dist-packages (from service_identity->-r requirements.txt (line 10))
Requirement already satisfied: pyasn1 in /usr/lib/python3/dist-packages (from service_identity->-r requirements.txt (line 10))
Requirement already satisfied: six>=1.5.2 in /usr/lib/python3/dist-packages (from pyopenssl>=17.3.0->-r requirements.txt (line 11))
Requirement already satisfied: cryptography>=1.9 in /usr/local/lib/python3.5/dist-packages (from pyopenssl>=17.3.0->-r requirements.txt (line 11))
Requirement already satisfied: scikit-build in /usr/local/lib/python3.5/dist-packages (from pyqrllib>=0.1.20->-r requirements.txt (line 12))
Requirement already satisfied: setuptools in /usr/local/lib/python3.5/dist-packages (from zope.interface>=4.0.2->Twisted==17.5.0->-r requirements.txt (line 6))
Requirement already satisfied: cffi>=1.7 in /usr/local/lib/python3.5/dist-packages (from cryptography>=1.9->pyopenssl>=17.3.0->-r requirements.txt (line 11))
Requirement already satisfied: idna>=2.1 in /usr/local/lib/python3.5/dist-packages (from cryptography>=1.9->pyopenssl>=17.3.0->-r requirements.txt (line 11))
Requirement already satisfied: asn1crypto>=0.21.0 in /usr/local/lib/python3.5/dist-packages (from cryptography>=1.9->pyopenssl>=17.3.0->-r requirements.txt (line 11))
Requirement already satisfied: wheel>=0.29.0 in /usr/lib/python3/dist-packages (from scikit-build->pyqrllib>=0.1.20->-r requirements.txt (line 12))
Requirement already satisfied: pycparser in /usr/local/lib/python3.5/dist-packages (from cffi>=1.7->cryptography>=1.9->pyopenssl>=17.3.0->-r requirements.txt (line 11))

But when i start the node i get:

:~/QRL# python start_qrl.py
dependencies not satisfied, run [pip3 install -r requirements.txt] first.
The 'pyqrllib>=0.1.20' distribution was not found and is required by the application

telnet "search" closing connection | CRITICAL : [TWISTED] Unhandled Error

searching for Q'address in telnet gives CRITICAL : [TWISTED] Unhandled Error | 'Chain' object has no attribute 'search_txhash'

$ telnet localhost 2000

getinfo

Version: 0.52.2a
Uptime: 30799.47098827362
Nodes connected: 7
Staking set to: True
Sync status: synced

search Q3605e34c94ca833a2d6e80137eb11414abace2723e5ad7b61d3c954b85c90741bdae01da
Connection closed by foreign host.
---------------------------~/.qrl/qrl.log -------------------------------------

2017-10-02 23:06:45,962 |synced| INFO : [ChainBuffer] Block #6193 added stake: Qd72b34429cc1efde3721a80f06b9d5755034a49f49c1c551f0843a8e7dd12275cecb6398
2017-10-02 23:06:58,667 |synced| INFO : >>> new local connection 1 IPv4Address(TCP, '127.0.0.1', 56192)
2017-10-02 23:07:28,302 |synced| CRITICAL : [TWISTED] Unhandled Error
Traceback (most recent call last):
File "/home/ubuntu/.local/lib/python3.5/site-packages/twisted/python/log.py", line 103, in callWithLogger
return callWithContext({"system": lp}, func, *args, **kw)
File "/home/ubuntu/.local/lib/python3.5/site-packages/twisted/python/log.py", line 86, in callWithContext
return context.call({ILogContext: newCtx}, func, *args, **kw)
File "/home/ubuntu/.local/lib/python3.5/site-packages/twisted/python/context.py", line 122, in callWithContext
return self.currentContext().callWithContext(ctx, func, *args, **kw)
File "/home/ubuntu/.local/lib/python3.5/site-packages/twisted/python/context.py", line 85, in callWithContext
return func(*args,**kw)
--- ---
File "/home/ubuntu/.local/lib/python3.5/site-packages/twisted/internet/posixbase.py", line 597, in _doReadOrWrite
why = selectable.doRead()
File "/home/ubuntu/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 208, in doRead
return self._dataReceived(data)
File "/home/ubuntu/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 214, in _dataReceived
rval = self.protocol.dataReceived(data)
File "/home/ubuntu/QRL/qrl/core/walletprotocol.py", line 340, in dataReceived
if not self.parse_cmd(self.parse(data)):
File "/home/ubuntu/QRL/qrl/core/walletprotocol.py", line 107, in parse_cmd
tmp_output = json.loads(self.factory.chain.search_txhash(args[0]))
builtins.AttributeError: 'Chain' object has no attribute 'search_txhash'

2017-10-02 23:07:29,976 |synced| INFO : create_new_block #6194
2017-10-02 23:07:29,991 |synced| INFO : BLOCK: 6191 epoch: 61 blocks_left: 8 nonce: 19 stake_selector Q321551228be4c8275bc3a2665347f4b399216268bf6a704c6fd5ced5666c117105f82613
2017-10-02 23:07:29,996 |synced| INFO : 68510366c570251670db75b083dcc819d74366325381e5729fead75c4fb233d6 1 tx passed verification.
2017-10-02 23:07:30,138 |synced| INFO : [ChainBuffer] Block #6194 added stake: Q3605e34c94ca833a2d6e80137eb11414abace2723e5ad7b61d3c954b85c90741bdae01da
2017-10-02 23:07:30,741 |synced| INFO : >>>Received block from 104.237.3.185:9000 6194 Q871011bfa3d8fb9e41c8b59904a116c31a028bab1eadcf5711e64b3445869034d6769cab
2017-10-02 23:07:30,898 |synced| INFO : [ChainBuffer] Block #6194 added stake: Q871011bfa3d8fb9e41c8b59904a116c31a028bab1eadcf5711e64b3445869034d6769cab

Wallet Recoverfromhexseed v.06

I synced the node and opened the wallet with Putty. Localhost Port 2000.

Fist I used the command Wallet. This worked fine and displayed 0 balance. Then I typed recoverfromhexseed so I could make sure I could recover my wallet. Then Putty force closed and this message appeared within the Node printout

`4cec30d4ed899253c1d2860b0975899b2fc6e609c255d2bf413a9290c48ba8d2
Unhandled Error
Traceback (most recent call last):
File "C:\Python27\lib\site-packages\twisted\python\log.py", line 103, in callWithLogger
return callWithContext({"system": lp}, func, *args, **kw)
File "C:\Python27\lib\site-packages\twisted\python\log.py", line 86, in callWithContext
return context.call({ILogContext: newCtx}, func, *args, **kw)
File "C:\Python27\lib\site-packages\twisted\python\context.py", line 122, in callWithContext
return self.currentContext().callWithContext(ctx, func, *args, **kw)
File "C:\Python27\lib\site-packages\twisted\python\context.py", line 85, in callWithContext
return func(*args,**kw)
--- ---
File "C:\Python27\lib\site-packages\twisted\internet\selectreactor.py", line 149, in _doReadOrWrite
why = getattr(selectable, method)()
File "C:\Python27\lib\site-packages\twisted\internet\tcp.py", line 208, in doRead
return self._dataReceived(data)
File "C:\Python27\lib\site-packages\twisted\internet\tcp.py", line 214, in _dataReceived
rval = self.protocol.dataReceived(data)
File "node.py", line 1354, in dataReceived

File "node.py", line 1269, in parse_cmd

exceptions.IndexError: list index out of range
`

Fails to compile on Mac OS 10.12.6

I have Python 3.6.3 via PyEnv and tried the install process with sudo pip3 install -r requirements.txt.
The process fails when PYTHON_LIBRARIES and PYTHON_INCLUDE_DIRSare not found, and think they should be added to CMakeLists.txt of qrllib, but this is installed via requirements.txt.

Is there a way I can specify them in the QRL setup?
Should I attempt to just download/install qrllib separately rather than via requirements.txt?

thank you
u.

Why not python3?

Comment is same as title.

Check the https://pythonclock.org/
You can 2 year and 9 month are lefted for supporting python 2.7

2to3 tool may help porting 2.7 to 3.x, try use!

Python 3.x support library

  • python-dev
  • jsonpickle
  • leveldb
  • beautifulsoup4
  • blessings
  • statistics (yes, that was a python 3.x module; backported!)
  • service_identity
  • ntplib

I think only ntplib are not support python3
(but you can porting ntplib also...)

Thanks for reading this issue.

0.52.2a Error in P2P Protocol.py

2017-10-06 18:43:37,118 |synced| ERROR : Traceback (most recent call last):
File "/home/pi/QRL/qrl/core/p2pprotocol.py", line 962, in parse_buffer
tmp2 = hstr2bin(tmp.decode())
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xfa in position 3: invalid start byte

2017-10-06 18:43:37,122 |synced| INFO : Struct.unpack error attempting to decipher msg length..

0.52.2a mnemonic file

wallet recovery with mnemonic file does not work
there got no error only two times the data path and wallet path output
and finally a new adress

output:
2017-10-03 09:29:46,622 |unsynced| DEBUG : =====================================================================================
2017-10-03 09:29:46,627 |unsynced| INFO : Data Path: /home/pi/.qrl/data
2017-10-03 09:29:46,632 |unsynced| INFO : Wallet Path: /home/pi/.qrl/wallet
2017-10-03 09:29:46,709 |unsynced| INFO : Initializing chain..
2017-10-03 09:29:46,711 |unsynced| INFO : DB path: /home/pi/.qrl/data/state
2017-10-03 09:29:46,751 |unsynced| INFO : Retrieving wallet file
2017-10-03 09:43:42,887 |unsynced| DEBUG : =====================================================================================
2017-10-03 09:43:42,888 |unsynced| INFO : Data Path: /home/pi/.qrl/data
2017-10-03 09:43:42,893 |unsynced| INFO : Wallet Path: /home/pi/.qrl/wallet
2017-10-03 09:43:42,974 |unsynced| INFO : Initializing chain..
2017-10-03 09:43:42,977 |unsynced| INFO : DB path: /home/pi/.qrl/data/state
2017-10-03 09:45:36,395 |unsynced| INFO : Syncing wallet file
2017-10-03 09:45:36,416 |unsynced| INFO : QRL blockchain ledger 0.52.2a
2017-10-03 09:45:36,420 |unsynced| INFO : loading db
2017-10-03 09:45:36,423 |unsynced| INFO : loading wallet
2017-10-03 09:45:36,426 |unsynced| INFO : mining/staking address Qa3684303eb230ed42fa312fc215c9e011fb06363f9bac24c3e613872dbd9aad45eeb36f5
2017-10-03 09:45:36,430 |unsynced| INFO : Reading chain..

control - C on telnet sessions gives |synced| CRITICAL : [TWISTED] Unhandled Error

2017-10-03 11:34:34,916 |synced| CRITICAL : [TWISTED] Unhandled Error
Traceback (most recent call last):
File "/home/jupiter/miniconda3/lib/python3.6/site-packages/twisted/python/log.py", line 103, in callWithLogger return callWithContext({"system": lp}, func, *args, **kw)
File "/home/jupiter/miniconda3/lib/python3.6/site-packages/twisted/python/log.py", line 86, in callWithContext return context.call({ILogContext: newCtx}, func, *args, **kw)
File "/home/jupiter/miniconda3/lib/python3.6/site-packages/twisted/python/context.py", line 122, in callWithContext return self.currentContext().callWithContext(ctx, func, *args, **kw)
File "/home/jupiter/miniconda3/lib/python3.6/site-packages/twisted/python/context.py", line 85, in callWithContext return func(*args,**kw)
--- ---
File "/home/jupiter/miniconda3/lib/python3.6/site-packages/twisted/internet/posixbase.py", line 597, in _doReadOrWrite why = selectable.doRead() File "/home/jupiter/miniconda3/lib/python3.6/site-packages/twisted/internet/tcp.py", line 208, in doRead
File "/home/jupiter/miniconda3/lib/python3.6/site-packages/twisted/internet/tcp.py", line 214, in _dataReceived rval = self.protocol.dataReceived(data) File "/home/jupiter/Downloads/ethereum/qrl/qrl/core/walletprotocol.py", line 340, in dataReceived if not self.parse_cmd(self.parse(data)):
File "/home/jupiter/Downloads/ethereum/qrl/qrl/core/walletprotocol.py", line 57, in parse_cmd if command.decode('utf-8') in self.cmd_list:
builtins.UnicodeDecodeError: 'utf-8' codec can't decode byte 0xff in position 0: invalid start byte

walletprotocol: 'search' when Qaddress has txns, it fails trying to cast list to bytes

Telnet: search Q871011bfa3d8fb9e41c8b59904a116c31a028bab1eadcf5711e64b3445869034d6769cab
(Genesis address with transactions)

In Chain.search_address()

my_txn = []
try:
    my_txn = self.state.db.get('txn_' + address)
except:
    pass

for txn_hash in my_txn:
    txn_metadata = self.state.db.get(txn_hash)

my_txn is a list of lists, and txn_hash is a list. However, self.state.db.get() expects something which can be cast to bytes:

    def get(self, key_obj):
        if not isinstance(key_obj, bytes):
            key_obj = bytes(key_obj, 'utf-8')
        value_obj = self.db.Get(key_obj)

So when key_obj is a list, line 3 fails.

0.53.0a telnet wallet command

as long grpc ist not implemented, telnet command wallet should work,

but for a unsynced node following error occurs:

2017-10-12 18:36:56,760 |syncing| CRITICAL : [TWISTED] Unhandled Error
Traceback (most recent call last):
File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 103, in callWithLogger
return callWithContext({"system": lp}, func, *args, **kw)
File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 86, in callWithContext
return context.call({ILogContext: newCtx}, func, *args, **kw)
File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 122, in callWithContext
return self.currentContext().callWithContext(ctx, func, *args, **kw)
File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 85, in callWithContext
return func(*args,**kw)
--- ---
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/posixbase.py", line 597, in _doReadOrWrite
why = selectable.doRead()
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 208, in doRead
return self._dataReceived(data)
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 214, in _dataReceived
rval = self.protocol.dataReceived(data)
File "/home/pi/QRL/qrl/core/walletprotocol.py", line 95, in dataReceived
if not self.parse_cmd(data):
File "/home/pi/QRL/qrl/core/walletprotocol.py", line 76, in parse_cmd
self.cmd_mappingcommand
File "/home/pi/QRL/qrl/core/walletprotocol.py", line 278, in _wallet
self.factory.chain.transaction_pool, True)
File "/home/pi/QRL/qrl/core/wallet.py", line 160, in list_addresses
tmp_state_balance = state.state_balance(addr_bundle.address)
File "/home/pi/QRL/qrl/core/state.py", line 155, in state_balance
nonce, balance, pubhash_list = self._get_address_state(addr)
File "/home/pi/QRL/qrl/core/state.py", line 394, in _get_address_state
data = self.db.get_raw(address.encode())
File "/home/pi/QRL/qrl/core/db.py", line 67, in get_raw
return self.db.Get(key)
builtins.KeyError:

[CLI] add version information

hi guys

I think invoking qrl from command line should also report version(s) of qrl and libqrl.
An alternative could be adding the -i [--info] flag to get them.
In some command line utilities version is the first thing shown.

"start_qrl" fails to launch if port 8080 is in use.

Type: Enhancement
Priority: Low

When launching QRL (start_qrl), if another application/service is already using port 8080, QRL fails to launch.

Instead of failing, can QRL [automatically] use another port instead?

GetObject of the PublicAPI Service fails to get transaction details

When trying to get details of a transaction through the PublicAPI grpc service, it throws 'Invalid Address'.

My node gets the following in debug logs:

2017-11-12 00:34:32,793 |synced| DEBUG : [PublicAPI] GetObject

JS Client gets this:

I20171112-11:34:32.785(11)? Error:  Invalid Address
I20171112-11:34:32.905(11)? Exception while invoking method 'getTxnHash' Error: Invalid Address
I20171112-11:34:32.906(11)?     at /Users/scottdonald/repos/qrl/scottdonaldau/qrl-wallet/node_modules/grpc/src/node/src/client.js:554:15

Test transaction hash: bade7769d112ea6d0cf5aabc9499383e9e024b0451ae80445657831a331508b8

See qrl-wallet issue for more info: theQRL/qrl-wallet#49

TypeError: 'NoneType' object is not subscriptable

Here is the log file with Raspberry Pi 3. https://transfer.sh/d805E/qrl.log

2017-10-26 20:49:24,860 |syncing| ERROR : Traceback (most recent call last):
  File "/home/pi/.local/lib/python3.5/site-packages/qrl/core/block.py", line 157, in validate_block
    if not self._validate_tx_in_block(chain):
  File "/home/pi/.local/lib/python3.5/site-packages/qrl/core/block.py", line 172, in _validate_tx_in_block
    valid = coinbase_txn.validate_extended(sv_list=sv_list, blockheader=self.blockheader)
  File "/home/pi/.local/lib/python3.5/site-packages/qrl/core/Transaction.py", line 478, in validate_extended
    if blockheader.blocknumber > 1 and sv_list[self.txto].slave_public_key != self.PK:
TypeError: 'NoneType' object is not subscriptable

Raspbian's version:

pi@raspberrypi:~/.qrl $ uname -a
Linux raspberrypi 4.9.41-v7+ #1023 SMP Tue Aug 8 16:00:15 BST 2017 armv7l GNU/Linux
pi@raspberrypi:~/.qrl $ lsb_release -a
No LSB modules are available.
Distributor ID: Raspbian
Description:    Raspbian GNU/Linux 9.1 (stretch)
Release:        9.1
Codename:       stretch

recoverfromhexseed gives CRITICAL : [TWISTED] Unhandled Error

Attempting to recover a wallet from hex seed gives the following error in telnet:

ubuntu@ip-172-31-23-129:~$ telnet localhost 2000
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
QRL node connection established. Try starting with "help" getinfo

Version: 0.52.2a
Uptime: 116.62990045547485
Nodes connected: 8
Staking set to: True
Sync status: synced
recoverfromhexseed 821cfa30e31b29beab2fd46fdca3d1495a6f29152887c668fa7f49fb9fca74852da675108ca37571010504bb1106e9c4
Connection closed by foreign host.

and in ~/.qrl/qrl.log output:

2017-10-02 23:22:03,947 |synced| INFO : >>> new local connection 1 IPv4Address(TCP, '127.0.0.1', 56234)
2017-10-02 23:22:25,761 |synced| INFO : >>>Received block from 104.251.219.215:9000 6213 Qada446e9ac25b11299e0615de8bd1b7f5404ce0052fbb27db7ada425904a5aea6063deb3
2017-10-02 23:22:25,766 |synced| INFO : BLOCK: 6210 epoch: 62 blocks_left: 89 nonce: 2 stake_selector Q7999ca133d82209ca4a3ad017998e7939d0422eea6cf4c9dac967dd76f2231556be4b56b
2017-10-02 23:22:25,769 |synced| INFO : 7de2798832f2cf90c27090ce7b62f983c7ebeae5d7713eb374d5c039e72acc62 1 tx passed verification.
2017-10-02 23:22:25,911 |synced| INFO : [ChainBuffer] Block #6213 added stake: Qada446e9ac25b11299e0615de8bd1b7f5404ce0052fbb27db7ada425904a5aea6063deb3
2017-10-02 23:22:54,490 |synced| CRITICAL : [TWISTED] Unhandled Error
Traceback (most recent call last):
File "/home/ubuntu/.local/lib/python3.5/site-packages/twisted/python/log.py", line 103, in callWithLogger
return callWithContext({"system": lp}, func, *args, **kw)
File "/home/ubuntu/.local/lib/python3.5/site-packages/twisted/python/log.py", line 86, in callWithContext
return context.call({ILogContext: newCtx}, func, *args, **kw)
File "/home/ubuntu/.local/lib/python3.5/site-packages/twisted/python/context.py", line 122, in callWithContext
return self.currentContext().callWithContext(ctx, func, *args, **kw)
File "/home/ubuntu/.local/lib/python3.5/site-packages/twisted/python/context.py", line 85, in callWithContext
return func(*args,**kw)
--- ---
File "/home/ubuntu/.local/lib/python3.5/site-packages/twisted/internet/posixbase.py", line 597, in _doReadOrWrite
why = selectable.doRead()
File "/home/ubuntu/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 208, in doRead
return self._dataReceived(data)
File "/home/ubuntu/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 214, in _dataReceived
rval = self.protocol.dataReceived(data)
File "/home/ubuntu/QRL/qrl/core/walletprotocol.py", line 340, in dataReceived
if not self.parse_cmd(self.parse(data)):
File "/home/ubuntu/QRL/qrl/core/walletprotocol.py", line 160, in parse_cmd
if not args or not hexseed_to_seed(args[0]):
File "/home/ubuntu/QRL/qrl/core/walletprotocol.py", line 21, in hexseed_to_seed
return hstr2bin(hex_seed)
builtins.TypeError: in method 'hstr2bin', argument 1 of type 'std::string const &'

Testnet or not testnet?

So I carefully read and applied the pdf, and got the node runnig in gentoo.
What bothers me, is that at the end of the pdf it is written to contact to get fake money. Is this wallet still a testnet wallet, or can I safely transfer some "real" quantas out of an exchange, and into that wallet?

[qrl wallet_ls] No wallet found at /xxx/xxx

when you use "qrl wallet_ls", it works only when you are in the "$HOME/.qrl/wallet".

pi@raspberrypi:~ $ qrl wallet_ls
No wallet found at /home/pi
pi@raspberrypi:~ $ cd .qrl/wallet/
pi@raspberrypi:~/.qrl/wallet $ qrl wallet_ls
Wallet at          : /home/pi/.qrl/wallet
Number  Address                                                                    Balance
-----------------------------------------------------------------------------------------------
0       Q1f009c3b5edef18531904e3d8c40ef108639f565f820751dcdf2970227cd264116165e04  100.00000000

Here is my pi3's information.

pi@raspberrypi:~ $ lsb_release -a
No LSB modules are available.
Distributor ID: Raspbian
Description:    Raspbian GNU/Linux 9.1 (stretch)
Release:        9.1
Codename:       stretch

Block validation failed - does this with each block (refers to min/max 615/617)

The following occurs for each block it attempts to fetch (min/max 615/617);

2017-10-24 18:29:09,581 |synced| INFO : Block validation failed
2017-10-24 18:29:09,581 |synced| INFO : Block #649
2017-10-24 18:29:09,581 |synced| INFO : Stake_selector b'Q0aafda6e082e072533194acebd0f6a82c38cfdca8aa562a317b4275676c93b1cb6988c8f'
2017-10-24 18:29:09,582 |synced| INFO : >>>Received block from 104.237.3.185:9000 650 b'Q05f82cfb3bec7ee85106022baf6e33ea78f257298bbc078275aa6a60c861887036ff6f69'
2017-10-24 18:29:09,582 |synced| ERROR : get_block_n blocknum not found in blocks 649
2017-10-24 18:29:09,582 |synced| ERROR : Min block num **615**
2017-10-24 18:29:09,582 |synced| ERROR : Max block num **617**
2017-10-24 18:29:09,583 |synced| ERROR : Traceback (most recent call last):
  File "/Users/propertydb/homebrew/lib/python3.6/site-packages/qrl/core/block.py", line 101, in validate_block
    if not self.blockheader.validate(last_block.blockheader):
AttributeError: 'NoneType' object has no attribute 'blockheader'

Crtitical Error withTwisted lib

2017-10-01 19:06:28,173 |synced| INFO : 104.251.219.215 peers data received: ['104.237.3.184', '104.251.219.145', '104.237.3.185', '104.251.219.40', '187.205.233.48', '75.8.77.11', '74.104.141.84', '108.226.196.132', '108.233.73.175', '192.222.211.183', '162.195.105.154', '187.149.33.128', '94.102.63.214', '91.7.178.160', '185.148.185.1'] 2017-10-01 19:06:28,332 |synced| INFO : >>>Blockheight from: 104.251.219.215 blockheight: 3699 local blockheight: 3799 1506877588.331957 2017-10-01 19:06:28,335 |synced| INFO : genesis pos countdown to block 1 begun, 60s until stake tx circulated.. 2017-10-01 19:06:28,340 |synced| INFO : 104.251.219.215 version: 0.52.1a | genesis prev_headerhash Cross-Breed-Testnet 2017-10-01 19:06:29,340 |synced| INFO : pre_pos_1 2017-10-01 19:06:29,365 |synced| CRITICAL : [TWISTED] Unhandled Error Traceback (most recent call last): File "start_qrl.py", line 13, in main() File "/home/pi/QRL/qrl/main.py", line 124, in main reactor.run() File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/base.py", line 1243, in run self.mainLoop() File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/base.py", line 1252, in mainLoop self.runUntilCurrent() --- --- File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/base.py", line 878, in runUntilCurrent call.func(*call.args, **call.kw) File "/home/pi/QRL/qrl/core/node.py", line 170, in pre_pos_1 if self.chain.mining_address not in self.chain.m_blockchain[0].stake_list: builtins.AttributeError: 'Block' object has no attribute 'stake_list'

Recovery of wallet address Bug

After recovery of a wallet address use the hex seed or recovery words, the wallet address starts working through the keys from the initial key pair. Thus, it will not pass any transactions until all the old keys are reused.
E.g. I used my address to send 60 transaction then started a new node. If I use the recover function I would have to attempt 60 transactions before I reach a new usable signature pair

The old chain seems to be loading after the hard fork

After the fork this is what I did (On a raspberry pi3, with python 3.6.0):
sudo pip3 uninstall qrl
sudo pip3 show qrl
Then it was empty, so uninstall seems to have worked.
Then:
sudo pip3 install -U qrl
start-qrl
It started loading, but even though the qrl block explorer says the last block is 1405, it loads past that number.

telnet: command crashes

When I use "getinfo" and "wallet" commands, I got following errors with the latest codebase.
Here is the log file's link. => https://transfer.sh/O1Nct/qrl.log

2017-10-09 13:32:55,932 |synced| INFO : >>> new local connection 1 IPv4Address(TCP, '127.0.0.1', 49186)
Unhandled Error
Traceback (most recent call last):
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 103, in callWithLogger
    return callWithContext({"system": lp}, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 86, in callWithContext
    return context.call({ILogContext: newCtx}, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 122, in callWithContext
    return self.currentContext().callWithContext(ctx, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 85, in callWithContext
    return func(*args,**kw)
--- <exception caught here> ---
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/posixbase.py", line 597, in _doReadOrWrite
    why = selectable.doRead()
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 208, in doRead
    return self._dataReceived(data)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 214, in _dataReceived
    rval = self.protocol.dataReceived(data)
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 98, in dataReceived
    if not self.parse_cmd(data):
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 78, in parse_cmd
    self.cmd_mapping[command](args)
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 345, in _wallet
    self.factory.state.state_read_chain(self.factory.chain)
  File "/home/pi/QRL/qrl/core/state.py", line 483, in state_read_chain
    self.zero_all_addresses()
  File "/home/pi/QRL/qrl/core/state.py", line 227, in zero_all_addresses
    self.db.Delete(address)
builtins.AttributeError: 'DB' object has no attribute 'Delete'

2017-10-09 13:32:59,137 |synced| CRITICAL : [TWISTED] Unhandled Error
Traceback (most recent call last):
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 103, in callWithLogger
    return callWithContext({"system": lp}, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 86, in callWithContext
    return context.call({ILogContext: newCtx}, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 122, in callWithContext
    return self.currentContext().callWithContext(ctx, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 85, in callWithContext
    return func(*args,**kw)
--- <exception caught here> ---
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/posixbase.py", line 597, in _doReadOrWrite
    why = selectable.doRead()
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 208, in doRead
    return self._dataReceived(data)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 214, in _dataReceived
    rval = self.protocol.dataReceived(data)
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 98, in dataReceived
    if not self.parse_cmd(data):
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 78, in parse_cmd
    self.cmd_mapping[command](args)
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 345, in _wallet
    self.factory.state.state_read_chain(self.factory.chain)
  File "/home/pi/QRL/qrl/core/state.py", line 483, in state_read_chain
    self.zero_all_addresses()
  File "/home/pi/QRL/qrl/core/state.py", line 227, in zero_all_addresses
    self.db.Delete(address)
builtins.AttributeError: 'DB' object has no attribute 'Delete'

2017-10-09 13:33:01,081 |synced| INFO : >>> new local connection 1 IPv4Address(TCP, '127.0.0.1', 49190)
Unhandled Error
Traceback (most recent call last):
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 103, in callWithLogger
    return callWithContext({"system": lp}, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 86, in callWithContext
    return context.call({ILogContext: newCtx}, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 122, in callWithContext
    return self.currentContext().callWithContext(ctx, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 85, in callWithContext
    return func(*args,**kw)
--- <exception caught here> ---
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/posixbase.py", line 597, in _doReadOrWrite
    why = selectable.doRead()
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 208, in doRead
    return self._dataReceived(data)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 214, in _dataReceived
    rval = self.protocol.dataReceived(data)
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 98, in dataReceived
    if not self.parse_cmd(data):
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 78, in parse_cmd
    self.cmd_mapping[command](args)
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 551, in _getinfo
    self.output['message'].write('>>> Version: ' + self.factory.chain.version_number + '\r\n')
builtins.AttributeError: 'Chain' object has no attribute 'version_number'

2017-10-09 13:33:04,076 |synced| CRITICAL : [TWISTED] Unhandled Error
Traceback (most recent call last):
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 103, in callWithLogger
    return callWithContext({"system": lp}, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 86, in callWithContext
    return context.call({ILogContext: newCtx}, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 122, in callWithContext
    return self.currentContext().callWithContext(ctx, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 85, in callWithContext
    return func(*args,**kw)
--- <exception caught here> ---
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/posixbase.py", line 597, in _doReadOrWrite
    why = selectable.doRead()
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 208, in doRead
    return self._dataReceived(data)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 214, in _dataReceived
    rval = self.protocol.dataReceived(data)
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 98, in dataReceived
    if not self.parse_cmd(data):
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 78, in parse_cmd
    self.cmd_mapping[command](args)
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 551, in _getinfo
    self.output['message'].write('>>> Version: ' + self.factory.chain.version_number + '\r\n')
builtins.AttributeError: 'Chain' object has no attribute 'version_number'

2017-10-09 13:33:05,918 |synced| INFO : >>> new local connection 1 IPv4Address(TCP, '127.0.0.1', 49194)
Unhandled Error
Traceback (most recent call last):
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 103, in callWithLogger
    return callWithContext({"system": lp}, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 86, in callWithContext
    return context.call({ILogContext: newCtx}, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 122, in callWithContext
    return self.currentContext().callWithContext(ctx, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 85, in callWithContext
    return func(*args,**kw)
--- <exception caught here> ---
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/posixbase.py", line 597, in _doReadOrWrite
    why = selectable.doRead()
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 208, in doRead
    return self._dataReceived(data)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 214, in _dataReceived
    rval = self.protocol.dataReceived(data)
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 98, in dataReceived
    if not self.parse_cmd(data):
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 78, in parse_cmd
    self.cmd_mapping[command](args)
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 541, in _listaddresses
    addresses, num_sigs, types = self.factory.chain.wallet.inspect_wallet()
builtins.AttributeError: 'Wallet' object has no attribute 'inspect_wallet'

2017-10-09 13:33:20,576 |synced| CRITICAL : [TWISTED] Unhandled Error
Traceback (most recent call last):
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 103, in callWithLogger
    return callWithContext({"system": lp}, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 86, in callWithContext
    return context.call({ILogContext: newCtx}, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 122, in callWithContext
    return self.currentContext().callWithContext(ctx, func, *args, **kw)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 85, in callWithContext
    return func(*args,**kw)
--- <exception caught here> ---
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/posixbase.py", line 597, in _doReadOrWrite
    why = selectable.doRead()
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 208, in doRead
    return self._dataReceived(data)
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 214, in _dataReceived
    rval = self.protocol.dataReceived(data)
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 98, in dataReceived
    if not self.parse_cmd(data):
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 78, in parse_cmd
    self.cmd_mapping[command](args)
  File "/home/pi/QRL/qrl/core/walletprotocol.py", line 541, in _listaddresses
    addresses, num_sigs, types = self.factory.chain.wallet.inspect_wallet()
builtins.AttributeError: 'Wallet' object has no attribute 'inspect_wallet'

0.52.2a wallet command crashes again, leads to block rejected

fresh codebase git pull
command wallet during sync leads to following new error
shortly after a block was rejected

2017-10-07 18:17:26,965 |syncing| INFO : <<<Fetching block: 120 from 104.237.3.185:9000
2017-10-07 18:17:27,096 |syncing| CRITICAL : [TWISTED] Unhandled Error
Traceback (most recent call last):
File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 103, in callWithLogger
return callWithContext({"system": lp}, func, *args, **kw)
File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/log.py", line 86, in callWithContext
return context.call({ILogContext: newCtx}, func, *args, **kw)
File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 122, in callWithContext
return self.currentContext().callWithContext(ctx, func, *args, **kw)
File "/home/pi/.local/lib/python3.5/site-packages/twisted/python/context.py", line 85, in callWithContext
return func(*args,**kw)
--- ---
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/posixbase.py", line 597, in _doReadOrWrite
why = selectable.doRead()
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 208, in doRead
return self._dataReceived(data)
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/tcp.py", line 214, in _dataReceived
rval = self.protocol.dataReceived(data)
File "/home/pi/QRL/qrl/core/walletprotocol.py", line 97, in dataReceived
if not self.parse_cmd(data):
File "/home/pi/QRL/qrl/core/walletprotocol.py", line 78, in parse_cmd
self.cmd_mappingcommand
File "/home/pi/QRL/qrl/core/walletprotocol.py", line 344, in _wallet
self.factory.state.state_read_chain(self.factory.chain)
File "/home/pi/QRL/qrl/core/state.py", line 486, in state_read_chain
c = chain.m_get_block(0).state
File "/home/pi/QRL/qrl/core/chain.py", line 481, in m_get_block
return self.load_from_file(n)
File "/home/pi/QRL/qrl/core/chain.py", line 665, in load_from_file
pos, size = pos_size.decode('utf-8').split(',')
builtins.ValueError: too many values to unpack (expected 2)

2017-10-07 18:17:27,407 |syncing| INFO : >>> Received Block #120

BLOCK reject error:
2017-10-07 18:17:27,407 |syncing| INFO : >>> Received Block #120
2017-10-07 18:17:27,497 |syncing| INFO : BLOCK: 120 epoch: 1 blocks_left: 79 nonce: 2 stake_selector Q871011bfa3d8fb9e41c8b59904a116c31a028bab1eadcf5711e64b3445869034d6769cab
2017-10-07 18:17:27,503 |syncing| INFO : d08c3daa75a524eaeee2e3da04e8c0db98f7400089bab839a1520117c5e710da 1 tx passed verification.
2017-10-07 18:17:27,521 |syncing| ERROR : block rejected - unable to decode serialised data 104.237.3.185
2017-10-07 18:17:27,544 |syncing| ERROR : Traceback (most recent call last):
File "/home/pi/QRL/qrl/core/p2pprotocol.py", line 430, in PB
if not self.factory.chain.add_block_mainchain(block):
File "/home/pi/QRL/qrl/core/chain.py", line 465, in add_block_mainchain
validate=validate)
File "/home/pi/QRL/qrl/core/ChainBuffer.py", line 190, in add_block_mainchain
chain.update_tx_metadata(block)
File "/home/pi/QRL/qrl/core/chain.py", line 447, in update_tx_metadata
self.update_txn_count(txn.txto, txn.txfrom)
File "/home/pi/QRL/qrl/core/chain.py", line 429, in update_txn_count
self.state.db.put('txn_count_' + txto, last_count + 1)
TypeError: can only concatenate list (not "int") to list

2017-10-07 18:18:04,468 |syncing| WARNING : verify_BK_hash Failed due to prevheaderhash mismatch, blockslen 0

"No package 'libffi' found" error during "pip3 install -r requirements.txt" on Raspberry Pi3

When I tried to sudo pip3 install -r requirements.txt , I got an error saying "Package libffi was not found."
RP3 users should install libffi-dev, like $ sudo apt-get install libffi-dev IMO.

Logs are followings:

pi@raspberrypi:~/QRL $ lsb_release -a
No LSB modules are available.
Distributor ID: Raspbian
Description:    Raspbian GNU/Linux 9.1 (stretch)
Release:        9.1
Codename:       stretch
pi@raspberrypi:~/QRL $ uname -a
Linux raspberrypi 4.9.41-v7+ #1023 SMP Tue Aug 8 16:00:15 BST 2017 armv7l GNU/Linux
pi@raspberrypi:~/QRL $ sudo pip3 install -r requirements.txt
Requirement already satisfied: jsonpickle>=0.9.5 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 2))
Requirement already satisfied: leveldb>=0.19 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 3))
Requirement already satisfied: statistics>=1.0.3.5 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 4))
Requirement already satisfied: ntplib>=0.3.3 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 5))
Requirement already satisfied: Twisted==17.5.0 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 6))
Requirement already satisfied: colorlog>=3.0.1 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 7))
Requirement already satisfied: simplejson>=3.11.1 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 8))
Requirement already satisfied: PyYAML==3.12 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 9))
Collecting service_identity (from -r requirements.txt (line 10))
  Using cached service_identity-17.0.0-py2.py3-none-any.whl
Collecting pyopenssl>=17.3.0 (from -r requirements.txt (line 11))
  Using cached pyOpenSSL-17.3.0-py2.py3-none-any.whl
Requirement already satisfied: pyqrllib>=0.1.20 in /usr/local/lib/python3.5/dist-packages (from -r requirements.txt (line 12))
Requirement already satisfied: docutils>=0.3 in /usr/local/lib/python3.5/dist-packages (from statistics>=1.0.3.5->-r requirements.txt (line 4))
Requirement already satisfied: constantly>=15.1 in /usr/local/lib/python3.5/dist-packages (from Twisted==17.5.0->-r requirements.txt (line 6))
Requirement already satisfied: zope.interface>=4.0.2 in /usr/local/lib/python3.5/dist-packages (from Twisted==17.5.0->-r requirements.txt (line 6))
Requirement already satisfied: Automat>=0.3.0 in /usr/local/lib/python3.5/dist-packages (from Twisted==17.5.0->-r requirements.txt (line 6))
Requirement already satisfied: incremental>=16.10.1 in /usr/local/lib/python3.5/dist-packages (from Twisted==17.5.0->-r requirements.txt (line 6))
Requirement already satisfied: hyperlink>=17.1.1 in /usr/local/lib/python3.5/dist-packages (from Twisted==17.5.0->-r requirements.txt (line 6))
Requirement already satisfied: attrs in /usr/local/lib/python3.5/dist-packages (from service_identity->-r requirements.txt (line 10))
Requirement already satisfied: pyasn1-modules in /usr/local/lib/python3.5/dist-packages (from service_identity->-r requirements.txt (line 10))
Requirement already satisfied: pyasn1 in /usr/lib/python3/dist-packages (from service_identity->-r requirements.txt (line 10))
Collecting cryptography>=1.9 (from pyopenssl>=17.3.0->-r requirements.txt (line 11))
  Using cached cryptography-2.0.3.tar.gz
Requirement already satisfied: six>=1.5.2 in /usr/lib/python3/dist-packages (from pyopenssl>=17.3.0->-r requirements.txt (line 11))
Requirement already satisfied: scikit-build in /usr/local/lib/python3.5/dist-packages (from pyqrllib>=0.1.20->-r requirements.txt (line 12))
Requirement already satisfied: setuptools in /usr/local/lib/python3.5/dist-packages (from zope.interface>=4.0.2->Twisted==17.5.0->-r requirements.txt (line 6))
Requirement already satisfied: idna>=2.1 in /usr/lib/python3/dist-packages (from cryptography>=1.9->pyopenssl>=17.3.0->-r requirements.txt (line 11))
Requirement already satisfied: asn1crypto>=0.21.0 in /usr/local/lib/python3.5/dist-packages (from cryptography>=1.9->pyopenssl>=17.3.0->-r requirements.txt (line 11))
Collecting cffi>=1.7 (from cryptography>=1.9->pyopenssl>=17.3.0->-r requirements.txt (line 11))
  Using cached cffi-1.11.0.tar.gz
Requirement already satisfied: wheel>=0.29.0 in /usr/local/lib/python3.5/dist-packages (from scikit-build->pyqrllib>=0.1.20->-r requirements.txt (line 12))
Requirement already satisfied: pycparser in /usr/local/lib/python3.5/dist-packages (from cffi>=1.7->cryptography>=1.9->pyopenssl>=17.3.0->-r requirements.txt (line 11))
Building wheels for collected packages: cryptography, cffi
  Running setup.py bdist_wheel for cryptography ... error
  Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-vsmjkw98/cryptography/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/tmp9_g1_6xopip-wheel- --python-tag cp35:
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  c/_cffi_backend.c:15:17: fatal error: ffi.h: そのようなファイルやディレクトリはありません
   #include <ffi.h>
                   ^
  compilation terminated.
  Traceback (most recent call last):
    File "/usr/lib/python3.5/distutils/unixccompiler.py", line 118, in _compile
      extra_postargs)
    File "/usr/lib/python3.5/distutils/ccompiler.py", line 909, in spawn
      spawn(cmd, dry_run=self.dry_run)
    File "/usr/lib/python3.5/distutils/spawn.py", line 36, in spawn
      _spawn_posix(cmd, search_path, dry_run=dry_run)
    File "/usr/lib/python3.5/distutils/spawn.py", line 159, in _spawn_posix
      % (cmd, exit_status))
  distutils.errors.DistutilsExecError: command 'arm-linux-gnueabihf-gcc' failed with exit status 1

  During handling of the above exception, another exception occurred:

  Traceback (most recent call last):
    File "/usr/lib/python3.5/distutils/core.py", line 148, in setup
      dist.run_commands()
    File "/usr/lib/python3.5/distutils/dist.py", line 955, in run_commands
      self.run_command(cmd)
    File "/usr/lib/python3.5/distutils/dist.py", line 974, in run_command
      cmd_obj.run()
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/bdist_egg.py", line 169, in run
      cmd = self.call_command('install_lib', warn_dir=0)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/bdist_egg.py", line 155, in call_command
      self.run_command(cmdname)
    File "/usr/lib/python3.5/distutils/cmd.py", line 313, in run_command
      self.distribution.run_command(command)
    File "/usr/lib/python3.5/distutils/dist.py", line 974, in run_command
      cmd_obj.run()
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/install_lib.py", line 11, in run
      self.build()
    File "/usr/lib/python3.5/distutils/command/install_lib.py", line 109, in build
      self.run_command('build_ext')
    File "/usr/lib/python3.5/distutils/cmd.py", line 313, in run_command
      self.distribution.run_command(command)
    File "/usr/lib/python3.5/distutils/dist.py", line 974, in run_command
      cmd_obj.run()
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/build_ext.py", line 75, in run
      _build_ext.run(self)
    File "/usr/lib/python3.5/distutils/command/build_ext.py", line 339, in run
      self.build_extensions()
    File "/usr/lib/python3.5/distutils/command/build_ext.py", line 448, in build_extensions
      self._build_extensions_serial()
    File "/usr/lib/python3.5/distutils/command/build_ext.py", line 473, in _build_extensions_serial
      self.build_extension(ext)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/build_ext.py", line 196, in build_extension
      _build_ext.build_extension(self, ext)
    File "/usr/lib/python3.5/distutils/command/build_ext.py", line 533, in build_extension
      depends=ext.depends)
    File "/usr/lib/python3.5/distutils/ccompiler.py", line 574, in compile
      self._compile(obj, src, ext, cc_args, extra_postargs, pp_opts)
    File "/usr/lib/python3.5/distutils/unixccompiler.py", line 120, in _compile
      raise CompileError(msg)
  distutils.errors.CompileError: command 'arm-linux-gnueabihf-gcc' failed with exit status 1

  During handling of the above exception, another exception occurred:

  Traceback (most recent call last):
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 158, in save_modules
      yield saved
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 199, in setup_context
      yield
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 254, in run_setup
      _execfile(setup_script, ns)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 49, in _execfile
      exec(code, globals, locals)
    File "/tmp/easy_install-31x93kpv/cffi-1.11.0/setup.py", line 235, in <module>

    File "/usr/lib/python3.5/distutils/core.py", line 163, in setup
      raise SystemExit("error: " + str(msg))
  SystemExit: error: command 'arm-linux-gnueabihf-gcc' failed with exit status 1

  During handling of the above exception, another exception occurred:

  Traceback (most recent call last):
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/easy_install.py", line 1104, in run_setup
      run_setup(setup_script, args)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 257, in run_setup
      raise
    File "/usr/lib/python3.5/contextlib.py", line 77, in __exit__
      self.gen.throw(type, value, traceback)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 199, in setup_context
      yield
    File "/usr/lib/python3.5/contextlib.py", line 77, in __exit__
      self.gen.throw(type, value, traceback)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 170, in save_modules
      saved_exc.resume()
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 145, in resume
      six.reraise(type, exc, self._tb)
    File "/usr/local/lib/python3.5/dist-packages/pkg_resources/_vendor/six.py", line 685, in reraise
      raise value.with_traceback(tb)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 158, in save_modules
      yield saved
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 199, in setup_context
      yield
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 254, in run_setup
      _execfile(setup_script, ns)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 49, in _execfile
      exec(code, globals, locals)
    File "/tmp/easy_install-31x93kpv/cffi-1.11.0/setup.py", line 235, in <module>

    File "/usr/lib/python3.5/distutils/core.py", line 163, in setup
      raise SystemExit("error: " + str(msg))
  SystemExit: error: command 'arm-linux-gnueabihf-gcc' failed with exit status 1

  During handling of the above exception, another exception occurred:

  Traceback (most recent call last):
    File "<string>", line 1, in <module>
    File "/tmp/pip-build-vsmjkw98/cryptography/setup.py", line 312, in <module>
      **keywords_with_side_effects(sys.argv)
    File "/usr/lib/python3.5/distutils/core.py", line 108, in setup
      _setup_distribution = dist = klass(attrs)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/dist.py", line 335, in __init__
      self.fetch_build_eggs(attrs['setup_requires'])
    File "/usr/local/lib/python3.5/dist-packages/setuptools/dist.py", line 456, in fetch_build_eggs
      replace_conflicting=True,
    File "/usr/local/lib/python3.5/dist-packages/pkg_resources/__init__.py", line 863, in resolve
      replace_conflicting=replace_conflicting
    File "/usr/local/lib/python3.5/dist-packages/pkg_resources/__init__.py", line 1141, in best_match
      return self.obtain(req, installer)
    File "/usr/local/lib/python3.5/dist-packages/pkg_resources/__init__.py", line 1153, in obtain
      return installer(requirement)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/dist.py", line 522, in fetch_build_egg
      return cmd.easy_install(req)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/easy_install.py", line 672, in easy_install
      return self.install_item(spec, dist.location, tmpdir, deps)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/easy_install.py", line 698, in install_item
      dists = self.install_eggs(spec, download, tmpdir)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/easy_install.py", line 879, in install_eggs
      return self.build_and_install(setup_script, setup_base)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/easy_install.py", line 1118, in build_and_install
      self.run_setup(setup_script, setup_base, args)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/easy_install.py", line 1106, in run_setup
      raise DistutilsError("Setup script exited with %s" % (v.args[0],))
  distutils.errors.DistutilsError: Setup script exited with error: command 'arm-linux-gnueabihf-gcc' failed with exit status 1

  ----------------------------------------
  Failed building wheel for cryptography
  Running setup.py clean for cryptography
  Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-vsmjkw98/cryptography/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" clean --all:
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  c/_cffi_backend.c:15:17: fatal error: ffi.h: そのようなファイルやディレクトリはありません
   #include <ffi.h>
                   ^
  compilation terminated.
  Traceback (most recent call last):
    File "/usr/lib/python3.5/distutils/unixccompiler.py", line 118, in _compile
      extra_postargs)
    File "/usr/lib/python3.5/distutils/ccompiler.py", line 909, in spawn
      spawn(cmd, dry_run=self.dry_run)
    File "/usr/lib/python3.5/distutils/spawn.py", line 36, in spawn
      _spawn_posix(cmd, search_path, dry_run=dry_run)
    File "/usr/lib/python3.5/distutils/spawn.py", line 159, in _spawn_posix
      % (cmd, exit_status))
  distutils.errors.DistutilsExecError: command 'arm-linux-gnueabihf-gcc' failed with exit status 1

  During handling of the above exception, another exception occurred:

  Traceback (most recent call last):
    File "/usr/lib/python3.5/distutils/core.py", line 148, in setup
      dist.run_commands()
    File "/usr/lib/python3.5/distutils/dist.py", line 955, in run_commands
      self.run_command(cmd)
    File "/usr/lib/python3.5/distutils/dist.py", line 974, in run_command
      cmd_obj.run()
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/bdist_egg.py", line 169, in run
      cmd = self.call_command('install_lib', warn_dir=0)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/bdist_egg.py", line 155, in call_command
      self.run_command(cmdname)
    File "/usr/lib/python3.5/distutils/cmd.py", line 313, in run_command
      self.distribution.run_command(command)
    File "/usr/lib/python3.5/distutils/dist.py", line 974, in run_command
      cmd_obj.run()
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/install_lib.py", line 11, in run
      self.build()
    File "/usr/lib/python3.5/distutils/command/install_lib.py", line 109, in build
      self.run_command('build_ext')
    File "/usr/lib/python3.5/distutils/cmd.py", line 313, in run_command
      self.distribution.run_command(command)
    File "/usr/lib/python3.5/distutils/dist.py", line 974, in run_command
      cmd_obj.run()
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/build_ext.py", line 75, in run
      _build_ext.run(self)
    File "/usr/lib/python3.5/distutils/command/build_ext.py", line 339, in run
      self.build_extensions()
    File "/usr/lib/python3.5/distutils/command/build_ext.py", line 448, in build_extensions
      self._build_extensions_serial()
    File "/usr/lib/python3.5/distutils/command/build_ext.py", line 473, in _build_extensions_serial
      self.build_extension(ext)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/build_ext.py", line 196, in build_extension
      _build_ext.build_extension(self, ext)
    File "/usr/lib/python3.5/distutils/command/build_ext.py", line 533, in build_extension
      depends=ext.depends)
    File "/usr/lib/python3.5/distutils/ccompiler.py", line 574, in compile
      self._compile(obj, src, ext, cc_args, extra_postargs, pp_opts)
    File "/usr/lib/python3.5/distutils/unixccompiler.py", line 120, in _compile
      raise CompileError(msg)
  distutils.errors.CompileError: command 'arm-linux-gnueabihf-gcc' failed with exit status 1

  During handling of the above exception, another exception occurred:

  Traceback (most recent call last):
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 158, in save_modules
      yield saved
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 199, in setup_context
      yield
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 254, in run_setup
      _execfile(setup_script, ns)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 49, in _execfile
      exec(code, globals, locals)
    File "/tmp/easy_install-hvqq8nwp/cffi-1.11.0/setup.py", line 235, in <module>

    File "/usr/lib/python3.5/distutils/core.py", line 163, in setup
      raise SystemExit("error: " + str(msg))
  SystemExit: error: command 'arm-linux-gnueabihf-gcc' failed with exit status 1

  During handling of the above exception, another exception occurred:

  Traceback (most recent call last):
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/easy_install.py", line 1104, in run_setup
      run_setup(setup_script, args)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 257, in run_setup
      raise
    File "/usr/lib/python3.5/contextlib.py", line 77, in __exit__
      self.gen.throw(type, value, traceback)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 199, in setup_context
      yield
    File "/usr/lib/python3.5/contextlib.py", line 77, in __exit__
      self.gen.throw(type, value, traceback)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 170, in save_modules
      saved_exc.resume()
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 145, in resume
      six.reraise(type, exc, self._tb)
    File "/usr/local/lib/python3.5/dist-packages/pkg_resources/_vendor/six.py", line 685, in reraise
      raise value.with_traceback(tb)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 158, in save_modules
      yield saved
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 199, in setup_context
      yield
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 254, in run_setup
      _execfile(setup_script, ns)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/sandbox.py", line 49, in _execfile
      exec(code, globals, locals)
    File "/tmp/easy_install-hvqq8nwp/cffi-1.11.0/setup.py", line 235, in <module>

    File "/usr/lib/python3.5/distutils/core.py", line 163, in setup
      raise SystemExit("error: " + str(msg))
  SystemExit: error: command 'arm-linux-gnueabihf-gcc' failed with exit status 1

  During handling of the above exception, another exception occurred:

  Traceback (most recent call last):
    File "<string>", line 1, in <module>
    File "/tmp/pip-build-vsmjkw98/cryptography/setup.py", line 312, in <module>
      **keywords_with_side_effects(sys.argv)
    File "/usr/lib/python3.5/distutils/core.py", line 108, in setup
      _setup_distribution = dist = klass(attrs)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/dist.py", line 335, in __init__
      self.fetch_build_eggs(attrs['setup_requires'])
    File "/usr/local/lib/python3.5/dist-packages/setuptools/dist.py", line 456, in fetch_build_eggs
      replace_conflicting=True,
    File "/usr/local/lib/python3.5/dist-packages/pkg_resources/__init__.py", line 863, in resolve
      replace_conflicting=replace_conflicting
    File "/usr/local/lib/python3.5/dist-packages/pkg_resources/__init__.py", line 1141, in best_match
      return self.obtain(req, installer)
    File "/usr/local/lib/python3.5/dist-packages/pkg_resources/__init__.py", line 1153, in obtain
      return installer(requirement)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/dist.py", line 522, in fetch_build_egg
      return cmd.easy_install(req)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/easy_install.py", line 672, in easy_install
      return self.install_item(spec, dist.location, tmpdir, deps)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/easy_install.py", line 698, in install_item
      dists = self.install_eggs(spec, download, tmpdir)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/easy_install.py", line 879, in install_eggs
      return self.build_and_install(setup_script, setup_base)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/easy_install.py", line 1118, in build_and_install
      self.run_setup(setup_script, setup_base, args)
    File "/usr/local/lib/python3.5/dist-packages/setuptools/command/easy_install.py", line 1106, in run_setup
      raise DistutilsError("Setup script exited with %s" % (v.args[0],))
  distutils.errors.DistutilsError: Setup script exited with error: command 'arm-linux-gnueabihf-gcc' failed with exit status 1

  ----------------------------------------
  Failed cleaning build dir for cryptography
  Running setup.py bdist_wheel for cffi ... error
  Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-vsmjkw98/cffi/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/tmp0wt6b0lopip-wheel- --python-tag cp35:
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  Package libffi was not found in the pkg-config search path.
  Perhaps you should add the directory containing `libffi.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'libffi' found
  running bdist_wheel
  running build
  running build_py
  creating build
  creating build/lib.linux-armv7l-3.5
  creating build/lib.linux-armv7l-3.5/cffi
  copying cffi/cffi_opcode.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/vengine_cpy.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/__init__.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/error.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/recompiler.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/commontypes.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/cparser.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/vengine_gen.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/lock.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/ffiplatform.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/model.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/api.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/verifier.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/setuptools_ext.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/backend_ctypes.py -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/_cffi_include.h -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/parse_c_type.h -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/_embedding.h -> build/lib.linux-armv7l-3.5/cffi
  copying cffi/_cffi_errors.h -> build/lib.linux-armv7l-3.5/cffi
  running build_ext
  building '_cffi_backend' extension
  creating build/temp.linux-armv7l-3.5
  creating build/temp.linux-armv7l-3.5/c
  arm-linux-gnueabihf-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -g -fdebug-prefix-map=/build/python3.5-RUbMX3/python3.5-3.5.3=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DUSE__THREAD -DHAVE_SYNC_SYNCHRONIZE -I/usr/include/ffi -I/usr/include/libffi -I/usr/include/python3.5m -c c/_cffi_backend.c -o build/temp.linux-armv7l-3.5/c/_cffi_backend.o
  c/_cffi_backend.c:15:17: fatal error: ffi.h: そのようなファイルやディレクトリはありません
   #include <ffi.h>
                   ^
  compilation terminated.
  error: command 'arm-linux-gnueabihf-gcc' failed with exit status 1

  ----------------------------------------
  Failed building wheel for cffi
  Running setup.py clean for cffi
Failed to build cryptography cffi
Installing collected packages: cffi, cryptography, pyopenssl, service-identity
  Running setup.py install for cffi ... error
    Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-vsmjkw98/cffi/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-lrxmya2_-record/install-record.txt --single-version-externally-managed --compile:
    Package libffi was not found in the pkg-config search path.
    Perhaps you should add the directory containing `libffi.pc'
    to the PKG_CONFIG_PATH environment variable
    No package 'libffi' found
    Package libffi was not found in the pkg-config search path.
    Perhaps you should add the directory containing `libffi.pc'
    to the PKG_CONFIG_PATH environment variable
    No package 'libffi' found
    Package libffi was not found in the pkg-config search path.
    Perhaps you should add the directory containing `libffi.pc'
    to the PKG_CONFIG_PATH environment variable
    No package 'libffi' found
    Package libffi was not found in the pkg-config search path.
    Perhaps you should add the directory containing `libffi.pc'
    to the PKG_CONFIG_PATH environment variable
    No package 'libffi' found
    Package libffi was not found in the pkg-config search path.
    Perhaps you should add the directory containing `libffi.pc'
    to the PKG_CONFIG_PATH environment variable
    No package 'libffi' found
    running install
    running build
    running build_py
    creating build
    creating build/lib.linux-armv7l-3.5
    creating build/lib.linux-armv7l-3.5/cffi
    copying cffi/cffi_opcode.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/vengine_cpy.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/__init__.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/error.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/recompiler.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/commontypes.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/cparser.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/vengine_gen.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/lock.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/ffiplatform.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/model.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/api.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/verifier.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/setuptools_ext.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/backend_ctypes.py -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/_cffi_include.h -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/parse_c_type.h -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/_embedding.h -> build/lib.linux-armv7l-3.5/cffi
    copying cffi/_cffi_errors.h -> build/lib.linux-armv7l-3.5/cffi
    running build_ext
    building '_cffi_backend' extension
    creating build/temp.linux-armv7l-3.5
    creating build/temp.linux-armv7l-3.5/c
    arm-linux-gnueabihf-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -g -fdebug-prefix-map=/build/python3.5-RUbMX3/python3.5-3.5.3=. -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DUSE__THREAD -DHAVE_SYNC_SYNCHRONIZE -I/usr/include/ffi -I/usr/include/libffi -I/usr/include/python3.5m -c c/_cffi_backend.c -o build/temp.linux-armv7l-3.5/c/_cffi_backend.o
    c/_cffi_backend.c:15:17: fatal error: ffi.h: そのようなファイルやディレクトリはありません
     #include <ffi.h>
                     ^
    compilation terminated.
    error: command 'arm-linux-gnueabihf-gcc' failed with exit status 1

    ----------------------------------------
Command "/usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-vsmjkw98/cffi/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-lrxmya2_-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-vsmjkw98/cffi/

0.52.2a fresh node has high chance to create forked blockchain

  • create node with fresh codebase and fresh wallet adress
  • load chain up to blockheight 7327 and node changed to status "synced"
  • since block 7443 my node forked
  • currently blockheight is 7563
    i checked git pull again and is still actual codebase

I noticed this "fork behavior" at least 3 times.

Installation on Fedora 25 within qubes.

Hi - I cant seem to install QRL, I have attempted to install dependencies but this fails:

[user@software ~]$ sudo dnf -y install swit3.0 python3-dev python3-pip build-essential cmake pkg-config libssl-dev libffi-dev

Qubes OS Repository for VM (updates) 207 kB/s | 529 kB 00:02
RPM Fusion for Fedora 23 - Free 726 kB/s | 457 kB 00:00
No package swit3.0 available.
No package python3-dev available.
Package python3-pip-7.1.0-1.fc23.noarch is already installed, skipping.
No package build-essential available.
No package pkg-config available.
No package libssl-dev available.
No package libffi-dev available.
Error: Unable to find a match.

Edit: Upgraded to fedora 25 per the recommendation from qubes here, retried above to same result.
Edit: Solved. Install on Debian instead of Fedora if running Qubes - instructions in the comments.

|synced| CRITICAL : [TWISTED] Unhandled Error, and one more

I got this error, and after a while got another one.

The first one:

2017-10-07 16:54:38,137 |synced| CRITICAL : [TWISTED] Unhandled Error
Traceback (most recent call last):
  File "start_qrl.py", line 13, in <module>
    main()
  File "/home/pi/QRL/qrl/main.py", line 136, in main
    reactor.run()
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/base.py", line 1243, in run
    self.mainLoop()
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/base.py", line 1252, in mainLoop
    self.runUntilCurrent()
--- <exception caught here> ---
  File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/base.py", line 878, in runUntilCurrent
    call.func(*call.args, **call.kw)
  File "/home/pi/QRL/qrl/core/node.py", line 519, in post_block_logic
    self.create_next_block(blocknumber)
  File "/home/pi/QRL/qrl/core/node.py", line 473, in create_next_block
    blocknumber - 1)
  File "/home/pi/QRL/qrl/core/node.py", line 284, in create_new_block
    block_obj = self.chain.create_stake_block(reveal_hash, vote_hash, last_block_number)
  File "/home/pi/QRL/qrl/core/chain.py", line 272, in create_stake_block
    block_obj = self.m_create_block(reveal_hash, vote_hash, last_block_number)
  File "/home/pi/QRL/qrl/core/chain.py", line 498, in m_create_block
    self.wallet.save_slave(slave_xmss)
  File "/home/pi/QRL/qrl/core/wallet.py", line 60, in save_slave
    outfile.write(w.SerializeToString())
builtins.TypeError: write() argument must be str, not bytes

The second one:

2017-10-07 23:37:25,646 |syncing| INFO : <<<Fetching block: 14543 from 144.217.5.9:9000
2017-10-07 23:37:26,901 |syncing| INFO : >>> Received Block #14543
2017-10-07 23:36:06,606 |syncing| ERROR : Traceback (most recent call last):
  File "/home/pi/QRL/qrl/core/block.py", line 90, in validate_block
    if not self.blockheader.validate(last_block.blockheader):
AttributeError: 'list' object has no attribute 'blockheader'

2017-10-07 23:36:06,609 |syncing| INFO : m_add_block failed - block failed validation.
2017-10-07 23:36:06,611 |syncing| INFO : Failed to add block by m_add_block, re-requesting the block #14543

Here is the log file.
https://transfer.sh/eAXmF/qrl.log

0.53.1a p2pprotocol, multiple error for blocknumber

2017-10-14 23:35:30,792 |synced| DEBUG : Sending PING to 158.69.79.24:9000
2017-10-14 23:35:30,885 |synced| INFO : >>>Received block from 104.237.3.185:9000 5916 Q321551228be4c8275bc3a2665347f4b399216268bf6a704c6fd5ced5666c117105f82613
2017-10-14 23:35:31,144 |synced| DEBUG : BLOCK: 5913 epoch: 59 blocks_left: 86 nonce: 2 stake_selector Q1164abe0aeb3d8026986309ecadace30b45e0def644ecb0ba71e3491a2e8a5ab408f69dc
2017-10-14 23:35:31,264 |synced| DEBUG : 7b2f035f7422910194e9e648062582a6c847e3188688b205a9bb6abf8c7816ea 2 tx passed verification.
2017-10-14 23:35:34,482 |synced| INFO : [ChainBuffer] Block #5916 added stake: Q321551228be4c8275bc3a2665347f4b399216268bf6a704c6fd5ced5666c117105f82613
2017-10-14 23:35:34,741 |synced| DEBUG : Received PONG from 104.237.3.185:9000
2017-10-14 23:35:34,744 |synced| DEBUG : Sending PING to 52.220.119.253:9000
2017-10-14 23:35:34,796 |synced| ERROR : executing [PBHL]
2017-10-14 23:35:34,799 |synced| ERROR : Traceback (most recent call last):
File "/home/pi/QRL/qrl/core/p2pprotocol.py", line 82, in parse_msg
func()
TypeError: PBHL() missing 1 required positional argument: 'blocknumber'

2017-10-14 23:35:35,518 |synced| DEBUG : Received PONG from 104.237.3.184:9000
2017-10-14 23:35:49,256 |synced| INFO : <<<Sending blockheight and headerhash to: 77.59.180.49 1508016949.2566955
2017-10-14 23:35:50,027 |synced| DEBUG : Sending PING to 77.59.180.49:55704

Error thrown when opening webwallet

When opening localhost:8888 the following error occurs immediately:

Unhandled Error
Traceback (most recent call last):
File "/usr/local/lib/python3.4/dist-packages/twisted/protocols/basic.py", line 571, in dataReceived
why = self.lineReceived(line)
File "/usr/local/lib/python3.4/dist-packages/twisted/web/http.py", line 2013, in lineReceived
self.allContentReceived()
File "/usr/local/lib/python3.4/dist-packages/twisted/web/http.py", line 2104, in allContentReceived
req.requestReceived(command, path, version)
File "/usr/local/lib/python3.4/dist-packages/twisted/web/http.py", line 866, in requestReceived
self.process()
--- ---
File "/usr/local/lib/python3.4/dist-packages/twisted/web/server.py", line 195, in process
self.render(resrc)
File "/usr/local/lib/python3.4/dist-packages/twisted/web/server.py", line 255, in render
body = resrc.render(self)
File "/usr/local/lib/python3.4/dist-packages/twisted/web/resource.py", line 250, in render
return m(request)
File "/usr/local/lib/python3.4/dist-packages/qrl/webwallet.py", line 56, in render_GET
return bytes(json.dumps(tmp), 'utf-8')
File "/usr/lib/python3.4/json/init.py", line 230, in dumps
return _default_encoder.encode(obj)
File "/usr/lib/python3.4/json/encoder.py", line 192, in encode
chunks = self.iterencode(o, _one_shot=True)
File "/usr/lib/python3.4/json/encoder.py", line 250, in iterencode
return _iterencode(o, 0)
File "/usr/lib/python3.4/json/encoder.py", line 173, in default
raise TypeError(repr(o) + " is not JSON serializable")
builtins.TypeError: b'Qfc0f60c91656555bdd5ba5ef711ed3963cfbd2b8b2103f1fb2373343bccaedf073c763e1' is not JSON serializable

2017-10-25 22:45:13,845 |synced| CRITICAL : [TWISTED] Unhandled Error
Traceback (most recent call last):
File "/usr/local/lib/python3.4/dist-packages/twisted/protocols/basic.py", line 571, in dataReceived
why = self.lineReceived(line)
File "/usr/local/lib/python3.4/dist-packages/twisted/web/http.py", line 2013, in lineReceived
self.allContentReceived()
File "/usr/local/lib/python3.4/dist-packages/twisted/web/http.py", line 2104, in allContentReceived
req.requestReceived(command, path, version)
File "/usr/local/lib/python3.4/dist-packages/twisted/web/http.py", line 866, in requestReceived
self.process()
--- ---
File "/usr/local/lib/python3.4/dist-packages/twisted/web/server.py", line 195, in process
self.render(resrc)
File "/usr/local/lib/python3.4/dist-packages/twisted/web/server.py", line 255, in render
body = resrc.render(self)
File "/usr/local/lib/python3.4/dist-packages/twisted/web/resource.py", line 250, in render
return m(request)
File "/usr/local/lib/python3.4/dist-packages/qrl/webwallet.py", line 56, in render_GET
return bytes(json.dumps(tmp), 'utf-8')
File "/usr/lib/python3.4/json/init.py", line 230, in dumps
return _default_encoder.encode(obj)
File "/usr/lib/python3.4/json/encoder.py", line 192, in encode
chunks = self.iterencode(o, _one_shot=True)
File "/usr/lib/python3.4/json/encoder.py", line 250, in iterencode
return _iterencode(o, 0)
File "/usr/lib/python3.4/json/encoder.py", line 173, in default
raise TypeError(repr(o) + " is not JSON serializable")
builtins.TypeError: b'Qfc0f60c91656555bdd5ba5ef711ed3963cfbd2b8b2103f1fb2373343bccaedf073c763e1' is not JS

Block 1 rejected

Hi there,
I recently started with testnet and installed url on a raspberry. It happen to work for a few days. But now i get some errors in the log:

2017-12-03 14:25:30,027|local-dev|syncing| INFO : Initializing download from 1
2017-12-03 14:25:30,032|local-dev|syncing| INFO : <<<Fetching block: 1 from 104.237.3.185:9000
2017-12-03 14:25:30,483|local-dev|syncing| INFO : >>> Received Block #1
2017-12-03 14:25:30,672|local-dev|syncing| INFO : Blocknumber not found
2017-12-03 14:25:30,674|local-dev|syncing| WARNING : main: Block 1 rejected. prevheaderhash mismatch
2017-12-03 14:25:30,675|local-dev|syncing| WARNING : PB failed to add block to mainchain
2017-12-03 14:25:30,686|local-dev|syncing| INFO : >>> Received Block #1
2017-12-03 14:25:30,688|local-dev|syncing| WARNING : Did not match None 104.237.3.185:9000
2017-12-03 14:25:50,032|local-dev|syncing| INFO : <<<Fetching block: 1 from 158.248.145.16:9000
2017-12-03 14:25:50,219|local-dev|syncing| INFO : >>> Received Block #1
2017-12-03 14:25:50,408|local-dev|syncing| INFO : Blocknumber not found
2017-12-03 14:25:50,410|local-dev|syncing| WARNING : main: Block 1 rejected. prevheaderhash mismatch
2017-12-03 14:25:50,412|local-dev|syncing| WARNING : PB failed to add block to mainchain

Any ideas?

ChainBuffer.py | TypeError: __init__() got an unexpected keyword argument 'pool_size'

(fresh node on a raspberry pi)

2017-10-09 15:50:47,451 |unsynced| INFO : Creating new chain file
2017-10-09 15:50:47,452 |unsynced| INFO : Loading genesis from /home/thomas/QRL/qrl/core/genesis.yml
2017-10-09 15:50:47,465 |unsynced| INFO : genesis:
2017-10-09 15:50:47,469 |unsynced| CRITICAL : Unhandled exception!
Traceback (most recent call last):
  File "start_qrl.py", line 13, in <module>
    main()
  File "/home/thomas/QRL/qrl/main.py", line 105, in main
    chain_obj.m_load_chain()
  File "/home/thomas/QRL/qrl/core/chain.py", line 601, in m_load_chain
    self.load_chain_by_epoch(0)
  File "/home/thomas/QRL/qrl/core/chain.py", line 453, in load_chain_by_epoch
    self.block_chain_buffer = ChainBuffer(self)
  File "/home/thomas/QRL/qrl/core/ChainBuffer.py", line 30, in __init__
    self.assign_slave_xmsspool(0)
  File "/home/thomas/QRL/qrl/core/ChainBuffer.py", line 47, in assign_slave_xmsspool
    pool_size = 2)
TypeError: __init__() got an unexpected keyword argument 'pool_size'

[CLI] Wallet commands path issue

The following command doesn't work until unless the user changes its current directory is to ~/.qrl/wallet

qrl wallet_secret --wallet-idx 0
Wallet index not found

Cannot open wallet after hard-fork / suggestions to make alpha-testing better

hi guys

as suggested by @cyyber on Discord I'm opening an issue related to this.
after the hard fork from the other day a lot of pieces have come loose in the alpha-tester workflow.

qrlexplorer.info has lost some functionality, but that we're now aware of, and being able to at least see blockheight is a starting point.

wallet.qrlexplorer.info has not allowed me to open the new wallet. on the other hand it's able to show me the old wallet's balance.

I think to be able to run alpha-testing we need to have detailed info about resets, forks and workflows.

  • stop running nodes
  • uninstall qrl (including special cases such as manually removing old versions)
  • re-install the whole shebang
  • erase the .qrl folder and all its content
  • do not try to reuse old wallets

besides, on hard-fork, the first things to be updated should be qrlexplorer and wallet, and they should point to the correct network(s).

Only at that point you should ask us to resume alpha-testing.
without the tools we're just taking a shot in the dark and silly/clueless questions are going to be posted on Discord.

I appreciate the hard work, but help us help you, and help us help the network be successful on launch, as this is what many of us are here for :)

thank you for listening
u.

ERROR : executing [BK] KeyError: 'Qe...'

2017-10-09 07:57:23,882 |synced| INFO : >>>Received block from 104.251.219.215:9000 18203 Qada446e9ac25b11299e0615de8bd1b7f5404ce0052fbb27db7ada425904a5aea6063deb3
2017-10-09 07:57:23,887 |synced| ERROR : executing [BK]
2017-10-09 07:57:23,891 |synced| ERROR : Traceback (most recent call last):
File "/home/lenij/crypto/QRL/qrl/core/p2pprotocol.py", line 75, in parse_msg
func(jdata['data'])
File "/home/lenij/crypto/QRL/qrl/core/p2pprotocol.py", line 340, in BK
self.factory.pos.pre_block_logic(block)
File "/home/lenij/crypto/QRL/qrl/core/node.py", line 420, in pre_block_logic
if not self.chain.block_chain_buffer.add_block(block):
File "/home/lenij/crypto/QRL/qrl/core/ChainBuffer.py", line 239, in add_block
self.move_to_mainchain(blocknum - config.dev.reorg_limit)
File "/home/lenij/crypto/QRL/qrl/core/ChainBuffer.py", line 463, in move_to_mainchain
if not self.state.state_add_block(self.chain, block):
File "/home/lenij/crypto/QRL/qrl/core/state.py", line 200, in state_add_block
nonce = self.stake_validators_list.sv_list[block.transactions[0].txto].nonce
KeyError: 'Qebe26789cc7d17e84bfd4c239c0fef378d1afba427b83443dddf7d70afc3708a647bd4c8'

0.53.0a unexpected exception leads to forked node

2017-10-13 20:29:20,985 |synced| DEBUG : -->>FBHL called
2017-10-13 20:29:36,032 |synced| ERROR : select_best_bkmr Unexpected Exception
2017-10-13 20:29:36,035 |synced| ERROR : 'ba6a349dd90dbb94eac47ddfa827389310f988c31738d3b2a90ff6e56d85eea7'
2017-10-13 20:29:38,250 |synced| INFO : 52.220.119.253 disconnected. remainder connected: 8
2017-10-13 20:29:38,254 |synced| DEBUG : connection lost: [Failure instance: Traceback (failure with no frames): <class 'twisted.internet.error.ConnectionLost'>: Connection to the other side was lost in a non-cle
an fashion.
]
2017-10-13 20:29:38,648 |synced| INFO : 104.251.219.145 disconnected. remainder connected: 7
2017-10-13 20:29:38,652 |synced| DEBUG : connection lost: [Failure instance: Traceback (failure with no frames): <class 'twisted.internet.error.ConnectionDone'>: Connection was closed cleanly.
]
2017-10-13 20:29:38,657 |synced| INFO : 104.251.219.40 disconnected. remainder connected: 6
2017-10-13 20:29:38,661 |synced| DEBUG : connection lost: [Failure instance: Traceback (failure with no frames): <class 'twisted.internet.error.ConnectionDone'>: Connection was closed cleanly.
]
2017-10-13 20:29:38,665 |synced| INFO : 104.237.3.185 disconnected. remainder connected: 5
2017-10-13 20:29:38,669 |synced| DEBUG : connection lost: [Failure instance: Traceback (failure with no frames): <class 'twisted.internet.error.ConnectionDone'>: Connection was closed cleanly.
]
2017-10-13 20:29:38,674 |synced| INFO : 104.237.3.184 disconnected. remainder connected: 4
2017-10-13 20:29:38,678 |synced| DEBUG : connection lost: [Failure instance: Traceback (failure with no frames): <class 'twisted.internet.error.ConnectionDone'>: Connection was closed cleanly.
]
2017-10-13 20:29:41,051 |synced| CRITICAL : [TWISTED] Unhandled Error
Traceback (most recent call last):
File "start_qrl.py", line 13, in
main()
File "/home/pi/QRL/qrl/main.py", line 141, in main
reactor.run()
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/base.py", line 1243, in run
self.mainLoop()
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/base.py", line 1252, in mainLoop
self.runUntilCurrent()
--- ---
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/base.py", line 878, in runUntilCurrent
call.func(*call.args, **call.kw)
File "/home/pi/QRL/qrl/core/p2pfactory.py", line 84, in RFM
peers_list = self.master_mr.requested_hash[msg_hash_str].peers_connection_list
builtins.KeyError: 'ba6a349dd90dbb94eac47ddfa827389310f988c31738d3b2a90ff6e56d85eea7'

2017-10-13 20:29:41,057 |synced| CRITICAL : [TWISTED] Unhandled Error
Traceback (most recent call last):
File "start_qrl.py", line 13, in
main()
File "/home/pi/QRL/qrl/main.py", line 141, in main
reactor.run()
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/base.py", line 1243, in run
self.mainLoop()
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/base.py", line 1252, in mainLoop
self.runUntilCurrent()
--- ---
File "/home/pi/.local/lib/python3.5/site-packages/twisted/internet/base.py", line 878, in runUntilCurrent
call.func(*call.args, **call.kw)
File "/home/pi/QRL/qrl/core/p2pfactory.py", line 84, in RFM
peers_list = self.master_mr.requested_hash[msg_hash_str].peers_connection_list
builtins.KeyError: 'ba6a349dd90dbb94eac47ddfa827389310f988c31738d3b2a90ff6e56d85eea7'

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.