1. HTTP/2 stream 1 was not closed
git clone 过程中报下面的错误
fatal: unable to access 'https://github.com/xxxx/xxx-cocoapods.git/': HTTP/2 stream 1 was not closed cleanly before end of the underlying stream
是git默认使用的通信协议出现了问题,可以通过将默认通信协议修改为 http/1.1 来解决该问题
git config --global http.version HTTP/1.1
设置后在根目录.gitconfig文件查看是否生效
2. LibreSSL SSL_read: error:02FFF03C
从github克隆报下面的错误
fatal: unable to access 'https://github.com/xxx/xxxxx-CocoaPods.git/': LibreSSL SSL_read: error:02FFF03C:system library:func(4095):Operation timed out, errno 60
一般来说都是网络原因,连不上github,有梯子的直接挂个梯子试试,不着急就过段时间再尝试。 或者按照下面的方式修改hosts
点击这个链接查看github的ip地址
然后将这个ip添加到hosts文件中
vim打开,或者直接前往文件目录修改
vim /etc/hosts
3.remote error: CAPTCHA required
Cloning into 'xxxxx'...
fatal: remote error: CAPTCHA required
Your Stash account has been marked as requiring a CAPTCHA to be solved before
you may login again. This is typically caused by too many attempts to login
with an incorrect password. The required CAPTCHA prevents your SCM client from
accessing Stash until it is solved, even if you enter your password correctly.
If you are currently logged in to Stash via a browser you may need to logout
and then log back in in order to clear the CAPTCHA.
字面意思,需要验证码,一开始很懵逼,网上也查了下,大概意思就是你钥匙串或者哪里保存了账号密码,但是现在要重新验证。我是先在钥匙串里找到了仓库地址保存的秘密,操作删除,但是没删除掉。后来在谷歌浏览器记住密码管理,找到对应的账号,删除。重新登陆下代码仓库,这时候发现是需要一个验证码登陆的,输入验证码,登陆后,就可以clone代码了