ci: dispatch tag push to Comfy Cloud#13541
Conversation
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
✅ Files skipped from review due to trivial changes (1)
📝 WalkthroughWalkthroughAdds a new GitHub Actions workflow triggered on tag pushes matching 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
.github/workflows/tag-dispatch-cloud.yml (1)
37-43: Harden the dispatch call for transient GitHub API/network failures.Line 37 uses a single-shot
curl; a brief 5xx/timeout can drop the tag signal. Add bounded retries + timeouts to improve delivery reliability.Suggested diff
- curl -fsSL \ + curl -fsSL \ + --retry 5 \ + --retry-delay 2 \ + --retry-all-errors \ + --connect-timeout 10 \ + --max-time 60 \ -X POST \ -H "Accept: application/vnd.github+json" \ -H "Content-Type: application/json" \ -H "Authorization: Bearer ${DISPATCH_TOKEN}" \ https://api.github.com/repos/Comfy-Org/cloud/dispatches \ -d "$PAYLOAD"🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In @.github/workflows/tag-dispatch-cloud.yml around lines 37 - 43, The single-shot curl POST to https://api.github.com/repos/Comfy-Org/cloud/dispatches using DISPATCH_TOKEN and PAYLOAD is fragile; replace it with a bounded retry + timeout strategy so transient 5xx/timeouts won't drop the dispatch. Implement a retry loop around the curl invocation (referencing the existing curl command, DISPATCH_TOKEN and PAYLOAD) that uses a per-request timeout (e.g., curl --max-time or equivalent), retries a limited number of times (e.g., 3–5 attempts) with a small backoff between attempts, treats non-2xx responses as failures to retry, and exits non-zero after exhausting attempts so the workflow fails visibly. Ensure the final failure logs the last HTTP status/body for debugging.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Nitpick comments:
In @.github/workflows/tag-dispatch-cloud.yml:
- Around line 37-43: The single-shot curl POST to
https://api.github.com/repos/Comfy-Org/cloud/dispatches using DISPATCH_TOKEN and
PAYLOAD is fragile; replace it with a bounded retry + timeout strategy so
transient 5xx/timeouts won't drop the dispatch. Implement a retry loop around
the curl invocation (referencing the existing curl command, DISPATCH_TOKEN and
PAYLOAD) that uses a per-request timeout (e.g., curl --max-time or equivalent),
retries a limited number of times (e.g., 3–5 attempts) with a small backoff
between attempts, treats non-2xx responses as failures to retry, and exits
non-zero after exhausting attempts so the workflow fails visibly. Ensure the
final failure logs the last HTTP status/body for debugging.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: b76f7713-1b3c-47d3-b350-d632ffb96efd
📒 Files selected for processing (1)
.github/workflows/tag-dispatch-cloud.yml
Fires on v* tag push (earlier than release.published, which can lag) and triggers a repository_dispatch on Comfy-Org/cloud with event_type comfyui_tag_pushed. Legacy desktop dispatch in release-webhook.yml is left untouched.
8e9675c to
c77ab1c
Compare
Summary
.github/workflows/tag-dispatch-cloud.ymlthat fires onv*tag push and triggers arepository_dispatch(event_type: comfyui_tag_pushed) onComfy-Org/cloud.release.publishedso cloud gets the signal immediately — release object creation can lag the tag.Comfy-Org/desktopdispatch inrelease-webhook.ymlis intentionally left alone.Prereqs before merging
CLOUD_REPO_DISPATCH_TOKEN— PAT/fine-grained token withrepository_dispatchwrite onComfy-Org/cloud.repository_dispatchlistener inComfy-Org/cloudfortypes: [comfyui_tag_pushed].Payload
{ "event_type": "comfyui_tag_pushed", "client_payload": { "release_tag": "v0.19.6", "release_url": "https://github.com/Comfy-Org/ComfyUI/releases/tag/v0.19.6" } }release_urlis constructed from the tag — GitHub serves that URL even before a release is cut.Test plan
CLOUD_REPO_DISPATCH_TOKENsecret exists in repo settings.v0.0.0-testtag (or wait for next real release) and confirm workflow run succeeds.Comfy-Org/cloudreceives the dispatch and its listener fires.🤖 Generated with Claude Code