Sasafrass / straattaal

Use an RNN to generate Dutch slang and interpret your newly created words!
GNU General Public License v2.0
8 stars 0 forks source link

Add server-side session management with Flask-Session. #39

Closed Sasafrass closed 3 years ago

Sasafrass commented 3 years ago

Adding server-side session management with Flask-Session. Two important benefits

Currently the session stores its required files in a flask_session folder which is personal, so no point in committing them to git, hence the update to the .gitignore. Once Redis is also up and running, we can switch the SESSION_TYPE from 'filesystem' to 'redis'.

Moreover I added an @login_required decorator to the index. This is because we currently have functionality in the /index route that assumes a current_user is logged in and available to be used for the user_id. Once we refactor this to something like a more specialized slang/meaning route, we can remove that.

Additions: @annaproxy : Since I've updated the requirements.txt, could you do the same for the environment.yml and see if it works?Thanks. PS. It also appears that I updated torch to the latest version.