heshengtao / comfyui_LLM_party

LLM Agent Framework in ComfyUI includes Omost,GPT-sovits, ChatTTS,GOT-OCR2.0, and FLUX prompt nodes,access to Feishu,discord,and adapts to all llms with similar openai/gemini interfaces, such as o1,ollama, grok, qwen, GLM, deepseek, moonshot,doubao. Adapted to local llms, vlm, gguf such as llama-3.2, Linkage neo4j KG, graphRAG / RAG / html 2 img
GNU Affero General Public License v3.0
1.05k stars 93 forks source link

fastapi文件名与所导包的包名重名 #21

Closed NingZhenPeng closed 5 months ago

NingZhenPeng commented 5 months ago

问题: 按照文档 pip install -r requirements.txt 执行后 ,在comfyui也安装成功了

1904af526d536afb31176cfdfa2771b2

但是执行 fastapi.py 时提示 ImportError: cannot import name 'FastAPI' from partially initialized module 'fastapi'

657f85f05234056fb958784e96cf0b0d

解决方法: 修改自己的 fastapi.py 名称,不要与 from fastapi import FastAPI, HTTPException,Request, Depends 导包的 fastapi 就可以了, 估计是自定义的文件名与所导包的包名重名导致

heshengtao commented 5 months ago

已修复!