#2373: @expose('json') won't return lists
----------------------------+-----------------------------------------------
 Reporter:  seedifferently  |       Owner:       
     Type:  defect          |      Status:  new  
 Priority:  normal          |   Milestone:  2.1a1
Component:  TurboGears      |     Version:  2.0.1
 Severity:  normal          |    Keywords:       
----------------------------+-----------------------------------------------
 When you return a list in a method that is @expose('json'), you instead
 get a concatenated string.

 Take this method for example:

 {{{
     @expose('json')
     def list_test(self):
         l = []
         l.append({'one': 1})
         l.append({'two': 2})
         l.append({'three': 3})

         return l
 }}}

 I believe this should return:


 {{{
 [{"one": 1}, {"two": 2}, {"three": 3}]
 }}}

 but instead it returns:

 {{{
 {'one': 1}{'two': 2}{'three': 3}
 }}}

-- 
Ticket URL: <http://trac.turbogears.org/ticket/2373>
TurboGears <http://www.turbogears.org/>
TurboGears front-to-back web development

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "TurboGears Tickets" group.
This group is read-only. No posting by normal members allowed.
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/turbogears-tickets?hl=en?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to