Hello,
I am about to start converting a large chunk of code from Python2 to Python3 and have some questions as to how to proceed. Ideally I would like to set up both versions of code in different virtual environments and then just switch back and forth between the two environments when debugging and testing.
I’ve used conda a bit in the past, added and installed python packages to an environment and then successfully used them to run my code. But I have a slightly different use-case this time in that the code that needs to be converted isn’t a “package”, but rather a collection of 40+ stand-alone scripts. So, what would be the easiest way to have the versatility of virtual environments and quickly/seamlessly switch from running the Python2 version of the scripts to the Python3 version?
I can think of a few “hack-jobs” (i.e. setting PYTHONPATH to the conda package directory for the environment that I want to run in), but I hope there’s a more proper/seamless way to accomplish this.
Thank you for any advice,
Catherine
My question is how to use conda to create a virtual environment for something that really isn’t a proper python “package”, but rather a collection of 40+ separate executable scripts.
What’s the best, least-kludgy way of getting all these scripts into conda so I can switch between the python2 and python3 versions of them seamlessly?
Catherine