I remember a bug of this nature in the SQLite vCard backend being
discussed a long time ago. Something to do with how the SQLite module
handles UTF-8.
I thought it'd been fixed, but I can't find anything in the (pretty
short) revision history for the vCard plugin. Maybe there's a patch
somewhere in the archive of this mailing list that didn't get committed?
Brad Fitzpatrick wrote:
Michail,
Let me copy some people that might help:
djabberd list, is this bug known/old and maybe already fixed?
Henry, can you open an internal LiveJournal bug for this, or route
appropriately, perhaps to the LJ Russia team?
On Mon, Dec 15, 2008 at 7:53 AM, Michail Pishchagin
<mbl...@yandex-team.ru <mailto:mbl...@yandex-team.ru>> wrote:
Hi Brad,
I'm not sure whether I should send this to you, or to LiveJournal
support, hopefully you could help me on that :-)
The bug I'm noticing is that when I ask for a vCard, string data is
returned as UTF-8-incoded-in-latin1.
Example:
<GIVEN>Ибупрофен Коллайдерыч Ð¢ÐµÑ Ñ
ерактов-ÐšÑ€Ð¸Ð·Ð¸Ð½Ñ </GIVEN>
But the proper result should've been:
<GIVEN>Ибупрофен Коллайдерыч Тессерактов-Кризинс</GIVEN>
It's fairly easy to check whether that data is valid UTF8, and
encode the data appropriately in such case.
The bug's been around for a long time, and since it's still not
fixed I'd like to know whether there are some serious technical
reasons for it staying the way it was?
Thanks!
Full XML log for reference:
<iq type="get" to="cyber_ly...@livejournal.com
<mailto:cyber_ly...@livejournal.com>" id="ab02a" >
<vCard xmlns="vcard-temp" version="2.0" prodid="-//HandGen//NONSGML
vGen v1.0//EN" />
</iq>
<iq from="cyber_ly...@livejournal.com
<mailto:cyber_ly...@livejournal.com>" type="result"
to="thembl...@ya.ru/siruba <http://thembl...@ya.ru/siruba>"
id="ab02a" lang="ru" >
<vCard xmlns="vcard-temp">
<NICKNAME>cyber_lyric</NICKNAME>
<N>
<GIVEN>Ибупрофен Коллайдерыч Ð¢ÐµÑ Ñ
ерактов-ÐšÑ€Ð¸Ð·Ð¸Ð½Ñ </GIVEN>
</N>
<URL>http://cyber-lyric.livejournal.com/</URL>
<ADR>
<CTRY>AU</CTRY>
<LOCALITY>Nowhere</LOCALITY>
</ADR>
<PHOTO>
<TYPE>image/jpeg</TYPE>
<BINVAL>SNIP</BINVAL>
</PHOTO>
</vCard>
</iq>
--
Michail Pishchagin
Yandex development team.