Subject: | Issued with Email::Address->parse() in 1.880 and 1.861 |
(sent this in email to rjbs@cpan.org but realized I should put it here too)
Hey there, was doing some work with Email::Address at Socialtext, and
discovered some weirdness you might want to be aware of. I'm sorry to
report I don't have a fix, but I do have a short script the demonstrates
the problem.
I hope this is helpful in some way.
Here's part of the message I sent to the rest of the Socialtext gang:
-=-=-=-=-=-
I stumbled upon this when merging trunk to the api branch.
EmailReceiver.pm now uses Email::Address. Deps.yaml recommend 1.861,
1.880 is the latest on CPAN. Each version performs differently with
econded utf8 categories in email addresses depending on the
Email::Address version _and_ the version of Perl. I've tested with:
v5.8.7 built for i486-linux-gnu-thread-multi
v5.8.7 built for x86_64-linux-gnu-thread-multi
v5.8.8 built for darwin-2level
A straightforward address does just fine with any version of
Email::Address and Perl when calling Email::Address->parse(),
but an address of the form
admin+=E6=96=B0=E5=8A=A0=E5=9D=A1_Weblog@test.socialtext.com
gets things a bit wackidocious, but with different versions.
gdb suggests we're stuck in the regular expression engine (which is not
all that surprising given the expression being used).
1.861 1.880
5.8.7 i486 works never returns
5.8.7 x86_64 empty result never returns
5.8.8 darwin untested never returns
I'll send this to rjbs as well.
My demo script:
-=-=-
#use lib './lib';
use Email::Address;
use YAML;
my @address2 = Email::Address->parse('cdent@burningchome.com');
warn Dump(@address2);
my @address1 =
Email::Address->parse('admin+=E6=96=B0=E5=8A=A0=E5=9D=A1_Weblog@test.socialt
ext.com');
warn Dump(@address1);
-=-=-