-
-
Notifications
You must be signed in to change notification settings - Fork 578
Gorilla securecookie behaviour change breaks buffalo #1067
Comments
Good find! Wow. Any ideas on how to fix this? Could be just as simple as using “development” in dev mode and let it raise an error in any other environment. I want it to error in prod if not set. But I agree that dev, there should be something. |
Quick fix is to set |
I'm brand new to Buffalo and Go, just working through the getting started documentation and the |
What does your Gorilla changed something so until the next buffalo release you just need to have an environment variable I don’t use the .env file so I can’t speak to that. I just set all my dev vars in my bash/fish configs. When dealing with environment variables it’s always best to restart any tools, or terminal windows, you have open that might not notice that the variable changed. |
@bencarter78 by default there is no "SESSION_SECRET" variable, but there is "SESSIONS_SECRET" in .env file. I've changed SESSIONS_SECRET to SESSION_SECRET and it works now as expected. |
It would be helpful if the error said something like the following:
|
* Force a default session secret in development environment fixes #1067 * fixed travis??
Steps to Reproduce the Problem
Please describe in painful detail what you did (so others can play along with you) to get to this point. This includes things like the exact command(s) you used, or the
curl
command you used, that sort of thing.Assume you have
buffalo
in yourPATH
and Postgres up and runningGo to http://localhost:3000
Expected Behavior
Here I would expect the a fully functioning buffalo based home page.
Actual Behavior
A buffalo error page with the following message:
securecookie: hash key is not set
An example of this can be found at:
https://ci.appveyor.com/project/markbates/buffalo/build/935
Info
Short version, the following commit to github.com/gorilla/securecookie broke things:
gorilla/securecookie@b009e17
The text was updated successfully, but these errors were encountered: