in reply to Re: CPANPLUS broken custom sources
in thread CPANPLUS broken custom sources

CPAN.pm and CPANPLUS.pm both have features for automatically following dependencies -- that's the main advantage over manually typing the build commands.

Also, they both support Module::Build based packages, as well as the older ExtUtils::MakeMaker style.

When we finally get to the stage where nearly everyone is using CPAN/CPANPLUS (or some similar system of automatically dealing with dependencies, e.g. Debian's debs via apt-get), then life will get much easier for CPAN authors. At present there's a direct trade-off between modularity and ease-of-adoption, because if your module depends on a dozen other modules, a large percentage of the perl users out there will give up on the "download & install" grind before finishing.

Update: Caveat: Forgot about Module::Install, which is a nice hack to alleviate this problem.

Replies are listed 'Best First'.
Re^3: CPANPLUS broken custom sources
by zerohero (Monk) on Mar 01, 2009 at 21:41 UTC

    >> Also, they both support Module::Build based packages, as well as the older ExtUtils::MakeMaker style.

    I'm using the Module::Build approach which seems to do a decent job of the basics. However, at the module level I would expect some things were a little easier. Like installing files to a custom place, like /var/www/html.

    >> When we finally get to the stage where nearly everyone is using CPAN/CPANPLUS (or some similar system of automatically dealing with dependencies, e.g. Debian's debs via apt-get), then life will get much easier for CPAN authors...

    Aren't you already there? Who isn't using package systems that automatically know how to resolve things? If this isn't the case, then perhaps it's not easy enough yet (I'd argue this is part of the problem). Look at yum/rpm, or apt-get. These are ultra simple for the user.

    >> At present there's a direct trade-off between modularity and ease-of-adoption, because if your module depends on a dozen other modules, a large percentage of the perl users out there will give up on the download & install grind before finishing.

    While there is some truth to this, I believe the current implementation to be part of the problem. cpanp is better than cpan, but it needs to go further. I'd contrast how easy it is to install via something like Yum, to CPAN. One obvious issue is that most people (even developers) don't want to see the 10 tons of crap scroll on their screen for a CPAN install (although it seems to have gone down to 5 tons of crap for cpanp). If I'm installing something, all I need is some dots .... for progress, so I know something is happening. Then, if there is a failure, tell me. Note, you have to give up on the current cpan paradigm, which was very developer-centric, and do the following: 1. Automatically follow dependencies by default, and 2. Don't show me a bunch of crap. You could make people happy with automatic follow, by first presenting the screen of what you will install with a y/n (just like yum does).

    Also, please don't tell me I can configure cpanp to work this way (as I know you can). That's the issue. A newbie won't know how to do this, and will probably break one of the 100 pieces of config. Make it "simple" by default (simple = reduced info, auto follow). Let the developers turn on enhanced detail.

    I really urge the CPAN people involved to look at yum and ask "why can't cpanp be this easy?" The answer is it can (and it's getting there). Then you won't have all these arguments like "people are afraid of module systems". They aren't, really, it's not that big a deal. If I have to sit and wait for a download, why do I care if it's downloading modules or one big thing? Most of the computing devices I own do this, and I'm not conscious of it (Mac, PS3, iPhone). Really, it's a solved problem. People want it to be simple. All I care about is having to hit OK a million times, and look at a bunch of technical crap that scares the bejesus out of me. Even if things fail, people still don't want to see that technical mumbo-jumbo. People are afraid of CPAN, because it was made for developers (note I'm a developer, but putting on my consumer hat here). I'd make cpanp behave more like yum by default, but have a "developer mode" that switches all the detail back on. Put it in "dummy mode" and have developers configure it differently. Also, aren't developers tired of seeing all that junk on the screen? I am. It's visually exhausting and mostly irrelevant. Just tell me everything is ok, and a few lines about what you did or are going to do. Put the detail on a log (as cpanp does currently).

      I'm using the Module::Build approach which seems to do a decent job of the basics. However, at the module level I would expect some things were a little easier. Like installing files to a custom place, like /var/www/html.
      It's even harder with ExtUtils::MakeMaker. That's probably the reason I'm going to switch to Module::Build.

      "When we finally get to the stage where nearly everyone is using CPAN/CPANPLUS (or some similar system of automatically dealing with dependencies, e.g. Debian's debs via apt-get), then life will get much easier for CPAN authors..." Aren't you already there? Who isn't using package systems that automatically know how to resolve things?
      Yes I am certainly already there, but if you release some modules on CPAN you'll discover that not everyone is. There's just enough set-up hassles for CPAN/CPANPLUS (e.g. finding a good set of mirror sites to use) that a lot people haven't done this -- I don't know how many, but clearly quite a few haven't.

      The biggest unsolved problem with CPAN.pm and CPANPLUS.pm, in my opinion, would be the occasional breakage of deps, and almost as bad, asking the user irritating questions. I don't care if it needs to chug for an hour, I don't want it to chug for an hour and then to hang-up on something.

      And further, it's a little hard to see how these problems can be fixed without a centralized agency in charge of cleaning them up (e.g a distro centered on perl?). Possibly the perl world needs to borrow a page from Debian and get a little more fanatic about defining and demanding adherence to Policy.