Build error with status code 502

Attempting to build a site but continue to get the error below:

9:14:28 AM: success Building production JavaScript and CSS bundles — 15.944 s
9:14:28 AM: success Rewriting compilation hashes — 0.001 s
9:14:29 AM: error UNHANDLED REJECTION
9:14:29 AM:
9:14:29 AM: Error: Request failed with status code 502
9:14:29 AM:
9:14:29 AM: - createError.js:16 createError
9:14:29 AM: [repo]/[axios]/lib/core/createError.js:16:15
9:14:29 AM:
9:14:29 AM: - settle.js:17 settle
9:14:29 AM: [repo]/[axios]/lib/core/settle.js:17:12
9:14:29 AM:
9:14:29 AM: - http.js:237 IncomingMessage.handleStreamEnd
9:14:29 AM: [repo]/[axios]/lib/adapters/http.js:237:11
9:14:29 AM:
9:14:29 AM: - next_tick.js:63 process._tickCallback
9:14:29 AM: internal/process/next_tick.js:63:19

Any help or advice would be greatly appreciated.

Thanks!

Hey, welcome to the forum :slight_smile:

I need a bit more information to understand what might be going on.

  • Are you getting this error locally or just when you deploy?
  • This looks like a truncated build log- could you include the full log and your Netlify site name?

On first glance, I can tell you that the 502 HTTP code means “bad gateway” and suggests that there may be a typo somewhere that means your build isn’t properly compiling, but again without more info, it’s hard to know where.

Let me know how this goes and if we can help further!