snakemake-executor-plugin-cluster-generic

raw JSON →
1.0.9 verified Mon Apr 27 auth: no python

A Snakemake executor plugin for generic cluster submission via command-line tools like qsub, sbatch, bsub. It allows users to define cluster submission commands via Snakemake profiles or configuration. Current version: 1.0.9. Releases are driven by upstream Snakemake interface changes; no fixed cadence.

pip install snakemake-executor-plugin-cluster-generic
error ModuleNotFoundError: No module named 'snakemake.executors.cluster_generic'
cause Import from the old Snakemake built-in path after switching to the plugin.
fix
Use 'from snakemake_executor_plugin_cluster_generic import ClusterGenericExecutor' instead.
error snakemake_executor_plugin_cluster_generic.settings.ExecutorSettingsError: submit_cmd must be set
cause The plugin requires the 'submit_cmd' configuration to be provided via profile or command-line.
fix
Add 'submit_cmd' to your profile (e.g., 'submit_cmd: "sbatch --parsable {script}"') or pass '--cluster-submit-cmd'.
breaking Requires Python >=3.11; not compatible with older Python versions.
fix Upgrade to Python 3.11 or later.
breaking The plugin is incompatible with Snakemake v7.x's built-in cluster support. Must use Snakemake >=7.8 (with adapter module) or >=8.x native plugin support.
fix Use Snakemake >=8.0 or install 'snakemake' together with the plugin.
deprecated The old configuration keys 'cluster', 'cluster-status', 'cluster-cancel' etc. are deprecated. Use 'submit_cmd', 'status_cmd', 'cancel_cmd', etc. in the profile dict.
fix Update your Snakemake profile to use the new keys (e.g., 'submit_cmd' instead of 'cluster').
gotcha Missing 'submit_cmd' configuration will cause a runtime error: 'submit_cmd must be set'.
fix Define 'submit_cmd' in your profile or environment (e.g., --cluster-submit-cmd).

Instantiate the plugin executor. Usually configured via Snakemake profiles; this shows direct usage.

import os
from snakemake_executor_plugin_cluster_generic import ClusterGenericExecutor

# Typically configured via Snakemake profile, but you can instantiate directly:
executor = ClusterGenericExecutor()
# Then pass to Snakemake workflow (requires proper context)
print('Executor ready')