redis-fix2
This commit is contained in:
parent
d8cd8ecb38
commit
f3eb18ae14
|
@ -42,7 +42,7 @@ async def messages_routing(msg, state):
|
|||
scr = int(await redis.get(key))
|
||||
scores.append(scr)
|
||||
toxic_score = math.floor(sum(scores)/len(scores)) if scores else 0
|
||||
text = f"Средняя токсичность сообщений: {toxic_score}%
|
||||
text = f"Средняя токсичность сообщений: {toxic_score}%"
|
||||
else:
|
||||
latest_toxic_message_id = await redis.get(f"toxic:{cid}")
|
||||
scoring_msg_id = reply_msg.get("message_id") or latest_toxic_message_id
|
||||
|
|
Loading…
Reference in New Issue
Block a user