• I’m running the following command:
    WP_CLI_PHP_ARGS=’-d include_path=vendor/google/appengine-php-sdk’ vendor/bin/wp –path=my-wordpress-project plugin list

    And I’m getting the following error:

    PHP Fatal error:  Uncaught Error: Call to undefined method GuzzleHttp\Utils::chooseHandler() in $PROJECT_DIR/vendor/guzzlehttp/guzzle/src/functions.php:61
    Stack trace:
    #0 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/vendor/guzzlehttp/guzzle/src/HandlerStack.php(42): GuzzleHttp\choose_handler()
    #1 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/vendor/guzzlehttp/guzzle/src/Client.php(65): GuzzleHttp\HandlerStack::create()
    #2 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/vendor/google/auth/src/HttpHandler/HttpHandlerFactory.php(33): GuzzleHttp\Client->__construct()
    #3 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/gcs.php(124): Google\Auth\HttpHandler\HttpHandlerFactory::build()
    #4 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/gcs.php(42): Google\Cloud\Storage\WordPress\get_google_storage_client()
    #5 $PROJECT_DIR/my-wordpress-project/wp-settings.php(391): include_once('/home/yar/yaraj...')
    #6 /home/yar/yaraj in $PROJECT_DIR/vendor/guzzlehttp/guzzle/src/functions.php on line 61
    Fatal error: Uncaught Error: Call to undefined method GuzzleHttp\Utils::chooseHandler() in $PROJECT_DIR/vendor/guzzlehttp/guzzle/src/functions.php:61
    Stack trace:
    #0 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/vendor/guzzlehttp/guzzle/src/HandlerStack.php(42): GuzzleHttp\choose_handler()
    #1 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/vendor/guzzlehttp/guzzle/src/Client.php(65): GuzzleHttp\HandlerStack::create()
    #2 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/vendor/google/auth/src/HttpHandler/HttpHandlerFactory.php(33): GuzzleHttp\Client->__construct()
    #3 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/gcs.php(124): Google\Auth\HttpHandler\HttpHandlerFactory::build()
    #4 $PROJECT_DIR/my-wordpress-project/wp-content/plugins/gcs/gcs.php(42): Google\Cloud\Storage\WordPress\get_google_storage_client()
    #5 $PROJECT_DIR/my-wordpress-project/wp-settings.php(391): include_once('/home/yar/yaraj...')
    #6 /home/yar/yaraj in $PROJECT_DIR/vendor/guzzlehttp/guzzle/src/functions.php on line 61
    Error: There has been a critical error on this website.Learn more about troubleshooting WordPress. There has been a critical error on this website.

    Here is my composer.json:

    {
        "require": {
            "google/cloud-tools": "^0.12.0",
            "wp-cli/wp-cli-bundle": "^2.5"
        },
        "require-dev": {
            "google/appengine-php-sdk": "^1.9"
        }
    }

    Please let me know if it will help for me to provide any other info/details to identify the problem.

    Thank you in advance!

  • The topic ‘GuzzleHTTP Critical Error when trying to list plugins’ is closed to new replies.