Closed tobilektri closed 5 years ago
I get the following on Ubuntu 18.04 x64 with PHP 7.2.10-0ubuntu0.18.04.1
PHP Fatal error: Uncaught InvalidArgumentException: missing the required redirect URI in /var/www/html/vendor/google/auth/src/OAuth2.php:650
Stack trace:
#0 /var/www/html/vendor/google/apiclient/src/Google/Client.php(339): Google\Auth\OAuth2->buildFullAuthorizationUri(Array)
#1 /var/www/html/quickstart.php(38): Google_Client->createAuthUrl()
#2 /var/www/html/quickstart.php(63): getClient()
#3 {main}
thrown in /var/www/html/vendor/google/auth/src/OAuth2.php on line 650
Got this error Microsoft Windows [Version 6.1.7601] Copyright (c) 2009 Microsoft Corporation. All rights reserved. `` Fatal error: Uncaught Error: Class 'Google_Client' not found in C:\xampp\phpMyAd min\quickstart.php:14 Stack trace:
thrown in C:\xampp\phpMyAdmin\quickstart.php on line 14
@tobilektri
Had exactly the same issue running php 7.2
I had to edit the CurlFactory.php file at C:\Users[...]\vendor\guzzlehttp\guzzle\src\Handler\CurlFactory.php on line 67
I had to cast the Object($this->handles) to an array:
I changed this:
if (count($this->handles) >= $this->maxHandles) { curl_close($resource);
to this:
$arrayHandle = (array)$this->handles; if (count($arrayHandle) >= $this->maxHandles) { curl_close($resource); } else {
This clear the error after re-entering the verification code, but then I go another message from my command line which am not sure its an error or warning or something else:
_Files: SAMVIC (1V8W0SguM210_nCZt5ZqtLUXSWa9TwS4Q) upgrade_221.html (1pwXW1bMjbcsaDa6izVIziSMBsWbEsFLX) upgrade_222.html (1shJX1DPaMdYOg_e6F5_NWdG8sPYGPF1i) pdo_sqlsrv_forge.php (1c7fw7CqYjTMPsXT5f_QfP-sxVE8PK3iP) pdo_sqlsrv_driver.php (1BcbnnXWoPA0M6mjIVRAs34Cig4UNlDjG) pdo_sqlite_forge.php (1ABhavgNtd2qHESJ06kwCPxQhjf9wWhn9) pdo_sqlite_driver.php (1ytHpG4AQF_ZXrTKu2nZjHV73zJauxPoo) pdo_odbc_forge.php (1VrsFMXtxDtCn9VWHS1pCE4jTrJ6U4yWX) pdo_odbc_driver.php (1RS9lM5EcgvTlX9Ay69lxpMwSCdH_k4if) pdo_oci_forge.php (1wolDrzxAvQXqHOSfjZBTHcMtKKsutQ3)
Well, I guess I have to find out when I run some other code.. Cheers.
This appears to be the same problem reported here:
https://github.com/googleapis/google-api-php-client/issues/1507
They claim the issue was fixed in version 2.2.2 of the google/apiclient dependency. Can you try updating to that version and let me know if it works? If so I can update the version dependency in the instructions.
@erickoledadevrel Thanks for the share. It seems like I have to manually update the guzzle folder.
code download php error Fatal error: Uncaught exception 'Google_Service_Exception' with message '{ "error": { "errors": [ { "domain": "global", "reason": "fileNotExportable", "message": "Export only supports Google Docs." } ], "code": 403, "message": "Export only supports Google Docs." } } ' in C:\AppServ\www\google\vendor\google\apiclient\src\Google\Http\REST.php:118 Stack trace:
Is there a solution? Please help.
ในวันที่ พฤ. 28 มี.ค. 2019 เวลา 23:43 Eric Koleda notifications@github.com เขียนว่า:
Closed #29 https://github.com/gsuitedevs/php-samples/issues/29.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/gsuitedevs/php-samples/issues/29#event-2236914983, or mute the thread https://github.com/notifications/unsubscribe-auth/AuX27M-y6LmHyT1e-nT_ntl3rV__dvoXks5vbPEZgaJpZM4X95_K .
Your problem isn't related to this issue. As the error message says, the file you are trying to export can't be exported.
Expected Behavior
Runs throught example without errors
Actual Behavior
Problems with required Guzzle Client...
PHP Warning: count(): Parameter must be an array or an object that implements Countable in C:\Users[...]\vendor\guzzlehttp\guzzle\src\Handler\CurlFactory.php on line 67
Warning: count(): Parameter must be an array or an object that implements Countable in C:\Users[...]\vendor\guzzlehttp\guzzle\src\Handler\CurlFactory.php on line 67
Steps to Reproduce the Problem
Specifications
php -v
):PHP 7.2.5 (cli)