Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"

Stopping CPAN from upgrading Perl

by chorg (Monk)
on Jul 18, 2001 at 22:08 UTC ( #97806=perlquestion: print w/replies, xml ) Need Help??

chorg has asked for the wisdom of the Perl Monks concerning the following question:

Hello -- I know this question has been asked before.

I am on a perl 5.6.0 system. I want to use cpan to get some stuff, but I don't want it to try to upgrade perl if I need a package that is part of the core perl distro. Can someone link me to the node that explained that? Or, you could just tell me.... :)
"Intelligence is a tool used achieve goals, however goals are not always chosen wisely..."

Replies are listed 'Best First'.
Re: Stopping CPAN from upgrading Perl
by mirod (Canon) on Jul 18, 2001 at 22:15 UTC

    What about trying "CPAN upgrade Perl" in Super Search?

    Simply put the answer is to first update CPAN, the last version does not try to upgrade Perl.

Re: Stopping CPAN from upgrading Perl
by merlyn (Sage) on Jul 18, 2001 at 23:25 UTC

      I'll ask this again since I never got an answer the last time.

      Why isn't this fix included with Perl 5.6.0? I suspect that "the fix" is included but that the release of Perl 5.6.x broke part of the fix so that the problem has reappeared.

      My (often fuzzy) memory recalls this chronology:

      • "CPAN suddenly upgrading Perl" bug fixed and it required both changes to the module and to some features of the CPAN itself (the collection of web/ftp servers).
      • Reports of people upgrading just and the problem going away.
      • Reduced frequency of reports of this problem
      • Release of Perl 5.6.0
      • Increase in frequency of reports again
      I'm in particular suspicious that the CPAN-web/ftp-site side of the fix got dropped/confused/undone by the release of Perl 5.6.0 and/or 5.6.1.

      BTW, I did do some work trying to check this on my own. In particular, the latest (according to's ChangeLog file says nothing of this fix (and hasn't been updated since March 1999).

      I'd dig deeper but I never use myself and am only interested in this bug as it relates to being able to help others when they run into this problem. (:

              - tye (but my friends call me "Tye")
        My personal memory goes as follows.

        Perl 5.005_03 released with (IIRC) version 1.48. This version will upgrade perl if it sees something that depends on Perl 5.6.x, but that fact not realized because Perl 5.6.x doesn't exist.

        Perl 5.6.0 released.

        Not too long thereafter while trying to install something I find that it is upgrading perl on me. I send a bug report. Andreas sends me back a "sorry" and a patch that will die horrible flaming death instead of doing the upgrade. I wasn't the first to complain, that honor goes to Joseph Hall.

        A bit after that I am installing some new machines, and trying to load a ton of modules from the old ones. The "die flaming death" aspect of things causes me grief so I convinced Adreas that he wants to make it skip that upgrade and anything which depends on it, but continue installing other things. (I might have sent him a patch that did that, I don't think so though.)

        Fast-forward to the present. Anyone who has a machine with an install of 5.005_03 who has not upgraded their CPAN from the default install, upon requiring any module which requires Perl 5.6.x, will upgrade Perl. Painfully. This problem is cropping up and will continue to crop up because more and more modules over time are requiring Perl 5.6.x.

        And so a plea to any module authors. Please think very, very carefully before making your module require something that involves 5.6.x. When you do that you are adding to this problem. Furthermore if you have a module which is used by other modules, and you introduce that dependency, then you have made all of those other modules also cause this problem. Please consider carefully the convenience to yourself versus the inconvenience of causing people to have Perl upgrade itself on them.

        Yes, the bug is in a version of a module released with Perl 5.005_03. But that version of Perl is still widely used. And it will, despite its best attempts to uninstall itself, continue to be for some time to come.

        Ok -- it worked like a charm -- trick was to upgrade CPAN only -- don't "install Bundle::CPAN" Thanks a lot for the prompt help.
        "Intelligence is a tool used achieve goals, however goals are not always chosen wisely..."
Re: Stopping CPAN from upgrading Perl
by rucker (Scribe) on Jul 18, 2001 at 22:45 UTC
    A quick and dirty method I've used in the past is when it starts asking the questions to config perl, control-c and then restart CPAN (and resume doing whatever you were trying before.) CPAN thinks there's a problem installing the new perl and skips it.

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://97806]
Approved by root
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (2)
As of 2023-10-04 19:11 GMT
Find Nodes?
    Voting Booth?

    No recent polls found