Project

General

Profile

Actions

Bug #75273

closed

Composer install of TER extensions fails when conflicts array is empty

Added by Peter Kraume about 8 years ago. Updated over 5 years ago.

Status:
Closed
Priority:
Should have
Assignee:
Category:
composer
Target version:
-
Start date:
2016-03-25
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
7
PHP Version:
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

I tried to install dd_googlesitemap via composer:
composer -v require typo3-ter/dd-googlesitemap:~2.0.6

This fails with this error message:

Installation failed, reverting ./composer.json to its original content.

  [ErrorException]
  Undefined index: conflicts

Exception trace:
 () at /.../vendor/typo3/cms-composer-installers/Classes/TYPO3/CMS/Composer/Installer/Downloader/T3xDownloader.php:327
 Composer\Util\ErrorHandler::handle() at /.../vendor/typo3/cms-composer-installers/Classes/TYPO3/CMS/Composer/Installer/Downloader/T3xDownloader.php:327
 TYPO3\CMS\Composer\Installer\Downloader\T3xDownloader->fixEmConf() at /.../vendor/typo3/cms-composer-installers/Classes/TYPO3/CMS/Composer/Installer/Downloader/T3xDownloader.php:264
 TYPO3\CMS\Composer\Installer\Downloader\T3xDownloader->constructEmConf() at /.../vendor/typo3/cms-composer-installers/Classes/TYPO3/CMS/Composer/Installer/Downloader/T3xDownloader.php:249
 TYPO3\CMS\Composer\Installer\Downloader\T3xDownloader->writeEmConf() at /.../vendor/typo3/cms-composer-installers/Classes/TYPO3/CMS/Composer/Installer/Downloader/T3xDownloader.php:70
 TYPO3\CMS\Composer\Installer\Downloader\T3xDownloader->extract() at phar:///.../composer.phar/src/Composer/Downloader/ArchiveDownloader.php:43
 Composer\Downloader\ArchiveDownloader->download() at /.../vendor/typo3/cms-composer-installers/Classes/TYPO3/CMS/Composer/Installer/Downloader/T3xDownloader.php:50
 TYPO3\CMS\Composer\Installer\Downloader\T3xDownloader->download() at phar:///.../composer.phar/src/Composer/Downloader/DownloadManager.php:213
 Composer\Downloader\DownloadManager->download() at /.../vendor/typo3/cms-composer-installers/Classes/TYPO3/CMS/Composer/Installer/ExtensionInstaller.php:191
 TYPO3\CMS\Composer\Installer\ExtensionInstaller->installCode() at /.../vendor/typo3/cms-composer-installers/Classes/TYPO3/CMS/Composer/Installer/ExtensionInstaller.php:123
 TYPO3\CMS\Composer\Installer\ExtensionInstaller->install() at phar:///.../composer.phar/src/Composer/Installer/InstallationManager.php:152
 Composer\Installer\InstallationManager->install() at phar:///.../composer.phar/src/Composer/Installer/InstallationManager.php:139
 Composer\Installer\InstallationManager->execute() at phar:///.../composer.phar/src/Composer/Installer.php:569
 Composer\Installer->doInstall() at phar:///.../composer.phar/src/Composer/Installer.php:228
 Composer\Installer->run() at phar:///.../composer.phar/src/Composer/Command/RequireCommand.php:170
 Composer\Command\RequireCommand->execute() at phar:///.../composer.phar/vendor/symfony/console/Command/Command.php:259
 Symfony\Component\Console\Command\Command->run() at phar:///.../composer.phar/vendor/symfony/console/Application.php:844
 Symfony\Component\Console\Application->doRunCommand() at phar:///.../composer.phar/vendor/symfony/console/Application.php:192
 Symfony\Component\Console\Application->doRun() at phar:///.../composer.phar/src/Composer/Console/Application.php:166
 Composer\Console\Application->doRun() at phar:///.../composer.phar/vendor/symfony/console/Application.php:123
 Symfony\Component\Console\Application->run() at phar:///.../composer.phar/src/Composer/Console/Application.php:99
 Composer\Console\Application->run() at phar:///.../composer.phar/bin/composer:43
 require() at /.../composer.phar:25

The reason for this problem seems to be that there is an empty conflicts array in the ext_emconf.php provided with the extension. See https://github.com/dmitryd/typo3-dd_googlesitemap/blob/development/ext_emconf.php#L37 for details.

Upon commenting out line 327 in vendor/typo3/cms-composer-installers/Classes/TYPO3/CMS/Composer/Installer/Downloader/T3xDownloader.php the installation works.

I'm not sure if this is a core bug or if it's up to the extension developer to remove the empty array from ext_emconf.php.

Actions

Also available in: Atom PDF