comfy-env 0.0.43__py3-none-any.whl → 0.0.44__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
comfy_env/env/manager.py CHANGED
@@ -383,13 +383,19 @@ class IsolatedEnvManager:
383
383
 
384
384
  if "wheel_template" in config:
385
385
  # Direct wheel URL from template
386
- effective_version = version or config.get("default_version")
387
- if not effective_version:
388
- raise RuntimeError(f"Package {package} requires version (no default in registry)")
389
-
390
- vars_dict["version"] = effective_version
391
- wheel_url = self._substitute_template(config["wheel_template"], vars_dict)
392
- self.log(f" Installing {package}=={effective_version}...")
386
+ template = config["wheel_template"]
387
+
388
+ # Only require version if template uses {version}
389
+ effective_version = None
390
+ if "{version}" in template:
391
+ effective_version = version or config.get("default_version")
392
+ if not effective_version:
393
+ raise RuntimeError(f"Package {package} requires version (no default in registry)")
394
+ vars_dict["version"] = effective_version
395
+
396
+ wheel_url = self._substitute_template(template, vars_dict)
397
+ version_str = f"=={effective_version}" if effective_version else ""
398
+ self.log(f" Installing {package}{version_str}...")
393
399
  self.log(f" URL: {wheel_url}")
394
400
  result = subprocess.run(
395
401
  pip_args + ["--no-deps", wheel_url],
@@ -398,6 +404,19 @@ class IsolatedEnvManager:
398
404
  if result.returncode != 0:
399
405
  raise RuntimeError(f"Failed to install {package}: {result.stderr}")
400
406
 
407
+ elif "find_links" in config:
408
+ # find_links: pip resolves wheel from index URL
409
+ find_links_url = config["find_links"]
410
+ effective_version = version or config.get("default_version")
411
+ pkg_spec = f"{package}=={effective_version}" if effective_version else package
412
+ self.log(f" Installing {pkg_spec} from {find_links_url}...")
413
+ result = subprocess.run(
414
+ pip_args + ["--no-deps", "--find-links", find_links_url, pkg_spec],
415
+ capture_output=True, text=True,
416
+ )
417
+ if result.returncode != 0:
418
+ raise RuntimeError(f"Failed to install {package}: {result.stderr}")
419
+
401
420
  elif "package_name" in config:
402
421
  # PyPI variant (e.g., spconv-cu124)
403
422
  pkg_name = self._substitute_template(config["package_name"], vars_dict)
@@ -411,7 +430,7 @@ class IsolatedEnvManager:
411
430
  raise RuntimeError(f"Failed to install {package}: {result.stderr}")
412
431
 
413
432
  else:
414
- raise RuntimeError(f"Package {package} in registry but missing wheel_template or package_name")
433
+ raise RuntimeError(f"Package {package} in registry but missing wheel_template, find_links, or package_name")
415
434
 
416
435
  else:
417
436
  # Not in registry - error
comfy_env/install.py CHANGED
@@ -367,11 +367,25 @@ def _resolve_wheel_url(
367
367
 
368
368
  # wheel_template: direct URL
369
369
  if "wheel_template" in config:
370
+ template = config["wheel_template"]
371
+
372
+ # Only require version if template uses {version}
373
+ if "{version}" in template:
374
+ effective_version = version or config.get("default_version")
375
+ if not effective_version:
376
+ raise InstallError(f"Package {package} requires version (no default in registry)")
377
+ vars_dict["version"] = effective_version
378
+
379
+ return _substitute_template(template, vars_dict)
380
+
381
+ # find_links: pip resolves wheel from index (e.g., miropsota's detectron2)
382
+ if "find_links" in config:
383
+ find_links_url = config["find_links"]
370
384
  effective_version = version or config.get("default_version")
371
- if not effective_version:
372
- raise InstallError(f"Package {package} requires version (no default in registry)")
373
- vars_dict["version"] = effective_version
374
- return _substitute_template(config["wheel_template"], vars_dict)
385
+ if effective_version:
386
+ return f"find_links:{find_links_url}:{package}=={effective_version}"
387
+ else:
388
+ return f"find_links:{find_links_url}:{package}"
375
389
 
376
390
  # package_name: PyPI variant (e.g., spconv-cu124)
377
391
  if "package_name" in config:
@@ -406,6 +420,11 @@ def _install_cuda_package(
406
420
  pkg_spec = f"{pkg_name}=={version}" if version else pkg_name
407
421
  log(f" Installing {package} as {pkg_spec} from PyPI...")
408
422
  _pip_install([pkg_spec], no_deps=False, log=log)
423
+ elif url_or_marker.startswith("find_links:"):
424
+ # find_links: pip resolves from index URL
425
+ _, find_links_url, pkg_spec = url_or_marker.split(":", 2)
426
+ log(f" Installing {pkg_spec} from {find_links_url}...")
427
+ _pip_install([pkg_spec, "--find-links", find_links_url], no_deps=True, log=log)
409
428
  else:
410
429
  # Direct wheel URL
411
430
  log(f" Installing {package}...")
@@ -25,18 +25,22 @@ packages:
25
25
  # ===========================================================================
26
26
  torch-scatter:
27
27
  wheel_template: "https://data.pyg.org/whl/torch-{torch_version}%2Bcu{cuda_short}/torch_scatter-{version}%2Bpt{torch_mm}cu{cuda_short}-{py_tag}-{py_tag}-{platform}.whl"
28
+ default_version: "2.1.2"
28
29
  description: Scatter operations for PyTorch
29
30
 
30
31
  torch-cluster:
31
32
  wheel_template: "https://data.pyg.org/whl/torch-{torch_version}%2Bcu{cuda_short}/torch_cluster-{version}%2Bpt{torch_mm}cu{cuda_short}-{py_tag}-{py_tag}-{platform}.whl"
33
+ default_version: "1.6.3"
32
34
  description: Clustering algorithms for PyTorch
33
35
 
34
36
  torch-sparse:
35
37
  wheel_template: "https://data.pyg.org/whl/torch-{torch_version}%2Bcu{cuda_short}/torch_sparse-{version}%2Bpt{torch_mm}cu{cuda_short}-{py_tag}-{py_tag}-{platform}.whl"
38
+ default_version: "0.6.18"
36
39
  description: Sparse tensor operations for PyTorch
37
40
 
38
41
  torch-spline-conv:
39
42
  wheel_template: "https://data.pyg.org/whl/torch-{torch_version}%2Bcu{cuda_short}/torch_spline_conv-{version}%2Bpt{torch_mm}cu{cuda_short}-{py_tag}-{py_tag}-{platform}.whl"
43
+ default_version: "1.2.2"
40
44
  description: Spline convolutions for PyTorch
41
45
 
42
46
  # ===========================================================================
@@ -114,7 +118,8 @@ packages:
114
118
  # Prebuilt wheels from miropsota's torch_packages_builder
115
119
  # ===========================================================================
116
120
  detectron2:
117
- wheel_template: "https://miropsota.github.io/torch_packages_builder/detectron2/detectron2-0.6%2B2a420edpt{torch_version}cu{cuda_short}-{py_tag}-{py_tag}-{platform}.whl"
121
+ find_links: "https://miropsota.github.io/torch_packages_builder/detectron2/"
122
+ default_version: "0.6"
118
123
  description: Detectron2 - Facebook's detection and segmentation library
119
124
 
120
125
  # ===========================================================================
@@ -131,5 +136,6 @@ packages:
131
136
  # Note: This uses a special package_name field, not wheel_template
132
137
  # ===========================================================================
133
138
  spconv:
134
- package_name: "spconv-cu{cuda_short2}"
135
- description: Sparse convolution library (installs spconv-cu124, spconv-cu126, etc.)
139
+ wheel_template: "https://github.com/PozzettiAndrea/cuda-wheels/releases/download/spconv_cu{cuda_short}-latest/spconv-{version}%2Bcu{cuda_short}torch{torch_mm}-{py_tag}-{py_tag}-{platform}.whl"
140
+ default_version: "2.3.8"
141
+ description: Sparse convolution library
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: comfy-env
3
- Version: 0.0.43
3
+ Version: 0.0.44
4
4
  Summary: Environment management for ComfyUI custom nodes - CUDA wheel resolution and process isolation
5
5
  Project-URL: Homepage, https://github.com/PozzettiAndrea/comfy-env
6
6
  Project-URL: Repository, https://github.com/PozzettiAndrea/comfy-env
@@ -2,7 +2,7 @@ comfy_env/__init__.py,sha256=OQJFNjmArjLcgrfHAFxgDJQFH_IhxibqMXbU5bu_j9Q,3822
2
2
  comfy_env/cli.py,sha256=hZv_oJsmaMoG62Fr2Fjp778P_32BHr4fzS7G4lULSwU,13153
3
3
  comfy_env/decorator.py,sha256=6JCKwLHaZtOLVDexs_gh_-NtS2ZK0V7nGCPqkyeYEAA,16688
4
4
  comfy_env/errors.py,sha256=8hN8NDlo8oBUdapc-eT3ZluigI5VBzfqsSBvQdfWlz4,9943
5
- comfy_env/install.py,sha256=lKkW55mDLut3zpJOUgjAi-BdLluBRPN-bblONHjo-Ws,16595
5
+ comfy_env/install.py,sha256=m4NKlfCcQGI5xzVRjHw3ep-lWbqx5kE1e21sUUZ2Leo,17528
6
6
  comfy_env/nodes.py,sha256=CWUe35jU5SKk4ur-SddZePdqWgxJDlxGhpcJiu5pAK4,4354
7
7
  comfy_env/pixi.py,sha256=y25mUDhB3bCqhPMGF0h23Tf8ZHykK4gLJrkvOhsPWmE,14398
8
8
  comfy_env/registry.py,sha256=w-QwvAPFlCrBYRAv4cXkp2zujQPZn8Fk5DUxKCtox8o,3430
@@ -11,7 +11,7 @@ comfy_env/env/__init__.py,sha256=imQdoQEQvrRT-QDtyNpFlkVbm2fBzgACdpQwRPd09fI,115
11
11
  comfy_env/env/config.py,sha256=Ila-5Yal3bj6jENbBeYJlZtkbgdwnzJzImVZK3ZF1lg,7645
12
12
  comfy_env/env/config_file.py,sha256=HzFKeQh9zQ--K1V-XuvgE6DiE_bYrXrChL1ZT8Tzlq4,24684
13
13
  comfy_env/env/cuda_gpu_detection.py,sha256=YLuXUdWg6FeKdNyLlQAHPlveg4rTenXJ2VbeAaEi9QE,9755
14
- comfy_env/env/manager.py,sha256=eDcrtJeNrW3jYb0q0R_DmUfAYjGo5Cs4BMuZUxWEzeg,21789
14
+ comfy_env/env/manager.py,sha256=C-lniAu1dhgUViNtl-78c7ZkiQMnbsaUGpIVi51Uzw8,22909
15
15
  comfy_env/env/security.py,sha256=dNSitAnfBNVdvxgBBntYw33AJaCs_S1MHb7KJhAVYzM,8171
16
16
  comfy_env/env/platform/__init__.py,sha256=Nb5MPZIEeanSMEWwqU4p4bnEKTJn1tWcwobnhq9x9IY,614
17
17
  comfy_env/env/platform/base.py,sha256=iS0ptTTVjXRwPU4qWUdvHI7jteuzxGSjWr5BUQ7hGiU,2453
@@ -36,9 +36,9 @@ comfy_env/workers/pool.py,sha256=MtjeOWfvHSCockq8j1gfnxIl-t01GSB79T5N4YB82Lg,695
36
36
  comfy_env/workers/tensor_utils.py,sha256=TCuOAjJymrSbkgfyvcKtQ_KbVWTqSwP9VH_bCaFLLq8,6409
37
37
  comfy_env/workers/torch_mp.py,sha256=4YSNPn7hALrvMVbkO4RkTeFTcc0lhfLMk5QTWjY4PHw,22134
38
38
  comfy_env/workers/venv.py,sha256=PmsVOu5i89tBYkGRupo2bjOLPBmk06q4GNUwDWsd9F8,32088
39
- comfy_env/wheel_sources.yml,sha256=07-ruJ7HHGtXJUs7rDmud8X6OsBcfogZKG6cyU7Gacg,7950
40
- comfy_env-0.0.43.dist-info/METADATA,sha256=HzyWA3jqZjM9YsoFQEhZkHMTB8b8agepqMvo2YkOQY8,7138
41
- comfy_env-0.0.43.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
42
- comfy_env-0.0.43.dist-info/entry_points.txt,sha256=J4fXeqgxU_YenuW_Zxn_pEL7J-3R0--b6MS5t0QmAr0,49
43
- comfy_env-0.0.43.dist-info/licenses/LICENSE,sha256=E68QZMMpW4P2YKstTZ3QU54HRQO8ecew09XZ4_Vn870,1093
44
- comfy_env-0.0.43.dist-info/RECORD,,
39
+ comfy_env/wheel_sources.yml,sha256=M9Z3PPJrimV_B4tRRmZ8o_z6phZanJY_iEcjfMimtZw,8141
40
+ comfy_env-0.0.44.dist-info/METADATA,sha256=6FS6i66IxVfnZafLY1Dyte4wc5dKM4CLt2pZho2_S18,7138
41
+ comfy_env-0.0.44.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
42
+ comfy_env-0.0.44.dist-info/entry_points.txt,sha256=J4fXeqgxU_YenuW_Zxn_pEL7J-3R0--b6MS5t0QmAr0,49
43
+ comfy_env-0.0.44.dist-info/licenses/LICENSE,sha256=E68QZMMpW4P2YKstTZ3QU54HRQO8ecew09XZ4_Vn870,1093
44
+ comfy_env-0.0.44.dist-info/RECORD,,