mageconfigsync
mageconfigsync copied to clipboard
Diff requires Symfony\Component\Yaml\Parser not found
Fatal error: Class 'Symfony\Component\Yaml\Parser' not found in phar:///mageconfigsync.phar/src/MageConfigSync/Command/DiffCommand.php on line 48
This is probably caused by some extension in Magento messing with the autoloader.
In my case it was Aitoc_Aitsys with this beauty:
// unregistering all, and varien autoloaders to make our performing first
$autoloaders = spl_autoload_functions();
if ($autoloaders and is_array($autoloaders) && !empty($autoloaders))
{
foreach ($autoloaders as $autoloader)
{
spl_autoload_unregister($autoloader);
}
}
if (version_compare(Mage::getVersion(),'1.3.1','>'))
{
spl_autoload_unregister(array(Varien_Autoload::instance(), 'autoload'));
}
spl_autoload_register(array(self::instance(), 'autoload'), false);
if (version_compare(Mage::getVersion(),'1.3.1','>'))
{
Varien_Autoload::register();
}
else
{
spl_autoload_register(array(self::instance(), 'performStandardAutoload'));
#self::_loadOverwrittenClasses();
}
Who needs other autoloaders when you've got Aitoc, right?! right?!
Fix for this is to require the vendor/autoload.php
again after initialising Magento, I suppose, registering the composer autoloading process again.