ppm update error

Posted by umuench on 2017-12-05 07:26
Forums: PPM | OS: Windows 10

Hello!

I can't update any repository on my laptop (see attachment)!!! Can you help me?

I have installed ActivePerl 5.22, 5.24 and 5.26 like this bin-path:

C:\Program Files\ActiveState\ActivePerl\5.22\..
C:\Program Files\ActiveState\ActivePerl\5.24\..
C:\Program Files\ActiveState\ActivePerl\5.26\..
AttachmentSize
ppm_error.txt4.53 KB

grahams
ActiveState Staff
Tue, 2017-12-05 09:31

1). Never use the version number as part of the installation target PATH. This has been a fatal problem for years. Especially, do not use ".". Windows software still doesn't handle "." in a folder name consistently.

2.) PPM does not work as expected when multiple versions of ActivePerl are installed simultaneously. Only *the last* version of PPM installed will be working. There is a work-around for this which basically is writing a batch script that alters the PATH value every time you switch Perls.

3). If you install ActivePerl into "Program Files" the functionality of PPM cannot be guaranteed. You will need to run PPM with elevated permissions (as Administrator), or run a PowerShell script to bulk modify the default security settings. That's not going to fix every problem either. There are still modules that will not install or work correctly if the Path includes white space. There is a workaround, which is to use an alternate module installation area on a per-user basis, but there can be only one alternate module installation area (at a time), which makes it incompatible with multiple Perls unless you're running batch files to reset your environment every time you switch Perls.

4). PPM is reporting that it can't modify existing files. The --force option will solve that problem, but --force will be destructive if there is a situation where PPM is working where you don't expect it to be, as it will be in this case.

The Better Way

A better way to deploy multiple versions is to install each one, in turn, into C:\Perl64. As you finish installing them, rename the folder. For example, you might end up with C:\Perl64522 C:\Perl64524, and C:\Perl64526. None of the Perls will work in this configuration (making mutual interference really difficult), but *any* of them will start working the minute you rename the desired folder back to C:\Perl64. This is rather like how PerlBrew works, without the PerlBrew helper scripts.