报错内容:
To create a public link, set `share=True` in `launch()`.
办理:对正在执行的.py文件进行修改,在demo.launch函数中设置share=True
demo.launch(server_name=socket.gethostbyname(socket.gethostname()), server_port=7870, inbrowser=True, share=True)
报错内容:
Could not create share link. Missing file: /root/miniconda3/envs/myenv/lib/python3.10/site-packages/gradio/frpc_linux_amd64_v0.3.
Please check your internet connection. This can happen if your antivirus software blocks the download of this file. You can install manually by following these steps:
1. Download this file: https://cdn-media.huggingface.co/frpc-gradio-0.3/frpc_linux_amd64
2. Rename the downloaded file to: frpc_linux_amd64_v0.3
3. Move the file to this location: /root/miniconda3/envs/myenv/lib/python3.10/site-packages/gradio
办理:按照上面的三条照做就行
报错内容:
Could not create share link. Please check your internet connection or our status page: https://status.gradio.app.
办理:为刚刚放进去的文件添加执行权限
chmod +x /root/miniconda3/envs/myenv/lib/python3.10/site-packages/gradio/frpc_linux_amd64_v0.3
报错内容:
2025/02/16 19:18:28 [W] [service.go:132] login to server failed: EOF
Could not create share link. Please check your internet connection or our status page: https://status.gradio.app.
办理:对正在执行的.py文件进行修改,在demo.launch函数中设置server_name='0.0.0.0'
demo.launch(server_name='0.0.0.0', server_port=7870, inbrowser=True, share=True)
原因:服务器上摆设的gradio能够远程访问须要①服务器连接到Gradio官网②Gradio官网天生一个公共访问的URL,让别的电脑能够访问到服务器发出的内容。
因此如果server_name='127.0.0.1',那么服务器发出的数据只能被服务器访问,原因如下:
【计算机网络】localhost,127.0.0.1 和 0.0.0.0傻傻分不清?这篇文章带你熟悉_localhost:127.0.0.1 ,0.0.0.0-CSDN博客
同时要确认Gradio官网稳定运行,其官网链接:https://status.gradio.app