bradjasper / ImportJSON

Import JSON into Google Sheets, this library adds various ImportJSON functions to your spreadsheet
GNU Lesser General Public License v3.0
2.11k stars 1.06k forks source link

Error - "Unknown function: ImportJSON" #146

Open andersjohansenn opened 4 years ago

andersjohansenn commented 4 years ago

Hello.

I use ImportJSON to update my Facebook Catalog and Google Ads data feed, but from time to time (1-2 times a week) I get an "unknown function" error.

It is not a huge problem, as it gets solved by clearing the sheet and undoing the clearing.

But is there any way to stop this from happening?

Screenshot 2020-01-09 at 07 56 18

Please see attached SS for details.

krijnsent commented 4 years ago

Hi Anders, from what I can find it's a problem of Google Sheets, not of the custom function. On Stackoverflow I found: -Clearing cookies seemed to do the trick. -Hard refresh + clearing cache fixed it. I have no clue how either of those solutions could be automated. Next time you bump into it, please file a bug with Google -> in sheets: Help->Report a problem. Cheers, Koen

andersjohansenn commented 4 years ago

Hello @krijnsent, thank you for the tips.

Unfortunately I have already tried them earlier without any success. To me it seems like the issue is related to Sheets not being able to load the script properly, maybe due to the size of it.

The reason I suggest size being the issue is that I have removed all comments from the script, and found the script to be much more stable.

This can obviously be a coincidence, but if anyone else has similar issues I would suggest trying the same.