Re: Tightening assignment to ForeignKeys (was: Little help with #6886)

2008-05-31 Thread Russell Keith-Magee
On Sun, Jun 1, 2008 at 3:23 AM, Jacob Kaplan-Moss <[EMAIL PROTECTED]> wrote: > > On Sat, May 31, 2008 at 10:00 AM, Jacob Kaplan-Moss > <[EMAIL PROTECTED]> wrote: >> So, a proposal: I'd like to change FK assignment to be "special" like >> you suggested. I'd like to: >> >> * Raise a ``ValueError`` i

Aggregation Updates

2008-05-31 Thread Nicolas E. Lara G.
Hello, Today I've commited what could be called the first working version of aggregate support. For those of you not keeping track of the project, it can be found at: http://code.google.com/p/django-aggregation/ Some words on the status of the project. Working * Currently both ann

broken pipe issue with runserver #4444

2008-05-31 Thread Ido Sebastiaan van Oostveen
Hi guys, While writing a little patch to get rid of the (annoyingly loud) 'broken pipe' exception/traceback; i found that there actually a ticket for it # which is marked won't fix. I would like to throw in two options for making this error a little less noisy. (As this error is 'common brow

Re: Tightening assignment to ForeignKeys (was: Little help with #6886)

2008-05-31 Thread [EMAIL PROTECTED]
It looks fine by me(though I didn't look at the tests), one style issue(line 231), no sense checking if something == False, just do `not self.field.null`. On May 31, 2:23 pm, "Jacob Kaplan-Moss" <[EMAIL PROTECTED]> wrote: > On Sat, May 31, 2008 at 10:00 AM, Jacob Kaplan-Moss > > <[EMAIL PROTECTED

Tightening assignment to ForeignKeys (was: Little help with #6886)

2008-05-31 Thread Jacob Kaplan-Moss
On Sat, May 31, 2008 at 10:00 AM, Jacob Kaplan-Moss <[EMAIL PROTECTED]> wrote: > So, a proposal: I'd like to change FK assignment to be "special" like > you suggested. I'd like to: > > * Raise a ``ValueError`` if you try to assign an object of the wrong > type to a FK. > * Raise a ``ValueError`` i

The Model.default_manager concept

2008-05-31 Thread Johannes Dollinger
I'd like to propose a change of the Model.defaul_manager concept. My first concern was the inability to control the default_manager when subclassing a Model that already provides a default_manager (the base class' manager will be added before the subclass' manager). This could be solved by

Re: Little help with #6886 ("Assigning a Model Instance to a Foreign Key Attribute Doesn't Cache the Instance")

2008-05-31 Thread Jacob Kaplan-Moss
> SVN knows all: http://code.djangoproject.com/changeset/2598 D'oh, your SVN-fu is greater than mine, apparently. > The edge case to look at is assigning None to the a foreign key where > null=False. Ah, there it is. There's nothing in the test suite that relies on that ``DoesNotExist`` excepti

Re: Runtime initialisation of db_table from context

2008-05-31 Thread ChrisStoyles
Hi Ludvig, I'm afraid I don't understand what you are saying here? Django's ORM is probably a bit too new to me still, would you mind explaining what you're saying in a little more depth? Cheers, Chris Ludvig Ericson wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > - -BEGIN PGP

Re: simplified FormWizard and sprint at EuroPython

2008-05-31 Thread Mikael Moutakis
sorry, that was an bad example. It should have been: #forms.py #Form01, and Form01 are ordinary forms class MyFormWizard(FormWizard): """Subclass of the new, simplified FormWizard""" forms=[Form01,Form02] #views.py def event_registration(request,event_id): """A simple view for signi