Open
Description
Summary
Bot hangs when trying to connect to restricted VC
Reproduction Steps
- Create a VC
- Forbid the bot to connect to it
- Run the
connect
command
Minimal Reproducible Code
import os
import discord
intents = discord.Intents.default()
intents.voice_states = True
bot = discord.Bot(intents=intents)
@bot.command()
async def connect(ctx):
await ctx.author.voice.channel.connect()
await ctx.respond("Connected")
bot.run(os.getenv("BOT_TOKEN"))
Expected Results
I'd expect a permission error raised
Actual Results
The execution hangs
Intents
default() + voice_states
System Information
- Python v3.11.2-final
- py-cord v2.4.1-final
- aiohttp v3.8.4
- system info:
Linux 4.14.232-QuicksilveR™-ReloadedOS-Edition #1 SMP PREEMPT Wed May 26 07:08:17 UTC 2021
Checklist
- I have searched the open issues for duplicates.
- I have shown the entire traceback, if possible.
- I have removed my token from display, if visible.
Additional Context
No response