Skip to content

Commit

Permalink
Merge pull request #20 from taskbadger/sk/mins-to-secs
Browse files Browse the repository at this point in the history
update schema with changes from API
  • Loading branch information
snopoke authored Sep 28, 2023
2 parents ead7be9 + cf36b28 commit 63fc3ba
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 10 deletions.
6 changes: 3 additions & 3 deletions taskbadger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -728,7 +728,7 @@ components:
minimum: 1
nullable: true
description: Maximum time to allow between task updates before considering
the task stale. (seconds)
the task stale. Only applies when task is in a running state. (seconds)
StatusEnum:
enum:
- pending
Expand Down Expand Up @@ -825,7 +825,7 @@ components:
minimum: 1
nullable: true
description: Maximum time to allow between task updates before considering
the task stale. (seconds)
the task stale. Only applies when task is in a running state. (seconds)
url:
type: string
readOnly: true
Expand Down Expand Up @@ -906,7 +906,7 @@ components:
minimum: 1
nullable: true
description: Maximum time to allow between task updates before considering
the task stale. (seconds)
the task stale. Only applies when task is in a running state. (seconds)
required:
- name
securitySchemes:
Expand Down
2 changes: 1 addition & 1 deletion taskbadger/internal/models/patched_task_request.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class PatchedTaskRequest:
max_runtime (Union[Unset, None, int]): Maximum duration the task can be running for before being considered
failed. (seconds)
stale_timeout (Union[Unset, None, int]): Maximum time to allow between task updates before considering the task
stale. (seconds)
stale. Only applies when task is in a running state. (seconds)
"""

name: Union[Unset, str] = UNSET
Expand Down
2 changes: 1 addition & 1 deletion taskbadger/internal/models/task.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ class Task:
max_runtime (Union[Unset, None, int]): Maximum duration the task can be running for before being considered
failed. (seconds)
stale_timeout (Union[Unset, None, int]): Maximum time to allow between task updates before considering the task
stale. (seconds)
stale. Only applies when task is in a running state. (seconds)
"""

id: str
Expand Down
2 changes: 1 addition & 1 deletion taskbadger/internal/models/task_request.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class TaskRequest:
max_runtime (Union[Unset, None, int]): Maximum duration the task can be running for before being considered
failed. (seconds)
stale_timeout (Union[Unset, None, int]): Maximum time to allow between task updates before considering the task
stale. (seconds)
stale. Only applies when task is in a running state. (seconds)
"""

name: str
Expand Down
8 changes: 4 additions & 4 deletions taskbadger/sdk.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,8 @@ def create_task(
value: The current 'value' of the task.
value_max: The maximum value the task is expected to achieve.
data: Custom task data.
max_runtime: Maximum expected runtime (minutes).
stale_timeout: Maximum allowed time between updates (minutes).
max_runtime: Maximum expected runtime (seconds).
stale_timeout: Maximum allowed time between updates (seconds).
actions: Task actions.
monitor_id: ID of the monitor to associate this task with.
Expand Down Expand Up @@ -128,8 +128,8 @@ def update_task(
value: The current 'value' of the task.
value_max: The maximum value the task is expected to achieve.
data: Custom task data.
max_runtime: Maximum expected runtime (minutes).
stale_timeout: Maximum allowed time between updates (minutes).
max_runtime: Maximum expected runtime (seconds).
stale_timeout: Maximum allowed time between updates (seconds).
actions: Task actions.
Returns:
Expand Down

0 comments on commit 63fc3ba

Please sign in to comment.