Re: Strange behavior using ModelForms

2012-12-18 Thread Karen Tracey
On Tue, Dec 18, 2012 at 4:11 PM, Francisco Vianna < francisco.v.via...@gmail.com> wrote: > After some debugging, I realized they become the same after calling > "is_valid" to the bound form. Now, I'm not sure if I am missing something > conceptually about ModelForms binding. > Its very ackward to

Re: Strange behavior using ModelForms

2012-12-18 Thread Chris Cogdon
The binding allows the modelform to read the current values of an instance, and also to write them back to the same instance when the values are changed. If you're only ever creating new instances, then you don't need to bind it. On Tuesday, December 18, 2012 6:19:45 PM UTC-8, fvianna wrote: >

Re: Strange behavior using ModelForms

2012-12-18 Thread Francisco Vianna
Because unless I'm getting some real debbuging issues, request.user is also changed during the process. It happens as if all references were pointing to the same object, when i believe thet, as far as I understand these Django machanisms and functionalities, this should not happen. The basic issu

Re: Strange behavior using ModelForms

2012-12-18 Thread Chris Cogdon
Rather than comparing to instance, why not compare to request.user ? On Tuesday, December 18, 2012 1:11:21 PM UTC-8, fvianna wrote: > > Hello everyone, > > I want to apologize if I came to the wrong place to talk about this, but > I've been using Django for a while now, and crossed to a very stra

Strange behavior using ModelForms

2012-12-18 Thread Francisco Vianna
Hello everyone, I want to apologize if I came to the wrong place to talk about this, but I've been using Django for a while now, and crossed to a very strange behavior that hits me as bug, but I'm not quite sure. First time trying to get a little deeper and maybe report something to help the co