>
> I had been trying to recover by doing a DBSession.close at the end of each 
> request using 
>
>     config.add_subscriber(clearSession, NewRequest)
>    and where clearSession does DBSesison.close().
>

i believe you want to use add_finished_callback ( 
http://docs.pylonsproject.org/projects/pyramid/en/latest/api/request.html#pyramid.request.Request.add_finished_callback
 
)

it might also be better if you did something like :

    my_session = models.DBSession()
    my_session.query()
    my_session.add()
    my_session.commit()
    my_session.remove()


-- 
You received this message because you are subscribed to the Google Groups 
"pylons-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/pylons-discuss.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to