- Issue created by @Summit
- Status changed to Postponed: needs info
almost 2 years ago 5:55pm 16 February 2023 Consolidation isnβt Drupal code. Drush is a separate project. If you give complete details and follow the prompt to re-run with -vvv perhaps we could help.
It looks like you are running a global Drush which is not supported.
- π¬π§United Kingdom longwave UK
This was fixed in https://github.com/consolidation/config/pull/56 - you need to upgrade
consolidation/config
. - π³π±Netherlands Summit
Hi, how do I upgrade consolidation/config? when I do
# rm -rf vendor/ web/ # composer update
Same errors
Rerun with -vvv
Exception trace: at htdocs/bizreview/vendor/drush/drush/src/Boot/BootstrapHook.php:36 Drush\Boot\BootstrapHook->initialize() at htdocs/bizreview/vendor/consolidation/annotated-command/src/Hooks/Dispatchers/InitializeHookDispatcher.php:44 Consolidation\AnnotatedCommand\Hooks\Dispatchers\InitializeHookDispatcher->doInitializeHook() at htdocs/bizreview/vendor/consolidation/annotated-command/src/Hooks/Dispatchers/InitializeHookDispatcher.php:36 Consolidation\AnnotatedCommand\Hooks\Dispatchers\InitializeHookDispatcher->callInitializeHook() at htdocs/bizreview/vendor/consolidation/annotated-command/src/Hooks/Dispatchers/InitializeHookDispatcher.php:29 Consolidation\AnnotatedCommand\Hooks\Dispatchers\InitializeHookDispatcher->initialize() at htdocs/bizreview/vendor/consolidation/annotated-command/src/CommandProcessor.php:145 Consolidation\AnnotatedCommand\CommandProcessor->initializeHook() at htdocs/bizreview/vendor/consolidation/annotated-command/src/AnnotatedCommand.php:375 Consolidation\AnnotatedCommand\AnnotatedCommand->initialize() at htdocs/bizreview/vendor/symfony/console/Command/Command.php:278 Symfony\Component\Console\Command\Command->run() at htdocs/bizreview/vendor/symfony/console/Application.php:1040 Symfony\Component\Console\Application->doRunCommand() at htdocs/bizreview/vendor/symfony/console/Application.php:314 Symfony\Component\Console\Application->doRun() at htdocs/bizreview/vendor/symfony/console/Application.php:168 Symfony\Component\Console\Application->run() at htdocs/bizreview/vendor/drush/drush/src/Runtime/Runtime.php:124 Drush\Runtime\Runtime->doRun() at htdocs/bizreview/vendor/drush/drush/src/Runtime/Runtime.php:51 Drush\Runtime\Runtime->run() at htdocs/bizreview/vendor/drush/drush/drush.php:77 require() at htdocs/bizreview/vendor/drush/drush/drush:4
Thanks in advance!
Greetings, Martijn - π¬π§United Kingdom longwave UK
Without seeing your full composer.json file it's impossible to tell - if you are willing to upload that as an attachment we might be able to help further.
- π³π±Netherlands Summit
Hi,
Changes referred to in https://app.codecov.io/gh/consolidation/config/pull/56 are allready in place in my /vendor/consolidation/config, don't know why it still gives those var errors.Attached my composer.json file (saved as odt:). Thanks in advance!
greetings, Martijn - π³π±Netherlands Summit
Better to put composer.json in txt. Here attached. Greetings, Martijn
- π³π±Netherlands Summit
Hi,
I found I had two drushes installed! One on users/[my username].composer and one in MAMP/htdocs/[my drupal project].
I deleted the one under [my username] and the errors where gone! composer update in [my drupal project], didn't off course renewed the 'old' one under users/[my username].Greetings, Martijn
- π³π±Netherlands Summit
And the root cause of drush updatedb not working was because of problems with MAMP and localhost.
As explained here https://stackoverflow.com/questions/20723803/pdoexception-sqlstatehy000-...I needed to alter localhost in settings.php to 127.0.0.1.
Then I could use drush updatedb correctly.The issue that arose here is that "localhost" uses a UNIX socket and can not find the database in the standard directory. However "127.0.0.1" uses TCP (Transmission Control Protocol), which essentially means it runs through the "local internet" on your computer being much more reliable than the UNIX socket in this case
- Status changed to Closed: works as designed
almost 2 years ago 4:38pm 20 February 2023 - π¬π§United Kingdom longwave UK
Thank you for getting back to us and explaining the solution, this might help if other people run into the same issue.
As this is not anything we can fix in Drupal core, closing as "works as designed".
- π¬π§United Kingdom Drupal Centric
It looks like you installed/updated drush for the project and not globally. Running
./vendor/bin/drush updatedb
would use the version you installed for the project, inside the vendor folder. This caught me out in the past. - πͺπΉEthiopia tsega
Similar to #9, my issue was related to having a compatible Drush version to my Drupal.
See the Drush install page for details - https://www.drush.org/13.x/install/#drupal-compatibility