Ruby on rails 使用OmniAuth时出现零对象错误(正常工作)

Ruby on rails 使用OmniAuth时出现零对象错误(正常工作),ruby-on-rails,twitter,oauth,omniauth,Ruby On Rails,Twitter,Oauth,Omniauth,我在使用Omniauth时出现了一个奇怪的错误。这似乎与我的代码没有什么关系 这是Twitter返回一些奇怪的变形对象的结果吗 You have a nil object when you didn't expect it! You might have expected an instance of ActiveRecord::Base. The error occurred while evaluating nil.[] oa-oauth (0.1.6) lib/omniauth/stra

我在使用Omniauth时出现了一个奇怪的错误。这似乎与我的代码没有什么关系

这是Twitter返回一些奇怪的变形对象的结果吗

You have a nil object when you didn't expect it!
You might have expected an instance of ActiveRecord::Base.
The error occurred while evaluating nil.[]

oa-oauth (0.1.6) lib/omniauth/strategies/oauth.rb:24:in `callback_phase'
oa-core (0.1.6) lib/omniauth/strategy.rb:27:in `call!'
oa-core (0.1.6) lib/omniauth/strategy.rb:19:in `call'
oa-core (0.1.6) lib/omniauth/builder.rb:30:in `call'
haml (3.0.24) lib/sass/plugin/rack.rb:41:in `call'

现在可以了。我高度怀疑这是推特的畸形回归

我也有类似的问题。清除浏览器缓存解决了这个问题


slothistype

是否添加了必要的回调路由?i、 e.匹配“/auth/:provider/callback”,:to=>”会话#创建“Yes”,因为它正常工作。这就是为什么它如此奇怪