Rt 4.0.8 and unknown charsets

Hi,

rt 4.0.8 installation and rt-mailgate script quite often cannot deliver
message to rt because:

[pid 8672] write(2, “RT server error.\n\nThe RT server which handled your
email did not behave as expected. It\nsaid:\n\nUnknown encoding ‘iso-8859-8-i’
at /usr/share/perl5/vendor_perl/RT/I18N.pm line 542\n\nStack:\n
[/usr/share/perl5/5.12.4/Carp.pm:62]\n
[/usr/lib/perl5/vendor_perl/5.12.0/i686-pld-linux-thread-
multi/Encode.pm:189]\n [/usr/share/perl5/vendor_perl/RT/I18N.pm:542]\n
[/usr/share/perl5/vendor_perl/RT/I18N.pm:214]\n
[/usr/share/perl5/vendor_perl/RT/I18N.pm:210]\n
[/usr/share/perl5/vendor_perl/RT/EmailParser.pm:282]\n
[/usr/share/perl5/vendor_perl/RT/Interface/Email.pm:1433]\n
[/usr/share/rt/html/REST/1.0/NoAuth/mail-gateway:61]\n\n”, 621) = 621

iso-8859-8-i is actually valid encoding
(ISO-8859-8-I - Wikipedia)

The question is - can rt be configured/changed that way it treats unknown
charsets as ascii or utf8? I really prefer to have borked charset than to
loose message.

Arkadiusz Miśkiewicz, arekm / maven.pl

iso-8859-8-i is actually valid encoding
(ISO-8859-8-I - Wikipedia)

Try putting this in your RT_SiteConfig.pm:

use Encode;
use Encode::Alias;
define_alias("iso-8859-8-i" => "iso-8859-8");

and then restarting RT.

The wikipedia page for ISO-8859-8 sheds some light on the difference:

Nominally ISO-8859-8 is for “visual order”, and ISO-8859-8-I is for
logical order. But usually in practice, and required for HTML and
XML documents, ISO-8859-8 also stands for logical order text.
    http://en.wikipedia.org/wiki/ISO/IEC_8859-8

iso-8859-8-i is actually valid encoding
(ISO-8859-8-I - Wikipedia)

Try putting this in your RT_SiteConfig.pm:

use Encode;
use Encode::Alias;
define_alias("iso-8859-8-i" => "iso-8859-8");

and then restarting RT.

That worked for this case, thanks!

Now I’m interested in more generic solution, so I won’t have to play manually
with every (random) charset someone is putting :slight_smile:

Arkadiusz Miśkiewicz, arekm / maven.pl

iso-8859-8-i is actually valid encoding
(ISO-8859-8-I - Wikipedia)

Try putting this in your RT_SiteConfig.pm:

use Encode;
use Encode::Alias;
define_alias("iso-8859-8-i" => "iso-8859-8");

and then restarting RT.

That worked for this case, thanks!

Now I’m interested in more generic solution, so I won’t have to play manually
with every (random) charset someone is putting :slight_smile:

There have been a few patches around this and at least one unmerged
branch that touches our internationalization code.

It should continue to get better in future releases.

-kevin