Skip to content

Commit 6c767cf

Browse files
handle more job status on SGE system (#491)
<!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Enhanced job status tracking with the addition of new status conditions for improved accuracy in job state representation. - **Bug Fixes** - Modified logic for determining job status to better reflect current conditions, improving system responsiveness. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent 39846ae commit 6c767cf

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

dpdispatcher/machines/pbs.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -261,6 +261,7 @@ def default_resources(self, resources):
261261
pass
262262

263263
def check_status(self, job):
264+
### https://softpanorama.org/HPC/Grid_engine/Queues/queue_states.shtml
264265
job_id = job.job_id
265266
status_line = None
266267
if job_id == "":
@@ -294,10 +295,12 @@ def check_status(self, job):
294295
else:
295296
status_word = status_line.split()[4]
296297
# dlog.info (status_word)
297-
if status_word in ["qw"]:
298+
if status_word in ["qw", "hqw", "t"]:
298299
return JobStatus.waiting
299-
elif status_word in ["r"]:
300+
elif status_word in ["r", "Rr"]:
300301
return JobStatus.running
302+
elif status_word in ["Eqw", "dr", "dt"]:
303+
return JobStatus.terminated
301304
else:
302305
return JobStatus.unknown
303306

0 commit comments

Comments
 (0)