运行命令“启动”(第21行)时出现以下错误。
OSError: [WinError 193] %1 is not a valid Win32 application
我已经研究过,所有答案都说这是将32位内容与64位内容混合在一起的方法,但是没有任何方法说明如何解决它。请帮忙!!!
from random import randint
from time import sleep
import asyncio
import nest_asyncio
nest_asyncio.apply()
client = discord.Client()
@client.event
async def on_ready():
print('{0.user} Active'.format(client))
@client.event
async def on_message(message):
if message.author == client.user:
return
if message.content.startswith("start"):
loop = asyncio.get_event_loop()
loop.run_until_complete(mmm(message.author))
async def mmm(user):
voice_channel=user.voice.channel
print(voice_channel)
channel=None
# only play music if user is in a voice channel
if voice_channel!= None:
# grab user's voice channel
channel=voice_channel.name
# create StreamPlayer
vc=voice_channel.connect
audio = discord.FFmpegPCMAudio(executable='C:/Users/Amir/Desktop/Serious-Programming/Stuff/Bots/MMM/microwave.mp3', source="mp3.mp3")
vc.play(audio)
async def playM(player):
ctx.voice_client.play(player)
#loop = asyncio.get_event_loop()
#loop.run_until_complete(playM.mmm(player))
client.run('my client token here')```