def say_match_start(self, msg):
serverlist = list(self.bot.servers)
for s in serverlist:
try: # Catching potential HTTPExceptions here is actually important, because if we don't then the background task will stop
matches_channel = self.bot.get_channel(self.get_matches_channel(s))
if matches_channel:
try:
await self.bot.send_message(matches_channel, msg)
except (discord.Forbidden, discord.NotFound, discord.InvalidArgument):
pass
except discord.HTTPException:
pass
#except Exception as e:
# print("Unable to announce draft: %s" % e)
评论列表
文章目录