metacpan / metacpan-monitoring

Monitoring metacpan
1 stars 3 forks source link

please check new version of cpanapi-monitoring source code #1

Closed melezhik closed 8 years ago

melezhik commented 9 years ago

Hi @ranguard , I have just update cpanapi-monitoring to keep in sync with the latest version of swat, let me know if everything is fine. Thanks.

melezhik commented 9 years ago

Also it'd be nice to get swat/metacpan reports on my email to see how things run in a dynamics ...

melezhik commented 8 years ago

I have just updated metacpan-monitoring code to accept recent changes in html output from some metacpan pages and also to use latest versions of swat and Outthentic DSL

melezhik commented 8 years ago

Hi guys! - @oalders @ranguard ! swat keep growing up, hopefully getting better and smarter. Please see my recent commits and let me know if cpanapi-monitoring is still in use? Thanks

ranguard commented 8 years ago

@melezhik I've finally got around to getting swat setup - but...

/home/vagrant/.swat/.cache/20377/prove/feed/recent/GET/request.t ..
ok 1 - 200 / 1 of 2 curl -X GET -k --connect-timeout 20 -m 20 -L -D - 'https://metacpan.org/feed/recent'
ok 2 - output match '200 OK'
ok 3 - output match '<title>Recent CPAN uploads - MetaCPAN</t'
ok 4 - output match /<dc:date>(\S+)<\/dc:date>/
parser error: eval error; sub:handle_generator; code:validate_latest_release( capture()->[0] )
error: Undefined subroutine &main::validate_latest_release called at (eval 88) line 1.
 at /home/vagrant/carton/metacpan-monitoring/lib/perl5/Outthentic/DSL.pm line 619.
    Outthentic::DSL::handle_generator('Outthentic::DSL=HASH(0x8ac1df8)', 'validate_latest_release( capture()->[0] )') called at /home/vagrant/carton/metacpan-monitoring/lib/perl5/Outthentic/DSL.pm line 442
    Outthentic::DSL::validate('Outthentic::DSL=HASH(0x8ac1df8)', '/home/vagrant/metacpan-monitoring/feed/recent/get.txt') called at /home/vagrant/carton/metacpan-monitoring/lib/perl5/swat.pm line 245
    eval {...} called at /home/vagrant/carton/metacpan-monitoring/lib/perl5/swat.pm line 244
    main::generate_asserts('/home/vagrant/metacpan-monitoring/feed/recent/get.txt') called at /home/vagrant/.swat/.cache/20377/prove/feed/recent/GET/request.t line 33
    eval {...} called at /home/vagrant/.swat/.cache/20377/prove/feed/recent/GET/request.t line 33
 at /home/vagrant/carton/metacpan-monitoring/lib/perl5/swat.pm line 256.
    main::generate_asserts('/home/vagrant/metacpan-monitoring/feed/recent/get.txt') called at /home/vagrant/.swat/.cache/20377/prove/feed/recent/GET/request.t line 33
    eval {...} called at /home/vagrant/.swat/.cache/20377/prove/feed/recent/GET/request.t line 33
1..4
# Looks like your test exited with 2 just after 4.
Dubious, test returned 2 (wstat 512, 0x200)
All 4 subtests passed
ranguard commented 8 years ago

So I'm guessing it's because the lib dir doesn't get picked up.

Our setup is the equivalent of:

cd /home/vagrant/carton/metacpan-monitoring
PERL_CARTON_PATH=/home/vagrant/carton/metacpan-monitoring /opt/perl-5.18.2/bin/carton exec swat

Adding -Ilib after the exec doesn't seem to work

@melezhik - any advice please?

melezhik commented 8 years ago

HI @ranguard , please try with this commit 5912519 . Please update dependencies as well, as I updated cpanfile. Let me know if it helps.

melezhik commented 8 years ago

Ah, sorry please use this commit - 3fc35ab

ranguard commented 8 years ago

@melezhik cool - that's working.

I'd updated the cpanfile & cpanfile.snapshot - and added a cron.sh... which is what I have in cron, running every 10 mins... so if the last line is NOT Result: PASS we'll get an email about it.

melezhik commented 8 years ago

Hi @ranguard , sounds good. I hope all is going to be fine, but let me know if tests fail, as I have not run them very much recently ...

ranguard commented 8 years ago

All tests are passing... if you can add more, especially against the API that would be amazing ;)

melezhik commented 8 years ago

Sure, my suggestion to decide what API end points need to be tested first, may be it is better to run a dedicated issue on it ?