Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How do you make a bot leave a voice channel? #1399

Closed
TanishkDeo opened this issue Jul 6, 2018 · 1 comment
Closed

How do you make a bot leave a voice channel? #1399

TanishkDeo opened this issue Jul 6, 2018 · 1 comment
Labels
question This is a question about the library

Comments

@TanishkDeo
Copy link

image
)

Issue #1
image
AttributeError: 'generator' object has no attribute 'disconnect'

@TanishkDeo TanishkDeo changed the title How do you make a bot leave a voice channel? & youtube dl How do you make a bot leave a voice channel? Jul 6, 2018
@Harmon758
Copy link
Contributor

Harmon758 commented Jul 6, 2018

You need to await join_voice_channel to get the VoiceClient object before using disconnect, which is also a coroutine.
Or you can just use your existing VoiceClient object instead of rejoining the channel to get another one.

For future questions like this, you should join either the official discord.py server or the Discord API server for help, as the README recommends.

@Rapptz Rapptz added the question This is a question about the library label Aug 20, 2018
@Rapptz Rapptz closed this as completed Aug 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question This is a question about the library
Projects
None yet
Development

No branches or pull requests

3 participants