问题描述
git clone 下载代码一直报错误
Cloning into 'PaddleDetection'...
remote: Enumerating objects: 257502, done. remote:
Counting objects: 100% (2499/2499), done. remote:
Compressing objects: 100% (1449/1449), done.
error: RPC failed; curl 56 GnuTLS recv error (-9):
A TLS packet with unexpected length was received.
解决方法
- 把缓存区大小设置大点:根据项目的具体情况来设置缓冲区大小
git config --global http.postBuffer 524288000 # 2GB
git config --global http.postBuffer 2097152000 # 2GB
git config --global http.postBuffer 3194304000 # 3GB
- 执行上面命令如果依旧clone失败,考虑可能原因2:网络下载速度缓慢
git config --global http.lowSpeedLimit 0
git config --global http.lowSpeedTime 999999