handle case bounce info too verbose in daily report

This commit is contained in:
Son 2021-12-26 22:25:00 +01:00
parent a6569d47dd
commit 32fffeaa6e
1 changed files with 2 additions and 1 deletions

View File

@ -399,7 +399,8 @@ def all_bounce_report() -> str:
.order_by(Bounce.created_at.desc())
.first()
)
res += f"Most recent cause: \n{most_recent.info or ''}"
# most_recent.info can be very verbose
res += f"Most recent cause: \n{most_recent.info[:200] if most_recent.info else 'N/A'}"
res += "\n----\n"
return res