AgnostiqHQ / covalent-slurm-plugin

Executor plugin interfacing Covalent with Slurm
https://covalent.xyz
Apache License 2.0
27 stars 6 forks source link

SLURM job crashes if Conda is not installed #60

Closed Andrew-S-Rosen closed 1 year ago

Andrew-S-Rosen commented 1 year ago

Environment

What is happening?

Note: this one is motivated by some "getting started" snags by a colleague of mine, @rwexler.

https://github.com/AgnostiqHQ/covalent-slurm-plugin/blob/bcf2049b61da4e9ddc1d507ef9b56562569d9d84/covalent_slurm_plugin/slurm.py#L337-L346

Because of this line, there is currently no way to use the plugin if you aren't using conda. There are many situations in which the user may not want to use an Anaconda environment. For instance, maybe the user is loading an HPC-hosted Python module, which they've installed packages with via pip. They would have to load the module in their prerun_commands but otherwise shouldn't be required to use conda.

How can we reproduce the issue?

Submit a job without conda in the PATH.

What should happen?

Covalent should support running with Python in the PATH but not necessarily relying on Conda.

Any suggestions?

Only add the conda-related lines if conda_env is not False.

santoshkumarradha commented 1 year ago

@arosen93 thank you for this ! this is an side effect of initial versions of covalent being only installable from conda due to few non python dependencies. But that's not the case now, I assume everything should work sans conda check. @wjcunningham7 can you confirm this?