Remove uncide notation
Chris Rebert
clp2 at rebertia.com
Thu Oct 18 05:40:06 EDT 2012
On Thu, Oct 18, 2012 at 2:27 AM, Ashish Jain <ashishjain.ash at gmail.com> wrote:
> Hi,
>
> I have a html string in an object, when I do repr() of that object, I get value as:
>
> {'Id' : 1, 'Body': u'<p> Hello </p>'}
>
> I don't wish to have 'u' as the character in my string representation. As this is not a valid json notation now.
If you want JSON, then *use the freakin' `json` std lib module*!
http://docs.python.org/library/json.html
repr(...) != JSON
[It's similar only coincidentally, and only to a degree.]
Regards,
Chris
More information about the Python-list
mailing list