Message194700
> this doesn't work if you use the wrong quote. without introspecting the data in e you can't reliably choose whether to use "'%s'" '"%s"' '"""%s"""' or "'''%s'''".
Indeed.
> and again tools other than python will run into escaped quotes in the data which may cause problems.
Then use s.translate() or re.sub() for encoding.
> when i execute this i get a traceback
Sorry, it should be
e.encode('latin1', 'backslashreplace').decode('unicode-escape'). |
|
Date |
User |
Action |
Args |
2013-08-08 17:31:07 | serhiy.storchaka | set | recipients:
+ serhiy.storchaka, r.david.murray, underrun |
2013-08-08 17:31:07 | serhiy.storchaka | set | messageid: <1375983067.05.0.514891322657.issue18679@psf.upfronthosting.co.za> |
2013-08-08 17:31:07 | serhiy.storchaka | link | issue18679 messages |
2013-08-08 17:31:06 | serhiy.storchaka | create | |
|