Skip Menu |
 

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Web-Scraper CPAN distribution.

Report information
The Basics
Id: 89186
Status: new
Priority: 0/
Queue: Web-Scraper

People
Owner: Nobody in particular
Requestors: sundaryourfriend [...] gmail.com
Cc:
AdminCc:

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



Subject: The scrape method does not check whether $stuff was actually passed in
MIME-Version: 1.0
X-Mailer: MIME-tools 5.504 (Entity 5.504)
Content-Disposition: inline
X-RT-Interface: Web
Message-ID: <rt-4.0.16-23060-1380682436-1752.0-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
X-RT-Encrypt: 0
X-RT-Sign: 0
Content-Length: 478
Download (untitled) / with headers
text/plain 478b
It's easy to called $scraper->scrape() and get bit by weird bugs, since the subroutine neither checks that $stuff is passed in nor does something that would cause it to error out in that case. So, we get only a vague warning of "use of uninitialized value in subroutine entry" within build_tree(), but the execution carries on which could lead to many subtle bugs. This just needs a single line check at the beginning of 'scrape' to verify that $stuff has a defined value.


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.