#4656: Allow In-depth serialization by specifying depth to follow relationship
---------------------------------------------+------------------------------
          Reporter:  jay.m.mar...@gmail.com  |         Owner:  nobody 
            Status:  new                     |     Milestone:         
         Component:  Serialization           |       Version:         
        Resolution:                          |      Keywords:  feature
             Stage:  Design decision needed  |     Has_patch:  0      
        Needs_docs:  0                       |   Needs_tests:  0      
Needs_better_patch:  0                       |  
---------------------------------------------+------------------------------
Comment (by russellm):

 @orokusaki My opening comment was a light-hearted (hence the smiley)
 attempt to draw attention to the fact that your proposal is very LISPy,
 but not very Pythonic. Yes, tuples and lists are Python data structures -
 that doesn't mean that nesting them N deep is a good idea. Off the top of
 my head, the only place we use nested 2-tuples is in the choices list on
 forms (to provide optgroups) and in specifying arguments to template
 loaders - and in both of those cases, the nesting is limited to depth 2. I
 can't think of any examples of arbitrarily nested tuples in Django.

 The reason I mentioned the excludes/fields issue is that I'm not
 especially inclined to start applying piecemeal fixes to serialization
 when there is a much bigger problem lurking - that of customization. Any
 good solution for customizable serialization will necessitate the ability
 to have fine grained control over recursion, the fields that are to be
 included, and the format in which they will be displayed. What you've
 proposed will fix one small part of a larger problem, and may do so in a
 way that constrains our ability to implement a truly generic solution.

-- 
Ticket URL: <http://code.djangoproject.com/ticket/4656#comment:19>
Django <http://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To post to this group, send email to django-upda...@googlegroups.com.
To unsubscribe from this group, send email to 
django-updates+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-updates?hl=en.

Reply via email to