await voice.channel.connect()
File "c:\Users\user.DESKTOP-A29085V\Documents\Python proj\ReviBot\main.py", line 100, in _play
await SongMaster.play(ctx)
File "c:\Users\user.DESKTOP-A29085V\Documents\Python proj\ReviBot\main.py", line 57, in play
voice_state.play(disnake.FFmpegPCMAudio("songs/song.mp3"))
File "C:\Users\user.DESKTOP-A29085V\AppData\Local\Programs\Python\Python311\Lib\site-packages\disnake\voice_client.py", line 572, in play
raise ClientException("Not connected to voice.")
disnake.errors.ClientException: Not connected to voice.
просить его подключиться он будет выдавать то что уже подключен, а если просить включить музыку или отключить от канала он будет говорить что не подключен, хотя находится там
RuntimeWarning: coroutine 'Song.init_after' was never awaited
self.after(error)
after=lambda e: await Song.init_after(ctx)
SyntaxError: 'await' outside async function
Traceback (most recent call last):
File "/home/container/.local/lib/python3.9/site-packages/disnake/player.py", line 742, in _call_after
self.after(error)
File "/home/container/main.py", line 194, in <lambda>
voice_state.play(disnake.FFmpegPCMAudio(f"songs/{ids[0]}.mp3"), after=lambda e: Song.init_after(ctx))
File "/home/container/main.py", line 166, in init_after
asyncio.create_task(Song.my_after(ctx))
File "/usr/local/lib/python3.9/asyncio/tasks.py", line 360, in create_task
loop = events.get_running_loop()
RuntimeError: no running event loop
try:
await voice_state.stop()
except:
pass
await Song.play_next(ctx)
return None
stats = True
while stats:
try:
client.tracks(track['id'])[0].download(f"songs/{track['id']}.mp3")
stats = False
except NetworkError:
pass
except asyncio.TimeoutError:
status = False
return await ctx.edit_original_response(components=None)
Command raised an exception: AssertionError: