Skip Menu |

This queue is for tickets about the Log-Report CPAN distribution.

Report information
The Basics
Id: 111420
Status: resolved
Priority: 0/
Queue: Log-Report

People
Owner: Nobody in particular
Requestors: paulo.a.ferreira [...] gmail.com
Cc:
AdminCc:

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



Subject: Dancer2::Plugin::LogReport - can't configure a translator
Date: Mon, 25 Jan 2016 16:51:46 +0000
To: bug-Log-Report [...] rt.cpan.org
From: Paulo A Ferreira <paulo.a.ferreira [...] gmail.com>
In Dancer2 module I'm using use Log::Report (); use Dancer2::Plugin::LogReport 'com_domain_myservice', mode => 'DEBUG', native_language => 'pt_PT', translator => { charset => "utf-8", lexicons => ['/home/myservice/LocaleData'] } ; With this syntax it reports Not an ARRAY reference at /home/myservice/lib/perl5/Log/Report/Domain.pm line 48. $transl = Log::Report::Translator->new(@$transl) if ref $transl eq 'HASH'; (shouldn't it be %$transl ?) The dancer2 app runs if I change to this translator => [ charset => "utf-8", lexicons => ['/home/myservice/LocaleData'] ] But then when using it on a page/route [myservice:3938] core @2016-01-25 16:19:15> Entering hook core.error.init in (eval 144) l. 1 panic: Can't call method "translate" on unblessed reference at /home/myservice/lib/perl5/Log/Report/Domain.pm line 148. at /home/myservice/libl5/Dancer2/Plugin/LogReport.pm line 50 Thank you!
Subject: Re: [rt.cpan.org #111420] AutoReply: Dancer2::Plugin::LogReport - can't configure a translator
Date: Mon, 25 Jan 2016 16:54:37 +0000
To: bug-Log-Report [...] rt.cpan.org
From: Paulo A Ferreira <paulo.a.ferreira [...] gmail.com>
Forgot to say that's the latest versions of the modules installed with cpanm on a perl 5.22.
Subject: Re: [rt.cpan.org #111420] Dancer2::Plugin::LogReport - can't configure a translator
Date: Mon, 25 Jan 2016 17:59:08 +0100
To: Paulo A Ferreira via RT <bug-Log-Report [...] rt.cpan.org>
From: Mark Overmeer <mark [...] overmeer.net>
* Paulo A Ferreira via RT (bug-Log-Report@rt.cpan.org) [160125 16:52]: Show quoted text
> Mon Jan 25 11:51:54 2016: Request 111420 was acted upon. > Transaction: Ticket created by paulo.a.ferreira@gmail.com > Queue: Log-Report > Subject: Dancer2::Plugin::LogReport - can't configure a translator > > In Dancer2 module I'm using > > translator => { > charset => "utf-8", > lexicons => ['/home/myservice/LocaleData'] > > With this syntax it reports > > Not an ARRAY reference at /home/myservice/lib/perl5/Log/Report/Domain.pm > line 48. > > $transl = Log::Report::Translator->new(@$transl) > if ref $transl eq 'HASH';
Show quoted text
> (shouldn't it be %$transl ?)
Yes, it should. I always use an explicit creation of the translator object myself, so did not encounter this buglet. Show quoted text
> [myservice:3938] core @2016-01-25 16:19:15> Entering hook core.error.init > in (eval 144) l. 1 > panic: Can't call method "translate" on unblessed reference at > /home/myservice/lib/perl5/Log/Report/Domain.pm line 148. > at /home/myservice/libl5/Dancer2/Plugin/LogReport.pm line 50
Does this still appear when you modify the above line? - $transl = Log::Report::Translator->new(@$transl) + $transl = Log::Report::Translator->new(%$transl) -- Regards, MarkOv ------------------------------------------------------------------------ Mark Overmeer MSc MARKOV Solutions Mark@Overmeer.net solutions@overmeer.net http://Mark.Overmeer.net http://solutions.overmeer.net
Subject: Re: [rt.cpan.org #111420] Dancer2::Plugin::LogReport - can't configure a translator
Date: Mon, 25 Jan 2016 17:40:52 +0000
To: bug-Log-Report [...] rt.cpan.org
From: Paulo A Ferreira <paulo.a.ferreira [...] gmail.com>
I changed it and it works! Then I had to install Log::Report::Lexicon::Index as it was missing. If I dump "textdomains" it nows shows the directory and all mo/po files. Great! The app doesn't show yet a translation but I'll try to figure out why not. :-) Thank you!! 2016-01-25 16:59 GMT+00:00 Mark Overmeer via RT <bug-Log-Report@rt.cpan.org> : Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=111420 > > > * Paulo A Ferreira via RT (bug-Log-Report@rt.cpan.org) [160125 16:52]:
> > Mon Jan 25 11:51:54 2016: Request 111420 was acted upon. > > Transaction: Ticket created by paulo.a.ferreira@gmail.com > > Queue: Log-Report > > Subject: Dancer2::Plugin::LogReport - can't configure a translator > > > > In Dancer2 module I'm using > > > > translator => { > > charset => "utf-8", > > lexicons => ['/home/myservice/LocaleData'] > > > > With this syntax it reports > > > > Not an ARRAY reference at /home/myservice/lib/perl5/Log/Report/Domain.pm > > line 48. > > > > $transl = Log::Report::Translator->new(@$transl) > > if ref $transl eq 'HASH';
>
> > (shouldn't it be %$transl ?)
> > Yes, it should. I always use an explicit creation of the > translator object myself, so did not encounter this buglet. >
> > [myservice:3938] core @2016-01-25 16:19:15> Entering hook core.error.init > > in (eval 144) l. 1 > > panic: Can't call method "translate" on unblessed reference at > > /home/myservice/lib/perl5/Log/Report/Domain.pm line 148. > > at /home/myservice/libl5/Dancer2/Plugin/LogReport.pm line 50
> > Does this still appear when you modify the above line? > - $transl = Log::Report::Translator->new(@$transl) > + $transl = Log::Report::Translator->new(%$transl) > -- > Regards, > MarkOv > > ------------------------------------------------------------------------ > Mark Overmeer MSc MARKOV Solutions > Mark@Overmeer.net solutions@overmeer.net > http://Mark.Overmeer.net http://solutions.overmeer.net > > >
Subject: Re: [rt.cpan.org #111420] Dancer2::Plugin::LogReport - can't configure a translator
Date: Tue, 26 Jan 2016 12:27:44 +0000
To: bug-Log-Report [...] rt.cpan.org
From: Paulo A Ferreira <paulo.a.ferreira [...] gmail.com>
Before closing this ticket, where's the best place to ask something about using the module ( specifically the translation part) ? Thank you! 2016-01-25 17:40 GMT+00:00 Paulo A Ferreira <paulo.a.ferreira@gmail.com>: Show quoted text
> I changed it and it works! > > Then I had to install Log::Report::Lexicon::Index as it was missing. > > If I dump "textdomains" it nows shows the directory and all mo/po files. > Great! > > The app doesn't show yet a translation but I'll try to figure out why not. > :-) > > Thank you!! > > 2016-01-25 16:59 GMT+00:00 Mark Overmeer via RT < > bug-Log-Report@rt.cpan.org>: >
>> <URL: https://rt.cpan.org/Ticket/Display.html?id=111420 > >> >> * Paulo A Ferreira via RT (bug-Log-Report@rt.cpan.org) [160125 16:52]:
>> > Mon Jan 25 11:51:54 2016: Request 111420 was acted upon. >> > Transaction: Ticket created by paulo.a.ferreira@gmail.com >> > Queue: Log-Report >> > Subject: Dancer2::Plugin::LogReport - can't configure a translator >> > >> > In Dancer2 module I'm using >> > >> > translator => { >> > charset => "utf-8", >> > lexicons => ['/home/myservice/LocaleData'] >> > >> > With this syntax it reports >> > >> > Not an ARRAY reference at /home/myservice/lib/perl5/Log/Report/Domain.pm >> > line 48. >> > >> > $transl = Log::Report::Translator->new(@$transl) >> > if ref $transl eq 'HASH';
>>
>> > (shouldn't it be %$transl ?)
>> >> Yes, it should. I always use an explicit creation of the >> translator object myself, so did not encounter this buglet. >>
>> > [myservice:3938] core @2016-01-25 16:19:15> Entering hook
>> core.error.init
>> > in (eval 144) l. 1 >> > panic: Can't call method "translate" on unblessed reference at >> > /home/myservice/lib/perl5/Log/Report/Domain.pm line 148. >> > at /home/myservice/libl5/Dancer2/Plugin/LogReport.pm line 50
>> >> Does this still appear when you modify the above line? >> - $transl = Log::Report::Translator->new(@$transl) >> + $transl = Log::Report::Translator->new(%$transl) >> -- >> Regards, >> MarkOv >> >> ------------------------------------------------------------------------ >> Mark Overmeer MSc MARKOV Solutions >> Mark@Overmeer.net solutions@overmeer.net >> http://Mark.Overmeer.net http://solutions.overmeer.net >> >> >>
>
Subject: Re: [rt.cpan.org #111420] Dancer2::Plugin::LogReport - can't configure a translator
Date: Tue, 26 Jan 2016 14:17:22 +0100
To: Paulo A Ferreira via RT <bug-Log-Report [...] rt.cpan.org>
From: Mark Overmeer <solutions [...] overmeer.net>
* Paulo A Ferreira via RT (bug-Log-Report@rt.cpan.org) [160126 12:28]: Show quoted text
> Queue: Log-Report > Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=111420 > > > Before closing this ticket, where's the best place to ask something about > using the module ( specifically the translation part) ?
The fastest way is via me. Sometimes Andy -- Regards, MarkOv ------------------------------------------------------------------------ Mark Overmeer MSc MARKOV Solutions Mark@Overmeer.net solutions@overmeer.net http://Mark.Overmeer.net http://solutions.overmeer.net
fixed over a year ago