Skip to content

Upgrading from 2.2.5 to 2.2.6: Fatal error: Interface ‘LaminasServiceManagerAbstractFactoryInterface’ not found

Im trying to upgrade a Magento 2 site from 2.2.2 to the latest 2.3. I’ve got up to 2.2.5 so far without issues.

When moving from 2.2.5 to 2.2.6 I am getting a fatal error when running php bin/magento setup:di:compile

Fatal error:  Interface 'LaminasServiceManagerAbstractFactoryInterface' not found in /var/www/html/setup/src/Zend/Mvc/Controller/LazyControllerAbstractFactory.php

I’ve added the Zend\Mvc\Controller line to the autoload PSR-4 section in the composer.json file as suggested elsewhere on the internet.

Here’s the steps I follow to update (from a working 2.2.5):

php bin/magento maintenance:enable
composer require magento/product-community-edition 2.2.6 --no-update
composer update
composer dumpautoload
rm -rf var/cache/* var/page_cache/* generated/code/*
php bin/magento setup:upgrade
composer dumpautoload
php bin/magento setup:di:compile
php bin/magento indexer:reindex
php bin/magento cache:flush
php bin/magento maintenance:disable

Its at the php bin/magento setup:di:compile step where I get the fatal error.

AFAICT the Laminas ServiceManager AbstractFactoryInterface isn’t anywhere in the Vendor dir.

Can anyone shed any light on this?