0

I am trying to import the config from another of my Drupal 9.1.4 projects with Composer / Drush (drush config-import from a folder source, all two websites on my local repository on Xampp), but a guzzlehttp/guzzle error is thrown in the middle of the process, whatever I try...

Error: Call to undefined method GuzzleHttp\Utils::chooseHandler() in GuzzleHttp\choose_handler() (line 61 of C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\guzzlehttp\guzzle\src\functions.php).

I have tried to reinstall everything from the beginning (including composer, drush, modules' dependencies...), to test with a fresh drupal/core install, to investigate guzzlehttp/guzzle dependencies, but at the end this error keeps showing up... Raaaaaahhhh !! I wonder if it could be related with multiple version requirements of guzzlehttp/guzzle caused by a faulty installation with consolidation/cgr in different places of my repository (i.e "6.5.5" in my project but "7.2" globally)?

When I try to update guzzlehttp/guzzle to 7.2 version in my project, the error message seems to confirm this, but I can't figure out what to do:

Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - drupal/core-recommended is locked to version 9.1.4 and an update of this package was not requested.
    - drupal/core-recommended 9.1.4 requires guzzlehttp/guzzle 6.5.5 -> found guzzlehttp/guzzle[6.5.5] but it conflicts with your root composer.json require (^7.2).
  Problem 2
    - drupal/core 9.1.4 requires guzzlehttp/guzzle ^6.5.2 -> found guzzlehttp/guzzle[6.5.2, ..., 6.5.x-dev] but it conflicts with your root composer.json require (^7.2).
    - drupal/views_url_path_arguments 1.1.0 requires drupal/core ^8 || ^9 -> satisfiable by drupal/core[9.1.4].
    - drupal/views_url_path_arguments is locked to version 1.1.0 and an update of this package was not requested.

Use the option --with-all-dependencies (-W) to allow upgrades, downgrades and removals for packages currently locked to specific versions.

Installation failed, reverting ./composer.json and ./composer.lock to their original content.

I'm a beginner with Composer / Drush-managed installs: some tips would be most welcome. Thank you by advance for your help!

If needed, here are my installed packages:

asm89/stack-cors                        1.3.0
clue/stream-filter                      v1.5.0
commerceguys/addressing                 v1.1.1
composer/installers                     v1.10.0
composer/semver                         3.2.2
davedevelopment/stiphle                 0.9.2
doctrine/annotations                    1.11.1
doctrine/cache                          1.10.2
doctrine/collections                    1.6.7
doctrine/common                         2.13.3
doctrine/event-manager                  1.1.1
doctrine/inflector                      1.4.3
doctrine/lexer                          1.2.1
doctrine/persistence                    1.3.8
doctrine/reflection                     1.2.2
drupal/address                          1.9.0
drupal/admin_toolbar                    3.0.0
drupal/advanced_text_formatter          2.0.0
drupal/allowed_formats                  1.3.0
drupal/asset_injector                   2.7.0
drupal/auto_entitylabel                 3.0.0-beta4
drupal/backup_migrate                   5.0.0-rc2
drupal/better_exposed_filters           5.0.0-beta1
drupal/boolean_single_state_formatter   1.1.0
drupal/bootstrap_business               1.0.0-beta4
drupal/calendar                         1.0.0-alpha3
drupal/calendar_datetime                1.0.0-alpha3
drupal/charts                           5.0.0-alpha2
drupal/color_field                      2.4.0
drupal/colorbox                         1.6.0
drupal/colorbutton                      1.2.0
drupal/composer_deploy                  1.6.0
drupal/conditional_fields               1.0.0-alpha10
drupal/config_update                    1.7.0
drupal/context                          4.0.0-beta5
drupal/core                             9.1.4
drupal/core-composer-scaffold           9.1.4
drupal/core-project-message             9.1.4
drupal/core-recommended                 9.1.4
drupal/core-vendor-hardening            9.1.4
drupal/crop                             2.1.0
drupal/css_editor                       1.3.0-rc1
drupal/csv_serialization                2.0.0
drupal/ctools                           3.4.0
drupal/custom_formatters                3.0.0-beta1
drupal/date_recur                       3.0.0
drupal/date_recur_modular               3.0.0
drupal/devel                            4.1.1
drupal/ds                               3.9.0
drupal/duration_field                   2.0.0
drupal/edux                             8.0.5
drupal/entity_browser                   2.5.0
drupal/entity_clone                     1.0.0-beta4
drupal/entity_reference_exposed_filters 1.0.0-alpha3
drupal/entity_reference_revisions       1.8.0
drupal/entity_update                    2.0.0-rc2
drupal/entity_usage                     2.0.0-beta3
drupal/eva                              2.1.0
drupal/feeds                            3.0.0-alpha10
drupal/feeds_ex                         1.0.0-alpha4
drupal/feeds_tamper                     2.0.0-beta2
drupal/field_delimiter                  1.1.0
drupal/field_group                      dev-3.x 9f59f95
drupal/field_group_table                dev-1.x 53814f5
drupal/file_mdm                         2.1.0
drupal/file_mdm_exif                    2.1.0
drupal/file_mdm_font                    2.1.0
drupal/filefield_sources                1.0.0-alpha4
drupal/focal_point                      1.5.0
drupal/focal_point_focus                1.10.0
drupal/geocoder                         3.14.0
drupal/geofield                         1.20.0
drupal/image_effects                    dev-3.x 82c47d5
drupal/inline_entity_form               1.0.0-rc8
drupal/jquery_ui                        1.4.0
drupal/jquery_ui_accordion              1.1.0
drupal/jquery_ui_datepicker             1.0.0
drupal/jquery_ui_draggable              1.2.0
drupal/jquery_ui_droppable              1.2.0
drupal/jquery_ui_slider                 1.1.0
drupal/jquery_ui_touch_punch            1.0.0
drupal/leaflet                          2.1.11
drupal/leaflet_geojson                  1.5.0
drupal/leaflet_more_maps                2.1.0
drupal/ludwig                           1.7.0
drupal/material_base                    1.8.0
drupal/media_entity_pinterest           2.5.0
drupal/migrate_plus                     5.1.0
drupal/migrate_source_csv               3.4.0
drupal/migrate_tools                    5.0.0
drupal/multiple_selects                 1.0.0
drupal/name                             1.0.0-rc3
drupal/node_export                      1.0.0-alpha1
drupal/office_hours                     1.3.0
drupal/optimizedb                       1.0.0-rc3
drupal/page_manager                     4.0.0-beta6
drupal/panelbutton                      1.3.0
drupal/panels                           4.6.0
drupal/paragraphs                       1.12.0
drupal/paragraphs_edit                  2.0.0-alpha8
drupal/paragraphs_ee                    1.7.0
drupal/paragraphs_features              1.11.0
drupal/pathauto                         1.8.0
drupal/pcr                              1.3.0
drupal/prepopulate                      2.3.0
drupal/range                            1.3.0
drupal/reference_table_formatter        1.1.0
drupal/require_on_publish               1.4.0
drupal/responsive_views_grid            dev-1.x b27f63a
drupal/rules                            dev-3.x 7d1833f
drupal/rules_token                      dev-1.x ad08411
drupal/search_api                       1.19.0
drupal/selective_better_exposed_filters 2.0.0-beta6
drupal/shs                              1.0.0-alpha5
drupal/smtp                             1.0.0
drupal/superfish                        1.4.0
drupal/svg_image                        1.14.0
drupal/table_field_group                dev-1.x be676c6
drupal/tamper                           1.0.0-alpha2
drupal/taxonomy_manager                 2.0.4
drupal/telephone_formatter              dev-1.x 0916a01
drupal/telephone_validation             2.3.0
drupal/term_reference_tree              1.0.0
drupal/thex                             8.0.6
drupal/token                            1.9.0
drupal/token_filter                     1.2.0
drupal/tvi                              1.0.0-rc2
drupal/typed_data                       1.0.0-alpha5
drupal/vefl                             3.0.0
drupal/viewfield                        3.0.0-beta6
drupal/views_accordion                  2.0.0
drupal/views_block_filter_block         1.0.0
drupal/views_bulk_edit                  2.5.0
drupal/views_bulk_operations            dev-3.x 84442e9
drupal/views_conditional                1.2.0
drupal/views_contextual_filters_or      1.2.0
drupal/views_data_export                1.0.0
drupal/views_entity_form_field          1.0.0-beta9
drupal/views_exposed_filter_blocks      1.1.0
drupal/views_field_formatter            1.13.0
drupal/views_field_view                 dev-1.x 91f01e9
drupal/views_fieldsets                  dev-3.x eea8080
drupal/views_flipped_table              1.4.0
drupal/views_geojson                    1.0.0
drupal/views_templates                  1.1.0
drupal/views_url_path_arguments         1.1.0
egulias/email-validator                 2.1.22
enshrined/svg-sanitize                  0.14.0
giggsey/libphonenumber-for-php          8.12.18
giggsey/locale                          1.9
guzzlehttp/guzzle                       6.5.5
guzzlehttp/promises                     1.4.0
guzzlehttp/psr7                         1.7.0
jetbrains/phpstorm-stubs                v2019.3
laminas/laminas-diactoros               2.5.0
laminas/laminas-escaper                 2.7.0
laminas/laminas-feed                    2.13.0
laminas/laminas-stdlib                  3.3.0
laminas/laminas-zendframework-bridge    1.1.1
league/csv                              9.6.2
lsolesen/pel                            0.9.10
masterminds/html5                       2.7.4
mehrpadin/superfish                     2.1
mtdowling/jmespath.php                  2.6.0
nikic/php-parser                        v4.10.4
pear/archive_tar                        1.4.12
pear/console_getopt                     v1.4.3
pear/pear-core-minimal                  v1.10.10
pear/pear_exception                     v1.0.1
phayes/geophp                           1.2
phenx/php-font-lib                      0.5.2
php-http/guzzle6-adapter                v2.0.1
php-http/httplug                        2.2.0
php-http/message                        1.11.0
php-http/message-factory                v1.0.2
php-http/promise                        1.1.0
phpdocumentor/reflection-common         2.2.0
phpdocumentor/reflection-docblock       5.2.2
phpdocumentor/type-resolver             1.4.0
phpmailer/phpmailer                     v6.2.0
psr/container                           1.0.0
psr/http-client                         1.0.1
psr/http-factory                        1.0.1
psr/http-message                        1.0.1
psr/log                                 1.1.3
querypath/querypath                     3.0.5
ralouphie/getallheaders                 3.0.3
rlanvin/php-rrule                       v1.6.3
roave/better-reflection                 4.3.0
roave/signature                         1.2.0
skaught/jquery-focuspoint               v1.1.3.1
softcreatr/jsonpath                     0.7.2
stack/builder                           v1.0.6
symfony-cmf/routing                     2.3.3
symfony/console                         v4.4.16
symfony/debug                           v4.4.16
symfony/dependency-injection            v4.4.16
symfony/error-handler                   v4.4.16
symfony/event-dispatcher                v4.4.16
symfony/event-dispatcher-contracts      v1.1.9
symfony/http-client-contracts           v2.3.1
symfony/http-foundation                 v4.4.16
symfony/http-kernel                     v4.4.16
symfony/mime                            v5.1.8
symfony/polyfill-ctype                  v1.20.0
symfony/polyfill-iconv                  v1.20.0
symfony/polyfill-intl-idn               v1.20.0
symfony/polyfill-intl-normalizer        v1.20.0
symfony/polyfill-mbstring               v1.20.0
symfony/polyfill-php72                  v1.22.1
symfony/polyfill-php73                  v1.22.1
symfony/polyfill-php80                  v1.20.0
symfony/process                         v4.4.16
symfony/psr-http-message-bridge         v2.0.2
symfony/routing                         v4.4.16
symfony/serializer                      v4.4.16
symfony/service-contracts               v2.2.0
symfony/translation                     v4.4.16
symfony/translation-contracts           v2.3.0
symfony/validator                       v4.4.16
symfony/var-dumper                      v5.1.8
symfony/yaml                            v4.4.16
twig/twig                               v2.14.1
typo3/phar-stream-wrapper               v3.1.6
webflo/drupal-finder                    1.2.2
webmozart/assert                        1.9.1
willdurand/geocoder                     4.4.0

EDIT 2021-02-17 at 1:39 PM (complete error message + 1 line before):

[notice] Synchronized configuration: create field.field.media.pinterest_post.feeds_item.
 [error]  Error: Call to undefined method GuzzleHttp\Utils::chooseHandler() in GuzzleHttp\choose_handler() (line 61 of C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\guzzlehttp\guzzle\src\functions.php) #0 C:\xampp\htdocs\D9e\vendor\guzzlehttp\guzzle\src\HandlerStack.php(42): GuzzleHttp\choose_handler()
#1 [internal function]: GuzzleHttp\HandlerStack::create()
#2 C:\xampp\htdocs\D9e\core\lib\Drupal\Component\DependencyInjection\Container.php(253): call_user_func_array(Array, Array)
#3 C:\xampp\htdocs\D9e\core\lib\Drupal\Component\DependencyInjection\Container.php(447): Drupal\Component\DependencyInjection\Container->createService(Array, 'private__2i5Fjk...')
#4 C:\xampp\htdocs\D9e\core\lib\Drupal\Component\DependencyInjection\Container.php(235): Drupal\Component\DependencyInjection\Container->resolveServicesAndParameters(Array)
#5 C:\xampp\htdocs\D9e\core\lib\Drupal\Component\DependencyInjection\Container.php(171): Drupal\Component\DependencyInjection\Container->createService(Array, 'http_client_fac...')
#6 C:\xampp\htdocs\D9e\core\lib\Drupal\Component\DependencyInjection\Container.php(432): Drupal\Component\DependencyInjection\Container->get('http_client_fac...', 1)
#7 C:\xampp\htdocs\D9e\core\lib\Drupal\Component\DependencyInjection\Container.php(247): Drupal\Component\DependencyInjection\Container->resolveServicesAndParameters(Array)
#8 C:\xampp\htdocs\D9e\core\lib\Drupal\Component\DependencyInjection\Container.php(171): Drupal\Component\DependencyInjection\Container->createService(Array, 'http_client')
#9 C:\xampp\htdocs\D9e\modules\contrib\feeds\src\Feeds\Fetcher\HttpFetcher.php(89): Drupal\Component\DependencyInjection\Container->get('http_client')
#10 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Plugin\Factory\ContainerFactory.php(21): Drupal\feeds\Feeds\Fetcher\HttpFetcher::create(Object(Drupal\Core\DependencyInjection\Container), Array, 'http', Array)
#11 C:\xampp\htdocs\D9e\modules\contrib\feeds\src\Plugin\Type\FeedsAnnotationFactory.php(21): Drupal\Core\Plugin\Factory\ContainerFactory->createInstance('http', Array)
#12 C:\xampp\htdocs\D9e\core\lib\Drupal\Component\Plugin\PluginManagerBase.php(83): Drupal\feeds\Plugin\Type\FeedsAnnotationFactory->createInstance('http', Array)
#13 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Plugin\DefaultSingleLazyPluginCollection.php(62): Drupal\Component\Plugin\PluginManagerBase->createInstance('http', Array)
#14 C:\xampp\htdocs\D9e\core\lib\Drupal\Component\Plugin\LazyPluginCollection.php(80): Drupal\Core\Plugin\DefaultSingleLazyPluginCollection->initializePlugin('http')
#15 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Plugin\DefaultSingleLazyPluginCollection.php(83): Drupal\Component\Plugin\LazyPluginCollection->get('http')
#16 C:\xampp\htdocs\D9e\modules\contrib\feeds\src\Feeds\FeedsSingleLazyPluginCollection.php(47): Drupal\Core\Plugin\DefaultSingleLazyPluginCollection->setConfiguration(Array)
#17 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Plugin\DefaultSingleLazyPluginCollection.php(99): Drupal\feeds\Feeds\FeedsSingleLazyPluginCollection->setConfiguration(Array)
#18 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Plugin\DefaultSingleLazyPluginCollection.php(55): Drupal\Core\Plugin\DefaultSingleLazyPluginCollection->addInstanceId('http', Array)
#19 C:\xampp\htdocs\D9e\modules\contrib\feeds\src\Feeds\FeedsSingleLazyPluginCollection.php(38): Drupal\Core\Plugin\DefaultSingleLazyPluginCollection->__construct(Object(Drupal\feeds\Plugin\Type\FeedsPluginManager), 'http', Array)
#20 C:\xampp\htdocs\D9e\modules\contrib\feeds\src\Entity\FeedType.php(534): Drupal\feeds\Feeds\FeedsSingleLazyPluginCollection->__construct(Object(Drupal\feeds\Plugin\Type\FeedsPluginManager), 'http', Array, Object(Drupal\feeds\Entity\FeedType))
#21 C:\xampp\htdocs\D9e\modules\contrib\feeds\src\Entity\FeedType.php(449): Drupal\feeds\Entity\FeedType->getPluginCollections()
#22 C:\xampp\htdocs\D9e\modules\contrib\feeds\src\Entity\FeedType.php(412): Drupal\feeds\Entity\FeedType->getPlugin('fetcher')
#23 C:\xampp\htdocs\D9e\modules\contrib\feeds\src\Entity\FeedType.php(562): Drupal\feeds\Entity\FeedType->getPlugins()
#24 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Entity\EntityStorageBase.php(494): Drupal\feeds\Entity\FeedType->preSave(Object(Drupal\Core\Config\Entity\ConfigEntityStorage))
#25 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Entity\EntityStorageBase.php(449): Drupal\Core\Entity\EntityStorageBase->doPreSave(Object(Drupal\feeds\Entity\FeedType))
#26 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Config\Entity\ConfigEntityStorage.php(263): Drupal\Core\Entity\EntityStorageBase->save(Object(Drupal\feeds\Entity\FeedType))
#27 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Entity\EntityBase.php(339): Drupal\Core\Config\Entity\ConfigEntityStorage->save(Object(Drupal\feeds\Entity\FeedType))
#28 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Config\Entity\ConfigEntityBase.php(591): Drupal\Core\Entity\EntityBase->save()
#29 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Config\Entity\ConfigEntityStorage.php(364): Drupal\Core\Config\Entity\ConfigEntityBase->save()
#30 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Config\ConfigImporter.php(990): Drupal\Core\Config\Entity\ConfigEntityStorage->importCreate('feeds.feed_type...', Object(Drupal\Core\Config\Config), Object(Drupal\Core\Config\Config))
#31 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Config\ConfigImporter.php(776): Drupal\Core\Config\ConfigImporter->importInvokeOwner('', 'create', 'feeds.feed_type...')
#32 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Config\ConfigImporter.php(603): Drupal\Core\Config\ConfigImporter->processConfiguration('', 'create', 'feeds.feed_type...')
#33 C:\xampp\htdocs\D9e\core\lib\Drupal\Core\Config\ConfigImporter.php(507): Drupal\Core\Config\ConfigImporter->processConfigurations(Array)
#34 C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\drush\drush\src\Drupal\Commands\config\ConfigImportCommands.php(335): Drupal\Core\Config\ConfigImporter->doSyncStep('processConfigur...', Array)
#35 C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\drush\drush\includes\drush.inc(206): Drush\Drupal\Commands\config\ConfigImportCommands->doImport(Object(Drupal\Core\Config\StorageComparer))
#36 C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\drush\drush\includes\drush.inc(197): drush_call_user_func_array(Array, Array)
#37 C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\drush\drush\src\Drupal\Commands\config\ConfigImportCommands.php(306): drush_op(Array, Object(Drupal\Core\Config\StorageComparer))
#38 [internal function]: Drush\Drupal\Commands\config\ConfigImportCommands->import(NULL, Array)
#39 C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\consolidation\annotated-command\src\CommandProcessor.php(257): call_user_func_array(Array, Array)
#40 C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\consolidation\annotated-command\src\CommandProcessor.php(212): Consolidation\AnnotatedCommand\CommandProcessor->runCommandCallback(Array, Object(Consolidation\AnnotatedCommand\CommandData))
#41 C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\consolidation\annotated-command\src\CommandProcessor.php(176): Consolidation\AnnotatedCommand\CommandProcessor->validateRunAndAlter(Array, Array, Object(Consolidation\AnnotatedCommand\CommandData))
#42 C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\consolidation\annotated-command\src\AnnotatedCommand.php(311): Consolidation\AnnotatedCommand\CommandProcessor->process(Object(Symfony\Component\Console\Output\ConsoleOutput), Array, Array, Object(Consolidation\AnnotatedCommand\CommandData))
#43 C:\xampp\htdocs\D9e\vendor\symfony\console\Command\Command.php(255): Consolidation\AnnotatedCommand\AnnotatedCommand->execute(Object(Drush\Symfony\DrushArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#44 C:\xampp\htdocs\D9e\vendor\symfony\console\Application.php(1027): Symfony\Component\Console\Command\Command->run(Object(Drush\Symfony\DrushArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#45 C:\xampp\htdocs\D9e\vendor\symfony\console\Application.php(273): Symfony\Component\Console\Application->doRunCommand(Object(Consolidation\AnnotatedCommand\AnnotatedCommand), Object(Drush\Symfony\DrushArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#46 C:\xampp\htdocs\D9e\vendor\symfony\console\Application.php(149): Symfony\Component\Console\Application->doRun(Object(Drush\Symfony\DrushArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#47 C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\drush\drush\src\Runtime\Runtime.php(118): Symfony\Component\Console\Application->run(Object(Drush\Symfony\DrushArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#48 C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\drush\drush\src\Runtime\Runtime.php(48): Drush\Runtime\Runtime->doRun(Array, Object(Symfony\Component\Console\Output\ConsoleOutput))
#49 C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\drush\drush\drush.php(72): Drush\Runtime\Runtime->run(Array)
#50 C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\drush\drush\drush(4): require('C:\\Users\\Clemen...')
#51 {main}.
Error: Call to undefined method GuzzleHttp\Utils::chooseHandler() in C:\Users\Clement\AppData\Roaming\Composer\global\drush\drush\vendor\guzzlehttp\guzzle\src\functions.php on line 61 #0 C:\xampp\htdocs\D9e\vendor\guzzlehttp\guzzle\src\HandlerStack.php(42): GuzzleHttp\choose_handler()
6
  • 1
    If you have multiple Drupal sites with different codebases and you are trying to import/export config between them, are they using the same versions of core/modules? Feb 17, 2021 at 10:24
  • I guess so. In my #2 site's root folder, I have started my migration by copying the composer.json file from site #1 in a brand new folder, then launched 'composer update'. It has successfully uploaded everything in "modules" and "libraries" subfolders. Is there a command to compare two installs or would I have to do it manually? (core, module and libraries versions, etc) Feb 17, 2021 at 10:44
  • I have created a brand new folder and made sure the installed modules and libraries are of identical versions than site #1. After launching the drush cim command, the import is processed but - again - interrupted by the same error. Please see at the bottom of my question where I will copy/edit the complete error exerpt. Feb 17, 2021 at 12:38
  • Do you get the same error if you import the config in the UI instead of with Drush? Feb 17, 2021 at 12:45
  • Ok, this time it worked through UI config import! (previously I ran in a memory limit issue in the middle of the batch process). Feb 17, 2021 at 14:51

3 Answers 3

0

I have succeeded in re-importing my config and content through the UI instead of drush, on the advice of @patrick-kenny. (That's what I tried at first but a memory limit issue incited me to try the drush config-import way)

Here is what I did:

  • created a new root folder, copied composer.json file from site #1
  • command 'composer update'
  • installed the site through the UI
  • removed manually default shortcut links in the UI
  • copied uuid from system.site.yml to my new site with command 'drush cset'
  • copied subfolders "libraries" and "default/files" from site #1
  • runned config import from file in the UI
  • imported database from #1

...and now everything seems at its right place!

This said, I will not be completely at ease until I understand precisely what's wrong with my drush setup...

Thank you for your kind help, Patrick!

0

I had the same error using a simple vanilla 9 version of Drupal, when using my computer's drush to run the site-install command.

I overcame this problem by requiring drush in the project and using it.

$ drush si
...
Error: Call to undefined method GuzzleHttp\Utils::chooseHandler()
$ composer require drush/drush
$ ./vendor/bin/drush si
 ...
Success!
0

I was having same issue (same error message) on my LANDO local instance.

Here is my file structure i.e

My-Project/lando.yml
My-Project/composer.json
My-Project/docroot

'docroot' folder has drupal core files/folders.

I was using composer to install drush (composer require drush/drush) at this path 'My-Project/composer.json' which executes other drush commands fine except 'drush cim' was generating errors.

When I used 'My-Project/docroot/composer.json' path instead, 'drush cim' works absolutely fine without any error.

In short, we should use composer.json file which comes with drupal core to install drush and this should fix this issue.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.