From 7e442030fd69568ece81647194ad3228b24dbb09 Mon Sep 17 00:00:00 2001 From: tonyrewin Date: Wed, 7 Sep 2022 20:14:59 +0300 Subject: [PATCH] ()[ --- services/stat/reacted.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/services/stat/reacted.py b/services/stat/reacted.py index 7f90b0e8..b8bdb066 100644 --- a/services/stat/reacted.py +++ b/services/stat/reacted.py @@ -221,12 +221,9 @@ class ReactedStorage: for slug in dict(self.reacted['shouts']).keys(): topics = session.query(ShoutTopic.topic).where(ShoutTopic.shout == slug).all() reactions = self.reacted['shouts'].get(slug, []) + print('[stat.reacted] shout {' + str(slug) + "}: " + str(len(reactions))) for ts in list(topics): - try: - tslug = ts.pop() - except Exception: - print(ts) - raise Exception('error') + tslug = ts[0] topic_reactions = self.reacted["topics"][tslug] if not topic_reactions: topic_reactions = []