composer-patches
composer-patches copied to clipboard
Can't install with Composer 2.2
Hi,
Composer 2.2 was released 3 hours ago. I have a cloud Deployment whre composer is installed via CURL in a Docker file during the build process. And on the last rebuilds composer install failed out of a sudden reproducable.
200/200 [============================] 100%
--
957 | - Installing cweagans/composer-patches (1.7.1): Extracting archive
958 | For additional security you should declare the allow-plugins config with a list of packages names that are allowed to run code. See https://getcomposer.org/allow-plugins
959 | You have until July 2022 to add the setting. Composer will then switch the default behavior to disallow all plugins.
960 | Plugin initialization failed (require(vendor/autoload.php): failed to open stream: No such file or directory), uninstalling plugin
961 | - Removing cweagans/composer-patches (1.7.1)
962 | Install of cweagans/composer-patches failed
963 |
964 |
965 | [ErrorException]
966 | require(vendor/autoload.php): failed to open stream: No such file or directory
967 |
968 |
969 | install [--prefer-source] [--prefer-dist] [--prefer-install PREFER-INSTALL] [--dry-run] [--dev] [--no-suggest] [--no-dev] [--no-autoloader] [--no-progress] [--no-install] [-v\|vv\|vvv\|--verbose] [-o\|--optimize-autoloader] [-a\|--classmap-authoritative] [--apcu-autoloader] [--apcu-autoloader-prefix APCU-AUTOLOADER-PREFIX] [--ignore-platform-req IGNORE-PLATFORM-REQ] [--ignore-platform-reqs] [--] [<packages>]...
970 |
971 | The command '/bin/sh -c composer install --prefer-dist' returned a non-zero code: 1
Once downgraded to the last version by using :
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/bin -- --filename=composer --version=2.1.14
Instead of
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/bin -- --filename=composer
it is working again.
958 | For additional security you should declare the allow-plugins config with a list of packages names that are allowed to run code. See https://getcomposer.org/allow-plugins
Did you try this? Did it fix your build?
Yes I have it in the config section of composer json. No it did not work. Had to use composer 2.1
Can you please post your complete composer.json somewhere? If you don't want it to be public, you can email it to me. [email protected]
I have the same issue. Composer install broken with composer v2.2. Works fine with composer v2.1.
I can confirm the issue as well with composer-patches 1.7.1 and Composer 2.2.4
This appears to be fixed now.