authlogic_openid
authlogic_openid copied to clipboard
Exception uninitialized constant OpenIdAuthentication::InvalidOpenId uninitialized
On a new project, while trying to setup Authlogic and Authlogic OpenId I constantly run into that exception, which in turn unables me to create users / login users.
I'm using Rails 2.3.5 with the following gems:
config.gem 'authlogic', :version => '2.1.3' config.gem 'rack-openid', :version => '0.2.2', :lib => 'rack/openid' config.gem 'ruby-openid', :version => '2.1.7', :lib => 'openid' config.gem 'authlogic-oid', :version => '1.0.4', :lib => 'authlogic_openid'
I'm also using the latest version of rails/open_id_authentication plugin.
Anyone could provide me with some assistance / guide me in the right direction on how to tackle this problem?
Best regards, DBA
"rails/open_id_authentication plugin has been updated a few days ago and it breaks compatibility with the authlogic_openid gem (v=1.0.4)." http://stackoverflow.com/questions/2092694/authlogic-openid-error-uninitialized-constant-openidauthenticationinvalidopeni
Since my original post I've downloaded the gem's source code and tried to fix the problem.
rails/open_id_authentication plugin has been massively updated over the months, without any updates to this gem. At the moment, in my source code, the problem is that in the User.save method I call the class controller's authenticate with open id but never receive the callback with the result.
If I use the rails plugin directly everything works fine and I receive the user's information in the registration hash.
After trying to make it work for an hour, I found a old version of plugin and cloned it. It works fine now. Guess that will have to do till Ben updates this gem.
The version it's ment to work with can be found in the gem's test/lib directory, if that's what you're looking for.
I've managed to get past the no callback issue. Apparently, this line was preventing the OpenID callback from happening: options[:return_to] = session_class.controller.url_for(:for_model => "1",:controller=>"users",:action=>"create")
Still wondering what's that :for_model => "1"
I would like to know if this problem will be fixed soon or if there's a way to set up my rails application so that it can be easily configured in the environment?
Will this be fixed in authlogic-oid or in open_id_authentication?
Any news on when it's gonna be fixed? We hacked around it by mixing the new and the old version of the open_id_authentication, but that should not go onto production
I resolved that issue with mreinsch/authlogic_openid@9b802c347f5addebcbce945af3b5f80b3ee7b214