GNOME Bugzilla – Bug 243998
Problems importing vcards in other than iso-8859-1 encoding.
Last modified: 2021-05-19 11:57:36 UTC
VCards encoded in encoding other than iso-8859-1 won't import properly: 1) If I try to import vCard 3.0 (as described in RFC2425), it always assumes it is in iso-8859-1. The same happens even if I send the vCard in a mail message with correctly specified encoding in MIME headers. => I suggest, when importing vCard v3.0 (i.e. without the "CHARSET=" properties), to honour the encoding as specified in the MIME-headers, or when not possible (importing from a file) use the default encoding for current locale or ask user. 2) If I add "CHARSET=" properties to the vCard (as specified in the vCard 2.1 specs), the vCard is imported several times with various combinations of fields being encoded in either encoding specified by the "CHARSET=" or iso-8859-1. => I suggest, that if a vCard contains any "CHARSET=" properies, it should be imported _only once_ honouring the specified charset.
I can confirm these problems for importing from both kaddressbook and gnome-pim. Suggested solution (use current locale encoding) is not sufficient, because for example kaddressbook VCard uses UTF-8 also in ISO-8859-2 locales. The best solution for import from file is "ask user". In case of import all settings, program can guess (gnome-pim - locale-specific, kaddressbook-3 - UTF-8).
as discussed on irc marking this as a part of bug 240756 which is about support of vcard 3.0. *** This bug has been marked as a duplicate of 240756 ***
this bug should be a dep of 40756, not a duplicate.
removing old target milestone
Isn't this obsolete? My impression was that when CHARSET is missing it is considered UTF-8. Also see bug 560681.
As report and comment #1 say, such simple assumption does not work: Import RFC2425 vCard 3.0: CHARSET is missing => needs ISO-8859-1. Import from gnome-pim: CHARSET is missing => needs locale-specific value, e. g. ISO-8859-2. Import from kaddressbook-3: CHARSET is missing => needs UTF-8.
comment #5 : Yes, see RFC2445, sec. 4.1.4. See also bug 557341.
Anybody having a testcase that could be attached here (without confidential data included)?
Created attachment 206095 [details] GnomeCard.gcrd Vcard file, as it was created by GnomeCard. (Who remembers it?) No information about encoding was provided.
Created attachment 206096 [details] linka3.vnt Example of Vnote file with a very obscure encoding. The text charset is UTF-7, the result was then encoded by quoted-printable encoding. (I know, that Evolution does not support Vnote format yet, but you can use it as a cut/paste source for, say, address.) This example was generated by the SE T630 mobile phone.
(In reply to comment #9) > Created an attachment (id=206095) [details] > GnomeCard.gcrd Even gedit fails, considering it ISO-8859-15: It displays zkou¹ka instead of zkouška. :-/
No, gedit does not fail. This file does not contain any charset hint. GnomeCard used Vcard file that always used charset equal to the locale charset. There is no way to discriminate between ISO-8859-1 and ISO-8859-2. If you add ISO-8859-2 to and remove ISO-8859-1 from gedit list of charsets, it will open it properly. Was to import such file: - Ask user. - Use contents based heuristics (e. g. ENCA) for initial guess. (But still needs to ask user - names are not easy to identify.)
GNOME is going to shut down bugzilla.gnome.org in favor of gitlab.gnome.org. As part of that, we are mass-closing older open tickets in bugzilla.gnome.org which have not seen updates for a longer time (resources are unfortunately quite limited so not every ticket can get handled). If you can still reproduce the situation described in this ticket in a recent and supported software version, then please follow https://wiki.gnome.org/Community/GettingInTouch/BugReportingGuidelines and create a new bug report ticket at https://gitlab.gnome.org/GNOME/evolution/-/issues/ Thank you for your understanding and your help.