Michael wrote:
Since we updated to 0.9.8, we have problems creating new accounts.
The error message users are getting is "Something went wrong, perhaps this email is already registered, try the
forgot password link"
production_errors.log
shows<backtrace>[RAILS_ROOT]/vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis/client.rb:85:in `call' [RAILS_ROOT]/vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis.rb:1205:in `block in sadd' [RAILS_ROOT]/vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis.rb:36:in `block in synchronize' /usr/local/rvm/rubies/ruby-2.0.0-p247/lib/ruby/2.0.0/monitor.rb:211:in `mon_synchronize' [RAILS_ROOT]/vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis.rb:36:in `synchronize' [RAILS_ROOT]/vendor/bundle/ruby/2.0.0/gems/redis-3.0.6/lib/redis.rb:1204:in `sadd' [RAILS_ROOT]/lib/common_passwords/common_passwords.rb:44:in `load_passwords' [RAILS_ROOT]/lib/common_passwords/common_passwords.rb:33:in `block in password_list' [RAILS_ROOT]/lib/common_passwords/common_passwords.rb:32:in `synchronize' .... [RAILS_ROOT]/vendor/bundle/ruby/2.0.0/bin/thin:23:in `<main>'</backtrace> <message>ERR wrong number of arguments for 'sadd' command</message> <url>http://test1101b.discoursehosting.net/users</url> <exception-class>Redis::CommandError</exception-class> </hash>
When removing line 44 (redis.sadd) from common_passwords.rb the problem goes away.
def self.load_passwords passwords = File.readlines(PASSWORD_FILE) redis.sadd LIST_KEY, passwords[0,5000].map!(&:chomp) rescue Errno::ENOENT # tolerate this so we don't block signups Rails.logger.error "Common passwords file #{PASSWORD_FILE} is not found! Common password checking is skipped." end
The
10k-common-passwords.txt
file is there, and it's readable.Anyone have any idea what is going on here?
Posts: 6
Participants: 3