Script gets stuck
Hi, Mike!
Thanks for the great work.
The individual account script is getting stuck on some of my accounts, not finishing all the actions. I’ve been playing with lowering number of days of report and other options, reading through documentation, but no luck.
Here is the example of logs(I’ve removed URL link not to get it public):
/10/7/2025 4:22:13 AMStarting the PMax Insights script.10/7/2025 4:22:20 AMSettings: {"numberOfDays":30,"tCost":10,"tRoas":4,"brandTerm":"musclebooster, muscle booster","accountType":"leadgen","aiTemplate":"1Lduw...","dgTemplate":"1ohhf...","whispererUrl":"","dgUrl":"1Lllj...","aiRunAt":1,"lotsProducts":2,"campFilter":"","turnonLP":false,"turnonPlace":false,"turnonGeo":false,"turnonChange":false,"turnonAISheet":true,"turnonTitleCampaign":false,"turnonTitleID":false,"turnonIDChannel":false,"turnonDemandGen":true,"sheetVersion":"s88","scriptVersion":"v88.2","minPlaceImpr":"300","ident":"MB Web","minLpImpr":50,"topCampaign":"no PMax campaigns found","apiKey":"","anth_apikey":"","ssUrl":"https://docs.google.com/spreadsheets/d/ 4:22:20 AMGreat work! You're using the latest versions. Script: v88.2, Sheet: s8810/7/2025 4:22:20 AMFetching campaign data. This may take a few moments.10/7/2025 4:22:21 AMFetching campaign data. This may take a few moments.10/7/2025 4:30:25 AMCampaign data fetched in 484.65 seconds10/7/2025 4:30:25 AMStarting data processing.10/7/2025 4:30:25 AMStarting data processing.10/7/2025 4:30:51 AMData processing completed in 25.86 seconds10/7/2025 4:30:51 AMWriting data to sheets.10/7/2025 4:30:51 AMWriting data to sheets.10/7/2025 4:32:55 AMData writing to sheets completed.10/7/2025 4:33:00 AMSheet writing completed in 128.86 seconds10/7/2025 4:33:00 AMStarting Demand Gen processing.10/7/2025 4:33:00 AMStarting Demand Gen processing.10/7/2025 4:37:08 AMThe JavaScript runtime exited unexpectedly.
Sometimes it’s just getting stuck for a really long time with no error message:
Sometimes in non-review mode I would get(yes, a single line):
10/6/2025 6:57:46 PMExceeded maximum execution time