Upload Click Conversions: Assignment not allowed to repeated field "conversions" in protocol message object.

172 views
Skip to first unread message

panu.kuu...@hopkins.fi

unread,
Jan 6, 2022, 1:14:16 PM1/6/22
to AdWords API and Google Ads API Forum
Upload Click Conversions 


The code example in Python seems to have an issue. 

request.conversions = [click_conversion] returns an error:

AttributeError: Assignment not allowed to repeated field "conversions" in protocol message object.

If have tried request.conversion.append(click_conversion) but I think that leads to a malformed request.

Anyone got any idea how I could get request.conversions = [click_conversion]  to work?

Thank you!

Google Ads API Forum Advisor

unread,
Jan 6, 2022, 5:38:58 PM1/6/22
to panu.kuu...@hopkins.fi, adwor...@googlegroups.com
Hi Panu,

Thanks for reaching out. Can you please privately reply with your complete request and response logs so that we can take a look at the error? 

Thanks,
Matt
Google Ads API Team

Google Logo
Matt
Google Ads API Team
 


ref:_00D1U1174p._5004Q2UhGsY:ref

panu.kuu...@hopkins.fi

unread,
Jan 6, 2022, 6:06:40 PM1/6/22
to AdWords API and Google Ads API Forum
Hi Matt,

thanks for reaching out so quickly. I have sent you a private message.

Best
Panu

Google Ads API Forum Advisor

unread,
Jan 6, 2022, 10:03:47 PM1/6/22
to panu.kuu...@hopkins.fi, adwor...@googlegroups.com
Hi Panu,

Thank you for sharing the details privately.

Upon checking, the error appears to be more related to the client library. That said, I would recommend that you reach out instead to the Python client library owners via this link, as they should be more equipped to provide guidance on this issue.

Best regards,

Google Logo
Peter Laurence Napa Oliquino
Google Ads API Team
 


ref:_00D1U1174p._5004Q2UhGsY:ref

panu.kuu...@hopkins.fi

unread,
Jan 11, 2022, 8:57:29 AM1/11/22
to Google Ads API and AdWords API Forum
Thanks will do. 

panu.kuu...@hopkins.fi

unread,
Jan 12, 2022, 4:58:02 AM1/12/22
to Google Ads API and AdWords API Forum
Solution:

request.conversions.append(click_conversion)
request.partial_failure = True
conversion_upload_response = (
conversion_upload_service.upload_click_conversions(
request=request,
)
)
request.conversions[:0]
Reply all
Reply to author
Forward
0 new messages