Re: [GSOC 2012] Customizable serialization

2012-04-03 Thread Piotr Grabowski
W dniu 03.04.2012 15:55, Tom Christie pisze: It breaks the problem down into two very well defined tasks. 1. Convert native datatypes to/from data streams. (eg. Tastypie's serializers , REST framework's

Re: [GSOC 2012] Customizable serialization

2012-04-03 Thread Tom Christie
Grabowski wrote: > > It's my second approach to customizable serialization. I did some > research, find some REST serializers. I focus more on deserialization - > it should be easy to provide data is round-trippable. I discard some > unnecessary fields and try to improve func

Re: [GSOC 2012] Customizable serialization

2012-04-02 Thread schinckel
I am quite interested in this, as most of my coding work has been developing APIs that get consumed by non-web-browser software. Lately, I've taken the approach that a Form is the appropriate tool to use for (de)serialisation: it's already used extensively by the template rendering (which is

Re: [GSOC 2012] Customizable serialization

2012-04-02 Thread Piotr Grabowski
It's my second approach to customizable serialization. I did some research, find some REST serializers. I focus more on deserialization - it should be easy to provide data is round-trippable. I discard some unnecessary fields and try to improve functionality. GSOC 2012 Customizable

Re: [GSOC 2012] Customizable serialization

2012-03-20 Thread Alex Ogier
>    One of my principle was to let user define any possible structure. > Ex > > > > > Django > > > > > > 1. With Meta.structure you can do: > def name >    return Django > structure="a[b[c[name__field]]] > > 2. Without: > def a >    return BFieldSerializer > class BFieldSerializer >    

Re: [GSOC 2012] Customizable serialization

2012-03-20 Thread Piotr Grabowski
W dniu 20.03.2012 22:00, Łukasz Rekucki pisze: 1) The Meta.structure things looks like a non-starter to me. It's a DSL inside a DSL. I'm also not sure what it actually does - you already have all those @attribute decorators, why repeat their names in some string? One of my principle

Re: [GSOC 2012] Customizable serialization

2012-03-20 Thread Alex Ogier
Actually, thinking about it a bit more, it seems fk_level is bound to be a significant source of untested edge-case behavior. Every time the limit is reached, there will be an unexpectedly flat relationship that a naive recursive deserializer may choke on. I would be +1 on a fail-fast version of

Re: [GSOC 2012] Customizable serialization

2012-03-20 Thread Alex Ogier
I like the project and am +1 on Łukasz's points #1 and #3. Meta.fk_level looks very useful though. For example if models have parent/sibling relationships or otherwise relate to themselves and you can't guarantee the relationships are acyclic. Definitely a worthy project. -Alex Ogier -- You

Re: [GSOC 2012] Customizable serialization

2012-03-20 Thread Łukasz Rekucki
On 20 March 2012 17:50, Piotr Grabowski wrote: > Hi, > > My name is Piotr Grabowski. I'm last year student at the Institute of > Computer Science University of Wrocław (Poland). I want to share with you > draft of my GSOC proposal. Hi, nice to meet you :) > >

[GSOC 2012] Customizable serialization

2012-03-20 Thread Piotr Grabowski
Hi, My name is Piotr Grabowski. I'm last year student at the Institute of Computer Science University of Wrocław (Poland). I want to share with you draft of my GSOC proposal. http://pastebin.com/ePRUj5HC PS. Sorry for my poor english :/ -- Piotr Grabowski -- You received this message