Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Pod-Weaver CPAN distribution.

Report information
The Basics
Id: 62191
Status: resolved
Priority: 0/
Queue: Pod-Weaver

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

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



Subject: Version plugin breaks if no package declaration found
The Version section plugin breaks if there's no package declaration in the PPI document: weave_document() failed on 'script/podweaver': Can't call method "namespace" without a package or object reference at /usr/local/share/perl/5.10.1/Pod/Weaver/Section/Version.pm line 66. Offending context is: if ( exists $input->{ppi_document} ) { my $pkg_node = $input->{ppi_document}->find_first('PPI::Statement::Package'); $args{module} = $pkg_node->namespace if defined $pkg_node; } PPI::Node->find_first() returns undef only on error, it returns a false-but-defined value if nothing is found, so line 66 should read: $args{module} = $pkg_node->namespace if $pkg_node;
Thanks, fixed in git. -- rjbs