# HG changeset patch # User Thierry Florac # Date 1497879524 -7200 # Node ID aa78027158d6c899fea1d2c6dd05d6931c82115f # Parent b32bcb6a311ea5cfe713f2d39fa16df034eac437 Updated docstrings diff -r b32bcb6a311e -r aa78027158d6 src/pyams_utils/progress.py --- a/src/pyams_utils/progress.py Mon Jun 19 15:08:50 2017 +0200 +++ b/src/pyams_utils/progress.py Mon Jun 19 15:38:44 2017 +0200 @@ -69,7 +69,15 @@ @locked(name=PROGRESS_LOCK_NAME) def init_progress_status(progress_id, owner, label, tags=None, length=None, current=None): - """Initialize progress status for given task ID""" + """Initialize progress status for given task + + :param str progress_id: task ID + :param str owner: user ID associated with this task + :param str label: label associated with this task + :param tags: list of tags associated with given task + :param int length: whole length of the given task, if available + :param int current: current position in the whole task length, if available + """ status = {'status': 'running', 'owner': owner, 'label': label, @@ -107,7 +115,14 @@ @locked(name=PROGRESS_LOCK_NAME) def set_progress_status(progress_id, status='running', message=None, length=None, current=None): - """Set status of given task""" + """Set status of given task + + :param str progress_id: task ID + :param str status: new status of the given task + :param str message: status message associated with the given task + :param int length: whole length of the given task, if available + :param int current: current position in the whole task length, if available + """ progress_cache = get_progress_cache() cache_key = PROGRESS_TASK_KEY.format(progress_id) try: