RoRomniauth 和 facebooker2
在新的 Rails 3.1 应用程序中,仅在 Gemfile 中:
gem "omniauth" gem“facebooker2”
bundle install
给出错误:
Bundler无法找到gem“hashie”的兼容版本: 在 Gemfile 中: facebooker2 (= 0.0.16) ruby 取决于 hashie (~> 1.1.0) ruby
omniauth (>= 0) ruby depends on
hashie (1.2.0)
如何使用omniauth 安装 facebooker2?
In a new application Rails 3.1 with only in Gemfile:
gem "omniauth"
gem "facebooker2"
bundle install
give the error:
Bundler could not find compatible versions for gem "hashie":
In Gemfile:
facebooker2 (= 0.0.16) ruby depends on
hashie (~> 1.1.0) ruby
omniauth (>= 0) ruby depends on
hashie (1.2.0)
How can I install facebooker2 with omniauth?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我刚刚用这 2 个 gem 运行了捆绑包,它起作用了。
但是它确实安装了 facebooker2 0.0.12,而不是 0.0.16,
它也可以在不指定omniauth 版本的情况下工作,但我强烈建议使用 1.0.0 版本,因为存在巨大差异。主要的一点是所有的提供商现在都处于自己的优势之中。
如果捆绑安装不起作用,请运行捆绑更新。
我的 Gemfile.lock 的相关部分:
I just ran bundle with those 2 gems and it worked.
It did install facebooker2 0.0.12 however, and not 0.0.16
it also worked without specifying the omniauth version, but I highly recommend using the a 1.0.0 release as there are huge differences. The main one being all the providers are now in their own gems.
If bundle install doesn't work, run bundle update.
The relevant sections of my Gemfile.lock:
我解决这个问题的唯一方法是克隆 mogli 项目并将 hashie 依赖项更新为 1.2:
https://github.com/davidsf/mogli/commit/bcee3dd815bab7c8eb68511ee0d7c2da39115e14
The only way I have to solve the problem was to clone the mogli project and update the hashie dependence to 1.2:
https://github.com/davidsf/mogli/commit/bcee3dd815bab7c8eb68511ee0d7c2da39115e14