- Notifications
You must be signed in to change notification settings - Fork749
Description
I'm having a bit of a hard time with a new box I've built. I have the following env:
- Win 10
- VS 2015 + Resharper 10
- Anaconda 3 with an additional 2.7 environment installed using
conda create -n python2 python=2.7 anaconda
- master branch of python.net
I am trying to get thePyObjectTest
running. If I run this I get:System.DllNotFoundException : Unable to load DLL 'python27': The specified module could not be found. (Exception from HRESULT: 0x8007007E)
Ok looks like it may be trying to load python27 and python3.x is the default. So I add this to the test:
string path = @"C:\Anaconda3\envs\python2\;" + Environment.GetEnvironmentVariable("Path", EnvironmentVariableTarget.Machine);Environment.SetEnvironmentVariable("Path", path, EnvironmentVariableTarget.Process);
The Unit Test then fails with no exception with the following error: 'Aborted' (no more details). Debugging does not help.
I have looked at the FAQ and searched the google (event Bing!!) and whilst there is plenty of info out there it all looks old.
Anyone had any luck with this kind of setup, my ultimate goal is to embed python in a .Net application. I will try to put this in a console application to try to remove unit tests (and resharper) from the equation but I don't think that will help.Done: Verified using theConsole
project and it also fails silently on thePythonEngine.Initialize()
call.
Note: I have verified that I am using 64 bit python (2.7 and 3.x) and I have verified that Python.Runtime and Python.Embedding.Tests are also targeting 64 bit so I dont think bitness is the issue.