timxx / pywpsrpc

Python bindings for WPS Office RPC (for Linux)
MIT License
219 stars 44 forks source link

pip/pip3 install都失败了? #81

Closed fantasyplus closed 1 year ago

fantasyplus commented 1 year ago

Describe the bug pip3 install pywpsrpc /usr/bin/pip3:6: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html from pkg_resources import load_entry_point Collecting pywpsrpc Using cached pywpsrpc-2.3.9.tar.gz (6.1 MB) Installing build dependencies ... done Getting requirements to build wheel ... done Preparing wheel metadata ... error ERROR: Command errored out with exit status 1: command: /usr/bin/python3 /tmp/tmpyu0ms52v prepare_metadata_for_build_wheel /tmp/tmprm5vyfl2 cwd: /tmp/pip-install-j2y7on81/pywpsrpc Complete output (27 lines): Traceback (most recent call last): File "/tmp/tmpyu0ms52v", line 126, in prepare_metadata_for_build_wheel hook = backend.prepare_metadata_for_build_wheel AttributeError: module 'sipbuild.api' has no attribute 'prepare_metadata_for_build_wheel'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/tmp/tmpyu0ms52v", line 280, in <module>
    main()
  File "/tmp/tmpyu0ms52v", line 263, in main
    json_out['return_val'] = hook(**hook_input['kwargs'])
  File "/tmp/tmpyu0ms52v", line 130, in prepare_metadata_for_build_wheel
    return _get_wheel_metadata_from_wheel(backend, metadata_directory,
  File "/tmp/tmpyu0ms52v", line 159, in _get_wheel_metadata_from_wheel
    whl_basename = backend.build_wheel(metadata_directory, config_settings)
  File "/tmp/pip-build-env-35vr5nuv/overlay/lib/python3.8/site-packages/sipbuild/api.py", line 46, in build_wheel
    project = AbstractProject.bootstrap('wheel',
  File "/tmp/pip-build-env-35vr5nuv/overlay/lib/python3.8/site-packages/sipbuild/abstract_project.py", line 87, in bootstrap
    project.setup(pyproject, tool, tool_description)
  File "/tmp/pip-build-env-35vr5nuv/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 586, in setup
    self.apply_user_defaults(tool)
  File "/tmp/pip-build-env-35vr5nuv/overlay/lib/python3.8/site-packages/sipbuild/project.py", line 237, in apply_user_defaults
    self.builder.apply_user_defaults(tool)
  File "/tmp/pip-install-j2y7on81/pywpsrpc/project.py", line 280, in apply_user_defaults
    raise sipbuild.UserException(
sipbuild.exceptions.UserException
----------------------------------------

ERROR: Command errored out with exit status 1: /usr/bin/python3 /tmp/tmpyu0ms52v prepare_metadata_for_build_wheel /tmp/tmprm5vyfl2 Check the logs for full command output.

Environment

fantasyplus commented 1 year ago

尝试了源码编译也失败了,缺少.pro文件: web@ubuntu:~/web/web-project/backend/thirdparty/pywpsrpc$ sip-wheel These bindings will be built: common, rpcwpsapi, rpcwppapi, rpcetapi. Generating the common bindings... Generating the common .pyi file... Generating the rpcwpsapi bindings... Generating the rpcwpsapi .pyi file... Generating the rpcwppapi bindings... Generating the rpcwppapi .pyi file... Generating the rpcetapi bindings... Generating the rpcetapi .pyi file... Generating the common project... Generating the rpcwpsapi project... Generating the rpcwppapi project... Generating the rpcetapi project... Generating the sip project... Generating the top-level project... sip-wheel: '/usr/bin/qmake -recursive pywpsrpc.pro' failed returning 1

web@ubuntu:~/web/web-project/backend/thirdparty/pywpsrpc$ sip-build These bindings will be built: common, rpcwpsapi, rpcwppapi, rpcetapi. Generating the common bindings... Generating the common .pyi file... Generating the rpcwpsapi bindings... Generating the rpcwpsapi .pyi file... Generating the rpcwppapi bindings... Generating the rpcwppapi .pyi file... Generating the rpcetapi bindings... Generating the rpcetapi .pyi file... Generating the common project... Generating the rpcwpsapi project... Generating the rpcwppapi project... Generating the rpcetapi project... Generating the sip project... Generating the top-level project... sip-build: '/usr/bin/qmake -recursive pywpsrpc.pro' failed returning 1

fantasyplus commented 1 year ago

通过手动下载py3.6的whl文件,把python版本换成3.6,pip install pyxxx.whl成功了 真不容易