亚洲在线久爱草,狠狠天天香蕉网,天天搞日日干久草,伊人亚洲日本欧美

為了賬號安全,請及時綁定郵箱和手機立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

與discord.embed相關的錯誤

與discord.embed相關的錯誤

慕桂英3389331 2023-07-18 13:47:39
當我運行 .py 文件時,窗口立即關閉。此時并沒有出現錯誤代碼。如果我把Embed相關的代碼刪除,就可以正常運行了。我不確定問題是什么......import discord, asyncio, osfrom discord.ext import commandstoken = "########"game = discord.Game("??&help??")bot =  commands.Bot(command_prefix = '&', status = discord.Status.online, activity = game)@bot.eventasync def on_ready():    print("hi")@bot.command()async def help(ctx):    embed=discord.Embed(title = "???? ?? ????,,," , description=f"?? ??? ??????.", color = 0x00ff56)    embed.add_field(name="??", value="&??", inline=True)    embed.add_field(name="?? ??", value="&??", inline=True)    embed.add_field(name="?? ??", value="&??", inline=True)    embed.add_field(name="??? ??", value="&??", inline=True)    embed.add_field(name="?? ???", value="&???", inline=True)    embed.add_field(name="??? ??", value="&??.", inline=True)    embed.add_field(name="? ??", value="&??", inline=True)    embed.add_field(name="??? ?? ??", value="&???", inline=True)    await ctx.send(embed=embed)bot.run(token)
查看完整描述

2 回答

?
HUH函數

TA貢獻1836條經驗 獲得超4個贊

只要嘗試韓語以外的其他語言,這可能就是問題所在。嘗試一下英語,看看是否是這個問題。



查看完整回答
反對 回復 2023-07-18
?
莫回無

TA貢獻1865條經驗 獲得超7個贊

我是這樣解決的。


title = ""   ----->   title = f"" 

value = ""   ----->   value = f""

.

.

但我不知道為什么這有效。:(


如果有人知道為什么,請告訴我


查看完整回答
反對 回復 2023-07-18
  • 2 回答
  • 0 關注
  • 143 瀏覽
慕課專欄
更多

添加回答

舉報

0/150
提交
取消
微信客服

購課補貼
聯系客服咨詢優惠詳情

幫助反饋 APP下載

慕課網APP
您的移動學習伙伴

公眾號

掃描二維碼
關注慕課網微信公眾號