亲测解决Bundler HTTPError Could not fetch specs from

这个问题源于ruby的网站连接不上,解决方法是修改网页地址或者网络配置。

环境

win11 + ruby

问题原文

c 复制代码
Retrying fetcher due to error (2/4): Bundler::HTTPError Could not fetch specs from 
https://rubygems.org/ due to underlying error <IO::TimeoutError: Failed to open TCP connection to rubygems.org:443 (Blocking operation timed out!) (https://rubygems.org/specs.4.8.gz)>

解决方法

方法一

打开Gemfile,将https改成http,Open the Gemfile and change first line from this:

c 复制代码
source 'https://www.rubygems.org'

to this

python 复制代码
source 'http://www.rubygems.org'

remove the 's' from 'https'.

方法二

一般方法一就可以解决了,如果不行尝试换一个网络:比如手机wifi。

Change it to another network (mobile hotspot)

方法三

关闭ipv6的配置。

参考

https://stackoverflow.com/a/47392700/15329637

https://stackoverflow.com/questions/51201517/ruby-cant-connect-to-rubygems-org

相关推荐
Freak嵌入式20 分钟前
aiohttps异步HTTPS库:uPyPI+MicroPython一键安装
人工智能·python·网络协议·http·https·micropython
AnalogElectronic29 分钟前
html+js+css实现七龙珠神龙召唤特效
javascript·css·html
LXXgalaxy1 小时前
HTML头部元信息避坑指南
前端·html
不恋水的雨2 小时前
html中补齐table表格合并导致每行td数量不一致的情况
前端·html
iReachers2 小时前
HTML打包EXE工具四种弹窗方式图文详解 - 单窗口/新窗口/标签页/浏览器打开
前端·javascript·html·弹窗·html打包exe·html转程序
木井巳2 小时前
【网络原理】初识相关概念
网络·网络协议·tcp/ip·http·https·udp
ZC跨境爬虫21 小时前
海南大学交友平台登录页开发实战day6(覆写接口+Flask 本地链接正常访问)
前端·后端·python·flask·html
iReachers1 天前
HTML打包EXE三种加密方式对比:静态密码、离线一机一码、网络验证
html·html转exe·html打包exe·html一键打包exe工具
05Nuyoah1 天前
第一阶段:HTML的笔记
前端·笔记·html
华科大胡子2 天前
HTML头部元信息避坑
html