本文介绍了Windows上的Conda Python环境缺少DLL文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Windows上创建了一个新的Conda环境:conda create --name recco networkx

I created a new Conda environment on Windows:conda create --name recco networkx

然后我用source activate激活了它.到目前为止,一切都很好.运行conda list验证我已安装:

I then activated it with source activate. So far so good. Running conda list verifies that I have installed:

decorator 4.0.4
msvc_runtime 1.0.1
networkx 1.10
python 3.5.1

好吧,让我们运行python --version来确保一切都应该是正确的:

Ok, let's run python --version to make sure that everything is as it should be:

那甚至是什么意思?当我deactivate并运行python --version时,一切都按预期运行,而我又退回Python 3.4.1.

What does that even mean? When I deactivate and run python --version everything runs as expected and I'm handed back Python 3.4.1.

推荐答案

此问题是因为msvc_runtime程序包出现问题.该软件包应包含这些DLL.您可以验证环境的根文件夹的内容吗?这些DLL应该同时存在于(前缀)/Library/bin中.

This issue is because something is going wrong with the msvc_runtime package. That package should contain these DLLs. Can you please verify the contents of your environment's root folder? These DLLs should live both in there, and in (prefix)/Library/bin.

一个可能的原因可能是msvc_runtime的版本错误:对于Python 3.5.x,在conda list输出中应该显示[vc14],对于3.4.x,应显示[vc10]

One possible cause might be the wrong version of msvc_runtime: it should say [vc14] somewhere in conda list output for Python 3.5.x, and [vc10] for 3.4.x

另一个原因可能是激活后PATH错误,并且您没有正确拾取DLL.您使用的是cmd.exe还是Powershell?我们尚不支持Powershell-已知只有cmd.exe可以工作.如果使用cmd.exe,可以发布echo %PATH%的输出吗?

One other cause might be that PATH is wrong after activation, and you're not picking up the DLLs correctly. Are you using cmd.exe or powershell? We don't support powershell yet - only cmd.exe is known to work. If using cmd.exe, can you post the output of echo %PATH% please?

这篇关于Windows上的Conda Python环境缺少DLL文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-06 11:37