Skip to content

Conda envs

dickgroenenberg edited this page Sep 7, 2022 · 2 revisions

Conda envs inside Galaxy

The way Galaxy is currently setup is that each tool runs in its own conda environment,
which is defined by <requirements> in the .xml of each tool.

The name of mulled conda environments can be found in 'manage dependencies' in the admin panel.
To show the name of the used conda environment and the python version running in stdout, add the
following to the top of the tools' shell script:
echo $CONDA_DEFAULT_ENV
python --version

Conda envs without Galaxy

For testing purposes it can be useful to create conda environments outside of Galaxy
(assuming that conda has been installed):
conda create -n HVT python pandas requests
conda activate HVT
  work in the environment, install additional packages if required
conda deactivate

where HV is the name(-n) of the new conda environment (in this case for data HarVesTing)
python pandas requests will install the latest version of python and the packages pandas
and requests. You can also specify version numbers: python=3.6 pandas=1.0.1

List all available conda environments:
conda info -e

List all installed packages in active environment:
conda list

Check version of Python libraries

python
import pandas
print(pandas.__version__)

Clone this wiki locally