[英]I'm calling pyperclip but it says :No Module named 'qtpy'
>>> import pyperclip
>>>
>>>
>>> pyperclip.copy('Hi!')
Traceback (most recent call last):
File "/home/dash/.local/lib/python3.11/site-packages/pyperclip/__init__.py", line 582, in determine_clipboard
import qtpy # check if qtpy is installed
^^^^^^^^^^^
ModuleNotFoundError: No module named 'qtpy'
I installed pyperclip it but it says:No module named 'qtpy' but I am actually calling to pyperclip我安装了 pyperclip,但它说:No module named 'qtpy' 但我实际上是在调用 pyperclip
It means that you have to pip install the qtpy module.这意味着您必须 pip 安装 qtpy 模块。
In a terminal window:在终端窗口中:
pip install qtpy --user pip 安装 qtpy --user
Note: I recommend using the --user option in order to avoid possible collisions with packages used by the system.注意:我建议使用 --user 选项以避免与系统使用的包发生冲突。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.