Merge pull request #2695 from lbryio/fix-12-to-13-migrator

Fix 12 to 13 migrator
This commit is contained in:
Jack Robison 2019-12-28 15:57:41 -05:00 committed by GitHub
commit aef83eec31
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 4 deletions

View file

@ -224,7 +224,7 @@ class PingQueue:
self._protocol.add_peer(peer) self._protocol.add_peer(peer)
return return
await self._protocol.get_rpc_peer(peer).ping() await self._protocol.get_rpc_peer(peer).ping()
except asyncio.TimeoutError: except (asyncio.TimeoutError, RemoteException):
pass pass
task = self._loop.create_task(ping_task()) task = self._loop.create_task(ping_task())
@ -668,7 +668,7 @@ class KademliaProtocol(DatagramProtocol):
log.debug("peer %s:%i is running an incompatible version of lbrynet", peer.address, peer.udp_port) log.debug("peer %s:%i is running an incompatible version of lbrynet", peer.address, peer.udp_port)
return peer.node_id, False return peer.node_id, False
if 'Invalid token' not in str(err): if 'Invalid token' not in str(err):
log.exception("Unexpected error while storing blob_hash") log.warning("Unexpected error while storing blob_hash: %s", err)
return peer.node_id, False return peer.node_id, False
self.peer_manager.clear_token(peer.node_id) self.peer_manager.clear_token(peer.node_id)
if not retry: if not retry:

View file

@ -65,7 +65,7 @@ def do_migration(conf):
added_on added_on
from file; from file;
insert into new_content_claim (stream_hash, bt_infohash, claim_outpoint) insert or ignore into new_content_claim (stream_hash, bt_infohash, claim_outpoint)
select stream_hash, NULL, claim_outpoint from content_claim; select stream_hash, NULL, claim_outpoint from content_claim;
drop table file; drop table file;

View file

@ -286,7 +286,7 @@ class SessionManager:
def _get_info(self): def _get_info(self):
"""A summary of server state.""" """A summary of server state."""
group_map = self._group_map() group_map = self._group_map()
method_counts = collections.defaultdict(0) method_counts = collections.defaultdict(int)
error_count = 0 error_count = 0
logged = 0 logged = 0
paused = 0 paused = 0