Hi Martin,

Please see this example as a reference:

try:
  page = campaign_service.get(selector)
except AdWordsGoogleInternalError, e:
  inner_error = e.errors[0]
  if 'RateExceededError.RATE_EXCEEDED' == inner_error.errorString:
    // do something with inner_error.retryAfterSeconds


-Danial, AdWords API Team.


On Thursday, January 16, 2014 9:45:22 PM UTC+4, Martin wrote:
>
> Hi,
> I am getting the RateExceededError and according to the suggestions I want 
> to catch this exception and respect the 'retryAfterSeconds' attribute.
> However I am failing to catch just this particular exception and leaving 
> the rest to be handled with my generic error handler.
>
> I tried to do something like this:
> try:
>     working_code()
> except RateExceededError as Rate_e:
>     time.sleep(Rate_e.retryAfterSeconds)
>
> but this does not work.
> Is there some Exceptions import I am missing or is there another way of 
> doing it?
> Thank you!
> Martin
>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog and discussion group:
http://googleadsdeveloper.blogspot.com
http://groups.google.com/group/adwords-api
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API Forum" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/adwords-api?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"AdWords API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to