modified: In Python 3.13, the functionality to forcibly downgrade the numpy version below 3.13 is disabled.

- Starting from Python 3.13, prebuilt wheels for `numpy` 1.26.4 are no longer provided.

https://github.com/comfyanonymous/ComfyUI/discussions/8187
This commit is contained in:
Dr.Lt.Data
2025-05-19 05:13:40 +09:00
parent 7258a09fe5
commit 166debfabb
5 changed files with 35 additions and 19 deletions

View File

@@ -121,11 +121,17 @@ read_config()
read_uv_mode()
check_file_logging()
cm_global.pip_overrides = {'numpy': 'numpy<2'}
if sys.version_info < (3, 13):
cm_global.pip_overrides = {'numpy': 'numpy<2'}
else:
cm_global.pip_overrides = {}
if os.path.exists(manager_pip_overrides_path):
with open(manager_pip_overrides_path, 'r', encoding="UTF-8", errors="ignore") as json_file:
cm_global.pip_overrides = json.load(json_file)
cm_global.pip_overrides['numpy'] = 'numpy<2'
if sys.version_info < (3, 13):
cm_global.pip_overrides['numpy'] = 'numpy<2'
if os.path.exists(manager_pip_blacklist_path):