Problems with ENUMS - AttributeError: Name

70 views
Skip to first unread message

Osman Seçmen

unread,
Jan 5, 2023, 11:44:11 AM1/5/23
to Google Ads API and AdWords API Forum
Hi !
I am getting such a weird error. I have been using this piece of code for almost a year and since 2 days it does not work. 

query = """
SELECT
campaign.status
FROM campaign_label
"""

CampaignStatus = client.get_type("CampaignStatusEnum").CampaignStatus
rows = batch.result etc etc

Then when I am iterating the rows: 
status=CampaignStatus.Name(row.campaign.status).      -> I get error on this line : AttributeError: Name
I get the same error for other enums as well like AdGroupStatusEnum or CampaignServingStatusEnum.

I am blocked in the middle of something.
Thanks in advance,
osman

Google Ads API and AdWords API Forum

unread,
Jan 6, 2023, 12:45:02 AM1/6/23
to Google Ads API and AdWords API Forum
Re-posting the last inquiry (https://groups.google.com/g/adwords-api/c/34HUpc3pMEs) from the forum as it wasn't routed to our support queue.

Kind regards,
Carmela
Google Ads API Team

Google Ads API and AdWords API Forum

unread,
Jan 6, 2023, 5:15:33 AM1/6/23
to Google Ads API and AdWords API Forum
Hi Osman,

Thank you for posting your concern.

You mentioned that you are getting a weird error. Having said that, provide the complete request and response logs with request ID and request header generated on your end so our team can provide guidance accordingly? If you haven't yet, logging can be enabled by navigating to the Client libraries > Your client library (ex. Java) > Logging documentation, which you can access from this link.

You may then send the requested logs via the Reply privately to author option. If this option is not available, you may send the details directly to our googleadsa...@google.com alias instead.

Regards,
Carmela
Google Ads API Team
On Friday, January 6, 2023 at 12:44:11 AM UTC+8 osman....@edreamsodigeo.com wrote:

Prabhat Kumar

unread,
Jan 6, 2023, 7:51:37 AM1/6/23
to adwor...@googlegroups.com, Prabhat Kumar, Sharad Chandel

--
--
=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~
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 adwor...@googlegroups.com
To unsubscribe from this group, send email to
adwords-api...@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 "Google Ads API and AdWords API Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adwords-api...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/adwords-api/425b32f9-11c1-423d-a41f-c9417074a040n%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages