Omniauth and Devise started failing on a blue morning this morning when they authenticated to Facebook?
Everything was fine and then:
I, [2017-03-28T02:54:18.998055 #663] INFO -- : Completed 200 OK in 39ms (Views: 14.3ms | ActiveRecord: 8.5ms)
I, [2017-03-28T02:54:26.225944 #663] INFO -- : Started GET "/users/auth/facebook" for 176.109.217.212 at 2017-03-28 02:54:26 -0400
I, [2017-03-28T02:54:26.411915 #663] INFO -- : Started GET "/users/auth/facebook/callback?code=CODE and STATE" for 176.109.217.212 at 2017-03-28 02:54:26 -0400
I, [2017-03-28T02:54:26.566419 #663] INFO -- : Processing by Users::OmniauthCallbacksController#failure as HTML
I, [2017-03-28T02:54:26.566667 #663] INFO -- : Parameters: {"code"=>"CODE", "state"=>"STATE"}
I, [2017-03-28T02:54:26.567608 #663] INFO -- : Redirected to https://example.com/users/sign_in
All Facebook logic doesn't seem to work, however the error is hard to catch. I am showing login with "credentials invalid" error to my users, but this is not their fault. How can I tell them facebook to blame.
+3
source to share
1 answer
Facebook migrated yesterday at night. You must use version omniauth-facebook
> = 4.0.0 for it to work again (source https://github.com/mkdynamic/omniauth-facebook/issues/278 )
Update your Gemfile with gem 'omniauth-facebook', '4.0.0'
, then run bundle update
and everything should be back to normal.
+2
source to share