You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When running composer update phpro/grumphp to update from 0.11.1 to 0.11.2 the follow error is thrown after (or during) the autoload files are generated:
[Symfony\Component\Debug\Exception\FatalThrowableError]
Class 'GrumPHP\Console\Command\ConfigureCommand' not found
Exception trace:
() at phar:///usr/local/bin/composer/src/Composer/Plugin/PluginManager.php(195) : eval()'d code:143
GrumPHP\Composer\GrumPHPPlugin_composer_tmp1->runScheduledTasks() at n/a:n/a
call_user_func() at phar:///usr/local/bin/composer/src/Composer/EventDispatcher/EventDispatcher.php:171
Composer\EventDispatcher\EventDispatcher->doDispatch() at phar:///usr/local/bin/composer/src/Composer/EventDispatcher/EventDispatcher.php:96
Composer\EventDispatcher\EventDispatcher->dispatchScript() at phar:///usr/local/bin/composer/src/Composer/Installer.php:307
Composer\Installer->run() at phar:///usr/local/bin/composer/src/Composer/Command/RequireCommand.php:174
Composer\Command\RequireCommand->execute() at phar:///usr/local/bin/composer/vendor/symfony/console/Command/Command.php:257
Symfony\Component\Console\Command\Command->run() at phar:///usr/local/bin/composer/vendor/symfony/console/Application.php:850
Symfony\Component\Console\Application->doRunCommand() at phar:///usr/local/bin/composer/vendor/symfony/console/Application.php:193
Symfony\Component\Console\Application->doRun() at phar:///usr/local/bin/composer/src/Composer/Console/Application.php:227
Composer\Console\Application->doRun() at phar:///usr/local/bin/composer/vendor/symfony/console/Application.php:124
Symfony\Component\Console\Application->run() at phar:///usr/local/bin/composer/src/Composer/Console/Application.php:100
Composer\Console\Application->run() at phar:///usr/local/bin/composer/bin/composer:54
require() at /usr/local/bin/composer:25
This is likely due to the change from PSR-0 to PSR-4 in 0.11.2 (or rather the change of folder structure since PSR-4 allows the PSR-0 structure) since the autoloader used by the Composer plugin have the old paths and thus can't find the file/class when the folder structure changes.
Not sure there's a fix for this really, or if it's worth fixing - but figured I'd report it at least :)
Indeed, that looks related to the PSR4.
It can be fixed by replacing the COMMAND_NAME constants with its values in the GrumPHPPlugin, but that is something I would like to avoid.
The error only occurs once. After that it keeps on working.
Until it is fixed, you might want to remove the old version before installing the new one:
@jyggen: I've tried fixing the errors by hardcoding the strings, but then the installation fails on other positions. I'll add the remark to the release notes and close this issue for now. It just isn't worth fixing :)
When running
composer update phpro/grumphp
to update from 0.11.1 to 0.11.2 the follow error is thrown after (or during) the autoload files are generated:This is likely due to the change from PSR-0 to PSR-4 in 0.11.2 (or rather the change of folder structure since PSR-4 allows the PSR-0 structure) since the autoloader used by the Composer plugin have the old paths and thus can't find the file/class when the folder structure changes.
Not sure there's a fix for this really, or if it's worth fixing - but figured I'd report it at least :)
Steps to reproduce:
mkdir tmp cd tmp composer require phpro/grumphp 0.11.1 composer require phpro/grumphp 0.11.2 -vvv
Result:
The text was updated successfully, but these errors were encountered: