Skip to content

Sentry Vite Plugin reactComponentAnnotation causes Javascript Heap OOM #638

Closed
@mikehuebner

Description

@mikehuebner

Environment

  • @sentry/vite-plugin -> ^2.22.7
  • vite -> 6.0.3
  • node -> 22.0.0

Steps to Reproduce

Build application with the following configuration

export default defineConfig({
  // ...
  plugins: [
    // ...
    sentryVitePlugin({
      org: 'cool-org-name',
      project: 'cooler-project-name',
      release: { name: `cooler-project-name@${Package.version}` },
      silent: true,
      reactComponentAnnotation: {
        enabled: true,
      },
    }),
  ]
});

Expected Result

A normal build, was working fine before the update to 2.22.7 I believe.

Actual Result

FATAL ERROR: Reached heap limit Allocation failed - JavaScript heap out of memory

Things I've Tried

Adding NODE_OPTIONS="--max_old_space_size=8192" - can keep increasing as our runners use --max_old_space_size=10240

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    Status

    Waiting for: Community

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions