better exceptions
This commit is contained in:
parent
e8c9f91a7c
commit
da8a5dbcee
@ -210,7 +210,8 @@ class MainService:
|
||||
async with self.lock_for(guild):
|
||||
await self._restore_vc(guild, vccid, vc_is_paused)
|
||||
except Exception as e:
|
||||
print(f'vc {vcgid} {vccid} {vc_is_paused} failed', e)
|
||||
print(f'vc {vcgid} {vccid} {vc_is_paused} failed')
|
||||
traceback.print_exc()
|
||||
else:
|
||||
print(f'vc restored {vcgid} {vccid}')
|
||||
|
||||
|
@ -1,5 +1,6 @@
|
||||
import asyncio
|
||||
import random
|
||||
import traceback
|
||||
from collections import deque
|
||||
from io import StringIO
|
||||
from typing import MutableSequence
|
||||
@ -48,6 +49,7 @@ class QueueAudio(discord.AudioSource):
|
||||
raise
|
||||
except Exception as e:
|
||||
print('queue respawn failed', e)
|
||||
traceback.print_exc()
|
||||
return respawned
|
||||
|
||||
@classmethod
|
||||
@ -189,10 +191,8 @@ class QueueAudio(discord.AudioSource):
|
||||
def shuffle(self) -> None:
|
||||
try:
|
||||
random.shuffle(ForwardView(self.queue))
|
||||
except:
|
||||
from traceback import print_exc
|
||||
print_exc()
|
||||
self.update_sources()
|
||||
finally:
|
||||
self.update_sources()
|
||||
|
||||
def branch(self, effects: str | None) -> None:
|
||||
if not self.queue:
|
||||
|
Loading…
Reference in New Issue
Block a user