-
Notifications
You must be signed in to change notification settings - Fork 5.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TypeError: 'NoneType' object is not iterable #3219
Comments
Hey there, @fireflywwj! 👋 I'm Dosu, a friendly bot here to help you squash bugs, answer your questions, and guide you on your way to becoming a contributor. While we wait for a human maintainer to join us, know that I'm here to assist. I see you've run into a bit of a snag with a TypeError. Let me take a closer look and I'll get back to you with a full answer shortly! Stay tuned. |
/server/utils.py 中 get_httpx_client() 方法中or host in os.environ.get("no_proxy", "").split(",") 代码中如下改能够解决该问题,我本地因为改过网络参数以及更新过依赖包出现该问题
|
The error running_models = list(api.list_running_models()) This error suggests that To fix this issue, you should ensure that running_models = list(api.list_running_models() or []) This change uses the However, it's also important to understand why For example, you could modify the function to log an error message before returning def list_running_models():
# ... existing code ...
if response.status_code != 200:
logger.error(f"Failed to list running models: {response.content}")
return None
# ... existing code ... This will log an error message whenever the function fails to list the running models, which could help you understand why it's returning I hope this helps! If you have any further questions, feel free to ask. Sources
|
这个问题已经被标记为 |
Traceback (most recent call last):
File "D:\ProgramData\Anaconda\envs\LangChainChatChat\Lib\site-packages\streamlit\runtime\scriptrunner\script_runner.py", line 535, in _run_script
exec(code, module.dict)
File "E:\01_Code\GitCode\Langchain-Chatchat\webui.py", line 64, in
pages[selected_page]["func"](api=api, is_lite=is_lite)
File "E:\01_Code\GitCode\Langchain-Chatchat\webui_pages\dialogue\dialogue.py", line 163, in dialogue_page
running_models = list(api.list_running_models())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TypeError: 'NoneType' object is not iterable
The text was updated successfully, but these errors were encountered: