From 2417d0f4f57c80ac1bab5d15aff3548974964623 Mon Sep 17 00:00:00 2001 From: Jan Janssen Date: Sun, 10 Aug 2025 21:15:02 +0200 Subject: [PATCH 1/2] Fix SLURM submisson with additional information --- pysqa/wrapper/slurm.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pysqa/wrapper/slurm.py b/pysqa/wrapper/slurm.py index 7f1a199..7f168d4 100644 --- a/pysqa/wrapper/slurm.py +++ b/pysqa/wrapper/slurm.py @@ -47,7 +47,7 @@ def get_queue_status_command(self) -> list[str]: @staticmethod def get_job_id_from_output(queue_submit_output: str) -> int: """Extracts the job ID from the output of the job submission command.""" - return int(queue_submit_output.splitlines()[-1].rstrip().lstrip().split()[-1]) + return int(queue_submit_output.splitlines()[-1].rstrip().lstrip().split()[-1].split(';')[0]) @staticmethod def convert_queue_status(queue_status_output: str) -> pandas.DataFrame: From b6a170245d705ec47ebcc7aeed1e2c3b4d5ce0c1 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sun, 10 Aug 2025 19:15:18 +0000 Subject: [PATCH 2/2] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- pysqa/wrapper/slurm.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/pysqa/wrapper/slurm.py b/pysqa/wrapper/slurm.py index 7f168d4..6ba6f19 100644 --- a/pysqa/wrapper/slurm.py +++ b/pysqa/wrapper/slurm.py @@ -47,7 +47,13 @@ def get_queue_status_command(self) -> list[str]: @staticmethod def get_job_id_from_output(queue_submit_output: str) -> int: """Extracts the job ID from the output of the job submission command.""" - return int(queue_submit_output.splitlines()[-1].rstrip().lstrip().split()[-1].split(';')[0]) + return int( + queue_submit_output.splitlines()[-1] + .rstrip() + .lstrip() + .split()[-1] + .split(";")[0] + ) @staticmethod def convert_queue_status(queue_status_output: str) -> pandas.DataFrame: