I know i can set the max_age in the config. I did that. 
But i want to override the max_age value from config, by setting max_age in 
get_sessions.

Use case is this. I want by default max_age to be None.
But if the user clicks on the "Remember me" checkbox,  their session to 
last longer than the browser session. 

On Monday, October 1, 2012 1:32:46 AM UTC-7, alex wrote:
>
> I believe you can do this by setting session_max_age config param. 
> See this for more details: 
> http://webapp-improved.appspot.com/_modules/webapp2_extras/sessions.html 
>
> Also, the webapp2 group is actually here: 
> https://groups.google.com/forum/#!forum/webapp2 
>
> -- alex 
>
> On Mon, Oct 1, 2012 at 10:17 AM, ogterran <[email protected]<javascript:>> 
> wrote: 
> > I am using webapp2 sessions and I want to override my default max_age 
> > settings (None) by using the max_age parameters in get_sessions() 
> > 
> > self.session_store = sessions.get_store(request=self.request) 
> > 
> > self.session_store.get_session(max_age=1000000, backend='datastore') 
> > 
> > The backend works here, as i see the session in the database, but 
> max_age is 
> > still None, as when i view the cookie in the browser, it expires when 
> the 
> > browsing session ends. 
> > 
> > How can i override the default max_age? 
> > 
> > 
> > Thanks 
> > 
> > Jon 
> > 
> > -- 
> > You received this message because you are subscribed to the Google 
> Groups 
> > "Google App Engine" group. 
> > To view this discussion on the web visit 
> > https://groups.google.com/d/msg/google-appengine/-/rdSeFu0wq4MJ. 
> > To post to this group, send email to 
> > [email protected]<javascript:>. 
>
> > To unsubscribe from this group, send email to 
> > [email protected] <javascript:>. 
> > For more options, visit this group at 
> > http://groups.google.com/group/google-appengine?hl=en. 
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google App Engine" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/google-appengine/-/wJ17Xn4mQhoJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-appengine?hl=en.

Reply via email to