From f9aa95c98708090a54382a4018dcfd714d75d40f Mon Sep 17 00:00:00 2001 From: Lex Berezhny Date: Tue, 31 Mar 2020 17:22:13 -0400 Subject: [PATCH] default to None for all values in wallet_status when wallet_manager not started yet --- lbry/extras/daemon/daemon.py | 2 +- tests/integration/blockchain/test_wallet_commands.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lbry/extras/daemon/daemon.py b/lbry/extras/daemon/daemon.py index edab45785..a9ff849cb 100644 --- a/lbry/extras/daemon/daemon.py +++ b/lbry/extras/daemon/daemon.py @@ -1342,7 +1342,7 @@ class Daemon(metaclass=JSONRPCServerType): Dictionary of wallet status information. """ if self.wallet_manager is None: - return {'is_encrypted': None, 'is_syncing': True, 'is_locked': None} + return {'is_encrypted': None, 'is_syncing': None, 'is_locked': None} wallet = self.wallet_manager.get_wallet_or_default(wallet_id) return { 'is_encrypted': wallet.is_encrypted, diff --git a/tests/integration/blockchain/test_wallet_commands.py b/tests/integration/blockchain/test_wallet_commands.py index 455f8b4e0..4f8f0d6ed 100644 --- a/tests/integration/blockchain/test_wallet_commands.py +++ b/tests/integration/blockchain/test_wallet_commands.py @@ -33,7 +33,7 @@ class WalletCommands(CommandTestCase): # when component manager hasn't started yet wallet.wallet_manager = None self.assertEqual( - {'is_encrypted': None, 'is_syncing': True, 'is_locked': None}, + {'is_encrypted': None, 'is_syncing': None, 'is_locked': None}, self.daemon.jsonrpc_wallet_status() ) wallet.wallet_manager = wallet_manager