RoR Rails 3 Devise :: SessionsController无法验证现有用户

时间:2011-10-31 01:13:52

标签: ruby-on-rails device

  • 我正在http://localhost:3000/users/sign_in
  • 启动该应用
  • 接受用户/密码;发布
  • 设备无法验证我的用户并跳转到#new
  • #new再次渲染sign_in,所以我处于循环中。

这是日志:

Started POST "/users/sign_in" for 127.0.0.1 at 2011-10-30 17:49:33 -0700
      Processing by Devise::SessionsController#create as HTML
      Parameters: {"utf8"=>"✓", "authenticity_token"=>"NhVu4CQwhatever+CAErP19YVIkz0lIz3qEERac=", "user"=>{"email"=>"abc@def.com", "password"=>"[FILTERED]", "remember_me"=>"1"}, "commit"=>"Sign in"}

然后它运行SQL来获取用户。 copy / pate到postgresql,'select'获取我的用户记录。它肯定存在**

[1m[35mUser Load (5.0ms)[0m  SELECT "users".* FROM "users" WHERE "users"."email" = 'abc@def.com' LIMIT 1

下一个日志条目:跳转到#new - 就像用户不存在一样

Processing by Devise::SessionsController#new as HTML
    Parameters: {"utf8"=>"✓", "authenticity_token"=>"NhVu4CQwhatever+CAErP19YVIkz0lIz3qEERac=", "user"=>{"email"=>"abc@def.com", "password"=>"[FILTERED]", "remember_me"=>"1"}, "commit"=>"Sign in"}
    Rendered devise/sessions/new.html.erb within layouts/application (4.0ms)

0 个答案:

没有答案