fix: remove redundant dependency installer
This commit is contained in:
@@ -21,7 +21,7 @@ git clone https://github.com/Ethanfel/ComfyUI-Tween.git
|
|||||||
pip install -r requirements.txt
|
pip install -r requirements.txt
|
||||||
```
|
```
|
||||||
|
|
||||||
Dependencies are declared in `pyproject.toml` and `requirements.txt` and are installed automatically by ComfyUI Manager or pip. LDF-VFI requires PyTorch 2.5+ plus a current `diffusers`/`accelerate` stack.
|
Dependencies are declared in `pyproject.toml` and `requirements.txt` and are installed automatically by ComfyUI Manager or pip. There is intentionally no custom `install.py`, avoiding a second redundant dependency-install pass after Manager processes `requirements.txt`. LDF-VFI requires PyTorch 2.5+ plus a current `diffusers`/`accelerate` stack.
|
||||||
|
|
||||||
### Demo workflow
|
### Demo workflow
|
||||||
|
|
||||||
|
|||||||
-21
@@ -1,21 +0,0 @@
|
|||||||
import os
|
|
||||||
import subprocess
|
|
||||||
import sys
|
|
||||||
|
|
||||||
|
|
||||||
def install():
|
|
||||||
"""Install required dependencies without mutating optional GPU packages."""
|
|
||||||
requirements_path = os.path.join(os.path.dirname(__file__), "requirements.txt")
|
|
||||||
subprocess.check_call([
|
|
||||||
sys.executable, "-m", "pip", "install", "-r", requirements_path
|
|
||||||
])
|
|
||||||
print(
|
|
||||||
"[Tween] Optional cupy is not installed automatically. "
|
|
||||||
"BIM-VFI, SGM-VFI, and GIMM-VFI use the PyTorch fallback unless you "
|
|
||||||
"install the matching cupy wheel manually; EMA-VFI, SPEED, and "
|
|
||||||
"LDF-VFI do not use cupy."
|
|
||||||
)
|
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
|
||||||
install()
|
|
||||||
+1
-1
@@ -1,7 +1,7 @@
|
|||||||
[project]
|
[project]
|
||||||
name = "comfyui-tween"
|
name = "comfyui-tween"
|
||||||
description = "Video frame interpolation nodes for ComfyUI using BIM-VFI, EMA-VFI, SGM-VFI, GIMM-VFI, SPEED, and LDF-VFI."
|
description = "Video frame interpolation nodes for ComfyUI using BIM-VFI, EMA-VFI, SGM-VFI, GIMM-VFI, SPEED, and LDF-VFI."
|
||||||
version = "1.2.1"
|
version = "1.2.2"
|
||||||
license = "Apache-2.0"
|
license = "Apache-2.0"
|
||||||
requires-python = ">=3.10"
|
requires-python = ">=3.10"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
|
|||||||
+22
-15
@@ -1,19 +1,26 @@
|
|||||||
import os
|
from pathlib import Path
|
||||||
import subprocess
|
import tomllib
|
||||||
import sys
|
|
||||||
|
|
||||||
import install as tween_install
|
|
||||||
|
|
||||||
|
|
||||||
def test_installer_never_installs_optional_cupy(monkeypatch):
|
REPO_ROOT = Path(__file__).resolve().parents[1]
|
||||||
calls = []
|
|
||||||
monkeypatch.setattr(subprocess, "check_call", calls.append)
|
|
||||||
|
|
||||||
tween_install.install()
|
|
||||||
|
|
||||||
requirements_path = os.path.join(
|
def _requirements():
|
||||||
os.path.dirname(tween_install.__file__), "requirements.txt"
|
return [
|
||||||
)
|
line.strip()
|
||||||
assert calls == [[
|
for line in (REPO_ROOT / "requirements.txt").read_text().splitlines()
|
||||||
sys.executable, "-m", "pip", "install", "-r", requirements_path
|
if line.strip() and not line.lstrip().startswith("#")
|
||||||
]]
|
]
|
||||||
|
|
||||||
|
|
||||||
|
def test_comfy_manager_has_no_redundant_install_script():
|
||||||
|
assert not (REPO_ROOT / "install.py").exists()
|
||||||
|
|
||||||
|
|
||||||
|
def test_declared_dependencies_stay_aligned_and_exclude_optional_cupy():
|
||||||
|
with (REPO_ROOT / "pyproject.toml").open("rb") as file:
|
||||||
|
project_dependencies = tomllib.load(file)["project"]["dependencies"]
|
||||||
|
|
||||||
|
requirements = _requirements()
|
||||||
|
assert requirements == project_dependencies
|
||||||
|
assert not any("cupy" in dependency.lower() for dependency in requirements)
|
||||||
|
|||||||
Reference in New Issue
Block a user