"An invalid API response was returned" - I get this error but only on the production server. Not locally

As the title says i get this error only on the production server but locally it seems to run fine.

I have tested to see if the production server has the correct repo name and endpoint and everything seems fine.

How can i debug this issue? The error doesnt provide much details.

Error: An invalid API response was returned
    at Client.fetch (file:///workspace/node_modules/@prismicio/client/dist/index.js:564:11)
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async Client.get (file:///workspace/node_modules/@prismicio/client/dist/index.js:278:12)
    at async Client.getByType (file:///workspace/node_modules/@prismicio/client/dist/index.js:339:12)
    at async Promise.all (index 1)
    at async file:///workspace/index.js:121:45```

Thanks

PS. Also this happened today. Yesterday it was working fine.

Update 1: I forked the pricmic client to add some console logs and its seems the response is this {"size":0}
Is it possible to be a problem with node-fetch?

Update 2: I destroyed the digital ocean app and recreated it in a different region (Frankfurt) and the problem was solved. so i guess it had something to do with the CDN or the network in general. Close as solved.

Hello @akumanara

Thanks for updating the thread. Let us know if you get any other trouble.

Priyanka