Search code examples
pythonpipvirtualenvcondaminiconda

question about virtual environments from conda to virtualenv


I have been working on a project in python that its inside an environment created at a linux machine. I recently got a new pc and i tried freebsd so i decided to see if i can port the settings, since these environments are supposed to be platform independent.

Since there is no support for conda in freebsd, i decided to write a script to migrate the dependencies from conda to virtualenv. The script, although it translates the .yml file into the .txt file needed for pip to install the dependencies, i can see that there are still a lot of packages missing, especially from the dependencies label in the .yml file.

Does it mean that these packages are not yet ported on freebsd or is there a different way to add them in the .txt file instead of just their name?


Solution

  • Does it mean that these packages are not yet ported on freebsd or is there a different way to add them in the .txt file instead of just their name?

    It sounds like pip can't find a number of your dependencies, so yes.

    Keep in mind that conda and pip are completely different build systems, despite being mostly compatible with each other and despite most packages available on one being available on the other. This also means that conda list usually includes some packages you don't necessarily need to install via pip. So you may be better off starting from scratch with a new requirements.txt file that includes the packages you actually need, and just let pip find what else it needs (which, again, is likely different than what conda needs).