Re: loaddata and foreignKey: manage.py silently failing

2007-05-14 Thread Sandro Dentella
> Yes, this seems to be the problem. The serializer doesn't currently > handle to_field as a special case. I'll work on a fix. > > However, there is another way to solve you problem. Are you sure that > you want Nation.code to be unique=True, and not primary_key=True? If > you set primary_key=Tru

Re: loaddata and foreignKey: manage.py silently failing

2007-05-14 Thread Russell Keith-Magee
On 5/14/07, Russell Keith-Magee <[EMAIL PROTECTED]> wrote: > On 5/14/07, sandro dentella <[EMAIL PROTECTED]> wrote: > > > > I produced the example (2 field, 2 models, 2 records!) > > I opened ticket http://code.djangoproject.com/ticket/4288 > > but now I cannot add files due to InternalError of t

Re: loaddata and foreignKey: manage.py silently failing

2007-05-14 Thread Russell Keith-Magee
On 5/14/07, sandro dentella <[EMAIL PROTECTED]> wrote: > > I produced the example (2 field, 2 models, 2 records!) > I opened ticket http://code.djangoproject.com/ticket/4288 > but now I cannot add files due to InternalError of the trac system! > So I put it here: http://www.e-den.it/misc/fixture_

Re: loaddata and foreignKey: manage.py silently failing

2007-05-13 Thread sandro dentella
I produced the example (2 field, 2 models, 2 records!) I opened ticket http://code.djangoproject.com/ticket/4288 but now I cannot add files due to InternalError of the trac system! So I put it here: http://www.e-den.it/misc/fixture_failing.tgz Anyhow my understanding is that is all due to the Fo

Re: loaddata and foreignKey: manage.py silently failing

2007-05-12 Thread Sandro Dentella
> Interesting. The "installed n fixtures" message is printed before the > transaction is commited, which might be causing the confusion, but if > the commit isn't succeeding, you should be seeing other errors (i.e., > db failures). Is it possible that stderr is getting redirected > somewhere other

Re: loaddata and foreignKey: manage.py silently failing

2007-05-12 Thread Russell Keith-Magee
On 5/10/07, sandro dentella <[EMAIL PROTECTED]> wrote: > > hi, > > I'm trying to play with initial_data fixture. I dumpdata (json > format) > and reload it cleanly if there are no foreign key contraints on the > table. > If the tables i'm dumping have foreign keys (in my case holydays/ > nat

loaddata and foreignKey: manage.py silently failing

2007-05-10 Thread sandro dentella
hi, I'm trying to play with initial_data fixture. I dumpdata (json format) and reload it cleanly if there are no foreign key contraints on the table. If the tables i'm dumping have foreign keys (in my case holydays/ nation bith in the same fixture), I get an error from the db that abort