nobugdebug 2023-04-22 18:23 采纳率: 89.5%
浏览 94
已结题

Python,在PyCharm中。无法安装autopy插件包

Python,在PyCharm中。无法安装autopy插件包,出现如图所示情况,请问该如何解决?

Collecting autopy
  Using cached autopy-4.0.0.tar.gz (20 kB)
  Preparing metadata (setup.py): started
  Preparing metadata (setup.py): finished with status 'error'

  error: subprocess-exited-with-error
  
  × python setup.py egg_info did not run successfully.
  │ exit code: 1
  ╰─> [6 lines of output]
      Traceback (most recent call last):
        File "<string>", line 2, in <module>
        File "<pip-setuptools-caller>", line 34, in <module>
        File "/private/var/folders/s7/k1xbsj5908gcm3llmltpm5kw0000gn/T/pip-install-5qnzx5z6/autopy_cc4e76d8606b4fe8907c5c938a94c337/setup.py", line 8, in <module>
          from setuptools_rust import Binding, RustExtension
      ModuleNotFoundError: No module named 'setuptools_rust'
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.

[notice] A new release of pip available: 22.3.1 -> 23.1
[notice] To update, run: pip install --upgrade pip

img

img

source /Users/xxxxxx/PycharmProjects/xxxxxx/venv/scripts/bin/activate
/Users/xxxxx/xxxxxx/venv/scripts/bin/Python /Applications/PyCharm CE.app/Contents/plugins/python-ce/helpers/packaging_tool.py install autopy


以下是更新pip后情况,依旧无法安装autopy

img

img

img


请问接下来该如何解决?

  • 写回答

2条回答 默认 最新

  • nobugdebug 2023-04-27 07:24
    关注

    是环境python版本太高了。autopy需要的wheel到目前为止都只有适配python3.4~3.8.2换了py3.8.2后直接pip instal即可。若没有python较低版本可从python官网上下载。

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

问题事件

  • 已结题 (查看结题原因) 4月27日
  • 已采纳回答 4月27日
  • 修改了问题 4月22日
  • 创建了问题 4月22日