Check Update in the legacy Custom Nodes Manager fetched every git nodepack inside GET /v2/customnode/getlist. The server answered nothing else until the last fetch had ended. The ComfyUI frontend waits 60 s for the answer to a request, so with many git nodepacks the page showed "Failed to get custom node list." (#3574). POST /v2/customnode/check_update of the legacy server now starts the check in a thread of its own and answers at once. The check fetches the enabled git nodepacks of the list and reports by the cm-check-update event: the number of fetches that are done, and at the end the nodepacks that have an update. The page shows that progress, then loads the list and marks them. A check that is asked for while one runs starts no second one: the nodepacks of its list that the running check does not have are added to that check. A request carries a ui_id that the page chooses, the end of a check names the ui_id of every request that it answers, and the page waits for the end that names its own. A check that fails tells so to the pages that wait for it. When the connection to the server comes back during a check, as after a restart of the server, the events of the check are lost, and the page asks for the check again. A task of the queue that is taken while a check runs waits for the check to end. So a task that is started during a check, such as Update All, runs after it as before, and the two do not work on one repository at the same time. A model download and an update of ComfyUI do not touch the repositories of the nodepacks, and do not wait. GET /v2/customnode/getlist no longer fetches, with or without skip_update. GET /v2/customnode/fetch_updates of the legacy server fetched inside the request in the same way and has no caller, and answers 410 as that of the new server does. The check found the folder of a nodepack by the id of its row in the list. A git nodepack that the registry does not know has none, or one that is not its repository name, so it was left out. The folder is now found by the key of the row, and every enabled git nodepack of the list is fetched. git_repo_update_check_with of the legacy core is left with the check as its one caller. Its update path, which nothing called, is removed, and it fetches and checks only. With that path goes a defect on Windows: a check that found an update put the install script of the nodepack down to run at the next start, though nothing had been updated.
ComfyUI-Manager: Core Backend (glob)
This directory contains the Python backend modules that power ComfyUI-Manager, handling the core functionality of node management, downloading, security, and server operations.
Directory Structure
- glob/ - code for new cacheless ComfyUI-Manager
- legacy/ - code for legacy ComfyUI-Manager
Core Modules
- manager_core.py: The central implementation of management functions, handling configuration, installation, updates, and node management.
- manager_server.py: Implements server functionality and API endpoints for the web interface to interact with the backend.
Specialized Modules
- share_3rdparty.py: Manages integration with third-party sharing platforms.
Architecture
The backend follows a modular design pattern with clear separation of concerns:
- Core Layer: Manager modules provide the primary API and business logic
- Utility Layer: Helper modules provide specialized functionality
- Integration Layer: Modules that connect to external systems
Security Model
The system implements a comprehensive security framework with multiple levels:
- Block: Highest security - blocks most remote operations
- High: Allows only specific trusted operations
- Middle: Standard security for most users
- Normal-: More permissive for advanced users
- Weak: Lowest security for development environments
Implementation Details
- The backend is designed to work seamlessly with ComfyUI
- Asynchronous task queuing is implemented for background operations
- The system supports multiple installation modes
- Error handling and risk assessment are integrated throughout the codebase
API Integration
The backend exposes a REST API via manager_server.py that enables:
- Custom node management (install, update, disable, remove)
- Model downloading and organization
- System configuration
- Snapshot management
- Workflow component handling