Thanks Piotr, It's been interesting and helpful watching your progress on this project. I wouldn't worry too much about not quite meeting all the goals you'd hoped for - it's a deceptively difficult task. In particular it's really difficult trying to maintain full backwards comparability with the existing fixture serialization implementation, whilst also totally redesigning the API to support the requirements of a more flexible serialization system. Like you say, I think the overall direction of your project is right, and personally I've found it useful for my own work watching how you've tackled various parts of it.
All the best, Tom On Thursday, 23 August 2012 01:14:26 UTC+1, Piotr Grabowski wrote: > > Hi, > > Google Sumer of Code is almost ended. I was working on customizable > serialization. This project was a lot harder than I expected, and sadly > in my opinion I failed to do it right. I want to apologize for that and > especially for my poor communication with this group and my mentor. I > want to improve it after midterm evaluation but it was only worse. > > I don't think my project is all wrong but there is a lot things that are > different from how I planned. How it looks like (I wrote more in > documentation) > There is Serializer class that is made of two classes: NativeSerializer > and FormatSerializer. > NativeSerializer is for serialization and deserialization python objects > from/to native python datatypes > FormatSerializer is for serialization and deserialization python native > datatypes to/from some format (xml, json, yaml) > > I want NativeSerializer to be fully independent from FormatSerializer > (and vice versa) but this isn't possible. Either NativeSerializer must > return some additional data or FormatSerializer must give > NativeSerializer some context. For exemple in xml all python native > datatypes must be serialized to string before serializing to xml. Some > custom model fields can have more sophisticated way to serialize to > sting than unicode() so `field.value_to_string` must be called and > `field` are only accessible in NativeSerializer object. So either > NativeSerializer will return also `field` or FormatSerializer will > inform NativeSerializer that it handles only text data. > > Backward compatible dumpdata is almost working. Only few tests are not > passed, but I am not sure why. > > Nested serialization of fk and m2m related fields which was main > functionality of this project is working but not well tested. There are > some issues especially with xml. I must write new xml format because old > wont work with nested serialization. > > I didn't do any performance tests. Running full test suite take 40 > seconds more with my serialization (about 1500s at all) if I remember > correctly. > > I will try to complete this project so it will be at least bug free and > usable. If someone was interested in using nested serialization there is > other great project: https://github.com/tomchristie/django-serializers > > Code: https://github.com/grapo/django/tree/soc2012-serialization > Documentation: https://gist.github.com/3085250 > > -- > Piotr Grabowski > -- You received this message because you are subscribed to the Google Groups "Django developers" group. To view this discussion on the web visit https://groups.google.com/d/msg/django-developers/-/a2gBdTn5C6EJ. To post to this group, send email to django-developers@googlegroups.com. To unsubscribe from this group, send email to django-developers+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/django-developers?hl=en.