[Catalyst] Wide (Unicode) character problem?

John M. Dlugosz wxju46gefd at snkmail.com
Wed Mar 23 14:49:06 GMT 2011

On 3/23/2011 8:58 AM, Bill Moseley moseley-at-hank.org |Catalyst/Allow to home| wrote:
> Post the smallest possible example (<20 lines?) that clearly shows the
> problem.
OK, I verified that it still chokes if I strip it down to the bare essentials.
If the view produces a stream that includes a wide character, I get the exception.

Here is my Controller:
package LEDft::Controller::Root;
use Moose;
use namespace::autoclean;
use Mail::Builder::Simple;

use Try::Tiny;

BEGIN { extends 'Catalyst::Controller::HTML::FormFu' }

# Sets the actions in this controller to be registered with no prefix
# so they function identically to actions created in MyApp.pm
__PACKAGE__->config(namespace => '');

my %Data= (
         priceline => "10\x{2032} poll",

sub index :Path :Args(0) {
     my ( $self, $c ) = @_;
     $c->{stash}->{AdminContent}= \%Data;

sub end : ActionClass('RenderView') {}



Here is the index.tt file:
<p>[% AdminContent.priceline %]</p>


Also, the app's config states:      default_view => 'Alloy',
So the tt file is being processed using Alloy.  I get the same result if I use 'TT', the 
more common choice.


So, if the template produces a result that includes a "wide" character, I get the exception.

More information about the Catalyst mailing list