Message340846
Hi,
I have a full install of Python from the installer in:
C:\Program Files\Python37
Then, I added libraries using pip.
Everything works fine from the command line Python.
Then, I build my C++ application with VisualStudio and link to the Python DLLs. I start Python inside my app using the usual code:
Py_SetPath(...);
Py_SetProgramName(...);
Py_InitializeEx(0);
PyRun_SimpleString("import sys");
PyRun_SimpleString("print(sys.path)");
PyRun_SimpleString("print(sys.prefix)");
PyRun_SimpleString("print(sys.executable)");
>> ['C:\\Program Files\\Python37\\DLLs', 'C:\\Program Files\\Python37\\Lib', 'C:\\Program Files\\Python37', 'C:\\Program Files\\Python37\\Lib\\site-packages']
>> C:\Program Files\Python37
>> C:\Program Files\Python37\python.exe
So, everything works fine at this point. If I run the following:
PyRun_SimpleString("import numpy");
>> ImportError("No module named 'numpy.core._multiarray_umath'") |
|
Date |
User |
Action |
Args |
2019-04-25 15:28:36 | ecosatto | set | recipients:
+ ecosatto, paul.moore, tim.golden, zach.ware, steve.dower |
2019-04-25 15:28:36 | ecosatto | set | messageid: <1556206116.26.0.761997235629.issue36716@roundup.psfhosted.org> |
2019-04-25 15:28:36 | ecosatto | link | issue36716 messages |
2019-04-25 15:28:36 | ecosatto | create | |
|