You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

使用pip安装dbt-snowflake失败求助:pyarrow编译wheel报错

解决pip安装dbt-snowflake时pyarrow编译失败的问题

错误信息

note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for pyarrow
Failed to build pyarrow
ERROR: Could not build wheels for pyarrow, which is required to install pyproject.toml-based projects
[end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.

解决方案

  • 升级pip及构建工具
    确保pip、setuptools和wheel是最新版本,避免工具本身的兼容性问题:

    pip install --upgrade pip setuptools wheel
    
  • 安装系统级编译依赖
    pyarrow编译需要C++编译环境和相关依赖库,根据操作系统安装:

    • Debian/Ubuntu:
      sudo apt-get install build-essential cmake libboost-all-dev
      
    • macOS:
      先安装Xcode命令行工具:
      xcode-select --install
      
      再通过Homebrew安装依赖:
      brew install cmake boost
      
    • Windows:
      安装Visual Studio Build Tools,勾选「Desktop development with C++」组件(包含MSVC编译器、CMake等)
  • 直接安装预编译pyarrow包
    跳过本地编译,使用官方预编译的wheel包:

    pip install pyarrow --only-binary :all:
    

    完成后再尝试安装dbt-snowflake:

    pip install dbt-snowflake
    
  • 指定兼容的dbt-snowflake版本
    部分新版本dbt-snowflake依赖的pyarrow版本对编译环境要求较高,可尝试安装稳定旧版本:

    pip install dbt-snowflake==1.8.0
    
  • 使用conda安装(推荐)
    若使用conda环境,conda会自动处理所有依赖(包括预编译的pyarrow):

    conda install -c conda-forge dbt-snowflake
    

内容的提问来源于stack exchange,提问作者Micah Tobias

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.08.09 14:00:57