Re: SimpleLazyObject for request.user not correctly evaluated inside RequestContext

2013-09-12 Thread giovanni allegri
Hi German, thanks for the reply. I apologize for the delay, but I didn't receive the notification :( I've definetly improved the form workflow defining a validator inside my form. My validator check avoids the IntegrityError from Postgres. Anyway, in case such an error happens, how should one ma

Re: SimpleLazyObject for request.user not correctly evaluated inside RequestContext

2013-09-06 Thread Germán
What DB engine are you using? If it is PostgreSQL, you need to roll back the transaction after a database error exception (e.g. IntegrityError). By the way, I think what you are doing is wrong. If the form data is invalid, then you need to call . form_invalid On Friday, September 6, 2013 11

SimpleLazyObject for request.user not correctly evaluated inside RequestContext

2013-09-06 Thread giovanni allegri
I've opened a new thread, which relates to a previous onefrom me. Digging into a wired behaviour in a FormView I've arrived to the following problem: - In my "form_valid" method I need to manage exceptions situations. - In case