栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 软件开发 > 后端开发 > Python

pip安装报错Could NOT find Arrow (missing: Arrow

Python 更新时间: 发布时间: IT归档 最新发布 模块sitemap 名妆网 法律咨询 聚返吧 英语巴士网 伯小乐 网商动力

pip安装报错Could NOT find Arrow (missing: Arrow

在ubuntu pip安装 datasets matplotlib pyarrow等包时 可能遇到如下报错:

  -- Found Python lib /usr/lib/python3.6/config-3.6m-x86_64-linux-gnu/libpython3.6m.so
  -- Found PkgConfig: /usr/bin/pkg-config (found version "0.29.1")
  -- Could NOT find Arrow (missing: Arrow_DIR)
  -- Checking for module 'arrow'
  --   No package 'arrow' found
  CMake Error at /usr/share/cmake-3.10/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
    Could NOT find Arrow (missing: ARROW_INCLUDE_DIR ARROW_LIB_DIR
    ARROW_FULL_SO_VERSION ARROW_SO_VERSION)
  Call Stack (most recent call first):
    /usr/share/cmake-3.10/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
    cmake_modules/FindArrow.cmake:450 (find_package_handle_standard_args)
    cmake_modules/FindArrowPython.cmake:46 (find_package)
    CMakeLists.txt:229 (find_package)


  -- Configuring incomplete, errors occurred!
  See also "/tmp/pip-build-y_r12kuh/pyarrow/build/temp.linux-x86_64-3.6/CMakeFiles/CMakeOutput.log".
  error: command 'cmake' failed with exit status 1

  ----------------------------------------
  Failed building wheel for pyarrow
  Running setup.py clean for pyarrow
Failed to build pyarrow
Installing collected packages: pyarrow
  Running setup.py install for pyarrow ... error
    Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-y_r12kuh/pyarrow/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('rn', 'n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-ffo8pwle-record/install-record.txt --single-version-externally-managed --compile:
    /usr/local/lib/python3.6/dist-packages/setuptools/__init__.py:151: SetuptoolsDeprecationWarning: setup_requires is deprecated. Supply build dependencies using PEP 517 pyproject.toml build-requires.
      SetuptoolsDeprecationWarning,
    running install
    /usr/local/lib/python3.6/dist-packages/setuptools/command/install.py:37: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
      setuptools.SetuptoolsDeprecationWarning,
    running build
    running build_py
    creating build
 

网上搜到的其他解决方案都没解决我的问题,最终本人用的:

python -m pip install --upgrade pip

另外, 拿到一个新linux环境,最常安装和修改的东西  可以记下来,下次使用新环境按checklist操作 可以快速避坑。新增和修改配置文件 可以echo后重定向或sed之类。  一般拿到新环境后, centos需要安装的东西 包括但不限于如下; 如果新安装python版本,安装后需要更新的其他工具(例如setuptools, pip)和源的修改 都可以记下来依次执行,有时候忘了更新这些,后面可能要定位奇怪的安装问题,这样的定位有点浪费时间,可以避免的。 本人平时记录了centos的,ubuntu的没记,这不,忘记更新pip,ubuntu上就踩坑了(将来多装几次ubuntu再发出来)

yum -y update
yum -y install gcc
yum -y install zlib zlib-devel
yum -y install bzip2 bzip2-devel
yum -y install ncurses ncurses-devel
yum -y install readline readline-devel
yum -y install openssl openssl-devel
yum -y install openssl-static
yum -y install xz lzma xz-devel
yum -y install sqlite sqlite-devel
yum -y install gdbm gdbm-devel
yum -y install tk tk-devel
yum -y install libffi libffi-devel

yum -y install python-devel
yum -y install libevent-devel
yum -y install gcc gcc-c++ 

安装python3后,除了常用的库 还有:

pip3 install --upgrade pip
pip3 install --upgrade setuptools
pip3 install setuptools_scm

当然 使用标准化后的docker 也是OK的。不过基础环境  还是要准备一下。

转载请注明:文章转载自 www.mshxw.com
本文地址:https://www.mshxw.com/it/357554.html
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号