Skip to content

Build Fails Due to JavaScript Heap Out of Memory and Missing deploy-manifest.json in Amplify Deployment #16304

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
3 tasks done
husamMousa opened this issue May 15, 2025 · 3 comments

Comments

@husamMousa
Copy link

Is there an existing issue for this?

How do you use Sentry?

Sentry Saas (sentry.io)

Which SDK are you using?

@sentry/browser

SDK Version

^8.26.0

Framework Version

@sentry/nuxt: 9.17.0 Nuxt: 3.16.2

Link to Sentry event

No response

Reproduction Example/SDK Setup

export default defineNuxtConfig({
  modules: ['@sentry/nuxt/module'],
  ssr: false,
  sourcemap: {client: 'hidden'}
  sentry: {
     sourceMapsUploadOptions: {
        authToken: "my-auth-token",
        org: "my-org",
        project: "my-project-name",
      }
  }
})

Steps to Reproduce

  • Push a commit that includes source map support using @sentry/nuxt on a branch connected to AWS Amplify.
  • Let Amplify auto-trigger its build pipeline.
  • The frontend build phase starts (e.g. pnpm build).
  • During nuxt build, the memory usage spikes and the process fails with a fatal JavaScript heap out of memory error.
  • Even though the build log shows "Build completed successfully", the deployment fails due to a missing deploy-manifest.json.

Expected Result

  • Nuxt build should complete without exceeding memory limits.
  • Source maps should be uploaded successfully.
  • deploy-manifest.json should be created in the expected output directory.
  • The deployment should succeed.

Actual Result

  • Nuxt build fails with:
    FATAL ERROR: Reached heap limit Allocation failed - JavaScript heap out of memory

  • Followed by:
    CustomerError: Failed to find the deploy-manifest.json file in the build output.

  • This only happens when sourcemaps.enable = true in the Sentry module config.

@andreiborza
Copy link
Member

Hi @husamMousa, thanks for writing in and sorry to see you experiencing issues during builds.

Could you try to disable source maps in your nuxt config: sourcemap: false and see if you're still running out of memory?

I'm not familiar with AWS amplify, is there an option to increase the available memory?

@husamMousa
Copy link
Author

husamMousa commented May 17, 2025

Hi @andreiborza, thank you for your reply.

I previously tried setting sourcemap to false. The build succeeded, but the sourcemap wasn't generated.

I also increased the memory size, but the problem persists.

@getsantry getsantry bot moved this to Waiting for: Product Owner in GitHub Issues with 👀 3 May 17, 2025
Copy link
Member

mydea commented May 19, 2025

This is possibly related to #13836 🤔
Can you tell us what the memory is that is configured? And how large are your largest build output files?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: No status
Development

No branches or pull requests

3 participants