fixed flake8 issues to pass CI test

Signed-off-by: Juergen Eckel <juergen@riddleandcode.com>
This commit is contained in:
Juergen Eckel 2019-10-02 01:43:23 +02:00
parent c269f0115c
commit 5fdea5dc3c
3 changed files with 5 additions and 11 deletions

View File

@ -2,8 +2,7 @@ import codecs
import base64
import binascii
from abci.types_pb2 import (Validator,
ValidatorUpdate,
from abci.types_pb2 import (ValidatorUpdate,
PubKey)
from bigchaindb.common.exceptions import InvalidPublicKey

View File

@ -15,10 +15,8 @@ def validator_pub_key():
@pytest.fixture
def init_chain_request():
addr = codecs.decode(b'9FD479C869C7D7E7605BF99293457AA5D80C3033', 'hex')
pk = codecs.decode(b'VAgFZtYw8bNR5TMZHFOBDWk9cAmEu3/c6JgRBmddbbI=',
'base64')
val_a = types.ValidatorUpdate(power=10,
pub_key=types.PubKey(type='ed25519', data=pk))
return types.RequestInitChain(validators=[val_a])

View File

@ -2,7 +2,6 @@
# SPDX-License-Identifier: (Apache-2.0 AND CC-BY-4.0)
# Code is Apache-2.0 and docs are CC-BY-4.0
import codecs
import json
import pytest
import random
@ -14,7 +13,6 @@ from abci.types_pb2 import (
RequestInfo,
RequestBeginBlock,
RequestEndBlock,
Validator,
ValidatorUpdate,
)
@ -49,7 +47,6 @@ def generate_address():
def generate_validator():
addr = codecs.decode(generate_address(), 'hex')
pk, _ = generate_key_pair()
pub_key = PubKey(type='ed25519', data=pk.encode())
val = ValidatorUpdate(power=10, pub_key=pub_key)