myxtype / eos-client

PHP library of simple and extensible to use eos rpc and offline signature.
46 stars 23 forks source link

'GuzzleHttp\\Client' not found #5

Closed mschoenebeck closed 3 years ago

mschoenebeck commented 3 years ago

When trying to use the Client I always get the above error. The thing is I have GuzzleHttp installed (version 7.3). I'm using php 7.2. This is the code:

require 'eos-client/src/Eos/Client.php'; use xtype\Eos\Client as EosClient; $client = new EosClient('https://eos.greymass.com');

Running composer update says everything is up to date. The full error:

PHP Fatal error: Uncaught Error: Class 'GuzzleHttp\\Client' not found in /home/mschoenebeck/eclipse-workspace/defi/eos-client/src/Eos/Client.php:37\nStack trace:\n#0 /home/mschoenebeck/eclipse-workspace/defi/sandbox.php(5): xtype\\Eos\\Client->__construct('https://eos.gre...')\n#1 {main}\n thrown in /home/mschoenebeck/eclipse-workspace/defi/eos-client/src/Eos/Client.php on line 37

Any ideas?

mschoenebeck commented 3 years ago

I solved the issue. I forgot to include the 'vendor/autoload.php'.