Info on using "bare" json module in "Serializing Django Objects"
|Reported by:||JonathanHayward||Owned by:||nobody|
|Has patch:||no||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
Description (last modified by gabrielhurley)
http://docs.djangoproject.com/en/dev/topics/serialization/ covers how to serialize certain data, namely QuerySets and other model-based data, but it does not appear to contain or cross-reference how one would use the "bare" json module and json.dumps (not serializers.get_serializer('json')()-created objects) to serialize a basic concoction of one or more strings, numbers, hashes, and lists.
In terms of "information scent", the page is a natural search result for django serialization which people could find if they are looking how to serialize JSON-like data for Ajax use. Ideally that page should cross-reference, or possibly contain, how to do basic serialization to JSON for constructions from strings/numbers/hashes/lists, particularly as what you get from serializers.get_serializer('json')() has an allergic response to being asked to serialize non-iterable data.
Change History (3)
comment:1 Changed 5 years ago by gabrielhurley
- Description modified (diff)
- Needs documentation unset
- Needs tests unset
- Patch needs improvement unset
- Summary changed from [Enhancement] Cross-reference to "bare" json module suggested for "Serializing Django Objects" to Info on using "bare" json module in "Serializing Django Objects"
- Triage Stage changed from Unreviewed to Accepted
comment:2 Changed 4 years ago by ramiro
- Resolution set to invalid
- Status changed from new to closed