5

I recently uploaded development releases of two distributions to CPAN where one depended on the other. Let's say one distro is named Distro, the other Prereq, and Distro requires Prereq version 0.009_001.

Unfortunately, I didn't get any test reports for Distro. I think the reason is that the versions of dev releases simply aren't tracked by CPAN. They don't appear in 02packages.details.txt, so CPAN thinks that the dependency can't be satisfied.

Is it impossible to make a CPAN Tester load a development release of a prerequisite? Or is there a work-around?

nwellnhof
  • 32,319
  • 7
  • 89
  • 113
  • I do sympathise, but there are good modules and bad modules. It sounds like you know how to fix your problem, so it doesn't look like you have a specific programming question – Borodin Apr 04 '16 at 19:06
  • 2
    @Borodin I don't understand what you are trying to say. – simbabque Apr 04 '16 at 19:39
  • 4
    I think you will get better answers in #toolchain on irc.perl.org. The usual suspects don't frequent SO. – simbabque Apr 04 '16 at 19:39
  • @nwellnhof can you provide specific informations about `Prereq` and `Distro`? Dev releases *are* supposed to be *tracked* by CPAN and should enter the Cpantesters process. – smonff Jan 18 '17 at 13:25
  • @smonff AFAIU, dev releases are only tracked in CPAN's [RECENT](http://www.cpan.org/RECENT) file which is used by CPANTesters, but they're not listed in 02packages.details.txt which is used to resolve prerequisites. – nwellnhof Jan 18 '17 at 20:34

1 Answers1

0

While some CPAN Testers might just happen to have that development release already installed when they test your distribution, most probably won't, and there's no way to require that they do have it.

If the prerequisite is Pure Perl, it is probably possible to bundle an entire copy of the prerequisite library in a ./t/bundled/ directory of your distribution, and then in test scripts include this near the top to force the bundled version to be loaded by automated testers:

use FindBin '$Bin';
use if $ENV{AUTOMATED_TESTING}, lib => "$Bin/bundled";
use Name::Of::Prerequisite;

(I do something similar not with CPAN Testers, but with Travis continuous integration, forcing it to test against the latest checkout from GitHub of certain prerequisites.)

tobyink
  • 13,478
  • 1
  • 23
  • 35