New script experience: Bugs in sitelink association and change logs

179 views
Skip to first unread message

Lennart Spengler

unread,
Mar 22, 2022, 6:42:12 AM3/22/22
to Google Ads Scripts Forum
Hi all, 

I am encountering bugs when handling extensions in the new script experience.

I am running a script to create and (dis)associate Sitelinks in multiple accounts. I have followed the migration instructions for extensions in the new script experience.

For the ads scripts team: The script Id is 4702117, execution ID: 1318100044048192972, MCC: 609-659-5825, client account: 707-352-2859

The Code

Sitelink creation.png

Line 208 - associating the sitelink to the account - does not work. Unfortunately the error logs dont show any details about this: 
Sitelink Errors.png
I know that the error is the association, because I receive the Sitelink IDs of the new sitelink in a spreadsheet ("output" in line 205). Also, I see the sitelink in the Ads Editor (just not associated to the account).

Does someone have any answers to that? Why is the association failing? And why are the logs empty?

Btw, it is not just the error change logs that are empty, the logs of successful changes show no details either in the same script run: 

Empty Change Log.png

Any help / info from the ads scrips team would be greatly appreciated.

Best
Lennart

Google Ads Scripts Forum Advisor

unread,
Mar 23, 2022, 3:49:38 AM3/23/22
to adwords...@googlegroups.com
Hi Lennart,

Thank you for reporting this to us.

I've checked the CID 609-659-5825, and it appears that his account does not exist. Could you verify and confirm if this is the correct MCC CID? Also, I checked the client account CID 707-352-2859 and didn't find any script there, so I assume that the script in question is implemented on the MCC level. Could you share the script name as well, so I could further investigate?

Regards,
Google Logo
Teejay Wennie
Google Ads Scripts Team
 


ref:_00D1U1174p._5004Q2YqDvC:ref

Lennart Spengler

unread,
Mar 23, 2022, 10:55:12 AM3/23/22
to Google Ads Scripts Forum
Hi Teejay, 

my bad, copy & paste error: The MCC Id where the script lies is 609-659-1137. The script name is "[Entity X]_Extensions - Sitelinks Douglas".
 The client account I was referring to was just one of the accounts the script operated in and where the asset based sitelink got created, but not associated to the client account. 

An example of an asset based sitelink that was created but not associated is the one with ID 35143772473 in the account 707-352-2859

Best,
Lennart

Google Ads Scripts Forum Advisor

unread,
Mar 25, 2022, 3:50:58 AM3/25/22
to adwords...@googlegroups.com
Hi Lennart,

Thank you for providing the requested information. 

I've checked the script in question and I can confirm that its implementation is fine. As per your screenshot, you're getting "An error occurred. Please try again later" which usually occurs when there's an internal system error. Other publishers reported this as well, and later reported back that the issue is gone now. I've checked your script history and it appears that the reported issue does not occur anymore. What we can suggest is to monitor the script once again, and let us know if you encounter that error once again. Also, if you were able to reliably reproduce the issue with a simple script, kindly provide to us so we could further check.

Lennart Spengler

unread,
Mar 25, 2022, 10:55:19 AM3/25/22
to Google Ads Scripts Forum
Hi,

I have been monitoring this for about a week and it has not gone away. 
Take the code snippet below (taken straight from the documention) for example, it leads to the same problem: Creation is successful, association fails.
This script ran as "Association Test" in 427-329-9482 at 3:38pm today (25th March):

function main() {
  // For full details on creating a new sitelink extension, see:
  // https://developers.google.com/google-ads/scripts/docs/reference/adsapp/adsapp_sitelinkbuilder

  const newSitelink = AdsApp.extensions().newSitelinkBuilder()
      .withLinkText('Music')                          // required
      .withFinalUrl('http://www.douglas.de/')   // required
      .build()
      .getResult();

  // Add sitelink to an account
  const account = AdsApp.currentAccount();
  account.addSitelink(newSitelink);
}

Also this thread is reporting exactly the same issue as I am: https://groups.google.com/g/adwords-scripts/c/4rKCpG27tTk

I would be very happy about updates regarding this problem. 

Best
Lennart

Google Ads Scripts Forum Advisor

unread,
Mar 28, 2022, 6:07:16 AM3/28/22
to adwords...@googlegroups.com
Hi Lennart,

Thank you for reporting this to us.

I've checked this and can confirm the reported issue on my end as well. With that, let me share this to the rest of the team for further investigation. I'll update this thread the soonest the team provide their feedback.

Google Ads Scripts Forum Advisor

unread,
Apr 13, 2022, 3:49:07 AM4/13/22
to adwords...@googlegroups.com
Hi Lennart,

I hope you're safe and doing fine.

The team provided their feedback and mentioned that you may call build(false) as mentioned in the documentation: https://developers.google.com/google-ads/scripts/docs/features/ad-extensions-migration#update. This should force it to use asset-based extensions.

Lennart Spengler

unread,
Apr 13, 2022, 5:24:11 AM4/13/22
to Google Ads Scripts Forum
Hi Teejay, 

the problem was not forcing the creation of asset based extension using build(false), the problem was that the newly created asset-based extension did not get associated to the account / campaign / ad group. 
However I just did another check and it apparently got resolved now. The asset based sitelink do get associated to the account without errors. 

Still, as a general feedback, the transition to new script experience has been anything but smooth. Especially emailing everyone to migrate their scripts which deal with extensions to the new experience while the new experience was still very much in beta caused a lot of headache. 

Best
Lennart

Google Ads Scripts Forum Advisor

unread,
Apr 18, 2022, 4:31:27 AM4/18/22
to adwords...@googlegroups.com
Hi Lennart,

Thank you for updating us and I'm glad that the issue has been resolved. In addition, I would like to expressed my gratitude with regard to your feedback for Google Ads Scripts New experience. I understand that there is indeed a bit of a learning curve in setting up your script into new experience, much more for migrating your existing script which still uses the legacy version. That being said, do kindly note that we always do strive to improve our script with each update, in our efforts to slowly make it more flexible to all our users. We recommend to keep an eye on our blog regarding this.
Reply all
Reply to author
Forward
0 new messages