diff --git a/aiida_hyperqueue/scheduler.py b/aiida_hyperqueue/scheduler.py index 2ccb1bf..915dd53 100644 --- a/aiida_hyperqueue/scheduler.py +++ b/aiida_hyperqueue/scheduler.py @@ -243,6 +243,15 @@ def _parse_joblist_output(self, retval: int, stdout: str, stderr: str) -> list: return job_info_list + def _get_detailed_job_info_command(self, job_id): + """Return the command to run to get the detailed information on a job, + even after the job has finished. + + The output text is just retrieved, and returned for logging purposes. + `jq` is used to transform the json into a one-line string. + """ + return f"hq job info {job_id} --output-mode json | jq -c ." + def _get_kill_command(self, jobid): """Return the command to kill the job with specified jobid.""" submit_command = f"hq job cancel {jobid}"