Magento 2.2.6 обновить до Magento 2.3 не удалось

Предварительные условия

Magento 2.2.6 Текущая версия PHP: PHP 7.1.22

Действия по воспроизведению

  1. Перейдите в System> Web Setup Wizard.
  2. Нажмите на обновления системы
  3. Запустите процесс обновления.

Процесс обновления остановится на шаге 2 с сообщением об ошибке ниже: Проверка зависимости компонентов Мы обнаружили конфликтующие зависимости компонентов. Скрыть детали

Ошибка команды «update»: загрузка репозиториев композитора с информацией о пакете. Обновление зависимостей (включая require-dev). Не удалось разрешить ваши требования в устанавливаемом наборе пакетов.

Проблема 1 - magento/product-community-edition 2.3.0 requires magento/magento2-base 2.3.0 -> satisfiable by magento/magento2-base[2.3.0]. - Conclusion: don't install symfony/console v2.8.38 - Conclusion: don't install symfony/console v4.1.6|install symfony/console v2.8.38 - Conclusion: don't install symfony/console v4.1.7|install symfony/console v2.8.38 - Conclusion: don't install symfony/console v4.1.8|install symfony/console v2.8.38 - Conclusion: don't install symfony/console v3.4.19|install symfony/console v4.1.6|install symfony/console v4.1.7|install symfony/console v4.1.8 - Conclusion: don't install symfony/console v4.1.2|install symfony/console v2.8.38|install symfony/console v3.4.19 - Conclusion: don't install symfony/console v4.1.3|install symfony/console v2.8.38|install symfony/console v3.4.19 - Conclusion: don't install symfony/console v4.1.4|install symfony/console v2.8.38|install symfony/console v3.4.19 - Installation request for magento/product-community-edition 2.3.0 -> satisfiable by magento/product-community-edition[2.3.0]. - Conclusion: don't install symfony/console v4.1.5|install symfony/console v2.8.38|install symfony/console v3.4.19 - Installation request for sebastian/phpcpd 2.0.4 -> satisfiable by sebastian/phpcpd[2.0.4]. - Conclusion: don't install symfony/console v3.4.18|install symfony/console v4.1.2|install symfony/console v4.1.3|install symfony/console v4.1.4|install symfony/console v4.1.5|install symfony/console v4.1.6|install symfony/console v4.1.7|install symfony/console v4.1.8 - sebastian/phpcpd 2.0.4 requires symfony/console ~2.7|^3.0 -> satisfiable by symfony/console[v2.7.0, v2.7.1, v2.7.10, v2.7.11, v2.7.12, v2.7.13, v2.7.14, v2.7.15, v2.7.16, v2.7.17, v2.7.18, v2.7.19, v2.7.2, v2.7.20, v2.7.21, v2.7.22, v2.7.23, v2.7.24, v2.7.25, v2.7.26, v2.7.27, v2.7.28, v2.7.29, v2.7.3, v2.7.30, v2.7.31, v2.7.32, v2.7.33, v2.7.34, v2.7.35, v2.7.36, v2.7.37, v2.7.38, v2.7.39, v2.7.4, v2.7.40, v2.7.41, v2.7.42, v2.7.43, v2.7.44, v2.7.45, v2.7.46, v2.7.47, v2.7.48, v2.7.49, v2.7.5, v2.7.6, v2.7.7, v2.7.8, v2.7.9, v2.8.0, v2.8.1, v2.8.10, v2.8.11, v2.8.12, v2.8.13, v2.8.14, v2.8.15, v2.8.16, v2.8.17, v2.8.18, v2.8.19, v2.8.2, v2.8.20, v2.8.21, v2.8.22, v2.8.23, v2.8.24, v2.8.25, v2.8.26, v2.8.27, v2.8.28, v2.8.29, v2.8.3, v2.8.30, v2.8.31, v2.8.32, v2.8.33, v2.8.34, v2.8.35, v2.8.36, v2.8.37, v2.8.38, v2.8.39, v2.8.4, v2.8.40, v2.8.41, v2.8.42, v2.8.43, v2.8.44, v2.8.45, v2.8.46, v2.8.47, v2.8.48, v2.8.5, v2.8.6, v2.8.7, v2.8.8, v2.8.9, v3.0.0, v3.0.1, v3.0.2, v3.0.3, v3.0.4, v3.0.5, v3.0.6, v3.0.7, v3.0.8, v3.0.9, v3.1.0, v3.1.1, v3.1.10, v3.1.2, v3.1.3, v3.1.4, v3.1.5, v3.1.6, v3.1.7, v3.1.8, v3.1.9, v3.2.0, v3.2.1, v3.2.10, v3.2.11, v3.2.12, v3.2.13, v3.2.14, v3.2.2, v3.2.3, v3.2.4, v3.2.5, v3.2.6, v3.2.7, v3.2.8, v3.2.9, v3.3.0, v3.3.1, v3.3.10, v3.3.11, v3.3.12, v3.3.13, v3.3.14, v3.3.15, v3.3.16, v3.3.17, v3.3.18, v3.3.2, v3.3.3, v3.3.4, v3.3.5, v3.3.6, v3.3.7, v3.3.8, v3.3.9, v3.4.0, v3.4.1, v3.4.10, v3.4.11, v3.4.12, v3.4.13, v3.4.14, v3.4.15, v3.4.16, v3.4.17, v3.4.18, v3.4.19, v3.4.2, v3.4.3, v3.4.4, v3.4.5, v3.4.6, v3.4.7, v3.4.8, v3.4.9]. - Can only install one of: symfony/console[v4.1.0, v2.7.0]. - Can only install one of: symfony/console[v4.1.0, v2.7.1]. - Can only install one of: symfony/console[v4.1.0, v2.7.10]. - Can only install one of: symfony/console[v4.1.0, v2.7.11]. - Can only install one of: symfony/console[v4.1.0, v2.7.12]. - Can only install one of: symfony/console[v4.1.0, v2.7.13]. - Can only install one of: symfony/console[v4.1.0, v2.7.14]. - Can only install one of: symfony/console[v4.1.0, v2.7.15]. - Can only install one of: symfony/console[v4.1.0, v2.7.16]. - Can only install one of: symfony/console[v4.1.0, v2.7.17]. - Can only install one of: symfony/console[v4.1.0, v2.7.18]. - Can only install one of: symfony/console[v4.1.0, v2.7.19]. - Can only install one of: symfony/console[v4.1.0, v2.7.2]. - Can only install one of: symfony/console[v4.1.0, v2.7.20]. - Can only install one of: symfony/console[v4.1.0, v2.7.21]. - Can only install one of: symfony/console[v4.1.0, v2.7.22]. - Can only install one of: symfony/console[v4.1.0, v2.7.23]. - Can only install one of: symfony/console[v4.1.0, v2.7.24]. - Can only install one of: symfony/console[v4.1.0, v2.7.25]. - Can only install one of: symfony/console[v4.1.0, v2.7.26]. - Can only install one of: symfony/console[v4.1.0, v2.7.27]. - Can only install one of: symfony/console[v4.1.0, v2.7.28]. - Can only install one of: symfony/console[v4.1.0, v2.7.29]. - Can only install one of: symfony/console[v4.1.0, v2.7.3]. - Can only install one of: symfony/console[v4.1.0, v2.7.30]. - Can only install one of: symfony/console[v4.1.0, v2.7.31]. - Can only install one of: symfony/console[v4.1.0, v2.7.32]. - Can only install one of: symfony/console[v4.1.0, v2.7.33]. - Can only install one of: symfony/console[v4.1.0, v2.7.34]. - Can only install one of: symfony/console[v4.1.0, v2.7.35]. - Can only install one of: symfony/console[v4.1.0, v2.7.36]. - Can only install one of: symfony/console[v4.1.0, v2.7.37]. - Can only install one of: symfony/console[v4.1.0, v2.7.38]. - Can only install one of: symfony/console[v4.1.0, v2.7.39]. - Can only install one of: symfony/console[v4.1.0, v2.7.4]. - Can only install one of: symfony/console[v4.1.0, v2.7.40]. - Can only install one of: symfony/console[v4.1.0, v2.7.41]. - Can only install one of: symfony/console[v4.1.0, v2.7.42]. - Can only install one of: symfony/console[v4.1.0, v2.7.43]. - Can only install one of: symfony/console[v4.1.0, v2.7.44]. - Can only install one of: symfony/console[v4.1.0, v2.7.45]. - Can only install one of: symfony/console[v4.1.0, v2.7.46]. - Can only install one of: symfony/console[v4.1.0, v2.7.47]. - Can only install one of: symfony/console[v4.1.0, v2.7.48]. - Can only install one of: symfony/console[v4.1.0, v2.7.49]. - Can only install one of: symfony/console[v4.1.0, v2.7.5]. - Can only install one of: symfony/console[v4.1.0, v2.7.6]. - Can only install one of: symfony/console[v4.1.0, v2.7.7]. - Can only install one of: symfony/console[v4.1.0, v2.7.8]. - Can only install one of: symfony/console[v4.1.0, v2.7.9]. - Can only install one of: symfony/console[v4.1.0, v2.8.0]. - Can only install one of: symfony/console[v4.1.0, v2.8.1]. - Can only install one of: symfony/console[v4.1.0, v2.8.10]. - Can only install one of: symfony/console[v4.1.0, v2.8.11]. - Can only install one of: symfony/console[v4.1.0, v2.8.12]. - Can only install one of: symfony/console[v4.1.0, v2.8.13]. - Can only install one of: symfony/console[v4.1.0, v2.8.14]. - Can only install one of: symfony/console[v4.1.0, v2.8.15]. - Can only install one of: symfony/console[v4.1.0, v2.8.16]. - Can only install one of: symfony/console[v4.1.0, v2.8.17]. - Can only install one of: symfony/console[v4.1.0, v2.8.18]. - Can only install one of: symfony/console[v4.1.0, v2.8.19]. - Can only install one of: symfony/console[v4.1.0, v2.8.2]. - Can only install one of: symfony/console[v4.1.0, v2.8.20]. - Can only install one of: symfony/console[v4.1.0, v2.8.21]. - Can only install one of: symfony/console[v4.1.0, v2.8.22]. - Can only install one of: symfony/console[v4.1.0, v2.8.23]. - Can only install one of: symfony/console[v4.1.0, v2.8.24]. - Can only install one of: symfony/console[v4.1.0, v2.8.25]. - Can only install one of: symfony/console[v4.1.0, v2.8.26]. - Can only install one of: symfony/console[v4.1.0, v2.8.27]. - Can only install one of: symfony/console[v4.1.0, v2.8.28]. - Can only install one of: symfony/console[v4.1.0, v2.8.29]. - Can only install one of: symfony/console[v4.1.0, v2.8.3]. - Can only install one of: symfony/console[v4.1.0, v2.8.30]. - Can only install one of: symfony/console[v4.1.0, v2.8.31]. - Can only install one of: symfony/console[v4.1.0, v2.8.32]. - Can only install one of: symfony/console[v4.1.0, v2.8.33]. - Can only install one of: symfony/console[v4.1.0, v2.8.34]. - Can only install one of: symfony/console[v4.1.0, v2.8.35]. - Can only install one of: symfony/console[v4.1.0, v2.8.36]. - Can only install one of: symfony/console[v4.1.0, v2.8.37]. - Can only install one of: symfony/console[v4.1.0, v2.8.39]. - Can only install one of: symfony/console[v4.1.0, v2.8.4]. - Can only install one of: symfony/console[v4.1.0, v2.8.40]. - Can only install one of: symfony/console[v4.1.0, v2.8.41]. - Can only install one of: symfony/console[v4.1.0, v2.8.42]. - Can only install one of: symfony/console[v4.1.0, v2.8.43]. - Can only install one of: symfony/console[v4.1.0, v2.8.44]. - Can only install one of: symfony/console[v4.1.0, v2.8.45]. - Can only install one of: symfony/console[v4.1.0, v2.8.46]. - Can only install one of: symfony/console[v4.1.0, v2.8.47]. - Can only install one of: symfony/console[v4.1.0, v2.8.48]. - Can only install one of: symfony/console[v4.1.0, v2.8.5]. - Can only install one of: symfony/console[v4.1.0, v2.8.6]. - Can only install one of: symfony/console[v4.1.0, v2.8.7]. - Can only install one of: symfony/console[v4.1.0, v2.8.8]. - Can only install one of: symfony/console[v4.1.0, v2.8.9]. - Can only install one of: symfony/console[v4.1.0, v3.0.0]. - Can only install one of: symfony/console[v4.1.0, v3.0.1]. - Can only install one of: symfony/console[v4.1.0, v3.0.2]. - Can only install one of: symfony/console[v4.1.0, v3.0.3]. - Can only install one of: symfony/console[v4.1.0, v3.0.4]. - Can only install one of: symfony/console[v4.1.0, v3.0.5]. - Can only install one of: symfony/console[v4.1.0, v3.0.6]. - Can only install one of: symfony/console[v4.1.0, v3.0.7]. - Can only install one of: symfony/console[v4.1.0, v3.0.8]. - Can only install one of: symfony/console[v4.1.0, v3.0.9]. - Can only install one of: symfony/console[v4.1.0, v3.1.0]. - Can only install one of: symfony/console[v4.1.0, v3.1.1]. - Can only install one of: symfony/console[v4.1.0, v3.1.10]. - Can only install one of: symfony/console[v4.1.0, v3.1.2]. - Can only install one of: symfony/console[v4.1.0, v3.1.3]. - Can only install one of: symfony/console[v4.1.0, v3.1.4]. - Can only install one of: symfony/console[v4.1.0, v3.1.5]. - Can only install one of: symfony/console[v4.1.0, v3.1.6]. - Can only install one of: symfony/console[v4.1.0, v3.1.7]. - Can only install one of: symfony/console[v4.1.0, v3.1.8]. - Can only install one of: symfony/console[v4.1.0, v3.1.9]. - Can only install one of: symfony/console[v4.1.0, v3.2.0]. - Can only install one of: symfony/console[v4.1.0, v3.2.1]. - Can only install one of: symfony/console[v4.1.0, v3.2.10]. - Can only install one of: symfony/console[v4.1.0, v3.2.11]. - Can only install one of: symfony/console[v4.1.0, v3.2.12]. - Can only install one of: symfony/console[v4.1.0, v3.2.13]. - Can only install one of: symfony/console[v4.1.0, v3.2.14]. - Can only install one of: symfony/console[v4.1.0, v3.2.2]. - Can only install one of: symfony/console[v4.1.0, v3.2.3]. - Can only install one of: symfony/console[v4.1.0, v3.2.4]. - Can only install one of: symfony/console[v4.1.0, v3.2.5]. - Can only install one of: symfony/console[v4.1.0, v3.2.6]. - Can only install one of: symfony/console[v4.1.0, v3.2.7]. - Can only install one of: symfony/console[v4.1.0, v3.2.8]. - Can only install one of: symfony/console[v4.1.0, v3.2.9]. - Can only install one of: symfony/console[v4.1.0, v3.3.0]. - Can only install one of: symfony/console[v4.1.0, v3.3.1]. - Can only install one of: symfony/console[v4.1.0, v3.3.10]. - Can only install one of: symfony/console[v4.1.0, v3.3.11]. - Can only install one of: symfony/console[v4.1.0, v3.3.12]. - Can only install one of: symfony/console[v4.1.0, v3.3.13]. - Can only install one of: symfony/console[v4.1.0, v3.3.14]. - Can only install one of: symfony/console[v4.1.0, v3.3.15]. - Can only install one of: symfony/console[v4.1.0, v3.3.16]. - Can only install one of: symfony/console[v4.1.0, v3.3.17]. - Can only install one of: symfony/console[v4.1.0, v3.3.18]. - Can only install one of: symfony/console[v4.1.0, v3.3.2]. - Can only install one of: symfony/console[v4.1.0, v3.3.3]. - Can only install one of: symfony/console[v4.1.0, v3.3.4]. - Can only install one of: symfony/console[v4.1.0, v3.3.5]. - Can only install one of: symfony/console[v4.1.0, v3.3.6]. - Can only install one of: symfony/console[v4.1.0, v3.3.7]. - Can only install one of: symfony/console[v4.1.0, v3.3.8]. - Can only install one of: symfony/console[v4.1.0, v3.3.9]. - Can only install one of: symfony/console[v4.1.0, v3.4.0]. - Can only install one of: symfony/console[v4.1.0, v3.4.1]. - Can only install one of: symfony/console[v4.1.0, v3.4.10]. - Can only install one of: symfony/console[v4.1.0, v3.4.11]. - Can only install one of: symfony/console[v4.1.0, v3.4.12]. - Can only install one of: symfony/console[v4.1.0, v3.4.13]. - Can only install one of: symfony/console[v4.1.0, v3.4.14]. - Can only install one of: symfony/console[v4.1.0, v3.4.15]. - Can only install one of: symfony/console[v4.1.0, v3.4.16]. - Can only install one of: symfony/console[v4.1.0, v3.4.17]. - Can only install one of: symfony/console[v4.1.0, v3.4.2]. - Can only install one of: symfony/console[v4.1.0, v3.4.3]. - Can only install one of: symfony/console[v4.1.0, v3.4.4]. - Can only install one of: symfony/console[v4.1.0, v3.4.5]. - Can only install one of: symfony/console[v4.1.0, v3.4.6]. - Can only install one of: symfony/console[v4.1.0, v3.4.7]. - Can only install one of: symfony/console[v4.1.0, v3.4.8]. - Can only install one of: symfony/console[v4.1.0, v3.4.9].

Исправления

Я запускаю следующую команду: composer require --dev phpunit/phpunit:~6.2.0 friendsofphp/php-cs-fixer:~2.10.1 lusitanian/oauth:~0.8.10 pdepend/pdepend:2.5.2 sebastian/phpcpd:~3.0.0 squizlabs/php_codesniffer:3.2.2 --no-update

Это решило проблему, и я смог обновить Magento до 2.3 из бэкэнда, но это создало другую проблему: Служба временно недоступна. Сервер временно не может обработать ваш запрос из-за простоя в обслуживании или проблем с производительностью. Пожалуйста, повторите попытку позже.

Я пробовал запустить эту команду:

bin/magento setup:static-content:deploy

Я получил эту ошибку на своем SSH:

#0 /chroot/home/[MY ROOT]/vendor/zendframework/zend-servicemanager/src/Config.php(137): Zend\ServiceManager\ServiceManager->addAbstractFactory('Zend\\Mvc\\Contro...')
#1 /chroot/home/[MY ROOT]/vendor/zendframework/zend-modulemanager/src/Listener/ServiceListener.php(225): Zend\ServiceManager\Config->configureServiceManager(Object(Zend\Mvc\Controller\ControllerManager))
#2 [internal function]: Zend\ModuleManager\Listener\ServiceListener->onLoadModulesPost(Object(Zend\ModuleManager\ModuleEvent))
#3 /chroot/home[MY ROOT]/vendor/zendframework/zend-eventmanager/src/EventManager.php(490): call_user_func(Array, Object(Zend\ModuleManager\ModuleEvent))

Как я могу исправить эту проблему?


person Abe    schedule 30.11.2018    source источник
comment
Учитывая, что я только что потратил большую часть сегодняшнего дня на восстановление своей локальной версии M2 для разработчиков после запуска composer update ... я бы сказал, выбросить все это в корзину и вернуться к 1.9x ... или Shopify * бормочет * ... вы можете получить лучший ответ на magento.stackexchange.com   -  person CD001    schedule 30.11.2018


Ответы (3)


Я также сталкиваюсь с той же проблемой при обновлении до версии 2.3.0. Затем я пытаюсь внести несколько изменений перед обновлением до версии 2.3.0.

Ниже приведены шаги для обновления до версии 2.3.0.

Шаг 1. Включите режим разработчика

php bin/magento deploy:mode:set developer

Шаг 2. Вот несколько команд, которые необходимо выполнить перед обновлением до Magento 2.3

composer config preferred-install dist
composer config sort-packages true
composer config prefer-stable true

Шаг 3. Теперь вам нужно исправить файл composer.json до версии Magento 2.3

composer require --dev friendsofphp/php-cs-fixer:~2.10.0 --no-update

Шаг 4. Обновите Magento до 2.3.0

composer require --dev sebastian/phpcpd:~3.0.0 --no-update

Шаг 5. Выполните следующую команду

php -r '$autoload=json_decode(file_get_contents("composer.json"), true); $autoload["autoload"]["psr-4"]["Zend\\Mvc\\Controller\\"]= "setup/src/Zend/Mvc/Controller/"; file_put_contents("composer.json", json_encode($autoload, JSON_PRETTY_PRINT|JSON_UNESCAPED_SLASHES));'

Шаг 6. Запустите команду обновления

composer update

Шаг 7. Команда обновления

php bin/magento setup:upgrade
person AbdurRahman Lakhani    schedule 10.12.2018

У Magento2 есть проблемы. Вы не можете использовать мастер настройки через Интернет для обновления его версии. Вы должны запустить команду напрямую:

cd to_your_magento_root_dir
composer install
php bin/magento s:up 

Но вы столкнетесь со многими ошибками, если установите несколько пользовательских модулей.

person bachlee89    schedule 06.12.2018
comment
Я знаю, что вы взволнованы, но, пожалуйста, постарайтесь держать свой язык под контролем. Считайте, что Stack Overflow больше похож на Википедию, чем на Reddit. - person Machavity♦; 06.12.2018

См. это.

Это поможет

php -f pre_composer_update_2.3.php -- --root='/var/www/html' --repo=https://repo.magento.com/
person Robert Mihai Ionas    schedule 27.02.2019