看门狗库未识别

发布于 2025-01-15 22:51:33 字数 542 浏览 0 评论 0原文

我正在尝试使用看门狗创建一个文件监视程序。但是,我的 VSCode 无法识别该库。

无法识别库 - 图像示例

我已经运行了pip install watchdog 在我的 powershell 上,它显示:要求已满足:c:\python310\lib\site-packages (2.1.6) 中的看门狗,当我运行 watchmedo 时--help 检查一下,不被识别。

我该如何解决这个问题?

[编辑] Watchmedo 已安装并且似乎运行正常。 时,我看不到它在哪个 python 环境中

但是,当我运行 watchmedo --help 没有Python环境的Watchmedo

I'm trying to create a file monitoring program using watchdog. However, my VSCode won't identify the library.

Library isn't recognized - image example

I have already ran pip install watchdog on my powershell and it displays: Requirement already satisfied: watchdog in c:\python310\lib\site-packages (2.1.6), and when I run watchmedo --help to check, it's not recognized.

How do I fix this?

[EDIT] Watchmedo is installed and seems to be running properly. However, I can't see in which python environment it is when I run watchmedo --help

Watchmedo without python environment

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

无敌元气妹 2025-01-22 22:51:33

您已在全局环境中安装了watchdog。请检查您在执行watchmedo --help时选择了哪个Python环境。您可以从 VSCode 中打开 cmd 来执行 watchmedo --help

You have installed the watchdog in the global environment. Please check which python environment you have selected when you execute watchmedo --help. You can open the cmd out of the VSCode to execute watchmedo --help.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文