inaturalist/inaturalist — Issue #9: Cannot connect to Yahoo
Author: kaleworsley
Created: 2012-02-28 23:46:06+00:00
State: open

When I click `Connect to Yahoo` on my profile, I get a 500 error.

On my development copy I get the following.

NoMethodError in Provider authorizationsController#create
--------------------------------------------------------------------------------

```
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.[]
```

```
/vagrant/app/controllers/provider_authorizations_controller.rb:98:in `create_provider_authorization'
/vagrant/app/controllers/provider_authorizations_controller.rb:61:in `create'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/base.rb:1333:in `send'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/base.rb:1333:in `perform_action_without_filters'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/filters.rb:617:in `call_filters'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/filters.rb:638:in `run_before_filters'
/vagrant/app/controllers/application_controller.rb:190:in `catch_missing_mobile_templates'
/var/lib/gems/1.8/gems/activesupport-2.3.12/lib/active_support/callbacks.rb:178:in `send'
/var/lib/gems/1.8/gems/activesupport-2.3.12/lib/active_support/callbacks.rb:178:in `evaluate_method'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/filters.rb:186:in `call'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/filters.rb:635:in `run_before_filters'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/filters.rb:615:in `call_filters'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/filters.rb:610:in `perform_action_without_benchmark'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/benchmarking.rb:68:in `perform_action_without_rescue'
/var/lib/gems/1.8/gems/activesupport-2.3.12/lib/active_support/core_ext/benchmark.rb:17:in `ms'
/usr/lib/ruby/1.8/benchmark.rb:308:in `realtime'
/var/lib/gems/1.8/gems/activesupport-2.3.12/lib/active_support/core_ext/benchmark.rb:17:in `ms'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/benchmarking.rb:68:in `perform_action_without_rescue'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/rescue.rb:160:in `perform_action_without_flash'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/flash.rb:151:in `perform_action'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/base.rb:532:in `send'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/base.rb:532:in `process_without_filters'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/filters.rb:606:in `process'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/base.rb:391:in `process'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/base.rb:386:in `call'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/routing/route_set.rb:438:in `call'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/dispatcher.rb:87:in `dispatch'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/dispatcher.rb:121:in `_call'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/dispatcher.rb:130:in `build_middleware_stack'
/var/lib/gems/1.8/gems/activerecord-2.3.12/lib/active_record/query_cache.rb:29:in `call'
/var/lib/gems/1.8/gems/activerecord-2.3.12/lib/active_record/query_cache.rb:29:in `call'
/var/lib/gems/1.8/gems/activerecord-2.3.12/lib/active_record/connection_adapters/abstract/query_cache.rb:34:in `cache'
/var/lib/gems/1.8/gems/activerecord-2.3.12/lib/active_record/query_cache.rb:9:in `cache'
/var/lib/gems/1.8/gems/activerecord-2.3.12/lib/active_record/query_cache.rb:28:in `call'
/var/lib/gems/1.8/gems/activerecord-2.3.12/lib/active_record/connection_adapters/abstract/connection_pool.rb:361:in `call'
/var/lib/gems/1.8/gems/oa-core-0.2.6/lib/omniauth/strategy.rb:164:in `call_app!'
/var/lib/gems/1.8/gems/oa-core-0.2.6/lib/omniauth/strategy.rb:129:in `callback_phase'
/var/lib/gems/1.8/gems/oa-openid-0.2.6/lib/omniauth/strategies/open_id.rb:89:in `callback_phase'
/var/lib/gems/1.8/gems/oa-core-0.2.6/lib/omniauth/strategy.rb:68:in `callback_call'
/var/lib/gems/1.8/gems/oa-core-0.2.6/lib/omniauth/strategy.rb:42:in `call!'
/var/lib/gems/1.8/gems/oa-core-0.2.6/lib/omniauth/strategy.rb:30:in `call'
/var/lib/gems/1.8/gems/oa-core-0.2.6/lib/omniauth/strategy.rb:44:in `call!'
/var/lib/gems/1.8/gems/oa-core-0.2.6/lib/omniauth/strategy.rb:30:in `call'
/var/lib/gems/1.8/gems/oa-core-0.2.6/lib/omniauth/strategy.rb:44:in `call!'
/var/lib/gems/1.8/gems/oa-core-0.2.6/lib/omniauth/strategy.rb:30:in `call'
/var/lib/gems/1.8/gems/oa-core-0.2.6/lib/omniauth/strategy.rb:44:in `call!'
/var/lib/gems/1.8/gems/oa-core-0.2.6/lib/omniauth/strategy.rb:30:in `call'
/var/lib/gems/1.8/gems/oa-core-0.2.6/lib/omniauth/builder.rb:30:in `call'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/string_coercion.rb:25:in `call'
/var/lib/gems/1.8/gems/rack-1.1.2/lib/rack/head.rb:9:in `call'
/var/lib/gems/1.8/gems/rack-1.1.2/lib/rack/methodoverride.rb:24:in `call'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/params_parser.rb:15:in `call'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/session/cookie_store.rb:99:in `call'
/var/lib/gems/1.8/gems/activesupport-2.3.12/lib/active_support/cache/strategy/local_cache.rb:25:in `call'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/failsafe.rb:26:in `call'
/var/lib/gems/1.8/gems/rack-1.1.2/lib/rack/lock.rb:11:in `call'
/var/lib/gems/1.8/gems/rack-1.1.2/lib/rack/lock.rb:11:in `synchronize'
/var/lib/gems/1.8/gems/rack-1.1.2/lib/rack/lock.rb:11:in `call'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/dispatcher.rb:114:in `call'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/reloader.rb:34:in `run'
/var/lib/gems/1.8/gems/actionpack-2.3.12/lib/action_controller/dispatcher.rb:108:in `call'
/var/lib/gems/1.8/gems/rails-2.3.12/lib/rails/rack/static.rb:31:in `call'
/var/lib/gems/1.8/gems/rack-1.1.2/lib/rack/urlmap.rb:47:in `call'
/var/lib/gems/1.8/gems/rack-1.1.2/lib/rack/urlmap.rb:41:in `each'
/var/lib/gems/1.8/gems/rack-1.1.2/lib/rack/urlmap.rb:41:in `call'
/var/lib/gems/1.8/gems/rails-2.3.12/lib/rails/rack/log_tailer.rb:17:in `call'
/var/lib/gems/1.8/gems/rack-1.1.2/lib/rack/content_length.rb:13:in `call'
/var/lib/gems/1.8/gems/rack-1.1.2/lib/rack/handler/webrick.rb:48:in `service'
/usr/lib/ruby/1.8/webrick/httpserver.rb:104:in `service'
/usr/lib/ruby/1.8/webrick/httpserver.rb:65:in `run'
/usr/lib/ruby/1.8/webrick/server.rb:173:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:162:in `start_thread'
/usr/lib/ruby/1.8/webrick/server.rb:95:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `each'
/usr/lib/ruby/1.8/webrick/server.rb:92:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:23:in `start'
/usr/lib/ruby/1.8/webrick/server.rb:82:in `start'
/var/lib/gems/1.8/gems/rack-1.1.2/lib/rack/handler/webrick.rb:14:in `run'
/var/lib/gems/1.8/gems/rails-2.3.12/lib/commands/server.rb:111
script/server:3:in `require'
script/server:3
```