Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the CPAN-Meta CPAN distribution.

Report information
The Basics
Id: 70936
Status: resolved
Priority: 0/
Queue: CPAN-Meta

People
Owner: Nobody in particular
Requestors: ilmari [...] ilmari.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: fails with non-ASCII names on 5.8.6 and before
Date: Tue, 13 Sep 2011 19:55:54 +0200
To: bug-CPAN-Meta [...] rt.cpan.org
From: ilmari [...] ilmari.org (Dagfinn Ilmari Mannsåker)
Hi, On 5.8.6 and before, JSON::PP needs the ->utf8 option set to be able to decode non-ascii JSON strings reliably. Without the below patch, building multidimensional-0.008 fails when generating MYMETA due to my non-ASCII name. diff --git a/lib/CPAN/Meta/Converter.pm b/lib/CPAN/Meta/Converter.pm index 09b4ac8..f79c93e 100644 --- a/lib/CPAN/Meta/Converter.pm +++ b/lib/CPAN/Meta/Converter.pm @@ -37,8 +37,8 @@ sub _dclone { local *UNIVERSAL::TO_JSON = sub { return "$_[0]" }; my $backend = Parse::CPAN::Meta->json_backend(); - return $backend->new->decode( - $backend->new->allow_blessed->convert_blessed->encode($ref) + return $backend->new->utf8->decode( + $backend->new->utf8->allow_blessed->convert_blessed->encode($ref) ); } -- ilmari "A disappointingly low fraction of the human race is, at any given time, on fire." - Stig Sandbeck Mathisen
Thank you. Fixed in 2.112580 released to CPAN minutes ago.