I am in the process of upgrading an instance of SilverStripe 3.6.5 to SS 4.x and I have been following the recommendations to install the SilverStripe upgrader.
But running composer global require silverstripe/upgrader
on my Windows development box yields this:
Using version ^1.4 for silverstripe/upgrader
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 1 install, 0 updates, 0 removals
- Installing silverstripe/upgrader (1.4.1): Downloading (100%)
Failed to download silverstripe/upgrader from dist: There was an error extracting the ZIP file, it is either corrupted or using an invalid format.
Now trying to download from source
- Installing silverstripe/upgrader (1.4.1): Cloning 84226286c8 from cache
Installation failed, reverting ./composer.json to its original content.
I am using this stack:
- Windows 8.1
- PHP 7.1.26
- composer 1.8.5
- git version 2.21.0.windows.1
I have no Composer package in the global scope at this moment.
What I have also tried (to no avail) is to uninstall composer, clear all caches and folders, and start afresh with downloading Composer-Setup.exe again and right after its installation is finished, try again composer global require silverstripe/upgrader
on the command line. The results were identical as to silverstripe/upgrader even though all other packages (I guess its dependencies) downloaded and installed fine. For instance, this is an excerpt of the command line output after starting afresh:
Changed current directory to C:/Users/Amenel/AppData/Roaming/Composer
Using version ^1.4 for silverstripe/upgrader
./composer.json has been created
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 35 installs, 0 updates, 0 removals
- Installing ocramius/package-versions (1.4.0): Downloading (100%)
- Installing composer/ca-bundle (1.1.4): Downloading (100%)
- Installing padraic/humbug_get_contents (1.1.2): Downloading (100%)
- Installing padraic/phar-updater (v1.0.6): Downloading (100%)
- Installing symfony/polyfill-ctype (v1.11.0): Downloading (100%)
- Installing symfony/filesystem (v4.3.1): Downloading (100%)
...
I can't seem to find anything related to this specific error when I perform a web search on it.
Also worthy of note: this error is also reported when I specify a previous version of silverstripe/upgrader, e.g. 1.3.0.
To sum up, my problem is that I can't start the upgrade process because the installation of the upgrader via composer fails.