PyDev/Eclipse not loading _mklinit when run from a Conda environment

前端 未结 5 1890
借酒劲吻你
借酒劲吻你 2020-12-18 08:24

I created a conda environment - testenv2 - installed python/numpy/pandas. Added it as the interpreter in Eclipse project settings and using it to run my test python script.

5条回答
  •  渐次进展
    2020-12-18 09:09

    Here you can find the section of the troubleshooting page for conda related to your issue and I think the inactive environment is the problem here.

    With the latest conda version the developers decided that instead of polluting your environment variables with their paths you need to ensure your environment is activated when performing any action in it, otherwise things like required DLLs will not be found.

    Current IDEs have not necessarily adapted to that change yet, I myself can't use integrated Python consoles in PyCharm because it tries to run it without activating the environment beforehand. Apparently the issue should be fixed in the next release.

    Anyways, if you can't make your IDE activate conda environments before running any commands, you'll just have to bear with using ordinary terminals, where you can ensure the environment is active.

提交回复
热议问题