【发布时间】:2016-04-06 21:51:20
【问题描述】:
不知从何而来,并且没有进行任何更改,我开始遇到此错误(团队中的其他人也是如此)。
这发生在某些 gem(指定 git 分支的那些)上,并且仅在我们重新创建环境时发生(在 vagrant 中)。我们没有改变任何东西。
有什么想法吗?更多信息如下:
Using active_utils (2.0.0) from git://github.com/Shopify/active_utils.git (at v2.0.0)
NoMethodError: undefined method `spec' for nil:NilClass
An error occurred while installing active_utils (2.0.0), and Bundler cannot continue.
Make sure that `gem install active_utils -v '2.0.0'` succeeds before bundling.
Using factory_girl (2.6.5) from https://github.com/thoughtbot/factory_girl (at 2.6.x)
NoMethodError: undefined method `spec' for nil:NilClass
An error occurred while installing factory_girl (2.6.5), and Bundler cannot continue.
Make sure that `gem install factory_girl -v '2.6.5'` succeeds before bundling.
- 运行 "gem install active_utils -v '2.0.0'" 有效,但始终捆绑 失败。
- 已清除 gem 缓存,但没有帮助
似乎是 Gemfile 中的所有条目都指定了一个开始失败的分支。
gem 'active_utils', :git => 'git://github.com/Shopify/active_utils.git', :branch => 'v2.0.0'
gem "will_paginate", :git => "git://github.com/mislav/will_paginate.git", :branch => "2-3-stable"
【问题讨论】: