snakemake-executor-plugin-slurm 0.10.1__tar.gz → 0.11.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of snakemake-executor-plugin-slurm might be problematic. Click here for more details.
- {snakemake_executor_plugin_slurm-0.10.1 → snakemake_executor_plugin_slurm-0.11.0}/PKG-INFO +1 -1
- {snakemake_executor_plugin_slurm-0.10.1 → snakemake_executor_plugin_slurm-0.11.0}/pyproject.toml +1 -1
- {snakemake_executor_plugin_slurm-0.10.1 → snakemake_executor_plugin_slurm-0.11.0}/snakemake_executor_plugin_slurm/__init__.py +16 -2
- {snakemake_executor_plugin_slurm-0.10.1 → snakemake_executor_plugin_slurm-0.11.0}/LICENSE +0 -0
- {snakemake_executor_plugin_slurm-0.10.1 → snakemake_executor_plugin_slurm-0.11.0}/README.md +0 -0
- {snakemake_executor_plugin_slurm-0.10.1 → snakemake_executor_plugin_slurm-0.11.0}/snakemake_executor_plugin_slurm/utils.py +0 -0
|
@@ -42,6 +42,18 @@ class ExecutorSettings(ExecutorSettingsBase):
|
|
|
42
42
|
"required": False,
|
|
43
43
|
},
|
|
44
44
|
)
|
|
45
|
+
requeue: bool = field(
|
|
46
|
+
default=False,
|
|
47
|
+
metadata={
|
|
48
|
+
"help": """
|
|
49
|
+
Allow requeuing preempted of failed jobs,
|
|
50
|
+
if no cluster default. Results in `sbatch ... --requeue ...`
|
|
51
|
+
This flag has no effect, if not set.
|
|
52
|
+
""",
|
|
53
|
+
"env_var": False,
|
|
54
|
+
"required": False,
|
|
55
|
+
},
|
|
56
|
+
)
|
|
45
57
|
|
|
46
58
|
|
|
47
59
|
# Required:
|
|
@@ -79,8 +91,6 @@ class Executor(RemoteExecutor):
|
|
|
79
91
|
self._fallback_account_arg = None
|
|
80
92
|
self._fallback_partition = None
|
|
81
93
|
self._preemption_warning = False # no preemption warning has been issued
|
|
82
|
-
# providing a short-hand, even if subsequent calls seem redundant
|
|
83
|
-
self.settings: ExecutorSettings = self.workflow.executor_settings
|
|
84
94
|
|
|
85
95
|
def warn_on_jobcontext(self, done=None):
|
|
86
96
|
if not done:
|
|
@@ -145,6 +155,9 @@ class Executor(RemoteExecutor):
|
|
|
145
155
|
call += self.get_account_arg(job)
|
|
146
156
|
call += self.get_partition_arg(job)
|
|
147
157
|
|
|
158
|
+
if self.workflow.executor_settings.requeue:
|
|
159
|
+
call += " --requeue"
|
|
160
|
+
|
|
148
161
|
if job.resources.get("clusters"):
|
|
149
162
|
call += f" --clusters {job.resources.clusters}"
|
|
150
163
|
|
|
@@ -361,6 +374,7 @@ needs to restart this job upon a Snakemake restart.
|
|
|
361
374
|
|
|
362
375
|
We leave it to SLURM to resume your job(s)"""
|
|
363
376
|
)
|
|
377
|
+
yield j
|
|
364
378
|
elif status == "UNKNOWN":
|
|
365
379
|
# the job probably does not exist anymore, but 'sacct' did not work
|
|
366
380
|
# so we assume it is finished
|
|
File without changes
|
|
File without changes
|