NameError in AccountController#login undefined local variable or method `salt' for #<User:0xb551ef2c>
Added by shivaranjani v about 12 years ago
Hello All,
I have installed redmine on Ubuntu 10.4LTS. The following are the version details
Redmine-1.4.2
Ruby-1.8.7
Rails-2.3.14.
I have installed mongrel. When I trying to login, it is displaying me the following error:-
undefined local variable or method `salt' for #<User:0xb5624b4c>
RAILS_ROOT: /var/www/redmine
Application Trace | Framework Trace | Full Trace
/usr/lib/ruby/gems/1.8/gems/activerecord-2.3.14/lib/active_record/attribute_methods.rb:260:in `method_missing'
/var/www/redmine/app/models/user.rb:244:in `check_password?'
/var/www/redmine/app/models/user.rb:144:in `try_to_login'
/var/www/redmine/app/controllers/account_controller.rb:143:in `password_authentication'
/var/www/redmine/app/controllers/account_controller.rb:138:in `authenticate_user'
/var/www/redmine/app/controllers/account_controller.rb:30:in `login'
Request
Parameters:
{"password"=>"admin",
"authenticity_token"=>"9EqEHbvAC7ly+aIwbdmV5dJ7Ns+uJUUPmBox3aMhBg4=",
"login"=>"Login \302\273",
"username"=>"admin"}
Show session dump
Response
Headers:
{"Content-Type"=>"",
"Cache-Control"=>"no-cache"}
When I try to run the command
sudo rake generate_session_store
sudo RAILS_ENV=production rake db:migrate
sudo RAILS_ENV=production rake redmine:load_default_data
I get the following error:-
redmine is not in the sudoers file. This incident will be reported.
redmine@redmine-server:/var/www/redmine$ rake generate_session_store
/usr/lib/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:213: warning: I nsecure world writable dir /usr/lib/ruby/gems/1.8 in PATH, mode 040777
Please install RDoc 2.4.2+ to generate documentation.
redmine@redmine-server:/var/www/redmine$ RAILS_ENV=production rake db:migrate /usr/lib/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:213: warning: I nsecure world writable dir /usr/lib/ruby/gems/1.8 in PATH, mode 040777
Please install RDoc 2.4.2+ to generate documentation.
AddWorkflowsAssigneeAndAuthor: migrating ================================
-- add_column(:workflows, :assignee, :boolean, {:null=>false, :default=>false})
rake aborted!
An error has occurred, all later migrations canceled:
Mysql::Error: Duplicate column name 'assignee': ALTER TABLE `workflows` ADD `ass ignee` tinyint(1) DEFAULT 0 NOT NULL
Tasks: TOP => db:migrate
(See full trace by running task with --trace)
redmine@redmine-server:/var/www/redmine$ RAILS_ENV=production rake redmine:load_ default_data
/usr/lib/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:213: warning: I nsecure world writable dir /usr/lib/ruby/gems/1.8 in PATH, mode 040777
Please install RDoc 2.4.2+ to generate documentation.
Select language: ar, bg, bs, ca, cs, da, de, el, en, en-GB, es, et, eu, fa, fi, fr, gl, he, hr, hu, id, it, ja, ko, lt, lv, mk, mn, nl, no, pl, pt, pt-BR, ro, r u, sk, sl, sq, sr, sr-YU, sv, th, tr, uk, vi, zh, zh-TW [en] en
====================================
Error: unknown attribute: issues_visibility
Default configuration data was not loaded.
I have added the patches attached. Still its displaying the error.
I do request you to provide your inputs inorder to resolve the issue.
Thanks,
SR
mongrel.rb (2.83 KB) mongrel.rb | |||
rails_6440_patch.rb (313 Bytes) rails_6440_patch.rb |
Replies (1)
RE: NameError in AccountController#login undefined local variable or method `salt' for #<User:0xb551ef2c>
-
Added by shivaranjani v about 12 years ago
It got resolved when i have deleted two fields from workflows table-assignee and author. Then run the command:- sudo RAILS_ENV=production rake db:migrate
and then sudo RAILS_ENV=production rake redmine:load_default_data run this command. The problem got resolved.