flex: composer fails in SF 4.2: " curl_multi_setopt(): CURLPIPE_HTTP1 is no longer supported "

I’m updating my v4.2 project. Composer’s uptodate,

cd ~

which composer
	/usr/local/bin/composer

composer --version
	Composer version 1.8.6 2019-06-11 15:03:05

composer -vv self-update
	You are already using composer version 1.8.6 (stable channel).

but in my Symfony project,

	cd /src/www/test
	composer --version

	  [ErrorException]
	  curl_multi_setopt(): CURLPIPE_HTTP1 is no longer supported

	composer -vv self-update

		                                                              
		  [ErrorException]                                            
		  curl_multi_setopt(): CURLPIPE_HTTP1 is no longer supported  
		                                                              

		Exception trace:
		 () at /src/www/test/vendor/symfony/flex/src/CurlDownloader.php:49
		 Composer\Util\ErrorHandler::handle() at n/a:n/a
		 curl_multi_setopt() at /src/www/test/vendor/symfony/flex/src/CurlDownloader.php:49
		 Symfony\Flex\CurlDownloader->__construct() at /src/www/test/vendor/symfony/flex/src/ParallelDownloader.php:48
		 Symfony\Flex\ParallelDownloader->__construct() at /src/www/test/vendor/symfony/flex/src/Flex.php:108
		 Symfony\Flex\Flex->activate() at phar:///usr/local/bin/composer.phar/src/Composer/Plugin/PluginManager.php:236
		 Composer\Plugin\PluginManager->addPlugin() at phar:///usr/local/bin/composer.phar/src/Composer/Plugin/PluginManager.php:205
		 Composer\Plugin\PluginManager->registerPackage() at phar:///usr/local/bin/composer.phar/src/Composer/Plugin/PluginManager.php:261
		 Composer\Plugin\PluginManager->loadRepository() at phar:///usr/local/bin/composer.phar/src/Composer/Plugin/PluginManager.php:76
		 Composer\Plugin\PluginManager->loadInstalledPlugins() at phar:///usr/local/bin/composer.phar/src/Composer/Factory.php:384
		 Composer\Factory->createComposer() at phar:///usr/local/bin/composer.phar/src/Composer/Factory.php:576
		 Composer\Factory::create() at phar:///usr/local/bin/composer.phar/src/Composer/Console/Application.php:345
		 Composer\Console\Application->getComposer() at phar:///usr/local/bin/composer.phar/src/Composer/Console/Application.php:458
		 Composer\Console\Application->getPluginCommands() at phar:///usr/local/bin/composer.phar/src/Composer/Console/Application.php:156
		 Composer\Console\Application->doRun() at phar:///usr/local/bin/composer.phar/vendor/symfony/console/Application.php:117
		 Symfony\Component\Console\Application->run() at phar:///usr/local/bin/composer.phar/src/Composer/Console/Application.php:104
		 Composer\Console\Application->run() at phar:///usr/local/bin/composer.phar/bin/composer:61
		 require() at /usr/local/bin/composer.phar:24

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 27 (8 by maintainers)

Commits related to this issue

Most upvoted comments

I had this issue in a project that I haven’t touched in a while.

I fixed it by:

  1. Updating the global symfony/flex using composer global require symfony/flex ^1.5 as @nicolas-grekas suggested.
  2. Removing the vendor/symfony/flex directory in my project.
  3. Running composer update.

I had this issue in a project that I haven’t touched in a while.

I fixed it by:

  1. Updating the global symfony/flex using composer global require symfony/flex ^1.5 as @nicolas-grekas suggested.
  2. Removing the vendor/symfony/flex directory in my project.
  3. Running composer update.

That worked for me. Thanks!

@diamondlee I have just had the same error. After removing the var and the vendor folder it worked for me. Another solution could be to run the install process without using the composer cache?

@nicolas-grekas this conversation is about the fact that the symfony flex code throws an exception with php 7.4.

Same issue today as well, couldn’t run any composer command in my project.

If you have the issue, the only reason I can imagine is because you didn’t update flex to the latest version.

Sure, but how do you updated it? I haven’t installed flex globally. And I can’t update anything since Composer is broken.

Thanks @TimoBakx for the solution, I had to rm -rf vendor to unblock my project…

Hi I’m also getting this exact same error as of today while trying to update from Symfony 4.2 to 5. My Composer version is 1.9.1.

Same issue today as well, couldn’t run any composer command in my project.

If you have the issue, the only reason I can imagine is because you didn’t update flex to the latest version.

Sure, but how do you updated it? I haven’t installed flex globally. And I can’t update anything since Composer is broken.

Thanks @TimoBakx for the solution, I had to rm -rf vendor to unblock my project…

FTR: you can also try composer update symfony/flex --no-plugins --no-scripts, then you should be able to run composer install (or other commands) normally

I have just had the same error too. And find that problem in php version. I run into problem if I use php 7.4, but on php 7.3 everything works