0

我从来没有遇到过安装 python 包的问题,​​但是我在我的 Mac 上使用了多种安装方法(conda、pip、brew)。

当我使用 conda 安装 geopandas 时:见下面的错误,但是安装了 geopandas 0.6.1(最新版本的 ATM 是 0.9.0,conda upgrade geopandas 什么都不做)

当我使用 pip 安装 geopandas 时:没问题,运行时出现 0.9.0pip list

我什至尝试过conda install -c conda-forge geopandas,诚然我不知道这里有什么区别。

但无论我如何安装它,我都会在我的 python 脚本中导入它,我得到这个错误:

OSError: 找不到 lib c 或加载它的任何变体 []。

我已经尝试在 Spyder 和 VSCode 中导入,但我怀疑这会有所作为。

我已尝试多次卸载并重新安装该软件包。我认为这可能与我的 conda 环境有关?但我以前从未遇到过这样的问题。我这么说是因为在通过 conda 或 condo-forge 安装结束时,我收到了以下警告:

Verifying transaction: \ WARNING conda.core.path_actions:verify(962): Unable to create environments file. Path not writable.
  environment location: /Users/me/.conda/environments.txt

done
Executing transaction: - WARNING conda.core.envs_manager:register_env(50): Unable to register environment. Path not writable or missing.
  environment location: /Users/me/opt/anaconda3
  registry file: /Users/me/.conda/environments.txt
4

1 回答 1

0

在 conda 和 pip 上卸载并重新安装 usingconda install -c conda-forge geopandas似乎工作..这次。我发誓我在这之前做了 3 次。希望这可以帮助另一个困惑的 python 用户!

于 2021-04-21T15:33:44.913 回答