CF Pages Error

I’ve been hitting an error while deploying my hugo site to CF Pages. The deployment ID is: f4dc09c6-99e9-4acf-ade5-878a3c83a83d

Here’s the deployment error log:

09:22:37.124    Uploading... (6850/13645)
09:22:43.013    /opt/pages/build_tool/js/node_modules/wrangler/wrangler-dist/cli.js:29573
09:22:43.013                throw a;
09:22:43.013                ^
09:22:43.013    
09:22:43.013    FatalError: Failed to upload files. Please try again. Error: {"text":"Received a malformed response from the API","notes":[{"text":"<!DOCTYPE html>\n<!--[if lt IE 7]> <html class=\"no-js ie6 oldie\" lang=\"en-US\"> <![endif]-->\n<!--[if I... (length = 7177)"},{"text":"POST /pages/assets/upload -> 524 "}],"kind":"error","name":"APIError"})
09:22:43.013        at /opt/pages/build_tool/js/node_modules/wrangler/wrangler-dist/cli.js:149152:13
09:22:43.013        at processTicksAndRejections (node:internal/process/task_queues:96:5)
09:22:43.013        at async run (/opt/pages/build_tool/js/node_modules/wrangler/wrangler-dist/cli.js:148676:26) {
09:22:43.013      code: 1
09:22:43.014    }
09:22:43.068    Failed: upload process exited with code: 7
09:22:44.725    Failed: error uploading static assets. Check the logs above for more information. If this continues for an unknown reason, contact support: https://cfl.re/3WgEyrH
09:22:44.725    Error: Failed to publish assets. For support, join our Discord (https://discord.gg/cloudflaredev) or create a ticket and reference the deployment ID: f4dc09c6-99e9-4acf-ade5-878a3c83a83d

Can anyone help me solve why this is happening?

Hi there,

Checking your deployments, it seems you had a few successful 8 days ago, then a succession of failed ones 4 days ago after a few changes.
I would advise you to go back to your latest successful build, check what changed since then and start from there.

Take care.

I tried reverting back already and it failed on
CF Pages.

FWIW, the GitHub repo deploys fine on my local Hugo server as well as netlify.

Thanks for your help!