A couple of questions: I''m getting "Error creating account: confirmation email not sent" with the salted login (using mysql-4.1.13), but I''m seeing nothing that looks like an error message logged anywhere. Where I read: <quote> When running tests, I kept getting cattr_accessor errors in the time.rb test, and also uninitialized constant Gem::Specification::Date errors in the user_test.rb To solve this, near the top of the test_helper.rb file and before the require File.expand_path() line, I added require .rubygems.. </quote> Is that the right fix? I assumed that cattr_accessor was a typo for attr_accessor, as I could find no mention of the method elswhere. Also, when I try to use Rails with Apache2 I can''t get at any of the user urls, so the login generator doesn''t work. I think this is because we don''t have RewriteEngine on but then we don''t have mod_rewrite in the modules directory for apache. Should it be there as standard, or do we need to get it and compile it? I certainly kind find from where, if that''s true, despite various queries to Google. Thank you, Hugh
I had this issue, and checking the db the user row had been added correctly. I adjusted the ActionMailer settings so they now look like: ActionMailer::Base.server_settings = { :address => "xxx.xxx.xxx.xxx", :port => 25, :domain => "osbaldestin.net" } where xxx.xxx.xxx.xxx is the real ip address of the mail server (local). Having used this instead of 127.0.0.1 it started to work. Once it started working I got lazy and moved on. Geoff Hugh Sasse wrote:> A couple of questions: > > I''m getting "Error creating account: confirmation email not sent" > with the salted login (using mysql-4.1.13), but I''m seeing nothing > that looks like an error message logged anywhere. > > Where I read: > <quote> > When running tests, I kept getting cattr_accessor errors in the > time.rb test, and also uninitialized constant Gem::Specification::Date > errors in the user_test.rb > > To solve this, near the top of the test_helper.rb file and before the > require File.expand_path() line, I added require .rubygems.. > > </quote> > > Is that the right fix? I assumed that cattr_accessor was a typo for > attr_accessor, as I could find no mention of the method elswhere. > > > Also, when I try to use Rails with Apache2 I can''t get at any of the > user urls, so the login generator doesn''t work. I think this is > because we don''t have > > RewriteEngine on > > but then we don''t have mod_rewrite in the modules directory for > apache. Should it be there as standard, or do we need to get it and > compile it? I certainly kind find from where, if that''s true, > despite various queries to Google. > > Thank you, > Hugh > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >
On Wed, 28 Sep 2005, Geoff wrote:> I had this issue, and checking the db the user row had been added correctly. > I adjusted the ActionMailer settings so they now look like: > > ActionMailer::Base.server_settings = { > :address => "xxx.xxx.xxx.xxx", > :port => 25, > :domain => "osbaldestin.net" > } > > where xxx.xxx.xxx.xxx is the real ip address of the mail server (local). > Having used this instead of 127.0.0.1 it started to work. Once it started > working I got lazy and moved on.This didn''t fix the problem. Can I squeeze more verbosity out of this so I can get a clue as to what the problem is, please?> > Geoff > > Hugh Sasse wrote: > >> A couple of questions: >> >> I''m getting "Error creating account: confirmation email not sent" >> with the salted login (using mysql-4.1.13), but I''m seeing nothing >> that looks like an error message logged anywhere. >> >> Where I read: >> <quote> >> When running tests, I kept getting cattr_accessor errors in the time.rb >> test, and also uninitialized constant Gem::Specification::Date errors in >> the user_test.rb >> >> To solve this, near the top of the test_helper.rb file and before the >> require File.expand_path() line, I added require .rubygems.. >> >> </quote> >> >> Is that the right fix? I assumed that cattr_accessor was a typo for >> attr_accessor, as I could find no mention of the method elswhere. >> >> >> Also, when I try to use Rails with Apache2 I can''t get at any of the >> user urls, so the login generator doesn''t work. I think this is >> because we don''t have >> >> RewriteEngine on >> >> but then we don''t have mod_rewrite in the modules directory for >> apache. Should it be there as standard, or do we need to get it and >> compile it? I certainly kind find from where, if that''s true, >> despite various queries to Google. >> >> Thank you, >> Hugh >> _______________________________________________ >> Rails mailing list >> Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org >> http://lists.rubyonrails.org/mailman/listinfo/rails >> > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >
On Sep 29, 2005, at 10:21 AM, Hugh Sasse wrote:> On Wed, 28 Sep 2005, Geoff wrote: > > >> I had this issue, and checking the db the user row had been added >> correctly. >> I adjusted the ActionMailer settings so they now look like: >> >> ActionMailer::Base.server_settings = { >> :address => "xxx.xxx.xxx.xxx", >> :port => 25, >> :domain => "osbaldestin.net" >> } >> >> where xxx.xxx.xxx.xxx is the real ip address of the mail server >> (local). Having used this instead of 127.0.0.1 it started to work. >> Once it started working I got lazy and moved on. >> > > This didn''t fix the problem. Can I squeeze more verbosity out of > this so I can get a clue as to what the problem is, please? >At the end of the signup method, in the rescue clause, add the line "raise." This will reraise the exception and you can see what the actual error is.> >> >> Geoff >> >> Hugh Sasse wrote: >> >> >>> A couple of questions: >>> I''m getting "Error creating account: confirmation email not sent" >>> with the salted login (using mysql-4.1.13), but I''m seeing nothing >>> that looks like an error message logged anywhere. >>> Where I read: >>> <quote> >>> When running tests, I kept getting cattr_accessor errors in the >>> time.rb test, and also uninitialized constant >>> Gem::Specification::Date errors in the user_test.rb >>> To solve this, near the top of the test_helper.rb file and before >>> the require File.expand_path() line, I added require .rubygems.. >>> </quote> >>> Is that the right fix? I assumed that cattr_accessor was a typo for >>> attr_accessor, as I could find no mention of the method elswhere. >>> Also, when I try to use Rails with Apache2 I can''t get at any of the >>> user urls, so the login generator doesn''t work. I think this is >>> because we don''t have >>> RewriteEngine on >>> but then we don''t have mod_rewrite in the modules directory for >>> apache. Should it be there as standard, or do we need to get it and >>> compile it? I certainly kind find from where, if that''s true, >>> despite various queries to Google. >>> >>> Thank you, >>> Hugh >>> _______________________________________________ >>> Rails mailing list >>> Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org >>> http://lists.rubyonrails.org/mailman/listinfo/rails >>> >> _______________________________________________ >> Rails mailing list >> Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org >> http://lists.rubyonrails.org/mailman/listinfo/rails >> >> > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >
On Thu, 29 Sep 2005, Joseph Hosteny wrote:> > On Sep 29, 2005, at 10:21 AM, Hugh Sasse wrote: > >> This didn''t fix the problem. Can I squeeze more verbosity out of >> this so I can get a clue as to what the problem is, please? >> > > At the end of the signup method, in the rescue clause, add the line "raise." > This will reraise the exception and you can see what the actual error is. >I''ve sent a patch off to the address in the gemspec for the salted login generator: --- ./salted_login_generator-1.1.1/templates/controller.rb.orig 2005-09-30 14:37:56.616605000 +0100 +++ ./salted_login_generator-1.1.1/templates/controller.rb 2005-09-30 16:30:30.325099000 +0100 @@ -30,8 +30,9 @@ redirect_to :action => ''login'' end end - rescue + rescue => e flash.now[''message''] = l(:<%= singular_name %>_confirmation_email_error) + logger.error "signup: #{e.inspect}" end end @@ -51,8 +52,9 @@ flash.now[''notice''] = l(:<%= singular_name %>_updated_password, "#{@<%= singular_name %>.email}") end end - rescue + rescue => e flash.now[''message''] = l(:<%= singular_name %>_change_password_email_error) + logger.error "change_password #{e.inspect}" end end @@ -86,8 +88,9 @@ end redirect_back_or_default :action => ''welcome'' end - rescue + rescue => e flash.now[''message''] = l(:<%= singular_name %>_forgotten_password_email_error, "#{@params[''<%= singular_name %>''][''email'']}") + logger.error "forgot_password: #{e.inspect}" end end end @@ -128,8 +131,9 @@ destroy(@<%= singular_name %>) end logout - rescue + rescue => e flash.now[''message''] = l(:<%= singular_name %>_delete_email_error, "#{@<%= singular_name %>[''email'']}") + logger.error "delete: #{e.inspect}" redirect_back_or_default :action => ''welcome'' end end which fixes the problem for me. Turned out to be due to a problem with the mail configuration, giving an SMTP related error.... Thank you Hugh