logging, gitignore, pin rns
This commit is contained in:
parent
decefb89d5
commit
a70d0db0bd
3 changed files with 10 additions and 3 deletions
|
|
@ -1,9 +1,12 @@
|
|||
import json
|
||||
import logging
|
||||
import random
|
||||
import threading
|
||||
import time
|
||||
import RNS
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
from tinyweb_forum.bloom import BloomFilter
|
||||
|
||||
FORUM_APP = "tinyweb-forum"
|
||||
|
|
@ -105,7 +108,7 @@ class ForumSync:
|
|||
count += 1
|
||||
except Exception as e:
|
||||
self.fdb.record_sync_result(inst["instance_hash"], False)
|
||||
print(f"[forum] sync error with {inst['instance_hash'][:16]}: {e}")
|
||||
logger.error("sync error with %s: %s", inst["instance_hash"][:16], e)
|
||||
return count
|
||||
|
||||
def _start_sync_loop(self):
|
||||
|
|
@ -153,7 +156,7 @@ class ForumSync:
|
|||
self._sync_with(inst["instance_hash"], my_topics)
|
||||
except Exception as e:
|
||||
self.fdb.record_sync_result(inst["instance_hash"], False)
|
||||
print(f"[forum] sync error with {inst['instance_hash'][:16]}: {e}")
|
||||
logger.error("sync error with %s: %s", inst["instance_hash"][:16], e)
|
||||
except Exception:
|
||||
pass
|
||||
prune_counter += 1
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue