-
-
Notifications
You must be signed in to change notification settings - Fork 553
Description
Problem/Motivation
When running drupal config_split:import -y get an Error: Call to undefined method Drupal\config_split\Command\ImportCommand::isMaintenance() in /var/www/html/vendor/drupal/console-core/src/EventSubscriber/MaintenanceModeListener.php on line 80
How to reproduce
Install drupal console
Setup a website with Drupal 8.7.6 with the config_split module activated.
Run config_split:import command.
Details to include:
- Drupal version 8.7.6
drupal/console 1.9.1 The Drupal CLI. A tool to generate boilerplate code, interact with and debug Drupal.
drupal/console-core 1.9.1 Drupal Console Core
drupal/console-en 1.9.1 Drupal Console English Language
drupal/console-extend-plugin 0.9.2 Drupal Console Extend Plugin - Console Launcher version 1.9.1
Solution
Fix the code... add the method that is missing, or remove the method call? I'm good with any of the above.
Details to include:
Stack trace:
/var/www/html $ drupal config_split:import
[16-Aug-2019 18:09:35 UTC] Error: Call to undefined method Drupal\config_split\Command\ImportCommand::isMaintenance() in /var/www/html/vendor/drupal/console-core/src/EventSubscriber/MaintenanceModeListener.php on line 80 #0 /var/www/html/vendor/drupal/console-core/src/EventSubscriber/MaintenanceModeListener.php(66): Drupal\Console\Core\EventSubscriber\MaintenanceModeListener->switchMaintenanceMode(Object(Symfony\Component\Console\Event\ConsoleTerminateEvent), 'off')
#1 /var/www/html/vendor/symfony/event-dispatcher/EventDispatcher.php(212): Drupal\Console\Core\EventSubscriber\MaintenanceModeListener->disableMaintenanceMode(Object(Symfony\Component\Console\Event\ConsoleTerminateEvent), 'console.termina...', Object(Symfony\Component\EventDispatcher\EventDispatcher))
#2 /var/www/html/vendor/symfony/event-dispatcher/EventDispatcher.php(44): Symfony\Component\EventDispatcher\EventDispatcher->doDispatch(Array, 'console.termina...', Object(Symfony\Component\Console\Event\ConsoleTerminateEvent))
#3 /var/www/html/vendor/symfony/console/Application.php(1014): Symfony\Component\EventDispatcher\EventDispatcher->dispatch('console.termina...', Object(Symfony\Component\Console\Event\ConsoleTerminateEvent))
#4 /var/www/html/vendor/symfony/console/Application.php(255): Symfony\Component\Console\Application->doRunCommand(Object(Drupal\config_split\Command\ImportCommand), Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#5 /var/www/html/vendor/drupal/console-core/src/Application.php(187): Symfony\Component\Console\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#6 /var/www/html/vendor/drupal/console/src/Application.php(64): Drupal\Console\Core\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#7 /var/www/html/vendor/symfony/console/Application.php(148): Drupal\Console\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#8 /var/www/html/vendor/drupal/console/bin/drupal.php(89): Symfony\Component\Console\Application->run()
#9 /var/www/html/vendor/drupal/console/bin/drupal(4): require('/var/www/html/v...')
#10 {main}
Error: Call to undefined method Drupal\config_split\Command\ImportCommand::isMaintenance() in Drupal\Console\Core\EventSubscriber\MaintenanceModeListener->switchMaintenanceMode() (line 80 of /var/www/html/vendor/drupal/console-core/src/EventSubscriber/MaintenanceModeListener.php)