๐ ๏ธ RH Task Manager
Check on or cancel a cloud run โ RH Task Manager
- config
- result
RH Task Manager is the pack's control panel for cloud tasks that are already running. Given a config and a task_id, it does exactly two things: report the task's current status, or ask RunningHub to cancel it. That's the whole feature set, and for a cloud bridge that's exactly what you want in graph form - because RH Execute is a blocking wait, and sometimes you need to do something about a job that's been queued for 20 minutes.
The main workflow: grab a task_id from an RH Execute run (or a batch from RH Batch Execute), drop it into this node, and pick an action.
Inputs
config- from RH Config. Required.task_id- the cloud task's ID. Required; an empty one raises "Task ID is required."action- a dropdown with exactly two choices:Get StatusorCancel Task.
What the outputs tell you
A single result STRING. It's an output node, so you see the string in the UI, and it's also printed to the console. The exact text depends on the action and what the API says back:
- Get Status returns something like
Status for <id>: QUEUED,RUNNING,COMPLETED, or an error string if the task failed cloud-side. When a task is done, the status comes back asCOMPLETED(the underlying check detects finished tasks by the presence of result files, not by a separate "done" flag). - Cancel Task returns
Successfully requested cancellation for task <id>.or a "Failed to cancelโฆ" message. Note it's a request - if the task already finished or the server refuses, cancel can fail gracefully.
How it works
Get Status polls /task/openapi/outputs for the task (the same endpoint the monitor uses) and interprets the result - queued, running, completed-with-files, or an error payload. Cancel POSTs to /task/openapi/cancel. Both are thin wrappers over the RunningHub open API, sharing the pack's shared utility code with Execute and Download. There's no polling loop here - each run is a one-shot check, which is exactly right for a status node.
Gotchas
The task ID is tied to your API key. A task from a different account, or one that's been purged from the platform, will come back as an error/unknown rather than a clean "not found." Also, cancellation isn't a refund: if the workflow already burned its credits before the cancel lands, the credits are spent. And because it's one-shot, keeping tabs on a long job means running the node repeatedly - which is fine on the canvas, just not automatic.
Install: ComfyUI Manager (search ComfyUI_RH_API) or git clone https://github.com/xuchenxu168/ComfyUI_RH_API.git into custom_nodes + pip install -r requirements.txt, restart.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| config | RH_CONFIG | โ | |
| task_id | STRING | โ | |
| action | COMBO | 2 options: Get Status, Cancel Task |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| result | STRING | โ |