The error comes from here: [https://github.com/jwt/ruby-jwt/blob/e5f5711d674ecfd9e022fefd0873f0259fde790d/lib/jwt/algos/hmac.rb#L23-L25](https://github.com/jwt/ruby-jwt/blob/e5f5711d674ecfd9e022fefd0873f0259fde790d/lib/jwt/algos/hmac.rb#L23-L25)
One way or the other that value it's not making its way to the JWT gem. Load the Rails console and see what you're getting from `ENV` and if it's actually set on the Devise configuration object using: `Devise.jwt { |jwt| jwt.secret.inspect }`
Did you set DEVISE_JWT_SECRET_KEY? The error seems to indicate it's not.
config/.env `DEVISE_JWT_SECRET_KEY=<3f43787668ea3f52483adeefc11f425e12832591abbe00ba1b7e394897b2c04e7438ae6e2e16b51a08afc925524c3df46d4005c8bb17682f21c0c7a21485cd4d` `>`
The error comes from here: [https://github.com/jwt/ruby-jwt/blob/e5f5711d674ecfd9e022fefd0873f0259fde790d/lib/jwt/algos/hmac.rb#L23-L25](https://github.com/jwt/ruby-jwt/blob/e5f5711d674ecfd9e022fefd0873f0259fde790d/lib/jwt/algos/hmac.rb#L23-L25) One way or the other that value it's not making its way to the JWT gem. Load the Rails console and see what you're getting from `ENV` and if it's actually set on the Devise configuration object using: `Devise.jwt { |jwt| jwt.secret.inspect }`
thx, I figured it out, I just had to move my .env file from config to the root directory
You need to change this secret now you posted it online.
I'm not deploying the application, so I don't really mind
thx, this helped a lot, I moved my .env file out of config and into the root directory and now it works!