Make videos on the computer you already own. FreeVideo runs MiniMax H3 in as little as 8 GB of VRAM and 16 GB of RAM, and adapts its acceleration path to your hardware.
Engine update: a refused connection is not a busy pool; setup spares a foreign server's job
Bowen Xuedc57ca50983b
diff --git a/freevideo_engine/comfy_launcher_runtime.py b/freevideo_engine/comfy_launcher_runtime.pyindex d5764a7..e5bf4bd 100644--- a/freevideo_engine/comfy_launcher_runtime.py+++ b/freevideo_engine/comfy_launcher_runtime.py@@ -494,8 +494,16 @@ def launcher_comfy(selected, info):return False+ENGINE_UPDATE_WAITS = 'ComfyUI is running a job, so the engine update waits'+++def _refused(error):+ return isinstance(error, ConnectionRefusedError) or isinstance(getattr(error, 'reason', None), ConnectionRefusedError)++def queue_busy(url):- """Preserve the legacy check; a pool must confirm every executor is idle."""+ """Preserve the legacy check; a pool must confirm every executor is idle. A refused+ connection means nothing listens, so there is no job; a timeout is not that answer."""from .gpu_pool import pool_enabledpooled = pool_enabled()try:@@ -506,8 +514,8 @@ def queue_busy(url):state = get_json(loopback_url(url) + '/freevideo/pool', timeout=3)return state.get('busy') is not False or state.get('confirmed') is not Truereturn False- except (OSError, ValueError, AttributeError):- return pooled+ except (OSError, ValueError, AttributeError) as error:+ return pooled and not _refused(error)@plain_errors@@ -1151,8 +1159,7 @@ class Controller:# Whoever started it (another launcher, the freevideo command), a ComfyUI of this installation# that is generating keeps its packages: the switch waits for the job.if queue_busy(loopback_url(self.server_address or self.selection['url'])):- raise RuntimeError('ComfyUI is running a job, so the engine update waits. Try again after it finishes; '- 'the job is left running.')+ raise RuntimeError(ENGINE_UPDATE_WAITS + '. Try again after it finishes; the job is left running.')self._stop_server_for_setup(selected['url'])engine_binding.rebind(selected['engine'], machine, selected['source'])self.stage('nodes', label='Install FreeVideo workflow')@@ -1178,12 +1185,11 @@ class Controller:keeps loaded after a video (Windows refuses to replace SageAttention's_fused.pyd), and a model switch must not leave the old model in thatworker. Stop our own idle server; connecting after setup starts it- again. A running job is never stopped."""- if not self.owns_server():- return+ again. A running job is never stopped, in a server another program started either."""if queue_busy(loopback_url(self.server_address or url)):raise RuntimeError('ComfyUI is running a job. Try again after it finishes; the job is left running.')- self.stop_owned_server()+ if self.owns_server():+ self.stop_owned_server()def ensure_shortcut(self):from .desktop_shortcut import create_after_installdiff --git a/freevideo_engine/launcher_session.py b/freevideo_engine/launcher_session.pyindex f71147f..4728af9 100644--- a/freevideo_engine/launcher_session.py+++ b/freevideo_engine/launcher_session.py@@ -13,7 +13,8 @@ from urllib.parse import parse_qsl, urlencode, urlsplit, urlunsplitfrom . import __version__from . import disk_space-from .comfy_launcher_runtime import Controller, layout, local_url, loopback_url, managed_frontend, new_layout, queue_busy+from .comfy_launcher_runtime import (ENGINE_UPDATE_WAITS, Controller, layout, local_url, loopback_url, managed_frontend,+ new_layout, queue_busy)from .desktop_runtime import launcher_root, materialize_sourcefrom .download_settings import Probe, read as download_preferences, speed_textfrom .launcher_settings import Store, default_language@@ -1288,10 +1289,11 @@ class Session:self.update_checked = time.monotonic()self.updater.run('check')- def _queue_busy(self):- """True or False once known for a server this launcher owns, None before."""+ def _queue_busy(self, any_server=False):+ """True or False once known for a server this launcher owns, None before. An engine update+ also waits for a server another program started: it moves the same installation."""owns = getattr(self.controller, 'owns_server', None)- if not callable(owns) or owns() is not True:+ if not any_server and (not callable(owns) or owns() is not True):return Falsenow = time.monotonic()if (self.queue_thread is None or not self.queue_thread.is_alive()) and (@@ -1365,7 +1367,7 @@ class Session:def _update_engine_when_idle(self):if self.task_busy():return- busy = self._queue_busy()+ busy = self._queue_busy(any_server=True)self.update_waiting = bool(busy)if busy is not False:return@@ -1772,6 +1774,13 @@ class Session:# Nothing new to download or approve: deploy, then restart ComfyUI.self.controller.run('install', True)row, busy = self.controller.state, self.controller.busy+ if (self.engine_updating and not busy and row.get('status') == 'failed'+ and str(row.get('error') or '').startswith(ENGINE_UPDATE_WAITS)):+ # A video started after the check: keep waiting for it instead of showing a failure.+ self.controller.state = row = dict(row, status='open', error=None, exception=None)+ self.engine_updating = self.engine_autoinstall = False+ self.update_intent = 'engine'+ self.queue_state = Noneif self.engine_updating and not busy and not self.engine_autoinstall:self.engine_updating = Falsegroups = row.get('task', {}).get('model_groups') or row.get('model_groups') or row.get('plan', {}).get('model_groups')