On Wed, Nov 30, 2011 at 6:13 AM, Michael G Schwern <schw...@pobox.com> wrote:
> Unfortunately, that would be a circular dependency between Mouse and TB2 
> unless...

Not a complete dependency, though, as one can function without the
other.  As long as the CPAN clients are smart enough not to follow the
prereq chain endlessly, it might work.

E.g.

* "install Mouse" -- requires TB2 -- TB2 requires Mouse and client
ignores repeat.  TB2 passes test by falling back on TB::Mouse.  Mouse
tests find TB2 and pass.

* "install TB2" -- requires Mouse -- Mouse requires TB2 and client
ignores repeat.  Mouse tests fail (ugly!).  TB2 fails to find Mouse,
falls back and passes.

That second case only happens if TB2 has *never* been installed on a
system (or if it's too old to meet Mouse's needs).  And possibly TB2's
Makefile could be smart and only add the Mouse prereq if it finds a
version of itself (or, really, of Test::More) sufficient to meet
Mouse's prereq needs.  (Bundling might still be easier.)

Another idea might be for TB2 to use the new "runtime/recomends"
prereq type in v2 CPAN Meta files.

One of my Paris QA hackathon goals is to teach at least CPAN.pm (and
maybe the other CPAN clients) to do something useful with the new
prereq types, and "useful" might include something smart when a
recommendation fails.  (E.g. letting it happen without complaining).
The definition of "useful" is one of the things I want to debate over
meals there in the non-coding hours.  :-)

-- David

Reply via email to