snakemake / snakemake-executor-plugin-slurm

A Snakemake executor plugin for submitting jobs to a SLURM cluster
MIT License
9 stars 13 forks source link

Slurm executor plugin is not found after installation #77

Closed vsbuffalo closed 2 months ago

vsbuffalo commented 2 months ago

Hi,

I am having trouble getting even a simple MRE to work. I also have not found any examples or installation instructions to get this plugin to work, so I'm hoping you can help me.

requirements.txt:

snakemake>=8
snakemake-executor-plugin-cluster-generic
$ pip install --requirement requirements.txt
$ snakemake --executor slurm
[...]
snakemake: error: argument --executor/-e: invalid choice: 'slurm' (choose from 'cluster-generic', 'local', 'dryrun', 'touch')

I have not found any instructions in the Snakemake docs on how to register a plugin, and assume such an action is unneeded. Is there something wrong with this MRE?

Note that this has not worked on a linux cluster, nor my OS X machine.

Thanks, Vince

cmeesters commented 2 months ago

Hi Vince,

The plugin is called snakemake-executor-slurm and installing it will also install its dependency snakemake-executor-slurm-jobstep. Neither installing snakemake nor snakemake-executor-plugin-cluster-generic will install this plugin. The latter is not even designed for a SLURM batch system.

BTW — Dependency resolution works regardless of the operating system you are working on.

vsbuffalo commented 2 months ago

My apologies for this error (perhaps I shouldn't have created this issue so late at night).

But the error was in my issue, not in my steps I think. I had tried manually installing snakemake-executor-plugin-slurm too with pip. (Note: above you say snakemake-executor-slurm — did you mean snakemake-executor-plugin-slurm which is what the documentation here says? When I try pip install snakemake-executor-slurm it says it does not exist.)

The correct requirements.txt is:

snakemake>=8
snakemake-executor-plugin-slurm

but even with this, and pip install --requirement requirements.txt and snakemake --executor slurm it still can't find it:

$ snakemake --executor slurm
[...]
snakemake: error: argument --executor/-e: invalid choice: 'slurm' (choose from 'cluster-generic', 'local', 'dryrun', 'touch')

Apologies if I am missing something obvious here.

vsbuffalo commented 2 months ago

Hm, so I did get this working on my linux cluster (I am not sure how). Either way, I am happy to close the issue. Thank you.