On Dec 5, 2007 12:25 PM, DeliciousPy <[EMAIL PROTECTED]> wrote: > As for Marty's response... > >However, I haven't looked at what it > > would take to actually commit changes to the already-synced tables. I > > have a feeling Django Evolution[2] will help with this, but I haven't > > done any testing with it yet. > > Yeah, I've seen the DynamicModels writeup, but there is that issue of > syncing modifications to models. Evolution might help, but as far as I > can tell that will look at the models.py file, not database entries, > so that brings me back to my original question of whether I should > build some kind of script/app to edit models.py files.
A cursory look at the django-evolution source reveals what I expected: it looks at the in-memory model class. Ordinarily, this will be created by writing a model in models.py directly, but it's quite possible to use database-backed model definitions and have them show up in an app's 'models' module. Django evolution would then have no way of knowing whether the model was written out by hand, or generated dynamically. I admit, I haven't done a thorough test of storing model definitions in a database, but it really should work, and without having to automatically build/edit your models.py file. Now that Django Evolution is gaining traction, I may set up a separate Google Code project just to create an app for managing dynamic models. I don't know yet though, and I certainly wouldn't have it done in the next few days or anything, so if you have more urgent need, feel free to continue with it on your own. I'd be happy to answer any questions you have about the process, to the best of my ability. -Gul --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---

