Quantcast
Channel: Active questions tagged youtube-api - Stack Overflow
Viewing all articles
Browse latest Browse all 3831

discord python music bot (bad operand type for unary +: 'dict') error

$
0
0

hi im having a problem with my discord music bot's "play" command

this the code :

@client.command()async def play(ctx,url):     FFMPEG_OPTIONS = {'before_options':'-reconnect 1 reconnect_streamed 1 -reconnect_delay_max 5', 'options':'-vm'}     YDL_OPTIONS = {'format':"bestaudio"}     vc = ctx.voice_client     with youtube_dl.YoutubeDL(YDL_OPTIONS) as ydl:         info = ydl.extract_info(url,download=False)         url2 = info['formats'][0]['url']         source = await discord.FFmpegOpusAudio.from_probe(url2,++FFMPEG_OPTIONS)         vc.play(source)

and this is the error :

Command raised an exception: TypeError: bad operand type for unary +: 'dict'

Viewing all articles
Browse latest Browse all 3831

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>