ErikBw / google-api-php-client

Automatically exported from code.google.com/p/google-api-php-client
Apache License 2.0
0 stars 0 forks source link

Do not throw exception when processing Batch return #418

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Today, when doing a Batch request and there is one error, the API is throwing 
an error, even if there is some success at Batch response.

The API could be changed to return the success results and the failures 
results, and not throw an exception

Original issue reported on code.google.com by eduardo....@dedalusprime.com.br on 31 Oct 2013 at 7:48

GoogleCodeExporter commented 8 years ago
I use the 0.6.7 with stable PHP 5.4.9.

I have 2 Errors (i think: same problem like before) with the 
batch-functionality:
I transfer a foreign google apps subscription to my Reseller Account. For 
multiple licenses is the "batch"-functionality needed. The transfer works fine 
or a single license with:

$result = $resellerService->subscriptions->insert('domain.com', 
$Google_Subscription, array('customerAuthToken' => 'DEDFF49E048BC20D'));

But It not works with (same like "examples/batch.php"):
$batch->add($resellerService->subscriptions->insert('domain.com', 
$Google_Subscription, array('customerAuthToken' => 'DEDFF49E048BC20D')));

1. Error:
Fatal error: Call to private method Google_CurlIO::parseResponseHeaders() from 
context 'Google_BatchRequest' in ...
There a 2 functions in "src/io/Google_CurlIO.php" with "Private" 
("parseHttpResponse", line 165 and "parseResponseHeaders", line 181 - i have it 
set to "public". It works, but if that is so correct?

2. Error: 
The error-description and the solution (it work for me) find here: - See the 
Google Groups Entry: 
https://groups.google.com/forum/#!searchin/google-api-php-client/batch|sort:rele
vance/google-api-php-client/MJquyMb1d0Q/wwQFuCk_KqgJ 

Please have a look at it. Thanks!

Original comment by f.naydow...@appsoffice.de on 19 Nov 2013 at 5:54

GoogleCodeExporter commented 8 years ago
Re that second point, that should be resolved in the alpha version on 
https://github.com/google/google-api-php-client/. Good point on the first part, 
will have a look at the error handling.

Original comment by ianbar...@google.com on 19 Nov 2013 at 1:50

GoogleCodeExporter commented 8 years ago
This issue tracker is now closing. Development on the Google PHP client library 
moved to GitHub with the release of the 1.0.0-alpha, and now the 1.0 branch has 
reached beta status there will be no further releases of the 0.6 branch of the 
library. 

Please take a look at the latest version on 
https://github.com/google/google-api-php-client

For information on migrating, please take a look at this guide: 
https://developers.google.com/api-client-library/php/guide/migration

For general library support please ask a question on StackOverflow: 
http://stackoverflow.com/questions/tagged/google-api-php-client

If you are looking for support with a specific API, please contact the team 
working with that API via StackOverflow or their preferred support mechanism. 

If your issue still exists with the new version of the library, please raise a 
bug in the GitHub issue tracker with a minimal code sample. 

Thanks!

Original comment by ianbar...@google.com on 22 Jan 2014 at 4:56

GoogleCodeExporter commented 8 years ago

Original comment by ianbar...@google.com on 22 Jan 2014 at 4:56