Re: Proposal: runserver --with-fixture

2007-08-16 Thread Adrian Holovaty
On 8/13/07, Adrian Holovaty <[EMAIL PROTECTED]> wrote: > I'm proposing a "--with-fixture" flag to django-admin.py, so that you > could do something like this: > > django-admin.py runserver --with-fixture=mydata.json I've implemented this in http://code.djangoproject.com/changeset/5912 The do

Re: Proposal: runserver --with-fixture

2007-08-15 Thread ludvig.ericson
On Aug 14, 11:19 pm, "Adrian Holovaty" <[EMAIL PROTECTED]> wrote: > On 8/14/07, Russell Keith-Magee <[EMAIL PROTECTED]> wrote: > > > I would suggest that rather than trying to make the --with-fixture > > flag handle all this, it would be better to do this as a top level > > command, i.e.: > > > dj

Re: Proposal: runserver --with-fixture

2007-08-14 Thread Adrian Holovaty
On 8/14/07, Russell Keith-Magee <[EMAIL PROTECTED]> wrote: > I would suggest that rather than trying to make the --with-fixture > flag handle all this, it would be better to do this as a top level > command, i.e.: > > django-admin.py testserver mydata.json accounts.json categories.json > > This wo

Re: Proposal: runserver --with-fixture

2007-08-14 Thread Russell Keith-Magee
On 8/14/07, Adrian Holovaty <[EMAIL PROTECTED]> wrote: > > I'm proposing a "--with-fixture" flag to django-admin.py, so that you > could do something like this: > > django-admin.py runserver --with-fixture=mydata.json +1 to the general idea. However, this syntax (--with-fixture) doesn't real

Re: Proposal: runserver --with-fixture

2007-08-14 Thread Tai Lee
if re-serializing the data when closing the dev server, wouldn't it be easier to just leave it in the db and not trash/recreate the db all the time, and manually dump/load the serialized data when necessary? --~--~-~--~~~---~--~~ You received this message because

Re: Proposal: runserver --with-fixture

2007-08-13 Thread Malcolm Tredinnick
On Mon, 2007-08-13 at 21:28 -0700, Brian Harring wrote: > On Mon, Aug 13, 2007 at 04:31:42PM -0500, Adrian Holovaty wrote: > > So I was writing Django view unit tests and setting up fixtures with > > sample data, and it hit me -- wouldn't it be useful we made it easy to > > run the Django developm

Re: Proposal: runserver --with-fixture

2007-08-13 Thread Collin Grady
Brian Harring said the following: > 2) Adding functionality to automatically collect/serialize a stream of > interp. commands I think there might be some misunderstanding here - I believe he's saying to merely dump the fixture out again using the new database with changes - so if you start runse

Re: Proposal: runserver --with-fixture

2007-08-13 Thread Brian Harring
On Mon, Aug 13, 2007 at 04:31:42PM -0500, Adrian Holovaty wrote: > So I was writing Django view unit tests and setting up fixtures with > sample data, and it hit me -- wouldn't it be useful we made it easy to > run the Django development server with fixture data? > > I'm proposing a "--with-fixtur

Re: Proposal: runserver --with-fixture

2007-08-13 Thread Malcolm Tredinnick
On Mon, 2007-08-13 at 18:36 -0400, Todd O'Bryan wrote: > On Mon, 2007-08-13 at 16:31 -0500, Adrian Holovaty wrote: > > I'm proposing a "--with-fixture" flag to django-admin.py, so that you > > could do something like this: > > > > django-admin.py runserver --with-fixture=mydata.json > > > >

Re: Proposal: runserver --with-fixture

2007-08-13 Thread Todd O'Bryan
On Mon, 2007-08-13 at 16:31 -0500, Adrian Holovaty wrote: > I'm proposing a "--with-fixture" flag to django-admin.py, so that you > could do something like this: > > django-admin.py runserver --with-fixture=mydata.json > > With this command, Django would: > > * Delete the test database when

Re: Proposal: runserver --with-fixture

2007-08-13 Thread Jacob Kaplan-Moss
On 8/13/07, Adrian Holovaty <[EMAIL PROTECTED]> wrote: > > django-admin.py runserver --with-fixture=mydata.json > I think you're reading my mind -- I was thinking about this just the other day. It would really, really help... and the "writeback" idea (serializing the data back into a fixture

Proposal: runserver --with-fixture

2007-08-13 Thread Adrian Holovaty
So I was writing Django view unit tests and setting up fixtures with sample data, and it hit me -- wouldn't it be useful we made it easy to run the Django development server with fixture data? I'm proposing a "--with-fixture" flag to django-admin.py, so that you could do something like this: