jieba Installation fails with the latest version of pip

sxissh06  于 2022-10-22  发布在  其他
关注(0)|答案(1)|浏览(118)

Looks like we're unable to install jieba with pip==22.0.4 and setuptools==62.0.0 (Python 3.9):

$ pip install jieba
Collecting jieba
  Downloading jieba-0.42.1.tar.gz (19.2 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 19.2/19.2 MB 1.7 MB/s eta 0:00:00
  Preparing metadata (setup.py) ... error
  error: subprocess-exited-with-error

  × python setup.py egg_info did not run successfully.
  │ exit code: 1
  ╰─> [1 lines of output]
      ERROR: Can not execute `setup.py` since setuptools is not available in the build environment.
      [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.
j8ag8udp

j8ag8udp1#

Can not execute setup.py since setuptools is not available in the build environment.
检查一下 pip show setuptools 吧,可能要先 pip install setuptools

相关问题