• python38安装jsonpath失败问题解决 上海


    前言

    在linux 上安装了python3.8.5环境,pip安装jsonpath的时候一直无法安装成功

    遇到问题

    运行环境:linux
    python环境:3.8.5
    pip安装jsonpath

    # pip3 install jsonpath
    Looking in indexes: http://mirrors.cloud.aliyuncs.com/pypi/simple/
    Requirement already satisfied: jsonpath in /root/python3/lib/python3.6/site-packages (0.82)
    You are using pip version 18.1, however version 21.3.1 is available.
    You should consider upgrading via the 'pip install --upgrade pip' command.
    [root@iZ2vchn8sk983jm605yhshZ hrun2_web]# pip38 install jsonpath
    Looking in indexes: http://mirrors.cloud.aliyuncs.com/pypi/simple/
    Collecting jsonpath
      Using cached http://mirrors.cloud.aliyuncs.com/pypi/packages/5f/c0/b54189dfe62f1a93ba294ab53508a81d440fc63adff253db369f557a996a/jsonpath-0.82.tar.gz (9.6 kB)
      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.
    

    一直无法安装成功

    解决办法

    可以先下载安装包到本地,在本地解压安装

    wget http://www.ultimate.com/phil/python/download/jsonpath-0.82.tar.gz
    

    解压文件

    tar -xvf jsonpath-0.82.tar.gz 
    

    用setup.py安装

    # cd jsonpath-0.82
    # python38 setup.py install
    

    show查看安装成功

    # pip38 show jsonpath
    Name: jsonpath
    Version: 0.82
    Summary: An XPath for JSON
    Home-page: http://www.ultimate.com/phil/python/#jsonpath
    Author: Phil Budne
    Author-email: phil@ultimate.com
    License: MIT
    Location: /root/python3.8/lib/python3.8/site-packages
    Requires: 
    Required-by: 
    
  • 相关阅读:
    CF519E
    Visual Studio 2017更新内容记录
    MSSQL导入数据时,出现“无法截断表 因为表正由Foreign key引用”错误
    使用NeatUpload控件实现ASP.NET大文件上传
    jquery 图片无缝切换
    less 能加快css编写?
    jquery 分页控件(二)
    jquery 分页控件(一)
    jquery仿天猫商城左侧导航菜单
    jquery 图片放大
  • 原文地址:https://www.cnblogs.com/yoyoketang/p/16457801.html
Copyright © 2020-2023  润新知