如何解决“未解决的导入discord.ext.tasks”?

时间:2020-05-10 22:23:06

标签: python discord discord.py

我想使用Python为我的服务器创建Discord机器人。我阅读了discord.py的文档,并尝试运行此处发布的示例。代码正在运行,但是不知道为什么会有这个警告“ unresolved import discord.ext.tasks”。尝试使用Python 3.7,但未导入任何软件包。有人可以帮我解决这个问题吗?

the error + code (photo)

1 个答案:

答案 0 :(得分:0)

不要使用visual studio 2019它无法正确导入discord.ext,我在使用Visual Studio Code时遇到了同样的问题