简体   繁体   English

没有要加载的此类文件-openid / store / filesystem(Rails omniauth)

[英]no such file to load — openid/store/filesystem (Rails omniauth)

This is first time I'm trying to use Omniauth. 这是我第一次尝试使用Omniauth。 While I was testing https://github.com/pt/devise-omniauth-example this example from github I came across an error 当我测试https://github.com/pt/devise-omniauth-example时,来自github的这个示例遇到了一个错误

 .rvm/gems/ruby-1.9.2-p290/gems/activesupport-3.1.3/lib/active_support/dependencies.rb:240:in `require': no such file to load -- openid/store/filesystem (LoadError)

Here is my Gemfile content 这是我的Gemfile内容

source 'http://rubygems.org'

gem 'rake'
gem 'rails'
gem 'sqlite3-ruby', :require => 'sqlite3'
gem 'devise', :git => 'git://github.com/plataformatec/devise', :branch => 'master'
gem "omniauth", "1.0.1"
gem 'paperclip'
gem "simple_form", "~> 1.5.2"
gem 'twitter_oauth', '0.4.3'
gem "rest-client", "1.6.7", :require => "restclient"
gem "sluggable"


group :development, :test do
 gem 'rspec-rails'
 gem 'fixjour'
end

I search web but there was no luck. 我在网上搜索,但没有运气。

According to this : 根据

If you get "openid/store/filesystem (LoadError)" then you may need to add this to your Gemfile: 如果收到“ openid / store / filesystem(LoadError)”,则可能需要将其添加到您的Gemfile中:

gem "oa-openid"

This is due to various versions of Gems you are using and the dependencies among them. 这是由于您使用的Gems版本不同以及它们之间的依赖性所致。
In the example at https://github.com/pt/devise-omniauth-example , https://github.com/pt/devise-omniauth-example的示例中,
if you notice the Gemfile ,there is 如果您注意到Gemfile ,则有

gem 'omniauth', '0.2.0'

but in your Gemfile above, you are using 但是在上面的Gemfile中,您正在使用

gem "omniauth", "1.0.1"

Add gem 'ruby-openid-apps-discovery' , and add below in application.rb . 添加gem 'ruby-openid-apps-discovery' ,然后在application.rb添加以下内容。

require 'omniauth-openid'
require 'openid'
require 'openid/store/filesystem'
require 'gapps_openid'

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Ruby和Rails与Omniauth-Google和OpenID错误 - Ruby and rails with Omniauth - google and openid error Rails在文件系统上的存储会话 - Rails store session on filesystem Ruby on Rails-“需要”中:无法加载此类文件-omniauth / oauth,即使我安装了omniauth - Ruby on Rails - in 'require': cannot load such file — omniauth/oauth, even though I installed omniauth 适用于Google帐户的OpenID2即将消失,rails和omniauth - OpenID2 for Google accounts is going away, rails and omniauth Rails Devise Omniauth omniauth_openid_connect问题; 总是得到`未找到。 验证通过 - Rails Devise Omniauth omniauth_openid_connect issue; Always getting `Not found. Authentication passthru` Rails Devise Omniauth omniauth_openid_connect 问题,如何使用不同主机的端点 - Rails Devise Omniauth omniauth_openid_connect issue, how to work with endpoints with different hosts 没有要加载的此类文件-openid / extensions / sreg - no such file to load — openid/extensions/sreg Ruby中的Omniauth + OpenID:弹出式窗口中的Google OpenID身份验证 - Omniauth + OpenID in Ruby: Google OpenID authentication in a popup 如何存储Rails应用对文件系统的响应 - How to store response of rails app to filesystem Rails中的Omniauth - Omniauth in Rails
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM