RateExceededError

2019-03-14 Thread Stella
Hi, I am migrating the paid search account extendedTextAd and encountered 
below RateExceedeError. Want to confirm the meaning of 
“retryAfterSeconds=86400”. 
Q1. Does that mean I can not upload w/i 24 h?

Q2. If so, I am hoping to know the exact amount limitation of request 
activity since this migration process is stucked the middle. 

I am already passing multiple AdGroupAdOperation in one shot based on 
BatchingRequest 
(https://developers.google.com/adwords/api/docs/guides/rate-limits#take_control).
 
But that does not work.
I have AdGroupAdService mutate request(about 10k) and also 
ad_group_ad_service select request(about 200k), which does not seems a lot. 
Q3.What is the best option to go for this situation?

Q4. Is this cap related with the whole account including UI operations and 
Adwords Editor operation? 
Q5. Should our company’s Google account manager be able to provide some 
source to optimize current request? We really need to get this work asap.

A lot of questions, appreciate you patient in advance. Thanks.


ads_uploaded = ad_group_ad_service.mutate(add_adgroup_operations)['value']
[2019-03-13 23:28:37,134 - googleads.soap - INFO] Request made: Service: 
"AdGroupAdService" Method: "mutate" URL: 
"https://adwords.google.com/api/adwords/cm/v201809/AdGroupAdService;
[2019-03-13 23:28:37,382 - googleads.soap - WARNING] Error summary: 
{'faultMessage': '[RateExceededError ]', 'requestId': 
'0005840808496c9a0ae9f205970eea1c', 'serviceName': 'AdGroupAdService', 
'methodName': 'mutate', 'operations': '4', 'responseTime': '132'}
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/googleads/common.py", line 
1377, in MakeSoapRequest
*packed_args, _soapheaders=soap_headers)['body']['rval']
  File "/usr/local/lib/python3.6/site-packages/zeep/client.py", line 45, in 
__call__
self._op_name, args, kwargs)
  File "/usr/local/lib/python3.6/site-packages/zeep/wsdl/bindings/soap.py", 
line 121, in send
return self.process_reply(client, operation_obj, response)
  File "/usr/local/lib/python3.6/site-packages/zeep/wsdl/bindings/soap.py", 
line 186, in process_reply
return self.process_error(doc, operation)
  File "/usr/local/lib/python3.6/site-packages/zeep/wsdl/bindings/soap.py", 
line 291, in process_error
detail=fault_node.find('detail'))
zeep.exceptions.Fault: [RateExceededError ]
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File 
"/Users/stellayang/Library/Python/3.6/lib/python/site-packages/IPython/core/interactiveshell.py",
 
line 2881, in run_code
exec(code_obj, self.user_global_ns, self.user_ns)
  File "", line 1, in 
ads_uploaded = 
ad_group_ad_service.mutate(add_adgroup_operations)['value']
  File "/usr/local/lib/python3.6/site-packages/googleads/common.py", line 
1389, in MakeSoapRequest
e.detail, errors=error_list, message=e.message)
googleads.errors.GoogleAdsServerFault: [RateExceededError 
]

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/e84ba5c9-791c-496e-b400-aeebcbf0f759%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Can AdId be reused to copy over ads across adgroup?

2019-02-21 Thread Stella
hi,
I am trying to migrate TextAd from one adgroup to another adgroup in the 
same campaign. Trying to figure out if there is any easy way to do that, 
other than copy over all values in TextAd.

I saw some related discussion on "Ids and mutating ads”, it seems when 
cloning camapign, a AdId can be reused. So wonder if anyway to reuse ad (by 
calling AdId) ?
Given (AdGroupId, AdId) pair is globally unique, can I ‘ADD' an ad by AdId 
to an existing AdGroupId?

Thanks!

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/bd9905d6-5764-4c6b-bf31-f50d26a8e334%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Where to get adcopies? AdGroupAdService or AdGroupExtensionSettingService

2019-02-05 Thread Stella
Hey, 
I am trying to pull existing adcopies from adgroup. 
Noticed AdGroupAdService and AdGroupExtensionSettingService are possible 
right service to use. However, when I am filering with a particular 
ad_group_id nothing is returned. But I can see ad extention for the adgroup 
from UI. 
1) Is there anything need to be modified from below code? 
2) when I add ExpandedTextAdDescription2 in get_adservice_adgroup() i got 
“googleads.errors.GoogleAdsServerFault: [SelectorError.INVALID_FIELD_NAME @ 
serviceSelector; trigger:'ExpandedTextAdDescription2']
“. However, that field is available in web 
https://developers.google.com/adwords/api/docs/appendix/selectorfields#v201809-AdGroupExtensionSettingService
 
. Any idea why this error still pop up?

I am quite new to adgroup service. Thank you very much


def get_adservice_adgroup(ad_group_ad_service, ad_group_id):

selector = {
'fields': ['Id', 'AdGroupId', 'AdType', 'Automated'
, 'Headline' , 'HeadlinePart1' , 'HeadlinePart2'\
, 'Description', 'Description1', 'Description2' \
# , 'ExpandedTextAdDescription2' \
, 'DisplayUrl', 'Url' \
, 'PromoText' , 'TemplateId'

   ]
, 'predicates': [
{'field': 'AdGroupId',
 'operator': 'EQUALS',
 'values': [ad_group_id]
 }
]

}

ad_group_ad_result = ad_group_ad_service.get(selector)['entries']

return ad_group_ad_result

def get_adextention_adgroup(ad_group_ad_service, ad_group_id):

selector = {
'fields': ['AdGroupId', 'ExtensionType'
, 'Extensions', 'PlatformRestrictions'
   ]
, 'predicates': [
{'field': 'AdGroupId',
 'operator': 'EQUALS',
 'values': [ad_group_id]
 }
]

}

ad_extension_result = ad_extension_service.get(selector)['entries']
return ad_extension_result


ad_group_ad_service = client.GetService('AdGroupAdService', version='v201809')
ad_extension_service = client.GetService('AdGroupExtensionSettingService', 
version='v201809')



-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/9f8baff2-b709-4432-8a60-7e4ae04896b1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Get readout from AdGroupCriterionService selector

2019-01-14 Thread Stella
Hi,  I am using 201809 version of adwords. trying to first get and then 
modify bidding at adgroup level. 
My CAMPAIGN_ID=1647087544 is one with tcpa set 
with biddingStrategySource=CAMPAIGN level. I believe in that way I can see 
the bidsCPA value. however, the ‘bids’ field is returned as empty. I get 
returns like this

Your doc, does not tell me how to access to “bids” field, can you tell me 
specificlly how based on below code?
https://developers.google.com/adwords/api/docs/appendix/selectorfields#v201809 

Thank you

def main(client, campaign_id):

  # Initialize appropriate service.

  ad_group_service = client.GetService('AdGroupCriterionService', 
version='v201809')
  offset = 0
  # Construct selector and get all ad groups.
  selector = {
  'fields': [
  'AdGroupId','BaseCampaignId','QualityScore' 
  
,'BiddingStrategyId','BiddingStrategyName','BiddingStrategySource','BiddingStrategyType'
 ],
  'predicates': [
  {
  'field': 'CampaignId',
  'operator': 'EQUALS',
  'values': [campaign_id]
  }
  ],
  'paging': {
  'startIndex': str(offset),
  'numberResults': str(PAGE_SIZE)
  }
  }

  more_pages = True
  while more_pages:
page = ad_group_service.get(selector)

# Display results.
if 'entries' in page:
  for ad_group in page['entries']:
print(ad_group)
else:
  print ('No ad groups were found.')
offset += PAGE_SIZE

selector['paging']['startIndex'] = str(offset)
more_pages = offset < int(page['totalNumEntries'])

if __name__ == '__main__':
  # Initialize client object.
  adwords_client = adwords.AdWordsClient.LoadFromStorage()
  main(adwords_client, CAMPAIGN_ID)


-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/528ff8f4-d455-4259-985d-cf33ee38f0dd%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


TrialAsyncErrorService: Could not retrieve errors for trial

2018-12-02 Thread Stella

Hi, 
I am creating trials from draft, which the same approach used to be 
successful before. However, not stable, I can tell it’s failed, the 
TrialAsyncErrorService could not return me why it’s failed. 
1) I can’t see fail reason under my acount even from chrome browser. In 
that case, how to make corrections and get successful ones pushed?

2) when get into CREATION_FAILED status, anyway to turn the existing trial 
to “active” w/o recreating the same trailf from draft (that will lead to 
conflict duplicate name to existing failed trial)? 

Out[77]: 
{
'id': 11437957,
'baseCampaignId': x,
'draftId': None,
'budgetId': None,
'name': None,
'startDate': None,
'endDate': None,
'trafficSplitPercent': None,
'status': 'CREATION_FAILED',
'trialCampaignId': xx
}

trial_async_error_service = client.GetService('TrialAsyncErrorService', 
version='v201806')

selector = {
'fields': ['TrialId', 'AsyncError'],
'predicates': [{
'field': 'TrialId',
'operator': 'IN',
'values': [11437957]
}]
}
trial_error_selector = trial_async_error_service.get(selector)['entries']

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/d633bcf9-108b-4035-9743-c93831b99f8c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: TrialService InternalApiError.UNEXPECTED_INTERNAL_API_ERROR

2018-10-02 Thread Stella
Yes, this is the same one. I could not immediately see what has been 
posted, and thought that was not successful 

On Sunday, September 30, 2018 at 11:04:11 PM UTC-7, Dannison Yao (AdWords 
API Team) wrote:
>
> Hi,
>
> It appears that this post is related to this thread 
> <https://groups.google.com/d/msgid/adwords-api/12294bc9-ed2e-4742-8fa0-6fab5951c9f2%40googlegroups.com>.
>  
> You may refer to the link provided for my response and to better track our 
> communication.
>
> Regards,
> Dannison
> AdWords API Team
>
> On Saturday, September 29, 2018 at 3:51:27 AM UTC+8, Stella wrote:
>>
>> Hi, I’ve checked provious dicussion the group, here is my code of 
>> following instructions of logging.
>>
>> I have used this code to create trial campaign 2weeks ago and it worked 
>> well. Now get below error, and I get no more logging when after following 
>> instructions.
>>
>> https://developers.google.com/adwords/api/docs/guides/campaign-drafts-experiments
>>
>> https://github.com/googleads/googleads-python-lib/tree/b80b8b3741a55f1d00c5974bc58f92540663c6f6#user-content-how-do-i-log-soap-interactions
>>
>> trial = {
>> 'draftId': available_pool.loc[index]['draftId'],
>> 'baseCampaignId': available_pool.loc[index]['draft_campaign_id'],
>> 'name': '%s_value' %available_pool.loc[index]['CampaignName'],
>> 'trafficSplitPercent': 30,
>> 'startDate': '2018-10-01',
>> 'endDate': '2019-01-26'
>> }
>> trial_operation = {'operator': 'ADD', 'operand': trial}
>>
>> import logging
>> logging.basicConfig(level=logging.INFO)
>> logging.getLogger('suds.transport').setLevel(logging.DEBUG)
>>
>> trial_result = trial_service.mutate([trial_operation])
>>
>>
>> [WARNING] 2018-09-28 09:18:55,308 googleads.soap(363): Error summary: 
>> {'faultMessage': '[InternalApiError.UNEXPECTED_INTERNAL_API_ERROR @ 
>> com.google.ads.api.services.common.error.InternalApiError.(InternalApiErro]',
>>  
>> 'requestId': '000576f0cfd8ecd00a37ac0b110b3534', 'serviceName': 
>> 'TrialService', 'methodName': 'mutate', 'operations': '1', 'responseTime': 
>> '337'}
>> Traceback (most recent call last):
>>   File "/usr/local/lib/python3.6/site-packages/googleads/common.py", line 
>> 1371, in MakeSoapRequest
>> *packed_args, _soapheaders=soap_headers)['body']['rval']
>>   File "/usr/local/lib/python3.6/site-packages/zeep/client.py", line 45, 
>> in __call__
>> self._op_name, args, kwargs)
>>   File 
>> "/usr/local/lib/python3.6/site-packages/zeep/wsdl/bindings/soap.py", line 
>> 121, in send
>> return self.process_reply(client, operation_obj, response)
>>   File 
>> "/usr/local/lib/python3.6/site-packages/zeep/wsdl/bindings/soap.py", line 
>> 186, in process_reply
>> return self.process_error(doc, operation)
>>   File 
>> "/usr/local/lib/python3.6/site-packages/zeep/wsdl/bindings/soap.py", line 
>> 291, in process_error
>> detail=fault_node.find('detail'))
>> zeep.exceptions.Fault: [InternalApiError.UNEXPECTED_INTERNAL_API_ERROR @ 
>> com.google.ads.api.services.common.error.InternalApiError.(InternalApiErro]
>> During handling of the above exception, another exception occurred:
>> Traceback (most recent call last):
>>   File 
>> "/Users/stellayang/Library/Python/3.6/lib/python/site-packages/IPython/core/interactiveshell.py",
>>  
>> line 2881, in run_code
>> exec(code_obj, self.user_global_ns, self.user_ns)
>>   File "", line 15, in 
>> trial_result = trial_service.mutate([trial_operation])['value']
>>   File "/usr/local/lib/python3.6/site-packages/googleads/common.py", line 
>> 1383, in MakeSoapRequest
>> e.detail, errors=error_list, message=e.message)
>> googleads.errors.GoogleAdsServerFault: 
>> [InternalApiError.UNEXPECTED_INTERNAL_API_ERROR @ 
>> com.google.ads.api.services.common.error.InternalApiError.(InternalApiErro]
>>
>>
>>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/ed1fd20c-3a66-4807-8bf5-7c1ed253280c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: UNEXPECTED_INTERNAL_API_ERROR retrieving callout extensions

2018-09-28 Thread Stella
hi Sreelakshmi,
I am trying to do the same thing as the poster.
Can you share about the right way to get soap log?
I am using below, but could not find extra log.
Thank you, Stella

import logging
logging.basicConfig(level=logging.INFO)
logging.getLogger('suds.transport').setLevel(logging.DEBUG)


trial_result = trial_service.mutate([trial_operation_set])


On Friday, August 24, 2018 at 2:51:50 PM UTC-7, Sreelakshmi Sasidharan 
(AdWords API Team) wrote:
>
> Hi Marcel,
>
> Your SOAP logs looks fine to me. The UNEXPECTED_INTERNAL_API_ERROR could 
> be due to a transient issue. Could you please confirm if you are seeing 
> this issue on retry? If so, could you give a try with a lesser number of 
> results like 100? If that request is failing, please share the SOAP logs of 
> that operation. We should be able to take a closer look with that. 
>
> Thanks,
> Sreelakshmi, AdWords API Team
>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/4eacb0a3-93d0-46e3-88ff-76a9bdad542b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: UNEXPECTED_INTERNAL_API_ERROR

2018-09-28 Thread Stella
hi Teja, 
I’d like to add some SOAP logs.  Following this instruction: 
https://github.com/googleads/googleads-python-lib/tree/b80b8b3741a55f1d00c5974bc58f92540663c6f6#user-content-how-do-i-log-soap-interactions
I ran this before call my service fn, I did not see more log pop up, this 
is right?

import logging
logging.basicConfig(level=logging.INFO)
logging.getLogger('suds.transport').setLevel(logging.DEBUG)

trial_result = trial_service.mutate([trial_operation_set])

Thanks ,Stella
On Thursday, June 28, 2018 at 2:27:50 PM UTC-7, Teja Makani wrote:
>
> Hello,
>
> There was an issue this morning. Our servers faced severe latency issues 
> resulting InternalApiError.UNEXPECTED_INTERNAL_API_ERROR 
> <https://developers.google.com/adwords/api/docs/common-errors#InternalApiError.UNEXPECTED_INTERNAL_API_ERROR>
>  to 
> some users. The issue should be resolved by now. If you are still facing 
> the issues, please share the SOAP logs of the failed request. That would 
> help us with the investigation. You could *reply privately to author *while 
> sharing the SOAP logs. Please let me know if you have any further 
> questions. 
>
> Regards,
> Sai Teja, AdWords API Team.
>

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/d77ccf69-c7d2-4d9d-a2c1-cf39f7723526%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


TrialService InternalApiError.UNEXPECTED_INTERNAL_API_ERROR

2018-09-28 Thread Stella
Hi, I’ve checked provious dicussion the group, here is my code of following 
instructions of logging.

I have used this code to create trial campaign 2weeks ago and it worked 
well. Now get below error, and I get no more logging when after following 
instructions.
https://developers.google.com/adwords/api/docs/guides/campaign-drafts-experiments
https://github.com/googleads/googleads-python-lib/tree/b80b8b3741a55f1d00c5974bc58f92540663c6f6#user-content-how-do-i-log-soap-interactions

trial = {
'draftId': available_pool.loc[index]['draftId'],
'baseCampaignId': available_pool.loc[index]['draft_campaign_id'],
'name': '%s_value' %available_pool.loc[index]['CampaignName'],
'trafficSplitPercent': 30,
'startDate': '2018-10-01',
'endDate': '2019-01-26'
}
trial_operation = {'operator': 'ADD', 'operand': trial}

import logging
logging.basicConfig(level=logging.INFO)
logging.getLogger('suds.transport').setLevel(logging.DEBUG)

trial_result = trial_service.mutate([trial_operation])


[WARNING] 2018-09-28 09:18:55,308 googleads.soap(363): Error summary: 
{'faultMessage': '[InternalApiError.UNEXPECTED_INTERNAL_API_ERROR @ 
com.google.ads.api.services.common.error.InternalApiError.(InternalApiErro]',
 
'requestId': '000576f0cfd8ecd00a37ac0b110b3534', 'serviceName': 
'TrialService', 'methodName': 'mutate', 'operations': '1', 'responseTime': 
'337'}
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/googleads/common.py", line 
1371, in MakeSoapRequest
*packed_args, _soapheaders=soap_headers)['body']['rval']
  File "/usr/local/lib/python3.6/site-packages/zeep/client.py", line 45, in 
__call__
self._op_name, args, kwargs)
  File "/usr/local/lib/python3.6/site-packages/zeep/wsdl/bindings/soap.py", 
line 121, in send
return self.process_reply(client, operation_obj, response)
  File "/usr/local/lib/python3.6/site-packages/zeep/wsdl/bindings/soap.py", 
line 186, in process_reply
return self.process_error(doc, operation)
  File "/usr/local/lib/python3.6/site-packages/zeep/wsdl/bindings/soap.py", 
line 291, in process_error
detail=fault_node.find('detail'))
zeep.exceptions.Fault: [InternalApiError.UNEXPECTED_INTERNAL_API_ERROR @ 
com.google.ads.api.services.common.error.InternalApiError.(InternalApiErro]
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
  File 
"/Users/stellayang/Library/Python/3.6/lib/python/site-packages/IPython/core/interactiveshell.py",
 
line 2881, in run_code
exec(code_obj, self.user_global_ns, self.user_ns)
  File "", line 15, in 
trial_result = trial_service.mutate([trial_operation])['value']
  File "/usr/local/lib/python3.6/site-packages/googleads/common.py", line 
1383, in MakeSoapRequest
e.detail, errors=error_list, message=e.message)
googleads.errors.GoogleAdsServerFault: 
[InternalApiError.UNEXPECTED_INTERNAL_API_ERROR @ 
com.google.ads.api.services.common.error.InternalApiError.(InternalApiErro]


-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/d2f278e1-ff3f-4a4e-98ed-ad0c53950cf7%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


TrialService gets UNEXPECTED_INTERNAL_API_ERROR (related with MakeSoapRequest)

2018-09-28 Thread Stella


Hi,

I am using the TrialService. It runs well for once two weeks ago when I 
create a trial through version=‘v201806’

But I did run into “InternalApiError.UNEXPECTED_INTERNAL_API_ERROR" today 
trying to  for one of my campaigns. I am following the same python demo 
here: 
https://developers.google.com/adwords/api/docs/guides/campaign-drafts-experiments

I got warnings and error :

[WARNING] 2018-09-28 08:12:42,534 googleads.soap(363): Error summary: 
{'faultMessage': '[InternalApiError.UNEXPECTED_INTERNAL_API_ERROR @ 
com.google.ads.api.services.common.error.InternalApiError.(InternalApiErro]',
 
'requestId': ‘xx', 'serviceName': 'TrialService', 'methodName': 
'mutate', 'operations': '1', 'responseTime': '245'}
During handling of the above exception, another exception occurred:
...in MakeSoapRequest e.detail, errors=error_list, message=e.message)
googleads.errors.GoogleAdsServerFault: 
[InternalApiError.UNEXPECTED_INTERNAL_API_ERROR @ 
com.google.ads.api.services.common.error.InternalApiError.(InternalApiErro]

Have also tryied logging according to a instruction in the group,but no 
more things pop up.  Please help take a look. Thank you

This is the code I am using:

trial_service = client.GetService('TrialService', version='v201806')

trial_async_error_service = client.GetService('TrialAsyncErrorService', 
version='v201806’)

trial = {
'draftId': draftId,

'baseCampaignId': baseCampaignId,

'name': '%s_trial' %CampaignName,
'trafficSplitPercent': 50,
'startDate':’2019-01-01',
'endDate':'2020-01-01'
}

trial_operation = {'operator': 'ADD', 'operand': trial}
trial_result = trial_service.mutate([trial_operation])['value’]


import logging
logging.basicConfig(level=logging.INFO)
logging.getLogger('suds.transport').setLevel(logging.DEBUG)
trial_result = trial_service.mutate([trial_operation])

-- 
-- 
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
Also find us on our blog:
https://googleadsdeveloper.blogspot.com/
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~

You received this message because you are subscribed to the Google
Groups "AdWords API and Google Ads API Forum" group.
To post to this group, send email to adwords-api@googlegroups.com
To unsubscribe from this group, send email to
adwords-api+unsubscr...@googlegroups.com
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 and Google Ads API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to adwords-api+unsubscr...@googlegroups.com.
Visit this group at https://groups.google.com/group/adwords-api.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/adwords-api/12294bc9-ed2e-4742-8fa0-6fab5951c9f2%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.