Re: Namspace packages in Django

2011-01-04 Thread Russell Keith-Magee
On Wed, Jan 5, 2011 at 4:15 AM, Nils Fredrik Gjerull wrote: > Hi, Django folks! > > This is my first time posting on the Django developer list. Thanks for > an amazing framework. > > The Distribute build system supports namespaced packages > (http://packages.python.org/distribute/setuptools.html#n

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Yo-Yo Ma
On Jan 4, 4:43 pm, Jacob Kaplan-Moss wrote: > On Tue, Jan 4, 2011 at 3:37 PM, Yo-Yo Ma wrote: > > What's with all the hostility here? I've heard about this from others. > > Let's just stop this, right now. There's no hostility in Marty's tone > -- if you're reading that, then take the night off a

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Jacob Kaplan-Moss
On Tue, Jan 4, 2011 at 3:37 PM, Yo-Yo Ma wrote: > What's with all the hostility here? I've heard about this from others. Let's just stop this, right now. There's no hostility in Marty's tone -- if you're reading that, then take the night off and come back to django-dev tomorrow. This discussion

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Yo-Yo Ma
Waylan: > Therefore, don't use Person.objects.create() Marty: > Developer mistakes can ruin your data. Full stop. > Unfortunately, this is one of the many issues where "X doesn't work > the way I think it should" gets confused with "X doesn't work the way > it should" or even "X doesn't work.

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Marty Alchin
On Tue, Jan 4, 2011 at 3:10 PM, Yo-Yo Ma wrote: > Simple question (A or B): Would you rather A) have a > SomeDjangoException come up where you don't expect it and a visitor > see a 500 page, or B) have your data ruined by a developer mistake? Developer mistakes can ruin your data. Full stop. Tha

Re: Paginating ListViews in CBV

2011-01-04 Thread Jacob Kaplan-Moss
On Tue, Jan 4, 2011 at 9:37 AM, Andrew Godwin wrote: > So, I've been working with the new generic Class Based Views for the > last few days, and come across a slight inconsistency in the ListView. > > If you specify a value for paginate_by, ListView happily returns a > "page" object into the conte

Namspace packages in Django

2011-01-04 Thread Nils Fredrik Gjerull
Hi, Django folks! This is my first time posting on the Django developer list. Thanks for an amazing framework. The Distribute build system supports namespaced packages (http://packages.python.org/distribute/setuptools.html#namespace-packages). I have found namespaced packages to be of great help

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Yo-Yo Ma
>> ...*before* writing to the db. Therefore, don't use >> Person.objects.create() >> ...it does strike me as being a little odd that there is no way to validate >> your data... Let me get this straight: I just shouldn't "use Person.objects.create()", if I ever want to to take advantage

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Waylan Limberg
On Tue, Jan 4, 2011 at 10:54 AM, Yo-Yo Ma wrote: [snip] > The difference in Django is that instantiation doesn't represent > "creation". Saving to the database does, and since the ORM is an > abstraction of the database, you don't care that the DB is ok with an > empty VARCHAR value. You only care

Re: Why 14202 is not in trunk?

2011-01-04 Thread James Bennett
On Tue, Jan 4, 2011 at 8:52 AM, Alexander Pugachev wrote: > Why http://code.djangoproject.com/ticket/14202 is not in trunk being accepted? Short answer: because "accepted" doesn't mean "closed, fixed". Longer answer: up until the beta release, just before Christmas, quite a bit of development ti

Why 14202 is not in trunk?

2011-01-04 Thread Alexander Pugachev
Hi. Why http://code.djangoproject.com/ticket/14202 is not in trunk being accepted? -- You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-develop...@googlegroups.com. To unsubscribe from this group, sen

Paginating ListViews in CBV

2011-01-04 Thread Andrew Godwin
So, I've been working with the new generic Class Based Views for the last few days, and come across a slight inconsistency in the ListView. If you specify a value for paginate_by, ListView happily returns a "page" object into the context. However, if there is only one page, it decides against this

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Yo-Yo Ma
> duplicate key, etc." [1] Since the creation of a model instance > doesn't affect the database, it should definitely not raise an This isn't correct. Model instantiation doesn't affect the database. Model creation (ie, the use of ``Model.create()`` does. I'm not arguing that instantiation should

Re: Problem with ``Model.objects.create``

2011-01-04 Thread Stephen Burrows
Just to clarify, an IntegrityError is raised if "the relational integrity of the database is affected, e.g. a foreign key check fails, duplicate key, etc." [1] Since the creation of a model instance doesn't affect the database, it should definitely not raise an IntegrityError. Additionally, blank=T

Re: AttributeError: module 'object' has no attribute events

2011-01-04 Thread Wesley Chun
+1 that this is not the correct list for you. before you go elsewhere, below are similar errors that i'm not sure if this is related to your situation, but it may help: http://www.google.com/search?q=appengine+OR+"app+engine"+"AttributeError:+'module'+object+has+no+attribute" http://code.google.c