Guzzle: MAJOR_VERSION undefined class constant in src/utils.php

Created on 14 Aug 2020  路  3Comments  路  Source: guzzle/guzzle

Guzzle version(s) affected: *7.0.1
PHP version: 7.2.24
cURL version: 7.58.0

Description
Getting an undefined class constant error when running the "vendor/bin/wp theme update -all" command from this tutorial

How to reproduce
On GAE standard environment, activate the GCS plugin on the live site and try to run any update on the local version. The error does not exist when GCS plugin is deactivated on live site during updates.

Additional context
vendor/bin/wp theme update --all --path=my-wordpress-projectPHP Fatal error: Uncaught Error: Undefined class constant 'MAJOR_VERSION' in /home/val-wp/vendor/guzzlehttp/guzzle/src/Utils.php:121

Most helpful comment

Talk with the people writing that tutorial...

It seams like you have more than on guzzle installation loaded.

All 3 comments

This is not a bug?

Talk with the people writing that tutorial...

It seams like you have more than on guzzle installation loaded.

Just in case anyone bumps into this too:
In my root project I had guzzle 7 installed, but I also had a legacy subproject that was loaded with the root project that had guzzle 6 installed, upgrading it to 7 too fixed the problem.

Thanks @Nyholm for the tip.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

warroyo picture warroyo  路  4Comments

benswinburne picture benswinburne  路  3Comments

novuscom picture novuscom  路  3Comments

halfer picture halfer  路  4Comments

SharkIng picture SharkIng  路  3Comments