ganga-devs / ganga

Ganga is an easy-to-use frontend for job definition and management
GNU General Public License v3.0
100 stars 159 forks source link

Job master kill error with failed subjobs #2358

Closed mesmith75 closed 5 months ago

mesmith75 commented 5 months ago

This needs fixing:

[11:27:10]
Ganga In [12]: jobs(2317).kill()
ERROR    failed to kill job 2317: JobStatusError: forbidden status transition of job 2317 from "failed" to "killed"
ERROR    JobError: failed to kill job 2317: JobStatusError: forbidden status transition of job 2317 from "failed" to "killed"
egede commented 5 months ago

To reply with an error to killing a job in a terminal (i.e. completed, failed, killed) state seems the correct behaviour to me.

mesmith75 commented 5 months ago

The job 2317 was in the running state. Some subjobs were completed, some failed and some were running. I would assume that doing kill() on the master job would kill the remaining running subjobs without complaint.

egede commented 5 months ago

Yes, I agree that behaviour is not ideal. In my mind, what should be changed is that the request to kill a completed/failed job should just result in "no operation" and the job just stay as completed/failed.