Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

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

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

People
Owner: BENNING [...] cpan.org
Requestors: henrik [...] hswn.dk
Cc:
AdminCc:

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



Subject: saftsumm 1.4 error 'Bareword "UUID::uuid" not allowed' in Log/Saftpresse/Plugin/Role/Tracking.pm (patch included)
Date: Sun, 15 May 2016 14:03:15 +0200
To: bug-Log-Saftpresse [...] rt.cpan.org
From: Henrik Størner <henrik [...] hswn.dk>
Hi, the fresh release of 1.4 made me test this again, and I ran into this problem: # saftsumm </var/log/mail.info could not load plugin Log::Saftpresse::Plugin::Postfix: Bareword "UUID::uuid" not allowed while "strict subs" in use at /usr/local/share/perl/5.20.2/Log/Saftpresse/Plugin/Role/Tracking.pm line 58. Compilation failed in require at /usr/share/perl5/Module/Runtime.pm line 317. Compilation failed in require at (eval 271) line 1. Seems to be a mistake in how the UUID generate() function is called. Changing Log/Saftpresse/Plugin/Role/Tracking.pm like this makes it work: --- ./blib/lib/Log/Saftpresse/Plugin/Role/Tracking.pm 2016-05-15 11:13:33.000000000 +0200 +++ /usr/local/share/perl/5.20.2/Log/Saftpresse/Plugin/Role/Tracking.pm 2016-05-15 13:56:33.968259362 +0200 @@ -55,7 +55,8 @@ my ( $self, $stash, $notes ) = @_; if( defined $stash->{'pid'} ) { - my $id = UUID::uuid; + my $id; + UUID::generate($id); $stash->{'tracking_id'} = $id; $notes->set('tracking-pid-'.$stash->{'pid'}, $id); $log->debug('generated tracking_id for pid-'.$stash->{'pid'}); Regards, Henrik
What is the version of your UUID module? perl -MUUID -E 'say $UUID::VERSION;' According to the docs the function is available in >=0.06: 0.06 Thu Dec 18 08:01:44 EST 2014 - Took over maintaining (Rick Myers - JRM) - Added uuid()
Subject: Re: [rt.cpan.org #114390] saftsumm 1.4 error 'Bareword "UUID::uuid" not allowed' in Log/Saftpresse/Plugin/Role/Tracking.pm (patch included)
Date: Sun, 15 May 2016 21:54:33 +0200
To: bug-Log-Saftpresse [...] rt.cpan.org
From: Henrik Størner <henrik [...] hswn.dk>
Hi, appears to be 0.05: $ perl -MUUID -E 'say $UUID::VERSION;' 0.05 Regards, Henrik Den 15-05-2016 kl. 19:48 skrev Markus Benning via RT: Show quoted text
> <URL: https://rt.cpan.org/Ticket/Display.html?id=114390 > > > What is the version of your UUID module? > > perl -MUUID -E 'say $UUID::VERSION;' > > According to the docs the function is available in >=0.06: > > 0.06 Thu Dec 18 08:01:44 EST 2014 > - Took over maintaining (Rick Myers - JRM) > - Added uuid() >
On 2016-05-15 13:47:59, BENNING wrote: Show quoted text
> What is the version of your UUID module? > > perl -MUUID -E 'say $UUID::VERSION;' > > According to the docs the function is available in >=0.06:
But Log-Saftpresse accepts every version of UUID: https://metacpan.org/source/BENNING/Log-Saftpresse-1.4/META.yml#L46
On Sun May 15 17:24:20 2016, SREZIC wrote: Show quoted text
> On 2016-05-15 13:47:59, BENNING wrote:
> > What is the version of your UUID module? > > > > perl -MUUID -E 'say $UUID::VERSION;' > > > > According to the docs the function is available in >=0.06:
> > But Log-Saftpresse accepts every version of UUID: > https://metacpan.org/source/BENNING/Log-Saftpresse-1.4/META.yml#L46
Since Debian/stable still includes 0.05 (others may also) i decided to change the code to use generate()/unparse() instead of uuid() and not to require version >=0.06 of the module. Just released 1.5. Thank you for reporting this problem. Markus