On Tue, May 21, 2019 at 08:12:30AM +0200, Charlene Wendling wrote:
>
> As said earlier, here is an update for WWW::Search::Ebay.
>
> What's new upstream [0]:
>
> - fix category test
> - sync with Ebay HTML changes
> - allow shipping to be "unknown"
>
> Port-wise it's a simple update with some cleaning.
>
> Testing:
>
> - 'make test' passes, but you may meet HTTP 501s very often [1]
> - There is one consumer, www/p5-WWW-Ebay, and it passes [2]
>
> Comments/feedback are welcome!
This one needs:
RUN_DEPENDS+= www/p5-LWP-Protocol-https
and a comment that tests need the network to run, similar to
p5-WWW-Tumbler.
It still doesn't quite seem to work right when I use:
AutoSearch --engine Ebay -n BSD -s bsd bsd
it does work though, check out:
https://www.ebay.com/itm/COMDEX-1999-special-1-4M-preview-release-of-the-NetBSD-operating-system-CD-ROM/333212907390?hash=item4d9509777e:g:GQcAAOSwX1xc2Wjm
But lots of warnings for:
Use of uninitialized value in numeric lt (<) at /usr/local/libdata/perl5/site_pe rl/WWW/Search/Ebay.pm line 672.
This patch seems to fix it, but I don't know if it's the right fix or if
there's some other extenuating reason that the end_date is sometimes
undefined. I do see a few wide characters in the output so I wonder if
it's just not very unicode safe and stuff is going wrong due to that.
$OpenBSD$
Index: lib/WWW/Search/Ebay.pm
--- lib/WWW/Search/Ebay.pm.orig
+++ lib/WWW/Search/Ebay.pm
@@ -669,7 +669,7 @@ sub result_as_HTML
my $dateNow = ParseDate('now');
print STDERR " DDD compare end_date ==$dateEnd==\n" if (DEBUG_DATES || (1 < $self->{_debug}));
print STDERR " DDD compare date_now ==$dateNow==\n" if (DEBUG_DATES || (1 < $self->{_debug}));
- if (Date_Cmp($dateEnd, $dateNow) < 0)
+ if ((Date_Cmp($dateEnd, $dateNow) || 0) < 0)
{
$sEndedColor = 'red';
$sEndedWord = 'ended';
@@ -1040,7 +1040,7 @@ sub _parse_tree
&&
(0 < $iBids) # Item got any bids
&&
- (Date_Cmp($enddate, 'now') < 0) # Item is ended
+ ((Date_Cmp($enddate, 'now') || 0) < 0) # Item is ended
)
{
# Item must have been sold!?!
>
> Charlène.
>
>
> [0]
> https://metacpan.org/diff/file?target=MTHURN/WWW-Search-Ebay-3.052/&source=MTHURN%2FWWW-Search-Ebay-3.042
> [1]
> https://www.cpantesters.org/distro/W/WWW-Search-Ebay.html?oncpan=1&distmat=1&version=3.052&grade=3
> [2] http://0x0.st/zm4L.tgz
>
>
> Index: Makefile
> ===================================================================
> RCS file: /cvs/ports/www/p5-WWW-Search-Ebay/Makefile,v
> retrieving revision 1.14
> diff -u -p -u -p -r1.14 Makefile
> --- Makefile 6 Aug 2017 20:12:57 -0000 1.14
> +++ Makefile 21 May 2019 05:38:13 -0000
> @@ -2,22 +2,26 @@
>
> COMMENT= backend for searching www.ebay.com
>
> -DISTNAME = WWW-Search-Ebay-3.042
> -REVISION = 1
> +DISTNAME= WWW-Search-Ebay-3.052
> CATEGORIES= www
>
> -# perl
> +# Perl
> PERMIT_PACKAGE_CDROM= Yes
>
> MODULES= cpan
> PKG_ARCH= *
>
> -BUILD_DEPENDS = devel/p5-Module-Install-AuthorTests
> -RUN_DEPENDS= www/p5-WWW-Search
> +BUILD_DEPENDS= devel/p5-Module-Install-AuthorTests
> +
> +RUN_DEPENDS= converters/p5-DateManip \
> + www/p5-HTML-Tree \
> + www/p5-WWW-Search>=2.517 \
> + www/p5-libwww
> +
> TEST_DEPENDS= devel/p5-IO-Capture
>
> MAKE_ENV+= TEST_POD="Yes"
>
> -CONFIGURE_STYLE = modinst
> +CONFIGURE_STYLE= modinst
>
> .include <bsd.port.mk>
> Index: distinfo
> ===================================================================
> RCS file: /cvs/ports/www/p5-WWW-Search-Ebay/distinfo,v
> retrieving revision 1.6
> diff -u -p -u -p -r1.6 distinfo
> --- distinfo 19 Sep 2015 10:05:48 -0000 1.6
> +++ distinfo 21 May 2019 05:38:13 -0000
> @@ -1,2 +1,2 @@
> -SHA256 (WWW-Search-Ebay-3.042.tar.gz) = IJnzUNMmnbHXrgb8Tbxbjb5QJ0wlu7dzCnFSYVPER5U=
> -SIZE (WWW-Search-Ebay-3.042.tar.gz) = 54585
> +SHA256 (WWW-Search-Ebay-3.052.tar.gz) = osgshTeJPvhLfwLOQoGN+TW4F7cL0EBrgoE6iA6R0Gg=
> +SIZE (WWW-Search-Ebay-3.052.tar.gz) = 54632
>
--
andrew - http://afresh1.com
Hey, I think I see a barn up ahead.
-- The American Astronaut
No comments:
Post a Comment