mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-06-06 03:47:29 +00:00
Log when a player's after function fails.
This commit is contained in:
parent
a18267ca49
commit
daf066dd39
@ -27,12 +27,15 @@ DEALINGS IN THE SOFTWARE.
|
|||||||
import threading
|
import threading
|
||||||
import subprocess
|
import subprocess
|
||||||
import audioop
|
import audioop
|
||||||
|
import logging
|
||||||
import shlex
|
import shlex
|
||||||
import time
|
import time
|
||||||
|
|
||||||
from .errors import ClientException
|
from .errors import ClientException
|
||||||
from .opus import Encoder as OpusEncoder
|
from .opus import Encoder as OpusEncoder
|
||||||
|
|
||||||
|
log = logging.getLogger(__name__)
|
||||||
|
|
||||||
__all__ = [ 'AudioSource', 'PCMAudio', 'FFmpegPCMAudio', 'PCMVolumeTransformer' ]
|
__all__ = [ 'AudioSource', 'PCMAudio', 'FFmpegPCMAudio', 'PCMVolumeTransformer' ]
|
||||||
|
|
||||||
class AudioSource:
|
class AudioSource:
|
||||||
@ -286,7 +289,7 @@ class AudioPlayer(threading.Thread):
|
|||||||
try:
|
try:
|
||||||
self.after(self._current_error)
|
self.after(self._current_error)
|
||||||
except:
|
except:
|
||||||
pass
|
log.exception('Calling the after function failed.')
|
||||||
|
|
||||||
def stop(self):
|
def stop(self):
|
||||||
self._end.set()
|
self._end.set()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user