Browse Source

logging

pull/10210/head
DA-344 4 weeks ago
parent
commit
482ae4b978
  1. 4
      discord/voice_state.py

4
discord/voice_state.py

@ -632,6 +632,7 @@ class VoiceConnectionState:
continue continue
if exc.code == 4015: if exc.code == 4015:
_log.info('Disconnected from voice, attempting a resume...')
try: try:
await self._connect( await self._connect(
reconnect=reconnect, reconnect=reconnect,
@ -641,11 +642,12 @@ class VoiceConnectionState:
resume=True, resume=True,
) )
except asyncio.TimeoutError: except asyncio.TimeoutError:
_log.warning('Could not resume the voice connection... Disconnecting...') _log.info('Could not resume the voice connection... Disconnecting...')
if self.state is not ConnectionFlowState.disconnected: if self.state is not ConnectionFlowState.disconnected:
await self.disconnect() await self.disconnect()
break break
else: else:
_log.info('Successfully resumed voice connection')
continue continue
_log.debug('Not handling close code %s (%s)', exc.code, exc.reason or 'no reason') _log.debug('Not handling close code %s (%s)', exc.code, exc.reason or 'no reason')

Loading…
Cancel
Save