A solution to store session into redis implemented by python