Error 500 occurring on all recent deployments

My Netlify site name is tangerine-brigadeiros-22bc72.netlify.app

I suddenly started getting an Error 500 on my site. This only started happening with recent deployments. There were no errors in the deploy summary or log. My site is working fine locally.

I even tried deleting my site, creating a new site, and deploying a version that had previously worked, but I still get the same error. I’m inclined to think it’s an issue on Netlify’s side.

This is what I see in the function log:

Sep 30, 04:39:05 PM: INIT_START Runtime Version: nodejs:18.v45	Runtime Version ARN: arn:aws:lambda:us-east-2::runtime:caaaaaad39c95ea5432b566032fcb4c52ccafa384d8995e8d38ff3beb67d2bea
Sep 30, 04:39:06 PM: 0a32bafd ERROR  20:39:06 [ERROR] TypeError: this.middleware is not a function
    at AppPipeline.getMiddleware (file:///var/task/node_modules/.pnpm/astro@4.15.9_typescript@5.6.2/node_modules/astro/dist/core/base-pipeline.js:51:45)
    at RenderContext.create (file:///var/task/node_modules/.pnpm/astro@4.15.9_typescript@5.6.2/node_modules/astro/dist/core/render-context.js:60:47)
    at App.render (file:///var/task/node_modules/.pnpm/astro@4.15.9_typescript@5.6.2/node_modules/astro/dist/core/app/index.js:216:49)
    at async Module.handler (file:///var/task/node_modules/.pnpm/@astrojs+netlify@5.5.3_astro@4.15.9/node_modules/@astrojs/netlify/dist/ssr-function.js:34:30)
    at async Runtime.handler (file:///var/task/___netlify-bootstrap.mjs:2:27991)
    at async Runtime.handleOnceStreaming (file:///var/runtime/index.mjs:1206:26)
Sep 30, 04:39:06 PM: 0a32bafd Duration: 969.7 ms	Memory Usage: 0 MB

Thanks!

Hi @standardnote

Thank you for reporting this! We’re working with the Astro team on a fix.

We’ll share an update here when the fix is released. In the meantime, you can use astro@4.15.8 as a workaround, as it looks like this regression was introduced in 4.15.9.

Thanks again!

1 Like

To close the loop here: this was fixed in astro@4.15.11 so you no longer need to pin to an older version.