Skip to content

[Partner Nodes] feat(Luma): add support for Luma Rays 3.2#14540

Merged
bigcat88 merged 2 commits into
masterfrom
feat/api-nodes/Luma-Ray-3.2
Jun 19, 2026
Merged

[Partner Nodes] feat(Luma): add support for Luma Rays 3.2#14540
bigcat88 merged 2 commits into
masterfrom
feat/api-nodes/Luma-Ray-3.2

Conversation

@bigcat88

@bigcat88 bigcat88 commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

PR adds 7 new nodes for the new Luma Ray 3.2 video model

API Node PR Checklist

Scope

  • Is API Node Change

Pricing & Billing

  • Need pricing update
  • No pricing update

If Need pricing update:

  • Metronome rate cards updated
  • Auto‑billing tests updated and passing

QA

  • QA done
  • QA not required

Comms

  • Informed Kosinkadink

@coderabbitai

coderabbitai Bot commented Jun 18, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

comfy_api_nodes/nodes_luma.py is updated to support Luma Ray 3.2 video workflows. Luma API imports are extended with Ray 3.2 keyframe chain/item types, additional request/option models, and upload_video_to_comfyapi. The previous inline submit/poll logic is extracted into a reusable _luma2_submit_and_poll async helper that posts to /proxy/luma_2/generations, polls until completion, validates output presence, and raises typed RuntimeErrors on failure. LumaImageNode is updated to use this helper. Seven new IO.ComfyNode subclasses are added — covering text-to-video, image-to-video, single/multi-keyframe interpolation, video edit, video reframe, and forward/backward extension — each building Luma2GenerationRequest objects and routing through shared _ray32_generate/_luma2_submit_and_poll helpers. All new classes are registered in LumaExtension.get_node_list().

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 10.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately reflects the main change: adding support for Luma Ray 3.2 video model with 7 new nodes.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description check ✅ Passed The pull request description clearly describes the addition of 7 new nodes for Luma Ray 3.2 video model and includes relevant checklist items confirming API node changes, pricing updates, and QA completion.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🧹 Nitpick comments (1)
comfy_api_nodes/nodes_luma.py (1)

1334-1334: 🏗️ Heavy lift

Avoid blocking the async worker while encoding uploaded videos.

These new long-video paths await upload_video_to_comfyapi, whose helper serializes the input with synchronous video.save_to(...) before the upload; 18–30s inputs can block the event loop. Prefer moving that encode/duration probe into asyncio.to_thread or an equivalent executor, ideally inside upload_video_to_comfyapi. Based on learnings, newly introduced synchronous CPU/IO-heavy work inside comfy_api_nodes async execute paths should be offloaded.

Also applies to: 1387-1387

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@comfy_api_nodes/nodes_luma.py` at line 1334, The call to
upload_video_to_comfyapi contains blocking synchronous I/O operations like
video.save_to() that can take 18-30 seconds and block the async event loop.
Refactor the upload_video_to_comfyapi function to offload the synchronous
encode/duration probe work using asyncio.to_thread() or an equivalent executor
to prevent blocking the worker thread. Ensure this refactoring applies to all
occurrences where upload_video_to_comfyapi is called in the new long-video paths
throughout the file.

Source: Learnings

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@comfy_api_nodes/nodes_luma.py`:
- Line 1051: The validate_string function calls in the Ray 3.2 execute paths use
strip_whitespace=False, which allows prompts containing only whitespace to pass
validation despite being effectively empty when sent to the Luma API. To match
the existing Luma UNI-1 validation behavior, either remove the
strip_whitespace=False parameter to use the default whitespace stripping
behavior, or explicitly set strip_whitespace=True. Apply this change to all
validate_string calls for prompt parameters at the specified line locations
(1051, 1105, 1232, 1329, 1384, and 1454).
- Around line 1330-1341: Remove the hardcoded duration logic in the try/except
block (lines 1330-1332) that calculates and sets duration to either "5s" or
"10s". Since the Luma2VideoOptions class accepts duration as an optional
parameter and the API should inherit the source video's duration for video_edit
type requests, omit the duration parameter entirely when constructing
Luma2VideoOptions for this request path. Delete the duration variable assignment
and simply remove duration from the Luma2VideoOptions initialization.

---

Nitpick comments:
In `@comfy_api_nodes/nodes_luma.py`:
- Line 1334: The call to upload_video_to_comfyapi contains blocking synchronous
I/O operations like video.save_to() that can take 18-30 seconds and block the
async event loop. Refactor the upload_video_to_comfyapi function to offload the
synchronous encode/duration probe work using asyncio.to_thread() or an
equivalent executor to prevent blocking the worker thread. Ensure this
refactoring applies to all occurrences where upload_video_to_comfyapi is called
in the new long-video paths throughout the file.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 9b3df748-7bca-42fd-9237-e25de76dc70a

📥 Commits

Reviewing files that changed from the base of the PR and between 16514da and f2e7fa5.

⛔ Files ignored due to path filters (1)
  • comfy_api_nodes/apis/luma.py is excluded by !comfy_api_nodes/apis/**
📒 Files selected for processing (1)
  • comfy_api_nodes/nodes_luma.py

Comment thread comfy_api_nodes/nodes_luma.py Outdated
Comment thread comfy_api_nodes/nodes_luma.py
Signed-off-by: bigcat88 <bigcat88@icloud.com>
@bigcat88 bigcat88 force-pushed the feat/api-nodes/Luma-Ray-3.2 branch from f2e7fa5 to 12eae7c Compare June 18, 2026 15:46
@bigcat88 bigcat88 merged commit 5955ddf into master Jun 19, 2026
16 of 17 checks passed
@bigcat88 bigcat88 deleted the feat/api-nodes/Luma-Ray-3.2 branch June 19, 2026 05:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants