mirror of
https://github.com/Comfy-Org/desktop.git
synced 2026-11-04 23:47:43 +00:00
[PR #1229] Implement Comfy URI Protocol (comfy://) for one-click custom node installation with comprehensive testing #1419
Labels
No labels
area: desktop-app
Bounty
bug
bug-cop:answered
bug-cop:response-received
component: installer
component: preload
custom node
dependencies
Design
documentation
duplicate
enhancement
expected
frontend
good first issue
installation
Low-Priority
performance
Planned
platform: cross-platform
platform: windows
Potential Bug
Potential Bug
pull-request
question
refactor
Release
stale
User Support
V1
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Comfy-Org/desktop#1419
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/Comfy-Org/desktop/pull/1229
Author: @Copilot
Created: 7/23/2025
Status: 🔄 Open
Base:
main← Head:copilot/fix-1228📝 Commits (7)
dee41daInitial plancb6a207Implement core protocol handling infrastructure2a5cfacComplete protocol implementation with ComfyUI Manager integration9458c7fAdd protocol implementation documentation8a2a4f1Add integration test for protocol URL handling with ComfyUI-AnimateDiff-Evolved02278a2Merge main into copilot/fix-1228 - resolve conflictsda22cefMerge branch 'main' into copilot/fix-1228📊 Changes
11 files changed (+989 additions, -52 deletions)
View changed files
📝
.gitignore(+3 -0)➕
docs/PROTOCOL.md(+89 -0)📝
src/constants.ts(+1 -0)📝
src/desktopApp.ts(+199 -52)📝
src/infrastructure/ipcChannels.ts(+6 -0)📝
src/main.ts(+46 -0)➕
src/protocol/protocolParser.ts(+99 -0)➕
src/services/comfyManagerService.ts(+169 -0)➕
tests/integration/post-install/protocolHandling.spec.ts(+162 -0)➕
tests/unit/protocol/protocolParser.test.ts(+82 -0)➕
tests/unit/services/comfyManagerService.test.ts(+133 -0)📄 Description
This PR implements the
comfy://protocol handler for ComfyUI Desktop, enabling seamless one-click installation of custom nodes and workflows directly from web browsers.Features
Protocol Actions
comfy://install-custom-node/<nodeId>- Install custom nodes via ComfyUI Managercomfy://import/<resourceId>- Import workflows and resourcesExample Usage
Implementation
Core Components
src/protocol/protocolParser.ts) - Robust parsing with comprehensive validationsrc/services/comfyManagerService.ts) - HTTP API client for custom node operationssrc/main.ts) - System-level protocol handler using Electron'sapp.setAsDefaultProtocolClient()src/desktopApp.ts) - Handles protocol URLs received before ComfyUI is readyUser Experience Flow
comfy://link in browserTechnical Highlights
second-instanceevent for protocol URLs when app is already runningTesting
Comprehensive Test Suite
Integration Tests
The integration tests launch ComfyUI Desktop with actual protocol URLs and verify:
Unit Test Coverage
comfy://install-custom-node/ComfyUI-AnimateDiff-EvolvedSecurity & Safety
install-custom-node,import)Bundle Impact
This enables the seamless browser-to-desktop workflow requested in the issue, allowing websites like the ComfyUI Registry to provide one-click installation buttons that launch ComfyUI Desktop and automatically install the selected custom nodes.
Fixes #1228.
💬 Share your feedback on Copilot coding agent for the chance to win a $200 gift card! Click here to start the survey.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.