feat(jobs): surface text/STRING node outputs in local jobs status as text_outputs (BE-3346)#550
feat(jobs): surface text/STRING node outputs in local jobs status as text_outputs (BE-3346)#550mattmillerai wants to merge 1 commit into
Conversation
…text_outputs (BE-3346)
|
Warning Review limit reachedYou’ve reached a temporary PR review limit under our Fair Usage Limits Policy. Next review available in: 2 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
✨ Finishing Touches🧪 Generate unit tests (beta)
✨ Simplify code
Comment |
There was a problem hiding this comment.
🔍 Cursor Review — Consolidated panel
Triggered by @mattmillerai.
Judge call failed (status=parse_error): Could not parse JSON findings from output. First 500 chars:
I've verified the code and line anchors. My analysis confirms: line 733 builds `f"[{node_id}] {first}"` and line 735 adds it to a Rich table cell (markup enabled by default), the line-730 guard misfires on leading-newline text, and the preview count is unbounded despite the "bounded" comment.
[
{
"file": "comfy_cli/command/jobs.py",
"line": 733,
"side": "RIGHT",
"severity": "high",
"body": "`node_id` and `text` are interpolated into `f\"[{node_id}] {first}\"` and handed to
Re-trigger by removing and re-adding the cursor-review label.
ELI-5
When a ComfyUI workflow has a node that produces text — like a Gemini node describing an image, or a ShowText node — that text is stored by ComfyUI but
comfy jobs statusnever showed it. You could only get it by manuallycurl-ing the server's/historyendpoint. This PR makescomfy jobs statusinclude those text outputs, so tools built on comfy-cli (like comfy-local-mcp) can read captions/descriptions/VLM tags without shelling out tocurl.What changed
extract_text_outputs(record)incomfy_client.py, next toextract_output_entries. For eachnode_idin the history record'soutputs, whennode_output["text"]is a list, it keeps thestritems and returns{node_id: [text, ...]}, omitting nodes with no text. Dict-shape tolerant (non-dictoutputs/node → skipped, never raises).jobs statussnapshot (_snapshot) as an always-present additive key"text_outputs":extract_text_outputs(body)on the history branch,{}on the queued/running branch. All existing keys (outputs,outputs_by_node,outputs_by_item,error,status) are unchanged — additive only.[node_id] <preview>). The--jsonpath emits the full untruncated strings, exactly like the existingerrorpayload.Why
Text outputs (
GeminiNodeimage descriptions,ShowText, anything emittingui.text) live inGET /history/<prompt_id>underoutputs[node_id]["text"]as bare strings, but the media-key flatten (images/gifs/videos/audio/files, each requiring a dict withfilename) drops them. This blocks local LLM/vision workflows (captioning, VLM tagging, prompt expansion) through the comfy-cli → comfy-local-mcp toolchain.Because comfy-local-mcp's
job_statusreturns comfy-cli's envelopedataverbatim, this additive key flows through the MCP with zero code changes there (a follow-up will just update the MCP docstring + version floor).Scope / judgment calls
_cloud_status_snapshot— belongs to the cloud sibling ticket),comfy downloadmaterializing text to files, and other UI-output keys (string, etc.)._wait_fetch_snapshot(jobs wait) is intentionally untouched: when the server is up it reuses_snapshot(inheriting the new key); its on-disk fallback is a minimal shape and out of scope for thisjobs statusticket.textare preserved as legitimate (empty) text outputs rather than silently dropped; only non-stritems in the list are filtered out.Testing
extract_text_outputs: text present / absent / non-listtext/ mixed-type items (only strings kept) / non-dictoutputs& node / int node-id coercion._snapshottests:text_outputsgrouped-by-node with full untruncated strings on the history branch;{}on the no-text history branch;{}on the queued/running branch.…marker) while the full text is not rendered in pretty mode.pytest(2583 passed, 37 skipped),ruff check ., andruff format --check .all pass (verified against the CI-pinned ruff0.15.15).🤖 Generated with Claude Code