You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've lost a couple of hours debugging today, because my sessions weren't working on a Rails app and I think that the culprit was this gem.
When you use this gem and try to use a session it returns just a hash, instead of the ActionDispatch::Request::Session which is Rails default.
I'm new to rails and for me it was "normal" for it to be a Hash, but I think to avoid wasting time debugging (as I did), it would be useful to make it easier for debugging. Some ideas that for me would be a better design than just "replace" the rails session with a Hash:
Raise an exception if you try to write to a session and it is not going to be stored
Log a warning if you write/read from a session when the session is disabled
Use another class as the session object, so it makes it easier to figure out that this gem overwrote the Rails session
After debugging a lot and trying a lot of things, I noticed this gem on the Gemfile, just commented it and everything worked again, and I was not even using it (I had replaced my ApplicationController to inherit from ActionController::Base).
As I said, I'm new to this, so I might me talking bullshit, if so, sorry, but if this is really caused by this gem, I'd really appreciate if it is easier to debug.
The text was updated successfully, but these errors were encountered:
I've lost a couple of hours debugging today, because my sessions weren't working on a Rails app and I think that the culprit was this gem.
When you use this gem and try to use a session it returns just a hash, instead of the
ActionDispatch::Request::Session
which is Rails default.I'm new to rails and for me it was "normal" for it to be a Hash, but I think to avoid wasting time debugging (as I did), it would be useful to make it easier for debugging. Some ideas that for me would be a better design than just "replace" the rails
session
with a Hash:After debugging a lot and trying a lot of things, I noticed this gem on the
Gemfile
, just commented it and everything worked again, and I was not even using it (I had replaced myApplicationController
to inherit fromActionController::Base
).As I said, I'm new to this, so I might me talking bullshit, if so, sorry, but if this is really caused by this gem, I'd really appreciate if it is easier to debug.
The text was updated successfully, but these errors were encountered: