aboutsummaryrefslogtreecommitdiff
path: root/discord/voice_client.py
diff options
context:
space:
mode:
authorImayhaveborkedit <[email protected]>2019-11-20 00:34:23 -0500
committerRapptz <[email protected]>2019-11-26 05:16:53 -0500
commit839afce17890a03c0718d5ad76069b641da54034 (patch)
tree7b073b8e6cbccbebdc9700187ff2d2b5462b9c3f /discord/voice_client.py
parentAdd new audit log entry types. Fix issue with unknown entry types (diff)
downloaddiscord.py-839afce17890a03c0718d5ad76069b641da54034.tar.xz
discord.py-839afce17890a03c0718d5ad76069b641da54034.zip
Print exception tracebacks in voice threads
Errors occurring within `AudioSource.read()` and `after()` functions will now display their tracebacks as if they were unhandled exceptions.
Diffstat (limited to 'discord/voice_client.py')
-rw-r--r--discord/voice_client.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/discord/voice_client.py b/discord/voice_client.py
index 63975743..f3729c9e 100644
--- a/discord/voice_client.py
+++ b/discord/voice_client.py
@@ -338,7 +338,8 @@ class VoiceClient:
or an error occurred.
If an error happens while the audio player is running, the exception is
- caught and the audio player is then stopped.
+ caught and the audio player is then stopped. If no after callback is
+ passed, any caught exception will be displayed as if it were raised.
Parameters
-----------
@@ -346,9 +347,8 @@ class VoiceClient:
The audio source we're reading from.
after: Callable[[:class:`Exception`], Any]
The finalizer that is called after the stream is exhausted.
- All exceptions it throws are silently discarded. This function
- must have a single parameter, ``error``, that denotes an
- optional exception that was raised during playing.
+ This function must have a single parameter, ``error``, that
+ denotes an optional exception that was raised during playing.
Raises
-------