在云服务器上,clone github时报Connection timed out&exit code: 128

文章目录

问题

在执行pip install安装依赖时,需要clone github代码,此时报了Connection timed out&exit code: 128错误,原因是访问超时了,此时需要使用代理

bash 复制代码
fatal: unable to access 'https://github.com/huggingface/peft/': Failed to connect to github.com port 443 after 130446 ms: Connection timed out
  error: subprocess-exited-with-error
  
  × git clone --filter=blob:none --quiet https://github.com/huggingface/peft /tmp/pip-req-build-6zluqgm4 did not run successfully.
  │ exit code: 128
  ╰─> See above for output.
  
  note: This error originates from a subprocess, and is likely not a problem with pip.

解决方案

使用https://ghproxy.com/代理,可以成功且快速地clone,如下图所示,在github地址前,加上,如:

bash 复制代码
https://ghproxy.com/https://github.com/huggingface/peft
相关推荐
苏宸啊7 小时前
Linux指令篇(一)
linux·运维·服务器
通义灵码7 小时前
Qoder 支持通过 DeepLink 添加 MCP Server
人工智能·github·mcp
睡不醒的猪儿8 小时前
nginx常见的优化配置
运维·nginx
我要升天!8 小时前
Linux中《网络基础》
linux·运维·网络
国强_dev8 小时前
在数据库开发和运维中的“错误信息误导(Red Herring)”
运维·adb·数据库开发
安科瑞刘鸿鹏178 小时前
工业自动化系统中抗晃电保护的协同控制研究
运维·网络·嵌入式硬件·物联网
ZStack开发者社区8 小时前
ZStack Cloud 5.5.0正式发布
运维·服务器·网络
草莓熊Lotso9 小时前
脉脉独家【AI创作者xAMA】|当豆包手机遭遇“全网封杀”:AI学会操作手机,我们的饭碗还保得住吗?
运维·开发语言·人工智能·智能手机·脉脉
三不原则9 小时前
银行 AIOps 实践拆解:金融级故障自愈体系如何搭建
大数据·运维
源代码•宸10 小时前
Golang语法进阶(并发概述、Goroutine、Channel)
服务器·开发语言·后端·算法·golang·channel·goroutine