This project has moved and is read-only. For the latest updates, please go here.

Tutorial for setting up VS for mixed Python dev

Apr 2, 2014 at 9:37 PM
I was wondering if there were any tutorials explaining how to setup VS for mixed python and c/c++ development? I've created a few custom python modules using the c api that I'd like to develop and debug.
Apr 2, 2014 at 10:27 PM
Pls check the docs. There is extensive walkrhru plus a video on youtube. Search for ptvs mixed mode debug.
Apr 2, 2014 at 10:31 PM
We have extensive docs for the debugging part of it, but not all the other things, like actually building them...

Right now this area is a bit of a mess in general - not because of anything to do with PTVS per se, but due to the general state of binary module development on Windows, what with the compiler versioning mess etc. I'm not aware of any thorough tutorials on the subject, unfortunately.

Generally speaking, my set-up was a Python project side by side with a C++ project, with a project-to-project dependency that ensures that C++ one gets build first (handy for F5). Though you'll need to use a recent 2.1 dev build to actually get the Python project to trigger a build on F5.

We currently don't have any special support for Python-to-C++ versions, so even with a P2P reference, you will still need to manually set up your Python project search path to point to the C++ project output directory. This is certainly something that I hope to improve in the future - ideally you should be able to just define the P2P reference from UI, and we wire everything up for you.

Beyond that, the debugging docs should cover everything in detail.