Menu

Hopla is a lightweight tool for submitting script for computation within a PBS cluster. It basically wraps submission and provide access to logs.

Note

This page is a reference documentation. It only explains the class signature, and not how to use it. Please refer to the gallery for the big picture.

class hopla.utils.InfoWatcher(delay_s=60)[source]

An instance of this class is shared by all jobs, and is in charge of calling scheduler to check status for all jobs at once.

Parameters:

delay_s : int, default 60

maximum delay before each non-forced call to the cluster.

clear()[source]

Clears cache.

get_info(job_id)[source]

Returns a dict containing info about the job.

Parameters:

job_id : int

id of the job on the cluster.

get_state(job_id)[source]

Returns the state of the job.

Parameters:

job_id : str

id of the job on the cluster.

is_done(job_id)[source]

Returns whether the job is finished.

Parameters:

job_id : str

id of the job on the cluster.

abstract read_info(string)[source]

Reads the output of the update command and returns a dictionary containing main jobs information.

register_job(job_id)[source]

Register a job on the instance for shared update.

update()[source]

Updates the info of all registered jobs.

abstract property update_command

Return the command to list jobs status.

abstract property valid_status

Return the list of valid status.

Follow us

© 2025, hopla developers