简体   繁体   English

pyperclip 模块引发错误消息

[英]pyperclip module raising an error message

I'm using Python 3.4.0 on ArchLinux ( without X11 ) as guest in a Vagrant box.我在 ArchLinux(没有 X11 )上使用 Python 3.4.0 作为 Vagrant 盒子中的来宾。 When running my script I get this error message:运行我的脚本时,我收到此错误消息:

Pyperclip could not find a copy/paste mechanism for your system Pyperclip 无法为您的系统找到复制/粘贴机制

According to this link , I've installed xsel and xclip packages but I cannot install gtk nor PyQt4 modules, because I get this another error message:根据此链接,我已经安装了xselxclip软件包,但无法安装gtkPyQt4模块,因为我收到了另一条错误消息:

Could not find a version that satisfies the requirement PyQt4 (from versions: )找不到满足 PyQt4 要求的版本(来自版本:)

According to this post , I should install python3-pyqt4 package, but the package more near showed by pacman is python-pyqt5 and it requires to install many packages included packages for X11.根据这篇文章,我应该安装python3-pyqt4包,但更接近 pacman 显示的包是python-pyqt5 ,它需要安装许多包,包括 X11 的包。 Is this necessary?这是必要的吗? I wish to preserve my distro light as possible.我希望尽可能保留我的发行版。

Any solution?有什么解决办法吗? Thanks in advance.提前致谢。

This method fixed it for me.这种方法为我修复了它。

pip install QtPy

also you could refer to this thread for more help https://pyperclip.readthedocs.io/en/latest/introduction.html#not-implemented-error您也可以参考此线程以获得更多帮助https://pyperclip.readthedocs.io/en/latest/introduction.html#not-implemented-error

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM