New Components - RenderIO#21181
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
|
Important Review skippedReview was skipped due to path filters ⛔ Files ignored due to path filters (1)
CodeRabbit blocks several paths by default. You can override this behavior by explicitly including those paths in the path filters. For example, including ⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
📝 WalkthroughWalkthroughAdds a complete RenderIO Pipedream integration: expands ChangesRenderIO Integration
Sequence DiagramssequenceDiagram
participant User
participant RunFFmpegAction as run-ffmpeg-command action
participant RenderioApp as renderio.app.mjs
participant RenderioAPI as RenderIO API
participant Filesystem
User->>RunFFmpegAction: invoke with inputFiles, outputFiles, command, options
RunFFmpegAction->>RunFFmpegAction: validate command, key prefixes (in_/out_), maxCommandRunSeconds
RunFFmpegAction->>RenderioApp: runFfmpegCommand(data)
RenderioApp->>RenderioAPI: POST /commands/run-ffmpeg-command (X-API-KEY)
RenderioAPI-->>RenderioApp: response with command_id
RenderioApp-->>RunFFmpegAction: initial response
alt waitForCompletion = true
loop poll every 3s until isTerminalStatus or timeout
RunFFmpegAction->>RenderioApp: getFfmpegCommand(commandId)
RenderioApp->>RenderioAPI: GET /commands/{commandId}
RenderioAPI-->>RenderioApp: status update
RenderioApp-->>RunFFmpegAction: updated response
end
alt downloadFilesToTmp = true
loop for each output HTTP URL
RunFFmpegAction->>RenderioAPI: GET storage URL (arraybuffer)
RenderioAPI-->>RunFFmpegAction: binary data
RunFFmpegAction->>Filesystem: writeFile to STASH_DIR or /tmp
end
end
RunFFmpegAction->>RunFFmpegAction: check error_message and terminal status
end
RunFFmpegAction-->>User: export $summary, return final response
sequenceDiagram
participant Timer
participant NewFFmpegCommandSource as new-ffmpeg-command source
participant RenderioApp as renderio.app.mjs
participant RenderioAPI as RenderIO API
participant PipedreamDB as db (lastTs)
Timer->>NewFFmpegCommandSource: run() or deploy()
NewFFmpegCommandSource->>PipedreamDB: _getLastTs()
PipedreamDB-->>NewFFmpegCommandSource: lastTs
loop paginated batches (offset, limit) until maxPages
NewFFmpegCommandSource->>RenderioApp: listCommands(limit, offset)
RenderioApp->>RenderioAPI: GET /commands (X-API-KEY)
RenderioAPI-->>RenderioApp: commands page
RenderioApp-->>NewFFmpegCommandSource: commands array
end
NewFFmpegCommandSource->>NewFFmpegCommandSource: filter ts >= lastTs, sort by timestamp, optionally cap count
loop for each qualifying command
NewFFmpegCommandSource->>NewFFmpegCommandSource: generateMeta(command)
NewFFmpegCommandSource->>NewFFmpegCommandSource: $emit(command, metadata)
end
NewFFmpegCommandSource->>PipedreamDB: _setLastTs(newest emitted timestamp)
Estimated code review effort🎯 4 (Complex) | ⏱️ ~60 minutes Suggested labels
Suggested reviewers
🚥 Pre-merge checks | ✅ 3 | ❌ 2❌ Failed checks (2 warnings)
✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
There was a problem hiding this comment.
Actionable comments posted: 4
🤖 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 `@components/renderio/common/utils.mjs`:
- Around line 52-55: The normalizeList function currently returns a non-array
value when response[key] is truthy but not an array (e.g., an object), which
will cause downstream for...of loops to crash. Fix this by adding an additional
Array.isArray check on response?.[key] before returning it. Only return
response[key] if it is actually an array, otherwise return an empty array. This
ensures normalizeList always returns either the original response if it is an
array, an array from response[key] if that property is an array, or an empty
array as a fallback.
- Around line 22-24: The parseRequiredObject function currently returns an empty
object when the input is falsy or invalid, which skips pre-flight validation.
Instead of returning {} as a fallback, throw a ConfigurationError with an
appropriate message when parseObject returns a falsy value. This ensures that
missing or invalid required configuration is caught immediately during
validation rather than deferring the failure to API calls.
In `@components/renderio/sources/new-ffmpeg-command/new-ffmpeg-command.mjs`:
- Around line 60-63: The comparison operator in the condition checking
timestamps within the pageCommands loop uses strict greater-than (ts > lastTs),
which causes commands sharing the same timestamp as the saved checkpoint to be
skipped on subsequent pages or runs. Change the comparison from strict
greater-than to greater-than-or-equal (ts >= lastTs) to ensure commands with
matching checkpoint timestamps are preserved and not lost during pagination,
maintaining reliable deduplication behavior as required by polling source
guidelines.
In `@components/renderio/sources/new-stored-file/new-stored-file.mjs`:
- Around line 58-61: The condition in the loop within new-stored-file.mjs that
checks `if (ts > lastTs)` uses a strict greater-than comparison, which can miss
files that share the same timestamp as the last checkpoint when records are
returned later through pagination or eventual consistency. Change the comparison
operator from `>` to `>=` in this condition to include files with a timestamp
equal to the last checkpoint timestamp, ensuring robust deduplication while
paginating through results.
🪄 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: ASSERTIVE
Plan: Pro
Run ID: 2293dbb2-9666-46cc-995e-a7edaa5431f7
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (21)
components/renderio/actions/delete-stored-file/delete-stored-file.mjscomponents/renderio/actions/download-and-process-video-with-ytdlp/download-and-process-video-with-ytdlp.mjscomponents/renderio/actions/download-video-with-ytdlp/download-video-with-ytdlp.mjscomponents/renderio/actions/execute-preset/execute-preset.mjscomponents/renderio/actions/get-ffmpeg-command-status/get-ffmpeg-command-status.mjscomponents/renderio/actions/get-preset/get-preset.mjscomponents/renderio/actions/get-stored-file/get-stored-file.mjscomponents/renderio/actions/list-presets/list-presets.mjscomponents/renderio/actions/list-stored-files/list-stored-files.mjscomponents/renderio/actions/run-chained-ffmpeg-commands/run-chained-ffmpeg-commands.mjscomponents/renderio/actions/run-ffmpeg-command/run-ffmpeg-command.mjscomponents/renderio/actions/run-multiple-ffmpeg-commands/run-multiple-ffmpeg-commands.mjscomponents/renderio/actions/store-file/store-file.mjscomponents/renderio/actions/upload-file/upload-file.mjscomponents/renderio/common/utils.mjscomponents/renderio/package.jsoncomponents/renderio/renderio.app.mjscomponents/renderio/sources/new-ffmpeg-command/new-ffmpeg-command.mjscomponents/renderio/sources/new-ffmpeg-command/test-event.mjscomponents/renderio/sources/new-stored-file/new-stored-file.mjscomponents/renderio/sources/new-stored-file/test-event.mjs
MCP Eval Results — RenderIO ✅14 / 14 passing | 100% tool coverage Ran evals against all 14 actions in this PR using Pipedream's remote MCP server with the privately published components.
All 14 tools were exercised. Avg 1.4 tool calls per eval. Total run time: ~60s. Evals tracked in pd-connect-eval-monster |
GTFalcao
left a comment
There was a problem hiding this comment.
Looks good, left a couple comments, one is a structural change for sources that we need to address.
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 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 `@components/renderio/sources/common/base.mjs`:
- Around line 43-46: The code is advancing lastTs with synthetic fallback
timestamps from getTimestamp() which returns Date.now() when API timestamps are
missing or invalid. This can cause legitimate events with older real timestamps
to be skipped. Modify the logic where items are checked and added (in the
condition checking ts >= lastTs and the items.push(item) section, as well as the
similar code at lines 64-66) to distinguish between real API timestamps and
synthetic fallback values, then only update lastTs with real timestamps from the
API, not with the Date.now() fallback values returned by getTimestamp().
🪄 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: ASSERTIVE
Plan: Pro
Run ID: 30aaa4d9-7891-4d3e-a3eb-659f730050f8
⛔ Files ignored due to path filters (1)
pnpm-lock.yamlis excluded by!**/pnpm-lock.yaml
📒 Files selected for processing (4)
components/renderio/actions/run-ffmpeg-command/run-ffmpeg-command.mjscomponents/renderio/sources/common/base.mjscomponents/renderio/sources/new-ffmpeg-command/new-ffmpeg-command.mjscomponents/renderio/sources/new-stored-file/new-stored-file.mjs
|
All evals passed! Ready for Release! |
Resolves #20895
Replaces #20896
Summary by CodeRabbit
Release Notes
New Features
Enhancements
$summaryoutput).